|
|
@@ -249,7 +249,7 @@ func (r *ErmcpModel) buildSql(nContractType, nQueryType int32) string {
|
|
|
" end) unsureqty," +
|
|
|
" t.reckonedamount PayAmount," +
|
|
|
" t.invoiceamount," +
|
|
|
- " (t.pricedamount + t.pricedqty * t.pricemove + t.RECKONADJUSTAMOUNT + t.RECKONOTHERAMOUNT -" +
|
|
|
+ " (t.pricedamount + t.RECKONADJUSTAMOUNT + t.RECKONOTHERAMOUNT -" +
|
|
|
" t.invoiceamount) as daikaiAmount," +
|
|
|
" to_char(t.startdate, 'yyyy-mm-dd hh24:mi:ss') startdate," +
|
|
|
" to_char(t.enddate, 'yyyy-mm-dd hh24:mi:ss') enddate," +
|
|
|
@@ -278,8 +278,8 @@ func (r *ErmcpModel) buildSql(nContractType, nQueryType int32) string {
|
|
|
" gm.modelname," +
|
|
|
" e.enumdicname," +
|
|
|
" t.contracttype," +
|
|
|
- " t.pricedamount + t.pricedqty * t.pricemove as pricedamount," +
|
|
|
- " case when t.pricedqty > 0 then (t.pricedamount + t.pricedqty * t.pricemove)/t.pricedqty else 0 end pricedAvg," +
|
|
|
+ " t.pricedamount," +
|
|
|
+ " case when t.pricedqty > 0 then (t.pricedamount)/t.pricedqty else 0 end pricedAvg," +
|
|
|
" t.ReckonRealQty," +
|
|
|
" t.ReckonOtherAmount," +
|
|
|
" t.ReckonAdjustAmount," +
|
|
|
@@ -287,7 +287,7 @@ func (r *ErmcpModel) buildSql(nContractType, nQueryType int32) string {
|
|
|
" t.ReckonedAmount," +
|
|
|
" to_char(t.audittime,'yyyy-mm-dd hh24:mi:ss') audittime," +
|
|
|
" to_char(t.createtime,'yyyy-mm-dd hh24:mi:ss') createtime," +
|
|
|
- " t.pricedamount + t.pricedqty * t.pricemove + t.ReckonAdjustAmount as LoanAmount" +
|
|
|
+ " t.pricedamount + t.ReckonAdjustAmount as LoanAmount" +
|
|
|
" from ermcp_spotcontract t" +
|
|
|
" left join useraccount u" +
|
|
|
" on t.%v = u.userid" +
|