|
@@ -161,10 +161,7 @@
|
|
|
a1.LOCKMARK,
|
|
|
a1.HASCONFLICT,
|
|
|
a1.CONFLICTDES,
|
|
|
- (select CUSTOMERABBREVIATION from aps_customer_management where ID =
|
|
|
- IF(IFNULL(a5.MERGEORDERNUMBER,'')='',a6.CUSTOMID,(select CUSTOMID from aps_production_merge_order where
|
|
|
- ORDERNO=a5.MERGEORDERNUMBER ) )
|
|
|
- and DELETED ='0') AS CUSTOMERABBREVIATION,
|
|
|
+ (select CUSTOMERABBREVIATION from aps_customer_management where ID = a6.CUSTOMID and DELETED ='0') AS CUSTOMERABBREVIATION,
|
|
|
a1.ID,
|
|
|
a3.ID AS blankOrderId,
|
|
|
a6.ID AS productionorderid,
|
|
@@ -197,8 +194,6 @@
|
|
|
LEFT JOIN (select GROUP_CONCAT(PRODUCTNAME)as PRODUCTNAME,GROUP_CONCAT(PRODUCTID) AS PRODUCTID,BLANKID from
|
|
|
aps_process_output_product where DELETED='0' group by BLANKID) a4 ON a3.ID = a4.BLANKID
|
|
|
LEFT JOIN aps_production_order a6 ON a6.ID = a3.PRODUCTIONORDERID
|
|
|
- LEFT JOIN (select MAINID,GROUP_CONCAT(DISTINCT MERGEORDERNUMBER) MERGEORDERNUMBER from aps_product_detail WHERE
|
|
|
- DELETED='0' group by MAINID) a5 ON a6.ID = a5.MAINID
|
|
|
LEFT JOIN aps_customer_management a7 on a6.CUSTOMID= a7.ID
|
|
|
left join asp_check_items b on a1.PROCESSDEVICEID =b.ID
|
|
|
left join sys_dict c on c.DICTTYPE='asp_check_item_type' AND b.CHECKITEMTYPE =c.VALUE
|