bug修改 #38

Merged
wangqiong123 merged 5 commits from wq into dev 2023-10-09 07:52:02 +00:00
2 changed files with 28 additions and 12 deletions
Showing only changes of commit 9644ae737d - Show all commits
@@ -58,9 +58,7 @@ public class CaseApplication extends BaseEntity {
/** 开庭日期 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
private Date hearDate;
/** 申请人仲裁诉求 */
@Excel(name = "申请人仲裁诉求")
private String arbitratClaims;
/** 借款开始日期 */
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
@Excel(name = "借款开始日期")
@@ -81,6 +79,9 @@ public class CaseApplication extends BaseEntity {
/** 申请人主张违约金 */
@Excel(name = "申请人主张违约金")
private BigDecimal claimLiquidDamag;
/** 申请人仲裁诉求 */
@Excel(name = "申请人仲裁诉求")
private String arbitratClaims;
/** 仲裁应缴费用 */
private BigDecimal feePayable;
@@ -88,6 +88,12 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
@Override
@Transactional
public int editCaseApplication(CaseApplication caseApplication) {
//根据仲裁费用计费规则计算应缴费用
//暂时设置计费比率为0.01
BigDecimal feeRate = new BigDecimal(0.01);
BigDecimal feePayable = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2,BigDecimal.ROUND_HALF_UP);
caseApplication.setFeePayable(feePayable);
int rows = caseApplicationMapper.updataCaseApplication(caseApplication);
List<CaseAffiliate> caseAffiliates = caseApplication.getCaseAffiliates();
if(caseAffiliates!=null&&caseAffiliates.size()>0){
@@ -183,14 +189,20 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
@Override
@Transactional
public String importCaseApplication(List<CaseApplication> caseApplicationList, String operName) {
StringBuilder successMsg = new StringBuilder();
StringBuilder failureMsg = new StringBuilder();
StringBuilder successMsg = new StringBuilder();
int successNum = 0;
int failureNum = 0;
if(caseApplicationList!=null&&caseApplicationList.size()>0){
List<CaseApplication> caseApplicationListinsert = new ArrayList<>();
for (int i = 0; i < caseApplicationList.size(); i++){
CaseApplication caseApplication = caseApplicationList.get(i);
//根据仲裁费用计费规则计算应缴费用
//暂时设置计费比率为0.01
BigDecimal feeRate = new BigDecimal(0.01);
BigDecimal feePayable = caseApplication.getCaseSubjectAmount().multiply(feeRate).setScale(2,BigDecimal.ROUND_HALF_UP);
caseApplication.setFeePayable(feePayable);
//赋值CaseApplication的案件关联人信息
List<CaseAffiliate> caseAffiliatesnew = new ArrayList<>();
assignmentCaseAffiliates(caseApplication,caseAffiliatesnew);
@@ -203,10 +215,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
caseApplicationListinsert.add(caseApplication);
}
}
// 编号存在不导入
if(StringUtils.isNotEmpty(failureMsg)){
return failureMsg.toString();
}
if(caseApplicationListinsert!=null&&caseApplicationListinsert.size()>0){
List<CaseApplication> caseApplicationListinsertDiffer = caseApplicationListinsert.stream().collect(
collectingAndThen(
@@ -262,8 +271,13 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
}else {
throw new ServiceException("导入立案申请数据不能为空!");
}
// 编号存在不导入
if(StringUtils.isNotEmpty(failureMsg)){
return failureMsg.append(successMsg).toString();
}else {
return successMsg.toString();
return successMsg.toString();
}
}
@Override
@@ -386,7 +400,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
//发送短信通知
SmsUtils.SendSmsRequest request = new SmsUtils.SendSmsRequest();
request.setTemplateId("1931000");
request.setTemplateId("1947342");
CaseApplication caseApplicationselect = caseApplicationMapper.selectCaseApplication(caseApplication);
String caseNum = caseApplicationselect.getCaseNum();
@@ -410,7 +424,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
Arbitrator arbitratorselect = arbitratorList.get(i);
//给仲裁员发送短信通知
request.setPhone(arbitratorselect.getTelephone());
// 1931000 普通短信 开庭日期通知 尊敬的{1}用户,您的{2}仲裁案件,开庭日期已确定为{3},请知晓,如非本人操作,请忽略本短信。
// 1947342 普通短信 开庭日期通知 尊敬的{1}用户,您的{2}仲裁案件,开庭日期已确定为{3},请知晓,如非本人操作,请忽略本短信。
String name = arbitratorselect.getArbitratorName();
request.setTemplateParamSet(new String[]{name, caseNum, hearDatestr});
SmsUtils.sendSms(request);
@@ -427,7 +441,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
int identityType = caseAffiliateselect.getIdentityType();
//给申请人、被申请人发送短信通知
request.setPhone(caseAffiliateselect.getContactTelphone());
// 1931000 普通短信 开庭日期通知 尊敬的{1}用户,您的{2}仲裁案件,开庭日期已确定为{3},请知晓,如非本人操作,请忽略本短信。
// 1947342 普通短信 开庭日期通知 尊敬的{1}用户,您的{2}仲裁案件,开庭日期已确定为{3},请知晓,如非本人操作,请忽略本短信。
String name = caseAffiliateselect.getName();
request.setTemplateParamSet(new String[]{name, caseNum, hearDatestr});
SmsUtils.sendSms(request);
@@ -490,6 +504,7 @@ public class CaseApplicationServiceImpl implements ICaseApplicationService {
caseApplicationNew.setClaimInterestOwed(caseApplicationinsertDiffer.getClaimInterestOwed());
caseApplicationNew.setClaimPrinciOwed(caseApplicationinsertDiffer.getClaimPrinciOwed());
caseApplicationNew.setClaimLiquidDamag(caseApplicationinsertDiffer.getClaimLiquidDamag());
caseApplicationNew.setFeePayable(caseApplicationinsertDiffer.getFeePayable());
}