Selaa lähdekoodia

商品组管理端添加查询内容

hu 2 vuotta sitten
vanhempi
commit
d35f90ea74

+ 4 - 1
src/custom/restcontroller/webmanage/sale/itemgroup/itemgroup.java

@@ -127,7 +127,10 @@ public class itemgroup extends Controller {
 
             if (whereObject.containsKey("condition") && !"".equals(whereObject.getString("condition"))) {
                 where = where + " and (t1.groupname like'%" + whereObject.getString("condition")
-                        + "%' or t1.groupnum like'%" + whereObject.getString("condition") + "%') ";
+                        + "%' or t1.groupnum like'%" + whereObject.getString("condition")
+                        + "%' or exists(select 1 from sa_itemgroupmx s1 left join plm_item s2 on s1.itemid=s2.itemid and  s1.siteid=s2.siteid where (s2.itemname like '%"
+                        + whereObject.getString("condition") + "%' or s2.itemno like '%" + whereObject.getString("condition")
+                        + "%') and s1.sa_itemgroupid=t1.sa_itemgroupid) ) ";
             }
             if (whereObject.containsKey("brandname") && !"".equals(whereObject.getString("brandname"))) {
                 where = where + " and (t3.brandname ='" + whereObject.getString("brandname") + "') ";