Forráskód Böngészése

订单管理、发货单、收支凭证列表增加经销商编码字段

hu 2 éve
szülő
commit
cb3dbe497f

+ 4 - 2
src/custom/restcontroller/webmanage/sale/order/SQL/订单_列表.sql

@@ -21,14 +21,16 @@ SELECT t1.sa_orderid,
        t4.county,
        t4.address,
        t4.phonenumber,
-        t6.projectname
+        t6.projectname,
+        t7.agentnum
     FROM sa_order t1
          LEFT JOIN sys_enterprise t2
                    ON t2.sys_enterpriseid = t1.sys_enterpriseid and t2.siteid = t1.siteid
          LEFT JOIN sa_brand t3 ON t3.sa_brandid = t1.sa_brandid
          LEFT JOIN sys_enterprise_contacts t4 ON t4.contactsid = t1.rec_contactsid and t4.siteid = t1.siteid
          LEFT JOIN sys_hr t5 on t5.hrid = t1.saler_hrid and t5.siteid = t1.siteid
-        left join sa_project t6 on t6.sa_projectid=t1.sa_projectid and t6.siteid = t1.siteid
+         left join sa_project t6 on t6.sa_projectid=t1.sa_projectid and t6.siteid = t1.siteid
+         left join sa_agents t7 on t7.sys_enterpriseid=t1.sys_enterpriseid and t7.siteid = t1.siteid
 where t1.siteid = $siteid$
   and $where$
   and t1.type!='工具借用单'