|
|
@@ -871,7 +871,7 @@ select t.HASWR,
|
|
|
on t.wrtradeorderid = mr.wrtradeorderid
|
|
|
left join taaccount ta
|
|
|
on t.accountid = ta.accountid
|
|
|
- where t.WRTRADETYPE = 1 and t.WRTRADEORDERSTATUS not in(2)
|
|
|
+ where t.WRTRADETYPE = 1 and t.WRTRADEORDERSTATUS not in(2) and t.isvaliddata=1
|
|
|
`
|
|
|
sqlId.And("t.USERID", r.USERID)
|
|
|
sqlId.And("t.haswr", r.HASWR)
|
|
|
@@ -1031,7 +1031,7 @@ func (r *WrTradeDetail) buildSqlHis() string {
|
|
|
" left join taaccount ta1 on t.accountid=ta1.accountid" +
|
|
|
" left join taaccount ta2 on t.matchaccountid=ta2.accountid" +
|
|
|
" left join useraccount u2 on ta2.userid=u2.userid" +
|
|
|
- " where 1=1"
|
|
|
+ " where 1=1 and t.isvaliddata=1"
|
|
|
sqlId.And("ta1.userid", r.USERID)
|
|
|
sqlId.And("t.haswr", r.HASWR)
|
|
|
sqlId.AndEx("t.marketid", r.MARKETID, r.MARKETID > 0)
|
|
|
@@ -2960,7 +2960,7 @@ select t.xgoodsid,
|
|
|
on w.wrstandardid = wd.wrstandardid
|
|
|
left join warehouseinfo h on w.warehouseid=h.autoid
|
|
|
left join enumdicitem e on wd.unitid=e.enumitemname and e.enumdiccode='goodsunit'
|
|
|
- where 1 = 1
|
|
|
+ where 1 = 1 and t.isvaliddata = 1
|
|
|
`
|
|
|
sqlId.AndEx("u.userid", r.USERID, r.USERID > 0)
|
|
|
sqlId.AndEx("t.accountid", r.ACCOUNTID, r.ACCOUNTID > 0)
|
|
|
@@ -3865,7 +3865,7 @@ SELECT to_char(t.WRBARGAINID) WRBARGAINID,
|
|
|
LEFT JOIN HIS_WRTRADE_ORDERDETAIL o on t.wrtradeorderid=o.wrtradeorderid
|
|
|
LEFT JOIN tmp on o.wrfactortypeid=tmp.wrfactortypeid
|
|
|
LEFT JOIN PERFORMANCEPLANTEMPLATE p on o.performancetemplateid=p.autoid
|
|
|
- WHERE 1 = 1
|
|
|
+ WHERE 1 = 1 and t.isvaliddata = 1
|
|
|
`
|
|
|
sqlId.AndEx("t.userid", r.USERID, r.USERID > 0)
|
|
|
sqlId.AndEx("t.matchuserid", r.MATCHUSERID, r.MATCHUSERID > 0)
|