|
|
@@ -213,6 +213,7 @@ public class InsPlyIncomeServiceImpl extends ServiceImpl<InsPlyIncomeMapper, Ins
|
|
|
insPlyIncome.setIsNotDocumentary("0");
|
|
|
insPlyIncome.setAllFeeValue(insFeeOrderNew.getNoSuperviseCostsPremiums());
|
|
|
insPlyIncome.setUserId(insFeeOrderNew.getUserId());
|
|
|
+ insPlyIncome.setInsuredName(order.getInsuredname());
|
|
|
insPlyIncome.setNoPremium(insFeeOrderNew.getNoPremium()); //非车保费
|
|
|
insPlyIncome.setNoNoTaxPremium(insFeeOrderNew.getNoNoTaxPremium()); //非车不含税保费
|
|
|
this.saveByCompanyId(insFeeOrderNew ,insAreaCompany.getCompanyId(),insPlyIncome);
|
|
|
@@ -260,6 +261,7 @@ public class InsPlyIncomeServiceImpl extends ServiceImpl<InsPlyIncomeMapper, Ins
|
|
|
insPlyIncome.setSyOtherCostsPremium(insFeeOrderNew.getSyOtherCostsPremiums());
|
|
|
insPlyIncome.setJqOtherCostsPremium(insFeeOrderNew.getJqOtherCostsPremiums());
|
|
|
insPlyIncome.setUserId(insFeeOrderNew.getUserId());
|
|
|
+ insPlyIncome.setInsuredName(order.getInsuredname());
|
|
|
this.saveByCompanyId(insFeeOrderNew ,insAreaCompany.getCompanyId(),insPlyIncome);
|
|
|
|
|
|
baseMapper.insert(insPlyIncome);
|
|
|
@@ -284,6 +286,7 @@ public class InsPlyIncomeServiceImpl extends ServiceImpl<InsPlyIncomeMapper, Ins
|
|
|
this.saveRiskCode(order.getProductid(),insPlyIncome);
|
|
|
insPlyIncome.setTaxPremium(allTaxPremium);
|
|
|
insPlyIncome.setUserId(insFeeOrderNew.getUserId());
|
|
|
+ insPlyIncome.setInsuredName(order.getInsuredname());
|
|
|
this.saveByCompanyId(insFeeOrderNew ,insAreaCompany.getCompanyId(),insPlyIncome);
|
|
|
baseMapper.insert(insPlyIncome);
|
|
|
}
|
|
|
@@ -347,6 +350,7 @@ public class InsPlyIncomeServiceImpl extends ServiceImpl<InsPlyIncomeMapper, Ins
|
|
|
insPlyIncome.setSyOtherCostsProportion(insFeeOrderNew.getSyOtherCostsProportion()); //商业跟单费比例
|
|
|
insPlyIncome.setNoOtherCostsProportion(insFeeOrderNew.getNoOtherCostsProportion()); //非车跟单费比例
|
|
|
insPlyIncome.setUserId(insFeeOrderNew.getUserId());
|
|
|
+ insPlyIncome.setInsuredName(order.getInsuredname());
|
|
|
this.saveByCompanyId(insFeeOrderNew ,insAreaCompany.getCompanyId(),insPlyIncome);
|
|
|
baseMapper.insert(insPlyIncome);
|
|
|
}
|
|
|
@@ -426,36 +430,30 @@ public class InsPlyIncomeServiceImpl extends ServiceImpl<InsPlyIncomeMapper, Ins
|
|
|
}
|
|
|
}
|
|
|
@Override
|
|
|
- public InsPlyIncome totalAmount(InsPlyIncomeVo insPlyIncomeVo) {
|
|
|
+ public HashMap<String,Object> totalAmount(List<String> selectIds) {
|
|
|
HashMap<String, Object> params = new HashMap<>();
|
|
|
- params = this.saveParams(insPlyIncomeVo, params);
|
|
|
- InsPlyIncome totalledAmount =baseMapper.totalAmount(params); //总金额
|
|
|
- params.put("handlingFeesStatus","0");
|
|
|
- InsPlyIncome noTotalAmount =baseMapper.totalAmount(params);
|
|
|
- if(ObjectUtils.isNotEmpty(totalledAmount) && ObjectUtils.isNotEmpty(noTotalAmount)){
|
|
|
- totalledAmount.setReadyTotalFeevalue(noTotalAmount.getTotalFeevalue());
|
|
|
- totalledAmount.setReadyCommissionFeevalue(noTotalAmount.getCommissionFeevalue());
|
|
|
- totalledAmount.setReadyOtherFeevalue(noTotalAmount.getOtherFeevalue());
|
|
|
- return totalledAmount;
|
|
|
- }
|
|
|
-
|
|
|
- return new InsPlyIncome();
|
|
|
+ params.put("selectIds",selectIds);
|
|
|
+ HashMap<String,Object> resultMap =baseMapper.totalAmount(params);
|
|
|
+ return resultMap;
|
|
|
}
|
|
|
|
|
|
@Override
|
|
|
@Transactional
|
|
|
public HttpResult<Object> batchPinBalance(InsPlyIncomeVo insPlyIncomeVo) {
|
|
|
|
|
|
- HashMap<String, Object> params = new HashMap<>();
|
|
|
- List<InsPlyIncome> list= this.baseMapper.queryNew(params);
|
|
|
- for (InsPlyIncome item : list) {
|
|
|
- item.setHandlingFeesStatus("1");
|
|
|
- item.setSettlementTime(LocalDate.now());
|
|
|
- baseMapper.updateById(item);
|
|
|
+ if(!CollectionUtils.isEmpty(insPlyIncomeVo.getSelectIds())){
|
|
|
+ List<String> selectIds = insPlyIncomeVo.getSelectIds();
|
|
|
+ for(String id: selectIds){
|
|
|
+ InsPlyIncome insPlyIncome = new InsPlyIncome();
|
|
|
+ insPlyIncome.setHandlingFeesStatus("1");
|
|
|
+ insPlyIncome.setSettlementTime(LocalDate.now());
|
|
|
+ insPlyIncome.setId(id);
|
|
|
+ baseMapper.updateById(insPlyIncome);
|
|
|
}
|
|
|
+ }
|
|
|
SettlementDocumentaryLogEntity settlementDocumentaryLogEntity = new SettlementDocumentaryLogEntity();
|
|
|
settlementDocumentaryLogEntity.setIds(insPlyIncomeVo.getIds());
|
|
|
- settlementDocumentaryLogEntity.setCompanyId(insPlyIncomeVo.getCompanyId());
|
|
|
+// settlementDocumentaryLogEntity.setCompanyId(insPlyIncomeVo.getCompanyId());
|
|
|
settlementDocumentaryLogEntity.setAmount(insPlyIncomeVo.getOtherFeevalue()); //跟单费金额
|
|
|
settlementDocumentaryLogEntity.setHandingAmount(insPlyIncomeVo.getCommissionFeevalue()); //手续费金额
|
|
|
settlementDocumentaryLogEntity.setCreateTime(new Date());
|
|
|
@@ -523,7 +521,7 @@ public class InsPlyIncomeServiceImpl extends ServiceImpl<InsPlyIncomeMapper, Ins
|
|
|
params.put("handlingFeesStatus",insPlyIncomeVo.getHandlingFeesStatus());
|
|
|
}
|
|
|
if(StringUtils.isNotEmpty(insPlyIncomeVo.getPartnerCompaniesId())){
|
|
|
- params.put("partnerCompaniesId",insPlyIncomeVo.getHandlingFeesStatus());
|
|
|
+ params.put("partnerCompaniesId",insPlyIncomeVo.getPartnerCompaniesId());
|
|
|
}
|
|
|
if(StringUtils.isNotEmpty(insPlyIncomeVo.getYear())){
|
|
|
params.put("year",insPlyIncomeVo.getYear());
|
|
|
@@ -543,6 +541,9 @@ public class InsPlyIncomeServiceImpl extends ServiceImpl<InsPlyIncomeMapper, Ins
|
|
|
if(StringUtils.isNotEmpty(insPlyIncomeVo.getCompanyName())){
|
|
|
params.put("companyName",insPlyIncomeVo.getCompanyName());
|
|
|
}
|
|
|
+ if(StringUtils.isNotEmpty(insPlyIncomeVo.getInsuredName())){
|
|
|
+ params.put("insuredName",insPlyIncomeVo.getInsuredName());
|
|
|
+ }
|
|
|
return params;
|
|
|
}
|
|
|
|
|
|
@@ -1033,10 +1034,10 @@ public class InsPlyIncomeServiceImpl extends ServiceImpl<InsPlyIncomeMapper, Ins
|
|
|
@Transactional
|
|
|
public void uodateBalance(InsPlyIncomeVo insPlyIncomeVo) {
|
|
|
InsPlyIncome insPlyIncome = new InsPlyIncome();
|
|
|
- insPlyIncomeVo.setHandlingFeesStatus("1");
|
|
|
+ insPlyIncomeVo.setHandlingFeesStatus("1");
|
|
|
insPlyIncomeVo.setSettlementTime(LocalDate.now());
|
|
|
BeanUtils.copyProperties(insPlyIncomeVo, insPlyIncome);
|
|
|
- baseMapper.uopdateByOrderno(insPlyIncome);
|
|
|
+ baseMapper.updateById(insPlyIncome);
|
|
|
|
|
|
// 生成记录
|
|
|
SettlementDocumentaryLogEntity settlementDocumentaryLogEntity = new SettlementDocumentaryLogEntity();
|
|
|
@@ -1328,7 +1329,6 @@ public class InsPlyIncomeServiceImpl extends ServiceImpl<InsPlyIncomeMapper, Ins
|
|
|
public InsPlyIncome bxTotalAmount(InsPlyIncomeVo insPlyIncomeVo) {
|
|
|
HashMap<String, Object> params = new HashMap<>();
|
|
|
params = this.saveParams(insPlyIncomeVo, params);
|
|
|
- params.remove("handlingFeesStatus");
|
|
|
InsPlyIncome totalledAmount =baseMapper.bxTotalAmount(params); //总金额
|
|
|
return totalledAmount;
|
|
|
}
|