|
|
@@ -2,6 +2,7 @@ package me.zhengjie.domain.model;
|
|
|
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
import lombok.RequiredArgsConstructor;
|
|
|
+import me.zhengjie.application.admin.controller.OrderCochainController;
|
|
|
import me.zhengjie.application.admin.service.dto.UserDto;
|
|
|
import me.zhengjie.application.admin.controller.vo.NotaryNoteDto;
|
|
|
import me.zhengjie.base.util.ApplicationContextUtil;
|
|
|
@@ -264,7 +265,7 @@ public class ModelSynthesizerDomain {
|
|
|
* @param businessNo
|
|
|
* @return
|
|
|
*/
|
|
|
- public Map<String, String> prepareNoteTemplateData(String businessNo, String contractNo) {
|
|
|
+ public Map<String, String> prepareNoteTemplateData(String businessNo) {
|
|
|
Map<String, String> noteValue = new HashMap<String, String>();
|
|
|
// 设置默认值
|
|
|
noteValue.put("$Date$", DateUtils.date2String(new Date(), 1));
|
|
|
@@ -290,6 +291,16 @@ public class ModelSynthesizerDomain {
|
|
|
noteValue.put("$Amounts$", contractOrderEntity.getContractMoney());
|
|
|
noteValue.put("$Term$", contractOrderEntity.getStartDate() + "~" + contractOrderEntity.getEndDate());
|
|
|
noteValue.put("$LoanRate$", contractOrderEntity.getRate());
|
|
|
+ noteValue.put("$McontractNO$",contractOrderEntity.getMainContractNo());
|
|
|
+ // 抵押合同需要补充借款合同中借款人信息
|
|
|
+ if (contractOrderEntity.getContractType() == OrderConstant.CONTRACT_TYPE_MORTGAGE) {
|
|
|
+ ContractOrderEntity mainOrder = contractOrderRepository.getEntityWithContractNo(contractOrderEntity.getBankId(), contractOrderEntity.getProdId(), contractOrderEntity.getMainContractNo());
|
|
|
+ if (mainOrder != null) {
|
|
|
+ String jointName = mainOrder.getJointFlag() == OrderConstant.JOINT_FLAG_TRUE ? "," + mainOrder.getJointName() : "";
|
|
|
+ String obligor = mainOrder.getName() + jointName;
|
|
|
+ noteValue.put("$obligor$", obligor);
|
|
|
+ }
|
|
|
+ }
|
|
|
try {
|
|
|
SimpleDateFormat monthformatter = new SimpleDateFormat("yyyy-MM");
|
|
|
Date beginDate = monthformatter.parse(contractOrderEntity.getStartDate());
|