lvhao 11 timmar sedan
förälder
incheckning
7e43fffb40
1 ändrade filer med 3 tillägg och 1 borttagningar
  1. 3 1
      core/CoreApp/controllers/Warehouse.php

+ 3 - 1
core/CoreApp/controllers/Warehouse.php

@@ -1709,6 +1709,7 @@ class Warehouse extends Start_Controller {
 			}
 			foreach ($userwh as $value) 
 		    {
+				if($value === '' || $value === null) continue;
 				$wid .= " id = ".$value." or";
 				$wtype .= " type = ".$value." or";
 			}
@@ -1918,6 +1919,7 @@ class Warehouse extends Start_Controller {
 			}
 			foreach ($userwh as $value) 
 		    {
+				if($value === '' || $value === null) continue;
 				$wid .= " id = ".$value." or";
 				$wtype .= " type = ".$value." or";
 			}
@@ -2172,7 +2174,7 @@ class Warehouse extends Start_Controller {
             {
                 $where  .= " and shop = '$shop'";
             }
-			if(!empty($type))
+			if($type)
             {
 				$where  .= " and type = '$type'";
 			}