|
@@ -1660,29 +1660,29 @@
|
|
WHEN tw.f_billstatus = '12' and tw.f_updete_status = '2'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_billstatus = '12' and tw.f_updete_status = '2'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
'运单变更'
|
|
'运单变更'
|
|
WHEN tw.f_updete_status = '3'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_updete_status = '3'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
- '运单修改驳回'
|
|
|
|
|
|
+ '申请变更驳回'
|
|
WHEN tw.f_updete_status = '4'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_updete_status = '4'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
- '运单修改提交'
|
|
|
|
|
|
+ '申请变更提交'
|
|
WHEN tw.f_updete_status = '5'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_updete_status = '5'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
- '运单修改审批中'
|
|
|
|
|
|
+ '申请变更审批中'
|
|
WHEN tw.f_updete_status = '6'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_updete_status = '6'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
- '运单修改通过'
|
|
|
|
|
|
+ '申请变更通过'
|
|
WHEN tw.f_submit_update = '3' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_submit_update = '3' and tw.f_delete_status = '2' THEN
|
|
- '修改提交驳回'
|
|
|
|
|
|
+ '提交变更驳回'
|
|
WHEN tw.f_submit_update = '4' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_submit_update = '4' and tw.f_delete_status = '2' THEN
|
|
- '修改提交审批'
|
|
|
|
|
|
+ '提交变更审批'
|
|
WHEN tw.f_submit_update = '5' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_submit_update = '5' and tw.f_delete_status = '2' THEN
|
|
- '修改提交审批中'
|
|
|
|
|
|
+ '提交变更审批中'
|
|
WHEN tw.f_submit_update = '6' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_submit_update = '6' and tw.f_delete_status = '2' THEN
|
|
- '修改提交通过'
|
|
|
|
|
|
+ '提交变更通过'
|
|
WHEN tw.f_delete_status = '3' THEN
|
|
WHEN tw.f_delete_status = '3' THEN
|
|
- '运单删除驳回'
|
|
|
|
|
|
+ '申请删单驳回'
|
|
WHEN tw.f_delete_status = '4' THEN
|
|
WHEN tw.f_delete_status = '4' THEN
|
|
- '运单删除提交'
|
|
|
|
|
|
+ '申请删单提交'
|
|
WHEN tw.f_delete_status = '5' THEN
|
|
WHEN tw.f_delete_status = '5' THEN
|
|
- '运单删除审批中'
|
|
|
|
|
|
+ '申请删单审批中'
|
|
WHEN tw.f_delete_status = '6' THEN
|
|
WHEN tw.f_delete_status = '6' THEN
|
|
- '运单删除通过'
|
|
|
|
|
|
+ '申请删单通过'
|
|
END AS fBillstatus,
|
|
END AS fBillstatus,
|
|
CASE
|
|
CASE
|
|
WHEN tf.f_billstatus = '1' THEN
|
|
WHEN tf.f_billstatus = '1' THEN
|
|
@@ -1768,7 +1768,28 @@
|
|
<if test="fIfdamage != null and fIfdamage != ''">and tw.f_ifdamage = #{fIfdamage}</if>
|
|
<if test="fIfdamage != null and fIfdamage != ''">and tw.f_ifdamage = #{fIfdamage}</if>
|
|
<if test="fBankcorpid != null and fBankcorpid != ''">and tw.f_bankcorpid = #{fBankcorpid}</if>
|
|
<if test="fBankcorpid != null and fBankcorpid != ''">and tw.f_bankcorpid = #{fBankcorpid}</if>
|
|
<if test="fBilltype != null and fBilltype != ''">and tw.f_billtype = #{fBilltype}</if>
|
|
<if test="fBilltype != null and fBilltype != ''">and tw.f_billtype = #{fBilltype}</if>
|
|
- <if test="fBillstatus != null ">and tw.f_billstatus = #{fBillstatus}</if>
|
|
|
|
|
|
+ <if test="fBillstatus == null">
|
|
|
|
+ and tw.f_updete_status = 2
|
|
|
|
+ and tw.f_submit_update = 2
|
|
|
|
+ and tw.f_delete_status = 2
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fBillstatus != null and (fBillstatus == 4 or fBillstatus == 6 or fBillstatus == 9 or fBillstatus == 11)">
|
|
|
|
+ and tw.f_billstatus = #{fBillstatus}
|
|
|
|
+ and tw.f_updete_status = 2
|
|
|
|
+ and tw.f_submit_update = 2
|
|
|
|
+ and tw.f_delete_status = 2
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fBillstatus != null and fBillstatus == 10">
|
|
|
|
+ and tw.f_billstatus in ('3','8')
|
|
|
|
+ and tw.f_updete_status in ('2','3')
|
|
|
|
+ and tw.f_submit_update in ('2','3')
|
|
|
|
+ and tw.f_delete_status in ('2','3')
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fBillstatus != null and fBillstatus == 12">
|
|
|
|
+ AND (tw.f_updete_status != 2
|
|
|
|
+ OR tw.f_submit_update != 2
|
|
|
|
+ OR tw.f_delete_status != 2 )
|
|
|
|
+ </if>
|
|
<if test="fItemsStatus != null ">and tw.f_items_status = #{fItemsStatus}</if>
|
|
<if test="fItemsStatus != null ">and tw.f_items_status = #{fItemsStatus}</if>
|
|
<if test="fBillingDeadline != null ">and tw.f_billing_deadline = #{fBillingDeadline}</if>
|
|
<if test="fBillingDeadline != null ">and tw.f_billing_deadline = #{fBillingDeadline}</if>
|
|
<if test="fProductName != null and fProductName != ''">and tw.f_product_name like concat('%',
|
|
<if test="fProductName != null and fProductName != ''">and tw.f_product_name like concat('%',
|
|
@@ -1892,29 +1913,29 @@
|
|
WHEN tw.f_billstatus = '12' and tw.f_updete_status = '2'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_billstatus = '12' and tw.f_updete_status = '2'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
'运单变更'
|
|
'运单变更'
|
|
WHEN tw.f_updete_status = '3'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_updete_status = '3'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
- '运单修改驳回'
|
|
|
|
|
|
+ '申请变更驳回'
|
|
WHEN tw.f_updete_status = '4'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_updete_status = '4'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
- '运单修改提交'
|
|
|
|
|
|
+ '申请变更提交'
|
|
WHEN tw.f_updete_status = '5'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_updete_status = '5'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
- '运单修改审批中'
|
|
|
|
|
|
+ '申请变更审批中'
|
|
WHEN tw.f_updete_status = '6'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_updete_status = '6'and tw.f_submit_update = '2' and tw.f_delete_status = '2' THEN
|
|
- '运单修改通过'
|
|
|
|
|
|
+ '申请变更通过'
|
|
WHEN tw.f_submit_update = '3' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_submit_update = '3' and tw.f_delete_status = '2' THEN
|
|
- '修改提交驳回'
|
|
|
|
|
|
+ '提交变更驳回'
|
|
WHEN tw.f_submit_update = '4' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_submit_update = '4' and tw.f_delete_status = '2' THEN
|
|
- '修改提交审批'
|
|
|
|
|
|
+ '提交变更审批'
|
|
WHEN tw.f_submit_update = '5' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_submit_update = '5' and tw.f_delete_status = '2' THEN
|
|
- '修改提交审批中'
|
|
|
|
|
|
+ '提交变更审批中'
|
|
WHEN tw.f_submit_update = '6' and tw.f_delete_status = '2' THEN
|
|
WHEN tw.f_submit_update = '6' and tw.f_delete_status = '2' THEN
|
|
- '修改提交通过'
|
|
|
|
|
|
+ '提交变更通过'
|
|
WHEN tw.f_delete_status = '3' THEN
|
|
WHEN tw.f_delete_status = '3' THEN
|
|
- '运单删除驳回'
|
|
|
|
|
|
+ '申请删单驳回'
|
|
WHEN tw.f_delete_status = '4' THEN
|
|
WHEN tw.f_delete_status = '4' THEN
|
|
- '运单删除提交'
|
|
|
|
|
|
+ '申请删单提交'
|
|
WHEN tw.f_delete_status = '5' THEN
|
|
WHEN tw.f_delete_status = '5' THEN
|
|
- '运单删除审批中'
|
|
|
|
|
|
+ '申请删单审批中'
|
|
WHEN tw.f_delete_status = '6' THEN
|
|
WHEN tw.f_delete_status = '6' THEN
|
|
- '运单删除通过'
|
|
|
|
|
|
+ '申请删单通过'
|
|
END AS fBillstatusName,
|
|
END AS fBillstatusName,
|
|
CASE
|
|
CASE
|
|
WHEN tf.f_billstatus = '1' THEN
|
|
WHEN tf.f_billstatus = '1' THEN
|
|
@@ -2000,7 +2021,28 @@
|
|
<if test="fIfdamage != null and fIfdamage != ''">and tw.f_ifdamage = #{fIfdamage}</if>
|
|
<if test="fIfdamage != null and fIfdamage != ''">and tw.f_ifdamage = #{fIfdamage}</if>
|
|
<if test="fBankcorpid != null and fBankcorpid != ''">and tw.f_bankcorpid = #{fBankcorpid}</if>
|
|
<if test="fBankcorpid != null and fBankcorpid != ''">and tw.f_bankcorpid = #{fBankcorpid}</if>
|
|
<if test="fBilltype != null and fBilltype != ''">and tw.f_billtype = #{fBilltype}</if>
|
|
<if test="fBilltype != null and fBilltype != ''">and tw.f_billtype = #{fBilltype}</if>
|
|
- <if test="fBillstatus != null ">and tw.f_billstatus = #{fBillstatus}</if>
|
|
|
|
|
|
+ <if test="fBillstatus == null">
|
|
|
|
+ and tw.f_updete_status = 2
|
|
|
|
+ and tw.f_submit_update = 2
|
|
|
|
+ and tw.f_delete_status = 2
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fBillstatus != null and (fBillstatus == 4 or fBillstatus == 6 or fBillstatus == 9 or fBillstatus == 11)">
|
|
|
|
+ and tw.f_billstatus = #{fBillstatus}
|
|
|
|
+ and tw.f_updete_status = 2
|
|
|
|
+ and tw.f_submit_update = 2
|
|
|
|
+ and tw.f_delete_status = 2
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fBillstatus != null and fBillstatus == 10">
|
|
|
|
+ and tw.f_billstatus in ('3','8')
|
|
|
|
+ and tw.f_updete_status in ('2','3')
|
|
|
|
+ and tw.f_submit_update in ('2','3')
|
|
|
|
+ and tw.f_delete_status in ('2','3')
|
|
|
|
+ </if>
|
|
|
|
+ <if test="fBillstatus != null and fBillstatus == 12">
|
|
|
|
+ AND (tw.f_updete_status != 2
|
|
|
|
+ OR tw.f_submit_update != 2
|
|
|
|
+ OR tw.f_delete_status != 2 )
|
|
|
|
+ </if>
|
|
<if test="fItemsStatus != null ">and tw.f_items_status = #{fItemsStatus}</if>
|
|
<if test="fItemsStatus != null ">and tw.f_items_status = #{fItemsStatus}</if>
|
|
<if test="fBillingDeadline != null ">and tw.f_billing_deadline = #{fBillingDeadline}</if>
|
|
<if test="fBillingDeadline != null ">and tw.f_billing_deadline = #{fBillingDeadline}</if>
|
|
<if test="fProductName != null and fProductName != ''">and tw.f_product_name like concat('%',
|
|
<if test="fProductName != null and fProductName != ''">and tw.f_product_name like concat('%',
|