Commit 1bc2ebd1 authored by zhangfeng's avatar zhangfeng

feat(wealth): 优化

parent 5e0924a4
...@@ -592,8 +592,8 @@ public class ReceiptServiceImpl extends AbstractService<ReceiptMapper, ReceiptDO ...@@ -592,8 +592,8 @@ public class ReceiptServiceImpl extends AbstractService<ReceiptMapper, ReceiptDO
Map<Integer, CurrencyRespDTO> currencyMap = currencyApi.getAllCurrency(); Map<Integer, CurrencyRespDTO> currencyMap = currencyApi.getAllCurrency();
for (ReceiptBackVO r : receiptBackPage) { for (ReceiptBackVO r : receiptBackPage) {
String sR = getReceiptMxStatus(listItem, r.getId()).getNameZh(); //String sR = getReceiptMxStatus(listItem, r.getId()).getNameZh();
r.setMxStatus(sR); //r.setMxStatus(sR);
//应收 //应收
String s1 = getYSShow(ReceiptAccountList, r.getId(), currencyMap); String s1 = getYSShow(ReceiptAccountList, r.getId(), currencyMap);
......
...@@ -135,8 +135,6 @@ public class ReceiptItemServiceImpl extends AbstractService<ReceiptItemMapper, R ...@@ -135,8 +135,6 @@ public class ReceiptItemServiceImpl extends AbstractService<ReceiptItemMapper, R
Long baseCurrencyId = receivableDOS.get(0).getBaseCurrencyId(); Long baseCurrencyId = receivableDOS.get(0).getBaseCurrencyId();
if (CollectionUtils.isNotEmpty(receiptAccountDOS) && baseCurrencyId.equals(receiptItem.getWriteOffCurrencyId())) { if (CollectionUtils.isNotEmpty(receiptAccountDOS) && baseCurrencyId.equals(receiptItem.getWriteOffCurrencyId())) {
ReceiptAccountDO receiptAccountDO = receiptAccountDOS.get(0); ReceiptAccountDO receiptAccountDO = receiptAccountDOS.get(0);
if (receiptAccountDO.getWriteOffAmount().compareTo(new BigDecimal(createReqVO.getRate())) != 0) {
BigDecimal receivableTotalAmount = BigDecimal.ZERO; BigDecimal receivableTotalAmount = BigDecimal.ZERO;
BigDecimal receiptAccountAmount = BigDecimal.ZERO; BigDecimal receiptAccountAmount = BigDecimal.ZERO;
for (ReceivableDO receivableDO : receivableDOS) { for (ReceivableDO receivableDO : receivableDOS) {
...@@ -168,7 +166,6 @@ public class ReceiptItemServiceImpl extends AbstractService<ReceiptItemMapper, R ...@@ -168,7 +166,6 @@ public class ReceiptItemServiceImpl extends AbstractService<ReceiptItemMapper, R
remark = remark + ";更新收款单" + currency1.getTitleZh() + "兑" + currency2.getTitleZh() + "币种汇率为" + createReqVO.getBatchRate(); remark = remark + ";更新收款单" + currency1.getTitleZh() + "兑" + currency2.getTitleZh() + "币种汇率为" + createReqVO.getBatchRate();
} }
} }
}
createFinanceReceiptItemWriteOff(FinanceReceiptItemVo.builder() createFinanceReceiptItemWriteOff(FinanceReceiptItemVo.builder()
.receiptId(receiptItem.getReceiptId()) .receiptId(receiptItem.getReceiptId())
.receiptNo(receiptDO.getReceiptNo()) .receiptNo(receiptDO.getReceiptNo())
...@@ -939,7 +936,7 @@ public class ReceiptItemServiceImpl extends AbstractService<ReceiptItemMapper, R ...@@ -939,7 +936,7 @@ public class ReceiptItemServiceImpl extends AbstractService<ReceiptItemMapper, R
batchCreateReqVO.setSettleRateRatio(receiptAccountDOS.get(0).getWriteOffRate()); batchCreateReqVO.setSettleRateRatio(receiptAccountDOS.get(0).getWriteOffRate());
} }
// 没有汇率有效期或者汇率没过期且能匹配到还是用原汇率 // 没有汇率有效期或者汇率没过期且能匹配到还是用原汇率
else if (matchReceiptDO.getRateValidateDate() == null || matchReceiptDO.getRateValidateDate().getTime() > System.currentTimeMillis()){ else if (matchReceiptDO.getRateValidateDate() == null || matchReceiptDO.getRateValidateDate().getTime() > System.currentTimeMillis()) {
if (!receiptAccountDOS.isEmpty() && baseCurrencyId.equals(Long.parseLong(batchCreateReqVO.getSettleCurrency()))) { if (!receiptAccountDOS.isEmpty() && baseCurrencyId.equals(Long.parseLong(batchCreateReqVO.getSettleCurrency()))) {
batchCreateReqVO.setSettleRateRatio(receiptAccountDOS.get(0).getWriteOffRate()); batchCreateReqVO.setSettleRateRatio(receiptAccountDOS.get(0).getWriteOffRate());
} }
......
...@@ -78,9 +78,7 @@ ...@@ -78,9 +78,7 @@
<if test="query.searchKey != null and query.searchKey !=''"> <if test="query.searchKey != null and query.searchKey !=''">
AND ( AND (
c.name LIKE concat('%',#{query.searchKey},'%') c.name LIKE concat('%',#{query.searchKey},'%')
or c.number LIKE concat('%',#{query.searchKey},'%') or c.number LIKE concat('%',#{query.searchKey},'%'))
or c.new_phone LIKE concat('%',#{query.searchKey},'%')
)
</if> </if>
</select> </select>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment