|
|
@@ -542,6 +542,9 @@ public class dispatch extends Controller {
|
|
|
if (isrecheck) {
|
|
|
sqlFactoryupdate = new SQLFactory(this, "发货单复核");
|
|
|
Rows orderRows =dbConnect.runSqlQuery("select distinct t1.sa_orderid from sa_orderitems t1 inner join sa_dispatch_items t2 on t1.siteid=t2.siteid and t1.sa_orderitemsid=t2.sa_orderitemsid where t1.siteid='" + siteid + "' and t2.sa_dispatchid=" + sa_dispatchid);
|
|
|
+ if(orderRows.size()==1){
|
|
|
+ sqlList.add("update sa_dispatch set sa_orderid="+orderRows.get(0).getLong("sa_orderid")+" where siteid='" + siteid + "' and sa_dispatchid=" + sa_dispatchid);
|
|
|
+ }
|
|
|
//对接erp生成erp发货单
|
|
|
if (Parameter.get("system.ccerp_dockswitch").equalsIgnoreCase("true")) {
|
|
|
ERPDocking erpDocking =new ERPDocking();
|