|
|
@@ -637,7 +637,7 @@ public class OrderItems extends Controller {
|
|
|
QuerySQL querySQL = SQLFactory.createQuerySQL(this, "sa_orderitems", "*");
|
|
|
querySQL.setTableAlias("t1");
|
|
|
querySQL.addJoinTable(JOINTYPE.left, "st_invbal_sale", "t2", "t2.siteid = t1.siteid AND t2.itemid = t1.itemid", "cansaleqty", "candispatchqty");
|
|
|
- querySQL.addJoinTable(JOINTYPE.left, "plm_item", "t3", "t3.itemid = t1.itemid and t3.siteid = t1.siteid", "orderminqty_auxunit", "orderaddqty_auxunit", "spec", "iscustomsize", "widthschemeid", "lengthschemeid", "standards", "k3outcode","outplace");
|
|
|
+ querySQL.addJoinTable(JOINTYPE.left, "plm_item", "t3", "t3.itemid = t1.itemid and t3.siteid = t1.siteid", "orderminqty_auxunit", "orderaddqty_auxunit", "spec", "iscustomsize", "widthschemeid", "lengthschemeid", "standards", "k3outcode","outplace","aftersalesitemno");
|
|
|
if (sa_promotionid > 0) {
|
|
|
querySQL.addJoinTable(JOINTYPE.left, "sa_promotion_items", "t4", "t4.sa_promotion_itemsid = t1.sa_promotion_itemsid and t4.siteid = t1.siteid and t4.sa_promotionid=" + sa_promotionid, "packagetypemx", "saledqty", "groupqty");
|
|
|
}
|
|
|
@@ -673,6 +673,8 @@ public class OrderItems extends Controller {
|
|
|
querySQL.addQueryFields("machineitemname", "t7.itemname");
|
|
|
querySQL.addQueryFields("machinemodel", "t7.model");
|
|
|
querySQL.addQueryFields("machinespec", "t7.spec");
|
|
|
+ querySQL.addQueryFields("warrantystatus", "CASE WHEN ifnull(t6.enddate,'')='' then '' else CASE WHEN t6.enddate >= CURDATE() THEN '保内' ELSE '保外' END end");
|
|
|
+
|
|
|
}
|
|
|
|
|
|
querySQL.setCondition("t1.itemno", "t1.itemname", "t1.model", "t3.spec", "t1.remarks");
|
|
|
@@ -752,6 +754,7 @@ public class OrderItems extends Controller {
|
|
|
} else {
|
|
|
row.put("cover", "");
|
|
|
}
|
|
|
+
|
|
|
}
|
|
|
return getSucReturnObject().setData(rows).toString();
|
|
|
}
|