瀏覽代碼

点选交收选不到问题

deng.yinping 2 年之前
父節點
當前提交
288a3e1815
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      models/wrTrade2.go

+ 1 - 1
models/wrTrade2.go

@@ -3692,7 +3692,7 @@ select a.*,
   from (select t.accountid,
                t.goodsid,
                t.wrstandardid,
-               t.inqty - t.cancelqty - t.deliveryqty - p.buycurpositionqty as uqty,
+               t.inqty - nvl(t.cancelqty,0) - nvl(t.deliveryqty,0) - nvl(p.buycurpositionqty,0) as uqty,
                hl.qty - hl.freezerqty qty,
                to_char(hl.wrfactortypeid) wrfactortypeid,
                to_char(hl.ladingbillid) ladingbillid,