|
|
@@ -1702,61 +1702,61 @@ func (r *QhjAccountOutInApply) calc() {
|
|
|
}
|
|
|
|
|
|
func (r *QhjAccountOutInApply) buildSql() string {
|
|
|
- var sqlId utils.SQLVal = "with tmp as(select t.userid, wm_concat(t.logincode) logincode from loginaccount t group by t.userid)" +
|
|
|
- "SELECT t.EXECUTETYPE," +
|
|
|
- " t.AMOUNT," +
|
|
|
- " t.CURRENCY," +
|
|
|
- " t.CHARGE," +
|
|
|
- " t.ACCOUNTPWD," +
|
|
|
- " to_char(t.UPDATETIME, 'yyyy-mm-dd hh24:mi:ss') UPDATETIME," +
|
|
|
- " t.BANKID," +
|
|
|
- " t.BRANCHBANKID," +
|
|
|
- " t.BRANCHBANKNAME," +
|
|
|
- " t.BANKACCOUNTNO," +
|
|
|
- " t.BANKACCOUNTNAME," +
|
|
|
- " t.EXTENDINFO," +
|
|
|
- " t.AUDITID," +
|
|
|
- " to_char(t.AUDITTIME, 'yyyy-mm-dd hh24:mi:ss') AUDITTIME," +
|
|
|
- " t.REMARK," +
|
|
|
- " t.NETADDR," +
|
|
|
- " t.ACCOUNTTICKET," +
|
|
|
- " t.CHECKERRORFLAG," +
|
|
|
- " t.REMARK2," +
|
|
|
- " t.REAUDITID," +
|
|
|
- " to_char(t.REAUDITTIME, 'yyyy-mm-dd hh24:mi:ss') REAUDITTIME," +
|
|
|
- " t.REAUDITREMARK," +
|
|
|
- " t.APPLYREMARK," +
|
|
|
- " t.RELATEDORDERID," +
|
|
|
- " t.CAPAMOUNTOUT," +
|
|
|
- " t.INFAMOUNT," +
|
|
|
- " t.PRIAMOUNT," +
|
|
|
- " t.BANK_APPLY_TICKET," +
|
|
|
- " to_char(t.CERTIFICATEPHOTOURL) CERTIFICATEPHOTOURL," +
|
|
|
- " t.SOUCREAMOUNT," +
|
|
|
- " t.SOUCRECURRENCYID," +
|
|
|
- " t.ACCOUNTCODE," +
|
|
|
- " t.CUSBANKID," +
|
|
|
- " t.TRADEDATE," +
|
|
|
- " t.EXCHTICKET," +
|
|
|
- " t.EXTOPERATEID," +
|
|
|
- " t.BANKTICKET," +
|
|
|
- " t.APPLYSTATUS," +
|
|
|
- " u.userid," +
|
|
|
- " u.accountname," +
|
|
|
- " ui.userinfotype," +
|
|
|
- " ui.mobile," +
|
|
|
- " tmp.logincode," +
|
|
|
- " bb.bankname," +
|
|
|
- " bc.CUSBANKNAME," +
|
|
|
- " bc.CUSBANKSHORTNAME" +
|
|
|
- " FROM BANK_ACCOUNTOUTINAPPLY t" +
|
|
|
- " INNER JOIN TAACCOUNT ta on t.accountcode=to_char(ta.accountid)" +
|
|
|
- " INNER JOIN USERACCOUNT u on ta.relateduserid=u.userid" +
|
|
|
- " INNER JOIN USERINFO ui on u.userid=ui.userid" +
|
|
|
- " INNER JOIN BANK_CUSBANKINFO bc on bc.cusbankid=t.CUSBANKID" +
|
|
|
- " LEFT JOIN tmp on u.userid=tmp.userid" +
|
|
|
- " LEFT JOIN bank_bankinfo bb ON bb.bankid=t.bankid" +
|
|
|
- " WHERE 1 = 1"
|
|
|
+ var sqlId utils.SQLVal = `with tmp as(select t.userid, wm_concat(t.logincode) logincode from loginaccount t group by t.userid)
|
|
|
+ SELECT t.EXECUTETYPE,
|
|
|
+ t.AMOUNT,
|
|
|
+ t.CURRENCY,
|
|
|
+ t.CHARGE,
|
|
|
+ t.ACCOUNTPWD,
|
|
|
+ to_char(t.UPDATETIME, 'yyyy-mm-dd hh24:mi:ss') UPDATETIME,
|
|
|
+ t.BANKID,
|
|
|
+ t.BRANCHBANKID,
|
|
|
+ t.BRANCHBANKNAME,
|
|
|
+ t.BANKACCOUNTNO,
|
|
|
+ t.BANKACCOUNTNAME,
|
|
|
+ t.EXTENDINFO,
|
|
|
+ t.AUDITID,
|
|
|
+ to_char(t.AUDITTIME, 'yyyy-mm-dd hh24:mi:ss') AUDITTIME,
|
|
|
+ t.REMARK,
|
|
|
+ t.NETADDR,
|
|
|
+ t.ACCOUNTTICKET,
|
|
|
+ t.CHECKERRORFLAG,
|
|
|
+ t.REMARK2,
|
|
|
+ t.REAUDITID,
|
|
|
+ to_char(t.REAUDITTIME, 'yyyy-mm-dd hh24:mi:ss') REAUDITTIME,
|
|
|
+ t.REAUDITREMARK,
|
|
|
+ t.APPLYREMARK,
|
|
|
+ t.RELATEDORDERID,
|
|
|
+ t.CAPAMOUNTOUT,
|
|
|
+ t.INFAMOUNT,
|
|
|
+ t.PRIAMOUNT,
|
|
|
+ t.BANK_APPLY_TICKET,
|
|
|
+ to_char(t.CERTIFICATEPHOTOURL) CERTIFICATEPHOTOURL,
|
|
|
+ t.SOUCREAMOUNT,
|
|
|
+ t.SOUCRECURRENCYID,
|
|
|
+ t.ACCOUNTCODE,
|
|
|
+ t.CUSBANKID,
|
|
|
+ t.TRADEDATE,
|
|
|
+ t.EXCHTICKET,
|
|
|
+ t.EXTOPERATEID,
|
|
|
+ t.BANKTICKET,
|
|
|
+ t.APPLYSTATUS,
|
|
|
+ u.userid,
|
|
|
+ u.accountname,
|
|
|
+ ui.userinfotype,
|
|
|
+ ui.mobile,
|
|
|
+ tmp.logincode,
|
|
|
+ bb.bankname,
|
|
|
+ bc.CUSBANKNAME,
|
|
|
+ bc.CUSBANKSHORTNAME
|
|
|
+ FROM BANK_ACCOUNTOUTINAPPLY t
|
|
|
+ INNER JOIN TAACCOUNT ta on t.accountcode=to_char(ta.accountid)
|
|
|
+ INNER JOIN USERACCOUNT u on ta.relateduserid=u.userid
|
|
|
+ INNER JOIN USERINFO ui on u.userid=ui.userid
|
|
|
+ INNER JOIN BANK_CUSBANKINFO bc on bc.cusbankid=t.CUSBANKID
|
|
|
+ LEFT JOIN tmp on u.userid=tmp.userid
|
|
|
+ LEFT JOIN bank_bankinfo bb ON bb.bankid=t.bankid
|
|
|
+ WHERE 1 = 1`
|
|
|
sqlId.And("u.userid", r.USERID)
|
|
|
sqlId.AndEx("t.EXECUTETYPE", r.QUERYTYPE, r.QUERYTYPE > 0)
|
|
|
switch r.STATUS {
|