|
@@ -69,10 +69,10 @@
|
|
|
a.establish_time,
|
|
a.establish_time,
|
|
|
a.biller,
|
|
a.biller,
|
|
|
a.invoicing_amount,
|
|
a.invoicing_amount,
|
|
|
- a.invoicing_amount_excess,
|
|
|
|
|
|
|
+ ABS(sum(c.invoice_money) - 5000000) as invoicing_amount_excess,
|
|
|
|
|
+
|
|
|
|
|
|
|
|
|
|
|
|
|
- b.account_id,
|
|
|
|
|
b.bank_card_num,
|
|
b.bank_card_num,
|
|
|
b.bank_name,
|
|
b.bank_name,
|
|
|
b.bank,
|
|
b.bank,
|
|
@@ -101,12 +101,20 @@
|
|
|
b.pub_day_lines_excess,
|
|
b.pub_day_lines_excess,
|
|
|
b.pri_day_lines_excess,
|
|
b.pri_day_lines_excess,
|
|
|
b.spend
|
|
b.spend
|
|
|
|
|
+
|
|
|
</sql>
|
|
</sql>
|
|
|
<select id="selectAccountsListPage" resultMap="BaseResultMap">
|
|
<select id="selectAccountsListPage" resultMap="BaseResultMap">
|
|
|
select
|
|
select
|
|
|
<include refid="Base_Column_List"/>
|
|
<include refid="Base_Column_List"/>
|
|
|
from inv_account a
|
|
from inv_account a
|
|
|
left join inv_account_card b on a.account_id = b.account_id
|
|
left join inv_account_card b on a.account_id = b.account_id
|
|
|
|
|
+ left join inv_account_incoice c on a.account_id = c.account_id
|
|
|
|
|
+ <if test="account.invoiceTimeStart!= null">
|
|
|
|
|
+ and c.invoice_time >= #{account.invoiceTimeStart}
|
|
|
|
|
+ </if>
|
|
|
|
|
+ <if test="account.invoiceTimeEnd!= null">
|
|
|
|
|
+ and c.invoice_time <= #{account.invoiceTimeEnd}
|
|
|
|
|
+ </if>
|
|
|
where a.del_flag = '0'
|
|
where a.del_flag = '0'
|
|
|
<if test="account.accountName!= null and account.accountName!= ''">
|
|
<if test="account.accountName!= null and account.accountName!= ''">
|
|
|
and a.account_name like concat('%',#{account.accountName},'%')
|
|
and a.account_name like concat('%',#{account.accountName},'%')
|
|
@@ -120,6 +128,8 @@
|
|
|
<if test="account.bankCardNum!= null and account.bankCardNum!= ''">
|
|
<if test="account.bankCardNum!= null and account.bankCardNum!= ''">
|
|
|
and b.bank_card_num like concat('%',#{account.bankCardNum},'%')
|
|
and b.bank_card_num like concat('%',#{account.bankCardNum},'%')
|
|
|
</if>
|
|
</if>
|
|
|
|
|
+ GROUP BY
|
|
|
|
|
+ a.account_id
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
<select id="selectAccountsList" resultMap="BaseResultMap">
|
|
<select id="selectAccountsList" resultMap="BaseResultMap">
|
|
@@ -127,6 +137,13 @@
|
|
|
<include refid="Base_Column_List"/>
|
|
<include refid="Base_Column_List"/>
|
|
|
from inv_account a
|
|
from inv_account a
|
|
|
left join inv_account_card b on a.account_id = b.account_id
|
|
left join inv_account_card b on a.account_id = b.account_id
|
|
|
|
|
+ left join inv_account_incoice c on a.account_id = c.account_id
|
|
|
|
|
+ <if test="account.invoiceTimeStart!= null">
|
|
|
|
|
+ and c.invoice_time >= #{account.invoiceTimeStart}
|
|
|
|
|
+ </if>
|
|
|
|
|
+ <if test="account.invoiceTimeEnd!= null">
|
|
|
|
|
+ and c.invoice_time <= #{account.invoiceTimeEnd}
|
|
|
|
|
+ </if>
|
|
|
where a.del_flag = '0'
|
|
where a.del_flag = '0'
|
|
|
<if test="account.accountId != null and account.accountId != ''">
|
|
<if test="account.accountId != null and account.accountId != ''">
|
|
|
and a.account_id = #{account.accountId}
|
|
and a.account_id = #{account.accountId}
|
|
@@ -140,6 +157,7 @@
|
|
|
<if test="account.juridicalPerson!= null and account.juridicalPerson!= ''">
|
|
<if test="account.juridicalPerson!= null and account.juridicalPerson!= ''">
|
|
|
and a.juridical_person like concat('%',#{account.juridicalPerson},'%')
|
|
and a.juridical_person like concat('%',#{account.juridicalPerson},'%')
|
|
|
</if>
|
|
</if>
|
|
|
-
|
|
|
|
|
|
|
+ GROUP BY
|
|
|
|
|
+ a.account_id
|
|
|
</select>
|
|
</select>
|
|
|
</mapper>
|
|
</mapper>
|