|
|
@@ -3,16 +3,22 @@ package com.ydtech.modules.order.service.impl;
|
|
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
|
|
+import com.ydtech.exception.SystemException;
|
|
|
import com.ydtech.modules.admin.model.SysUser;
|
|
|
import com.ydtech.modules.admin.model.SysUserRole;
|
|
|
import com.ydtech.modules.admin.model.dto.SysUserLinkAreaDto;
|
|
|
+import com.ydtech.modules.fnc.entity.InsPlyIncome;
|
|
|
+import com.ydtech.modules.fnc.service.InsPlyIncomeService;
|
|
|
import com.ydtech.modules.order.dao.InsOrderReadPdfMapper;
|
|
|
import com.ydtech.modules.order.entity.BasePageResult;
|
|
|
+import com.ydtech.modules.order.entity.InsAreaCompany;
|
|
|
import com.ydtech.modules.order.entity.api.pingan.utils.PDFUtil;
|
|
|
import com.ydtech.modules.order.entity.dto.InsOrderReadPdfContentDto;
|
|
|
import com.ydtech.modules.order.entity.po.InsOrderReadPdf;
|
|
|
import com.ydtech.modules.order.entity.vo.InsOrderReadPdfContentVo;
|
|
|
import com.ydtech.modules.order.entity.vo.InsOrderReadPdfVo;
|
|
|
+import com.ydtech.modules.order.service.InsAreaCompanyService;
|
|
|
+import com.ydtech.modules.order.service.InsOrderPayDateRecordService;
|
|
|
import com.ydtech.modules.order.service.InsOrderReadPdfService;
|
|
|
import com.ydtech.utils.StringUtils;
|
|
|
import org.springframework.beans.BeanUtils;
|
|
|
@@ -35,6 +41,15 @@ public class InsOrderReadPdfServiceImpl extends ServiceImpl<InsOrderReadPdfMappe
|
|
|
@Autowired
|
|
|
private InsOrderReadPdfMapper insOrderReadPdfMapper;
|
|
|
|
|
|
+ @Autowired
|
|
|
+ private InsAreaCompanyService insAreaCompanyService;
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private InsPlyIncomeService insPlyIncomeService;
|
|
|
+
|
|
|
+ @Autowired
|
|
|
+ private InsOrderPayDateRecordService insOrderPayDateRecordService;
|
|
|
+
|
|
|
@Override
|
|
|
public BasePageResult<InsOrderReadPdf> queryPage(InsOrderReadPdfVo insOrderReadPdfVo) {
|
|
|
Page<InsOrderReadPdf> page = new Page<>(insOrderReadPdfVo.getPageNum(),
|
|
|
@@ -89,4 +104,34 @@ public class InsOrderReadPdfServiceImpl extends ServiceImpl<InsOrderReadPdfMappe
|
|
|
}
|
|
|
return new InsOrderReadPdfContentDto(pdfText,content);
|
|
|
}
|
|
|
+ /**
|
|
|
+ * @version
|
|
|
+ * @author: hxl
|
|
|
+ * @Date: 2024/12/30 10:42
|
|
|
+ * @Description: 手动更新结算表的签单时间
|
|
|
+ */
|
|
|
+ @Override
|
|
|
+ public void updatePlySignDate(String id) {
|
|
|
+ InsPlyIncome ply = insPlyIncomeService.getById(id);
|
|
|
+ if(ply!=null){
|
|
|
+ if(ply.getOrderno() ==null){
|
|
|
+ new SystemException("子订单编号为空不允许更新");
|
|
|
+ }else{
|
|
|
+ InsAreaCompany iac = insAreaCompanyService.getById(ply.getOrderno());
|
|
|
+ //更新子订单的签单时间
|
|
|
+ if(iac.getSigningTime()==null){
|
|
|
+ try{
|
|
|
+ insOrderPayDateRecordService.updateOrderDate(ply.getOrderno());
|
|
|
+ }catch(Exception e){
|
|
|
+ new SystemException("更新保单签单时期失败");
|
|
|
+ }
|
|
|
+ }
|
|
|
+ InsAreaCompany newIac = insAreaCompanyService.getById(ply.getOrderno());
|
|
|
+ if(newIac.getSigningTime()!=null){
|
|
|
+ ply.setSignDate(iac.getSigningTime());
|
|
|
+ insPlyIncomeService.saveOrUpdate(ply);
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|