Better error log

This commit is contained in:
Laurent Destailleur 2023-05-16 18:49:22 +02:00
parent eac41d195d
commit c2e386e2b5

View file

@ -71,7 +71,12 @@ if ($action == 'getProducts') {
$object = new Categorie($db);
if ($category == "supplements") {
$category = getDolGlobalInt('TAKEPOS_SUPPLEMENTS_CATEGORY');
if (empty($category)) {
echo 'Error, the category to use for supplements is not defined. Go into setup of module TakePOS.';
exit;
}
}
$result = $object->fetch($category);
if ($result > 0) {
$filter = array();