Просмотр исходного кода

Merge branch 'release_toaliyun_real_offline_activity' of https://git.malls.iformall.com/server/formallProject into release_toaliyun_real_offline_activity

release_toaliyun_real
xiaohu 1 год назад
Родитель
Сommit
5d208c2e03
3 измененных файлов: 26 добавлений и 12 удалений
  1. +3
    -3
      mallinkService/src/main/java/com/iformall/service/impl/WxFinancePrintServiceImpl.java
  2. +15
    -1
      mallinkService/src/main/java/com/iformall/service/impl/WxFinanceServiceImpl.java
  3. +8
    -8
      mallinkService/src/main/resources/mapper/WxAllBillMapper.xml

+ 3
- 3
mallinkService/src/main/java/com/iformall/service/impl/WxFinancePrintServiceImpl.java Просмотреть файл

@@ -122,10 +122,10 @@ public class WxFinancePrintServiceImpl implements WxFinancePrintService {
record.setUpdateTime(date); record.setUpdateTime(date);
record.setName(record.getTitle()); record.setName(record.getTitle());
Map map = new HashMap(); Map map = new HashMap();
map.put("width", 770);
map.put("width", 768);
map.put("height", 500); map.put("height", 500);
map.put("pageWidth", 325);
map.put("pageHeight", 275);
map.put("pageWidth", 215);
map.put("pageHeight", 140);
map.put("tempItems", record.getTempItems()); map.put("tempItems", record.getTempItems());
map.put("id", String.valueOf(record.getId())); map.put("id", String.valueOf(record.getId()));
map.put("title", record.getName()); map.put("title", record.getName());


+ 15
- 1
mallinkService/src/main/java/com/iformall/service/impl/WxFinanceServiceImpl.java Просмотреть файл

@@ -198,7 +198,8 @@ public class WxFinanceServiceImpl implements WxFinanceService {


@Override @Override
public FinanceBillSetoffSum getBillSetoffSum(WxFinanceReceive record) { public FinanceBillSetoffSum getBillSetoffSum(WxFinanceReceive record) {
record.setType(EnumFinanceReceiveType.ADVANCE.getCode());
record.setType(EnumFinanceCashierType.RECEIVE.getCode());
record.setReceiveType(EnumFinanceReceiveType.ADVANCE.getCode());
record.setStatus(EnumFinanceReceiveStatus.NORMAL.getCode()); record.setStatus(EnumFinanceReceiveStatus.NORMAL.getCode());
List<WxFinanceReceive> advanceList = wxFinanceReceiveMapper.getMerchantAdvanceGroupSumList(record); List<WxFinanceReceive> advanceList = wxFinanceReceiveMapper.getMerchantAdvanceGroupSumList(record);
BigDecimal total = new BigDecimal(0); BigDecimal total = new BigDecimal(0);
@@ -970,6 +971,19 @@ public class WxFinanceServiceImpl implements WxFinanceService {
wxFinanceReceiveMapper.updateById(advance); wxFinanceReceiveMapper.updateById(advance);
} }
} }
//要更新账单的冲抵
WxBillPayDTO payDto = new WxBillPayDTO();
payDto.updateTenantInfo(record);
payDto.setId(bill.getId());
payDto.setBillTypeValue(bill.getBillType());
payDto.setAddpay("0");
payDto.setSetOff(rb.getReceive());
if (isRedSetoff) {
payDto.setRemark("收款单红冲,自动回退");
}else {
payDto.setRemark("收款单作废,自动回退");
}
wxBillAllHelper.backPay(payDto, user);
//记录删除 //记录删除
wxFinanceReceiveSetoffMapper.deleteByConditon(rsq); wxFinanceReceiveSetoffMapper.deleteByConditon(rsq);
} }


+ 8
- 8
mallinkService/src/main/resources/mapper/WxAllBillMapper.xml Просмотреть файл

