|
|
@ -108,7 +108,7 @@ func CustProduct(conf *config.EnvConfig) { |
|
|
|
oemorders = append(oemorders, v.Oemseq) |
|
|
|
} |
|
|
|
//状态必须都是80,时间是14天以前的客户订单(并且预留1000个oemseq订单)
|
|
|
|
err = e.Table("pln_custorder").Join("INNER", "pln_calloffdata_landing", "pln_calloffdata_landing.finr = pln_custorder.finr and pln_calloffdata_landing.calloffnr = pln_custorder.calloffnr").NotIn("pln_custorder.oemordernr", oemorders).NotIn("pln_custorder.custordernr", custorders).Where("pln_custorder.status = ? and pln_custorder.credatuz <= ? and pln_calloffdata_landing.parsed = ?", common.CO_STATUS_CLOSED, oneWeekStr, 1).Desc("pln_custorder.oemseq").Limit(10).Find(&data) |
|
|
|
err = e.Table("pln_custorder").Join("INNER", "pln_calloffdata_landing", "pln_calloffdata_landing.finr = pln_custorder.finr and pln_calloffdata_landing.calloffnr = pln_custorder.calloffnr").NotIn("pln_custorder.oemordernr", oemorders).NotIn("pln_custorder.custordernr", custorders).Where("pln_custorder.status = ? and pln_custorder.calloffswet <= ? and pln_calloffdata_landing.parsed = ?", common.CO_STATUS_CLOSED, oneWeekStr, 1).Desc("pln_custorder.oemseq").Limit(10).Find(&data) |
|
|
|
if err != nil { |
|
|
|
glog.InfoExtln("调度生成终止", "err : ", err) |
|
|
|
return |
|
|
|