@@ -76,23 +76,23 @@
</if> </if>
<if test=" null == nearBillLastTime and null != oweBillLastTime"> <if test=" null == nearBillLastTime and null != oweBillLastTime">
and ( and (
(`starttime` &lt;= #{oweBillLastTime} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') + IFNULL(`return_pay`,'0') &gt; 0 and status not in (3,6,7) and bill_type not in (13,21,5))
(`starttime` &lt;= #{oweBillLastTime} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') + IFNULL(`return_pay`,'0') &gt; 0 and status not in (3,6,7,9) and bill_type not in (13,21,5))
or or
(`starttime` &lt;= #{oweBillLastTime} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') &gt; 0 and status not in (3,6,7) and bill_type in (13,21,5))
(`starttime` &lt;= #{oweBillLastTime} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') &gt; 0 and status not in (3,6,7,9) and bill_type in (13,21,5))
) )
</if> </if>
<if test=" null != nearBillLastTime and null != oweBillLastTime"> <if test=" null != nearBillLastTime and null != oweBillLastTime">
and ( and (
(`starttime` &gt; #{oweBillLastTime} and `starttime` &lt;= #{nearBillLastTime} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') + IFNULL(`return_pay`,'0') &gt; 0 and status not in (3,6,7) and bill_type not in (13,21,5))
(`starttime` &gt; #{oweBillLastTime} and `starttime` &lt;= #{nearBillLastTime} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') + IFNULL(`return_pay`,'0') &gt; 0 and status not in (3,6,7,9) and bill_type not in (13,21,5))
or or
(`starttime` &gt; #{oweBillLastTime} and `starttime` &lt;= #{nearBillLastTime} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') &gt; 0 and status not in (3,6,7) and bill_type in (13,21,5))
(`starttime` &gt; #{oweBillLastTime} and `starttime` &lt;= #{nearBillLastTime} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') &gt; 0 and status not in (3,6,7,9) and bill_type in (13,21,5))
) )
</if> </if>
<if test=" null != needPayStartDay"> <if test=" null != needPayStartDay">
and ( and (
(`starttime` &lt;= #{needPayStartDay} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') + IFNULL(`return_pay`,'0') &gt; 0 and status not in (3,6,7) and bill_type not in (13,21,5))
(`starttime` &lt;= #{needPayStartDay} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') + IFNULL(`return_pay`,'0') &gt; 0 and status not in (3,6,7,9) and bill_type not in (13,21,5))
or or
(`starttime` &lt;= #{needPayStartDay} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') &gt; 0 and status not in (3,6,7) and bill_type in (13,21,5))
(`starttime` &lt;= #{needPayStartDay} and `receive_pay` - `pay` - IFNULL(`set_off`,'0') &gt; 0 and status not in (3,6,7,9) and bill_type in (13,21,5))
) )
</if> </if>
<if test=" null != toPayMerchant"> <if test=" null != toPayMerchant">
@@ -105,9 +105,9 @@
</if> </if>
<if test=" 1 == notifyed "> <if test=" 1 == notifyed ">
and ( and (
(`last_owe_call_time` is not null and `receive_pay` - `pay`- IFNULL(`set_off`,'0') + IFNULL(`return_pay`,'0') &gt; 0 and status not in (3,6,7) and bill_type not in (13,21,5))
(`last_owe_call_time` is not null and `receive_pay` - `pay`- IFNULL(`set_off`,'0') + IFNULL(`return_pay`,'0') &gt; 0 and status not in (3,6,7,9) and bill_type not in (13,21,5))
or or
(`last_owe_call_time` is not null and `receive_pay` - `pay`- IFNULL(`set_off`,'0') &gt; 0 and status not in (3,6,7) and bill_type in (13,21,5))
(`last_owe_call_time` is not null and `receive_pay` - `pay`- IFNULL(`set_off`,'0') &gt; 0 and status not in (3,6,7,9) and bill_type in (13,21,5))
) )
</if> </if>
<if test=" null != hasMerchant ">and `merchant_id` is not null</if> <if test=" null != hasMerchant ">and `merchant_id` is not null</if>


Загрузка…
Отмена
Сохранить