Commit 58bd9ce0 authored by 刘林's avatar 刘林

fix(jg):超设计使用年限功能开发

parent c88b1d81
...@@ -48,8 +48,8 @@ public class JgOverDesignServiceLifeDto extends BaseDto { ...@@ -48,8 +48,8 @@ public class JgOverDesignServiceLifeDto extends BaseDto {
@ApiModelProperty(value = "使用登记编号") @ApiModelProperty(value = "使用登记编号")
private String useRegistrationCode; private String useRegistrationCode;
@ApiModelProperty(value = "原使用登记证") @ApiModelProperty(value = "其他附件")
private String originalUseRegistrationCertificate; private String otherAccessories;
@ApiModelProperty(value = "状态") @ApiModelProperty(value = "状态")
private String status; private String status;
...@@ -110,4 +110,7 @@ public class JgOverDesignServiceLifeDto extends BaseDto { ...@@ -110,4 +110,7 @@ public class JgOverDesignServiceLifeDto extends BaseDto {
@ApiModelProperty(value = "创建时间") @ApiModelProperty(value = "创建时间")
private Date createDate; private Date createDate;
@ApiModelProperty(value = "延期使用年限")
private Date delayServiceLife;
} }
...@@ -41,46 +41,10 @@ public class JgOverDesignServiceLife extends BaseEntity { ...@@ -41,46 +41,10 @@ public class JgOverDesignServiceLife extends BaseEntity {
private String useUnitCreditCode; private String useUnitCreditCode;
/** /**
* 安全评估机构名称 * 其他附件
*/ */
@TableField("safety_assessment_name") @TableField("other_accessories")
private String safetyAssessmentName; private String otherAccessories;
/**
* 安全评估机构统一信用代码
*/
@TableField("safety_assessment_credit_code")
private String safetyAssessmentCreditCode;
/**
* 安全评估报告
*/
@TableField("safety_assessment_report")
private String safetyAssessmentReport;
/**
* 安全评估结果
*/
@TableField("safety_assessment_result")
private String safetyAssessmentResult;
/**
* 安全评估日期
*/
@TableField("safety_assessment_date")
private Date safetyAssessmentDate;
/**
* 使用登记编号
*/
@TableField("use_registration_code")
private String useRegistrationCode;
/**
* 原使用登记证
*/
@TableField("original_use_registration_certificate")
private String originalUseRegistrationCertificate;
/** /**
* 状态 * 状态
......
...@@ -52,4 +52,51 @@ public class JgOverDesignServiceLifeEq extends BaseEntity { ...@@ -52,4 +52,51 @@ public class JgOverDesignServiceLifeEq extends BaseEntity {
@TableField("create_user_name") @TableField("create_user_name")
private String createUserName; private String createUserName;
/**
* 设备信息json
*/
@TableField("device_info")
private String deviceInfo;
/**
* 使用登记证
*/
@TableField("use_registration_code")
private String useRegistrationCode;
/**
* 安全评估机构名称
*/
@TableField("safety_assessment_name")
private String safetyAssessmentName;
/**
* 安全评估机构统一信用代码
*/
@TableField("safety_assessment_credit_code")
private String safetyAssessmentCreditCode;
/**
* 安全评估报告
*/
@TableField("safety_assessment_report")
private String safetyAssessmentReport;
/**
* 安全评估结果
*/
@TableField("safety_assessment_result")
private String safetyAssessmentResult;
/**
* 安全评估日期
*/
@TableField("safety_assessment_date")
private Date safetyAssessmentDate;
/**
* 延期使用年限
*/
@TableField("delay_service_life")
private String delayServiceLife;
} }
...@@ -7,6 +7,7 @@ import lombok.Getter; ...@@ -7,6 +7,7 @@ import lombok.Getter;
@AllArgsConstructor @AllArgsConstructor
public enum RegistrationTypeEnum { public enum RegistrationTypeEnum {
新设备首次启用("新设备首次启用","DJ_SY"), 新设备首次启用("新设备首次启用","DJ_SY"),
达到设计使用年限继续使用("达到设计使用年限继续使用","DJ_CSJ"),
历史无证设备登记("历史无证设备登记","SP_TT"); 历史无证设备登记("历史无证设备登记","SP_TT");
private String name; private String name;
......
...@@ -806,9 +806,8 @@ public class CommonController extends BaseController { ...@@ -806,9 +806,8 @@ public class CommonController extends BaseController {
public ResponseModel<Map<String,Object>> getRegistrationChangeCertificateUrl(@RequestBody JSONObject map) { public ResponseModel<Map<String,Object>> getRegistrationChangeCertificateUrl(@RequestBody JSONObject map) {
JSONObject formData = JSONObject.parseObject(JSONObject.toJSONString(map.get("formData"))); JSONObject formData = JSONObject.parseObject(JSONObject.toJSONString(map.get("formData")));
ReginParams selectedOrgInfo = getSelectedOrgInfo(); ReginParams selectedOrgInfo = getSelectedOrgInfo();
String manageType = String.valueOf(map.get("manageType"));
formData.put("userName",selectedOrgInfo.getUserModel().getRealName()); formData.put("userName",selectedOrgInfo.getUserModel().getRealName());
return ResponseHelper.buildResponse(commonService.getRegistrationChangeCertificateUrl(manageType, formData)); return ResponseHelper.buildResponse(commonService.getRegistrationChangeCertificateUrl(formData));
} }
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
......
...@@ -2,6 +2,9 @@ package com.yeejoin.amos.boot.module.jg.biz.controller; ...@@ -2,6 +2,9 @@ package com.yeejoin.amos.boot.module.jg.biz.controller;
import com.alibaba.fastjson.JSONObject; import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.yeejoin.amos.boot.biz.common.bo.ReginParams;
import com.yeejoin.amos.boot.biz.common.utils.RedisKey;
import com.yeejoin.amos.boot.biz.common.utils.RedisUtils;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
...@@ -9,15 +12,14 @@ import org.springframework.web.bind.annotation.RestController; ...@@ -9,15 +12,14 @@ import org.springframework.web.bind.annotation.RestController;
import com.yeejoin.amos.boot.biz.common.controller.BaseController; import com.yeejoin.amos.boot.biz.common.controller.BaseController;
import com.yeejoin.amos.boot.module.jg.biz.service.impl.JgOverDesignServiceLifeServiceImpl; import com.yeejoin.amos.boot.module.jg.biz.service.impl.JgOverDesignServiceLifeServiceImpl;
import org.typroject.tyboot.component.event.RestEventTrigger; import org.typroject.tyboot.component.event.RestEventTrigger;
import org.typroject.tyboot.core.foundation.context.RequestContext;
import org.typroject.tyboot.core.restful.utils.ResponseHelper; import org.typroject.tyboot.core.restful.utils.ResponseHelper;
import org.typroject.tyboot.core.restful.utils.ResponseModel; import org.typroject.tyboot.core.restful.utils.ResponseModel;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import javax.servlet.http.HttpServletRequest;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import com.yeejoin.amos.boot.module.jg.api.entity.JgOverDesignServiceLife; import com.yeejoin.amos.boot.module.jg.api.entity.JgOverDesignServiceLife;
import org.typroject.tyboot.core.restful.doc.TycloudOperation; import org.typroject.tyboot.core.restful.doc.TycloudOperation;
import org.typroject.tyboot.core.foundation.enumeration.UserType; import org.typroject.tyboot.core.foundation.enumeration.UserType;
import java.util.Collections; import java.util.Collections;
import java.util.List; import java.util.List;
...@@ -32,19 +34,21 @@ import java.util.List; ...@@ -32,19 +34,21 @@ import java.util.List;
public class JgOverDesignServiceLifeController extends BaseController { public class JgOverDesignServiceLifeController extends BaseController {
@Autowired @Autowired
JgOverDesignServiceLifeServiceImpl jgOverDesignServiceLifeServiceImpl; private JgOverDesignServiceLifeServiceImpl jgOverDesignServiceLifeServiceImpl;
@Autowired
private RedisUtils redisUtils;
/** /**
* 新增 * 新增
* *
* @return * @return
*/ */
@TycloudOperation(ApiLevel = UserType.AGENCY) @TycloudOperation(ApiLevel = UserType.AGENCY)
@PostMapping(value = "/save") @PostMapping(value = "/save")
@ApiOperation(httpMethod = "POST", value = "新增", notes = "新增") @ApiOperation(httpMethod = "POST", value = "新增", notes = "新增")
public ResponseModel<JgOverDesignServiceLife> save(@RequestBody JgOverDesignServiceLife entity) { public ResponseModel<Object> save(@RequestBody JSONObject map) {
entity = jgOverDesignServiceLifeServiceImpl.createWithModel(entity); ReginParams reginParams = JSONObject.parseObject(redisUtils.get(RedisKey.buildReginKey(RequestContext.getExeUserId(), RequestContext.getToken())).toString(), ReginParams.class);
return ResponseHelper.buildResponse(entity); return ResponseHelper.buildResponse(jgOverDesignServiceLifeServiceImpl.saveOrUpdate(map, reginParams));
} }
/** /**
......
...@@ -265,5 +265,5 @@ public interface ICommonService { ...@@ -265,5 +265,5 @@ public interface ICommonService {
void getRegistrationFormStream(JSONObject formData,String manageType,HttpServletResponse response); void getRegistrationFormStream(JSONObject formData,String manageType,HttpServletResponse response);
Map<String, Object> getRegistrationChangeCertificateUrl(String manageType ,JSONObject formData); Map<String, Object> getRegistrationChangeCertificateUrl(JSONObject formData);
} }
...@@ -104,6 +104,7 @@ import java.net.URLEncoder; ...@@ -104,6 +104,7 @@ import java.net.URLEncoder;
import java.nio.charset.StandardCharsets; import java.nio.charset.StandardCharsets;
import java.nio.file.Files; import java.nio.file.Files;
import java.text.ParseException; import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.time.LocalDateTime; import java.time.LocalDateTime;
import java.time.format.DateTimeFormatter; import java.time.format.DateTimeFormatter;
import java.util.*; import java.util.*;
...@@ -186,6 +187,7 @@ public class CommonServiceImpl implements ICommonService { ...@@ -186,6 +187,7 @@ public class CommonServiceImpl implements ICommonService {
private static final String VEHICLE = "vehicle"; private static final String VEHICLE = "vehicle";
private static final String UNIT = "unit"; private static final String UNIT = "unit";
private static final String SET = "set"; private static final String SET = "set";
private static final String OVER_DESIGN = "overDesign";
@Autowired @Autowired
EquipmentCategoryMapper equipmentCategoryMapper; EquipmentCategoryMapper equipmentCategoryMapper;
@Autowired @Autowired
...@@ -265,6 +267,8 @@ public class CommonServiceImpl implements ICommonService { ...@@ -265,6 +267,8 @@ public class CommonServiceImpl implements ICommonService {
@Autowired @Autowired
private JgUseRegistrationManageServiceImpl jgUseRegistrationManageService; private JgUseRegistrationManageServiceImpl jgUseRegistrationManageService;
@Autowired @Autowired
JgOverDesignServiceLifeServiceImpl jgOverDesignServiceLifeService;
@Autowired
private CodeGenServiceImpl codeGenService; private CodeGenServiceImpl codeGenService;
@Value("${qrcode.prefix:https://sxtzsb.sxsei.com:19435/tzs}") @Value("${qrcode.prefix:https://sxtzsb.sxsei.com:19435/tzs}")
...@@ -1301,7 +1305,7 @@ public class CommonServiceImpl implements ICommonService { ...@@ -1301,7 +1305,7 @@ public class CommonServiceImpl implements ICommonService {
noticeObj.put("receiveOrgCode", !ObjectUtils.isEmpty(basicObj.get("receiveOrgCreditCode")) ? String.valueOf(basicObj.get("receiveOrgCreditCode")) : String.valueOf(basicObj.get("receiveOrgCreditCode1"))); noticeObj.put("receiveOrgCode", !ObjectUtils.isEmpty(basicObj.get("receiveOrgCreditCode")) ? String.valueOf(basicObj.get("receiveOrgCreditCode")) : String.valueOf(basicObj.get("receiveOrgCreditCode1")));
provideMap.put(DWBG_PAGE_ID, noticeObj); provideMap.put(DWBG_PAGE_ID, noticeObj);
JSONObject jsonObject = new JSONObject(provideMap); JSONObject jsonObject = new JSONObject(provideMap);
return jgChangeRegistrationUnitServiceImpl.saveUnitByProjectContraption(submitType,jsonObject, reginParams); return jgChangeRegistrationUnitServiceImpl.saveUnitByProjectContraption(submitType, jsonObject, reginParams);
} else if (type.equals(ApplicationFormTypeEnum.DWBG.getBusinessCode())) { } else if (type.equals(ApplicationFormTypeEnum.DWBG.getBusinessCode())) {
noticeObj.put("receiveOrgCode", !ObjectUtils.isEmpty(basicObj.get("receiveOrgCreditCode")) ? String.valueOf(basicObj.get("receiveOrgCreditCode")) : String.valueOf(basicObj.get("receiveOrgCreditCode1"))); noticeObj.put("receiveOrgCode", !ObjectUtils.isEmpty(basicObj.get("receiveOrgCreditCode")) ? String.valueOf(basicObj.get("receiveOrgCreditCode")) : String.valueOf(basicObj.get("receiveOrgCreditCode1")));
provideMap.put(DWBG_PAGE_ID, noticeObj); provideMap.put(DWBG_PAGE_ID, noticeObj);
...@@ -1335,6 +1339,12 @@ public class CommonServiceImpl implements ICommonService { ...@@ -1335,6 +1339,12 @@ public class CommonServiceImpl implements ICommonService {
noticeObj.put("receiveOrgCode", !ObjectUtils.isEmpty(basicObj.get("receiveOrgCreditCode")) ? String.valueOf(basicObj.get("receiveOrgCreditCode")) : String.valueOf(basicObj.get("receiveOrgCreditCode1"))); noticeObj.put("receiveOrgCode", !ObjectUtils.isEmpty(basicObj.get("receiveOrgCreditCode")) ? String.valueOf(basicObj.get("receiveOrgCreditCode")) : String.valueOf(basicObj.get("receiveOrgCreditCode1")));
JSONObject jsonObject = new JSONObject(noticeObj); JSONObject jsonObject = new JSONObject(noticeObj);
return jgEnableDisableServiceImpl.saveOrUpdate(jsonObject, reginParams); return jgEnableDisableServiceImpl.saveOrUpdate(jsonObject, reginParams);
} else if (type.equals(ApplicationFormTypeEnum.CSJ.getBusinessCode())) {
noticeObj.put("submit", submitType);
noticeObj.put("formType", "add");
noticeObj.put("receiveOrgCode", !ObjectUtils.isEmpty(basicObj.get("receiveOrgCreditCode")) ? String.valueOf(basicObj.get("receiveOrgCreditCode")) : String.valueOf(basicObj.get("receiveOrgCreditCode1")));
JSONObject jsonObject = new JSONObject(noticeObj);
return jgOverDesignServiceLifeService.saveOrUpdate(jsonObject, reginParams);
} }
return null; return null;
} }
...@@ -2252,7 +2262,7 @@ public class CommonServiceImpl implements ICommonService { ...@@ -2252,7 +2262,7 @@ public class CommonServiceImpl implements ICommonService {
return equipmentCategoryMapper.getEquDefineByParentId(parentId); return equipmentCategoryMapper.getEquDefineByParentId(parentId);
} }
public JSONObject buildFile (String manageType, JSONObject jsonObject){ public JSONObject buildFile(String manageType, JSONObject jsonObject) {
JSONObject formData = new JSONObject(); JSONObject formData = new JSONObject();
formData.putAll(jsonObject); formData.putAll(jsonObject);
//去除值为null的key //去除值为null的key
...@@ -2267,81 +2277,81 @@ public class CommonServiceImpl implements ICommonService { ...@@ -2267,81 +2277,81 @@ public class CommonServiceImpl implements ICommonService {
} }
//如果是历史无证的修改类型为SP_TT并且枚举没有在登记类型中 //如果是历史无证的修改类型为SP_TT并且枚举没有在登记类型中
if(Objects.isNull(RegistrationTypeEnum.getNameByType(formData.getString("type"))) && "jg_his_black".equals(formData.getString("dataSource"))){ if (Objects.isNull(RegistrationTypeEnum.getNameByType(formData.getString("type"))) && "jg_his_black".equals(formData.getString("dataSource"))) {
formData.put("type","SP_TT"); formData.put("type", "SP_TT");
} }
//登记类型 //登记类型
if (formData.containsKey("type")){ if (formData.containsKey("type")) {
formData.put("registrationType",RegistrationTypeEnum.getNameByType(formData.getString("type"))); formData.put("registrationType", RegistrationTypeEnum.getNameByType(formData.getString("type")));
} }
for (String key : formData.keySet()) { for (String key : formData.keySet()) {
if (key.contains("Date") && timePattern.matcher(formData.getString(key)).matches()){ if (key.contains("Date") && timePattern.matcher(formData.getString(key)).matches()) {
// 解析原始日期时间字符串 // 解析原始日期时间字符串
LocalDateTime dateTime = LocalDateTime.parse(formData.getString(key), inputFormatter); LocalDateTime dateTime = LocalDateTime.parse(formData.getString(key), inputFormatter);
// 格式化为仅包含年月日的字符串 // 格式化为仅包含年月日的字符串
String formattedDate = dateTime.format(outputFormatter); String formattedDate = dateTime.format(outputFormatter);
formData.put(key,formattedDate); formData.put(key, formattedDate);
} }
} }
//管理员赋值 台套/单位模版 //管理员赋值 台套/单位模版
if (formData.containsKey("safetyManager") && formData.getString("safetyManager").contains("_")){ if (formData.containsKey("safetyManager") && formData.getString("safetyManager").contains("_")) {
formData.put("safetyManagerName",formData.getString("safetyManager").split("_")[1]); formData.put("safetyManagerName", formData.getString("safetyManager").split("_")[1]);
} }
//施工单位及检测监管部门赋值 车用气瓶模版 //施工单位及检测监管部门赋值 车用气瓶模版
if (formData.containsKey("installUnitCode") && formData.getString("installUnitCode").contains("_")){ if (formData.containsKey("installUnitCode") && formData.getString("installUnitCode").contains("_")) {
formData.put("installUnitName",formData.getString("installUnitCode").split("_")[1]); formData.put("installUnitName", formData.getString("installUnitCode").split("_")[1]);
} }
if (formData.containsKey("inspectUnitCreditCode") && formData.getString("inspectUnitCreditCode").contains("_")){ if (formData.containsKey("inspectUnitCreditCode") && formData.getString("inspectUnitCreditCode").contains("_")) {
formData.put("inspectUnitName",formData.getString("inspectUnitCreditCode").split("_")[1]); formData.put("inspectUnitName", formData.getString("inspectUnitCreditCode").split("_")[1]);
} }
//管理员赋值 车用气瓶模版 //管理员赋值 车用气瓶模版
if (formData.containsKey("safetyManagerId") && formData.getString("safetyManagerId").contains("_")){ if (formData.containsKey("safetyManagerId") && formData.getString("safetyManagerId").contains("_")) {
formData.put("safetyManagerName",formData.getString("safetyManagerId").split("_")[1]); formData.put("safetyManagerName", formData.getString("safetyManagerId").split("_")[1]);
} }
formData.put("changeCategory", "达到设计使用年限继续使用"); formData.put("changeCategory", "达到设计使用年限继续使用");
//产权单位赋值 //产权单位赋值
if (formData.containsKey("estateUnitName") && null != formData.getString("estateUnitName") && formData.getString("estateUnitName").contains("_")){ if (formData.containsKey("estateUnitName") && null != formData.getString("estateUnitName") && formData.getString("estateUnitName").contains("_")) {
LambdaQueryWrapper<TzBaseEnterpriseInfo> wrapper = new LambdaQueryWrapper<>(); LambdaQueryWrapper<TzBaseEnterpriseInfo> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(TzBaseEnterpriseInfo::getUseUnitCode,formData.getString("estateUnitName").split("_")[0]); wrapper.eq(TzBaseEnterpriseInfo::getUseUnitCode, formData.getString("estateUnitName").split("_")[0]);
//产权单位联系电话 //产权单位联系电话
TzBaseEnterpriseInfo tzBaseEnterpriseInfo = enterpriseInfoMapper.selectOne(wrapper); TzBaseEnterpriseInfo tzBaseEnterpriseInfo = enterpriseInfoMapper.selectOne(wrapper);
String contactPhone = tzBaseEnterpriseInfo.getContactPhone(); String contactPhone = tzBaseEnterpriseInfo.getContactPhone();
if (StringUtils.isNotEmpty(contactPhone)){ if (StringUtils.isNotEmpty(contactPhone)) {
formData.put("estatePhone",contactPhone); formData.put("estatePhone", contactPhone);
} }
formData.put("CQUnitCode",formData.getString("estateUnitName").split("_")[0]); formData.put("CQUnitCode", formData.getString("estateUnitName").split("_")[0]);
formData.put("estateUnitName",formData.getString("estateUnitName").split("_")[1]); formData.put("estateUnitName", formData.getString("estateUnitName").split("_")[1]);
} }
if (formData.containsKey("equList") ){ if (formData.containsKey("equList")) {
formData.put("equList", EquipmentClassifityEnum.getNameByCode(formData.getString("equList"))); formData.put("equList", EquipmentClassifityEnum.getNameByCode(formData.getString("equList")));
} }
//产品名称 //产品名称
if (formData.containsKey("projectContraption") ){ if (formData.containsKey("projectContraption")) {
formData.put("productName", formData.getString("projectContraption")); formData.put("productName", formData.getString("projectContraption"));
} }
//单位模版 部分字段需从设备列表中获取 //单位模版 部分字段需从设备列表中获取
if (formData.containsKey("equipmentLists") ){ if (formData.containsKey("equipmentLists")) {
JSONArray equipmentLists = formData.getJSONArray("equipmentLists"); JSONArray equipmentLists = formData.getJSONArray("equipmentLists");
List<Map<String, Object>> equips = equipmentLists.stream() List<Map<String, Object>> equips = equipmentLists.stream()
.filter(obj -> obj instanceof Map) .filter(obj -> obj instanceof Map)
.map(obj -> (Map<String, Object>) obj).collect(Collectors.toList()); .map(obj -> (Map<String, Object>) obj).collect(Collectors.toList());
if (manageType.equals(UNIT) && !CollectionUtils.isEmpty(equips)){ if (manageType.equals(UNIT) && !CollectionUtils.isEmpty(equips)) {
//管道计算的是管道长度 //管道计算的是管道长度
if ("8000".equals(formData.getString("equListCode")) || "8000".equals(formData.getString("EQU_LIST_CODE"))){ if ("8000".equals(formData.getString("equListCode")) || "8000".equals(formData.getString("EQU_LIST_CODE"))) {
double pipeLength = equips.stream().filter(Objects::nonNull) double pipeLength = equips.stream().filter(Objects::nonNull)
.filter(map -> map.containsKey("pipeLength") && StringUtils.isNotEmpty((String)map.get("pipeLength"))) .filter(map -> map.containsKey("pipeLength") && StringUtils.isNotEmpty((String) map.get("pipeLength")))
.mapToDouble(map -> Double.parseDouble((String) map.get("pipeLength"))) .mapToDouble(map -> Double.parseDouble((String) map.get("pipeLength")))
.sum(); .sum();
formData.put("equNum", pipeLength +"(m)"); formData.put("equNum", pipeLength + "(m)");
}else { } else {
//设备数量 //设备数量
formData.put("equNum",equipmentLists.size()); formData.put("equNum", equipmentLists.size());
} }
//设备品种 //设备品种
formData.put("equDefine",equips.get(0).get("equDefineName")); formData.put("equDefine", equips.get(0).get("equDefineName"));
Set<String> productNameSet = equips.stream() Set<String> productNameSet = equips.stream()
.filter(Objects::nonNull) // 过滤掉equip为null的情况 .filter(Objects::nonNull) // 过滤掉equip为null的情况
...@@ -2351,103 +2361,151 @@ public class CommonServiceImpl implements ICommonService { ...@@ -2351,103 +2361,151 @@ public class CommonServiceImpl implements ICommonService {
.collect(Collectors.toSet()); // 收集到Set中 .collect(Collectors.toSet()); // 收集到Set中
// 将set转成字符串逗号拼接 // 将set转成字符串逗号拼接
String productName=""; String productName = "";
List<String> sortedProductNameList = new List<String> sortedProductNameList = new
ArrayList<>(productNameSet); ArrayList<>(productNameSet);
if (sortedProductNameList.size() > 3 if (sortedProductNameList.size() > 3
) { ) {
productName = String.join(",", sortedProductNameList.subList(0, 3)) + ",..."; productName = String.join(",", sortedProductNameList.subList(0, 3)) + ",...";
} else } else {
{
productName = String.join(",", sortedProductNameList); productName = String.join(",", sortedProductNameList);
} }
formData.put("productName",productName); formData.put("productName", productName);
}else if (manageType.equals(VEHICLE) && !CollectionUtils.isEmpty(equips)){ } else if (manageType.equals(VEHICLE) && !CollectionUtils.isEmpty(equips)) {
//气瓶数量 //气瓶数量
formData.put("gasNum",equips.size()); formData.put("gasNum", equips.size());
//设备品种 //设备品种
formData.put("equDefineName",equips.get(0).get("equDefineName")); formData.put("equDefineName", equips.get(0).get("equDefineName"));
// 气瓶压力及容积求和 BUG 27524 【现场需求】监管业务-登记管理-使用登记,气瓶特种设备使用登记表气瓶公称压力取最大值 // 气瓶压力及容积求和 BUG 27524 【现场需求】监管业务-登记管理-使用登记,气瓶特种设备使用登记表气瓶公称压力取最大值
// equips.stream().mapToDouble(e -> Optional.ofNullable(e.get("nominalWorkingPressure")).map(v -> Double.valueOf(v.toString())).orElse(0.0)).sum() // equips.stream().mapToDouble(e -> Optional.ofNullable(e.get("nominalWorkingPressure")).map(v -> Double.valueOf(v.toString())).orElse(0.0)).sum()
formData.put("workPressure", equips.stream().mapToDouble(e -> Optional.ofNullable(e.get("nominalWorkingPressure")).map(v -> Double.valueOf(v.toString())).orElse(0.0)).max().getAsDouble()); formData.put("workPressure", equips.stream().mapToDouble(e -> Optional.ofNullable(e.get("nominalWorkingPressure")).map(v -> Double.valueOf(v.toString())).orElse(0.0)).max().getAsDouble());
formData.put("volume", equips.stream().mapToDouble(e -> Optional.ofNullable(e.get("singleBottleVolume")).map(v -> Double.valueOf(v.toString())).orElse(0.0)).sum()); formData.put("volume", equips.stream().mapToDouble(e -> Optional.ofNullable(e.get("singleBottleVolume")).map(v -> Double.valueOf(v.toString())).orElse(0.0)).sum());
Set<String> chargingMedium = equips.stream().map(e -> String.valueOf(e.get("chargingMedium"))).collect(Collectors.toSet()); Set<String> chargingMedium = equips.stream().map(e -> String.valueOf(e.get("chargingMedium"))).collect(Collectors.toSet());
if (chargingMedium.size()>1){ if (chargingMedium.size() > 1) {
throw new BadRequest("充装介质仅可选择同一类型"); throw new BadRequest("充装介质仅可选择同一类型");
}else { } else {
formData.put("chargingMedium",equips.get(0).get("chargingMedium")); formData.put("chargingMedium", equips.get(0).get("chargingMedium"));
} }
} }
} }
//设备类型 台套模版 //设备类型 台套模版
if (formData.containsKey("equDefine") && !manageType.equals(UNIT) ){ if (formData.containsKey("equDefine") && !manageType.equals(UNIT)) {
EquipmentCategory define = equipmentCategoryMapper.selectOne(new LambdaQueryWrapper<EquipmentCategory>() EquipmentCategory define = equipmentCategoryMapper.selectOne(new LambdaQueryWrapper<EquipmentCategory>()
.eq(EquipmentCategory::getCode, formData.getString("equDefine"))); .eq(EquipmentCategory::getCode, formData.getString("equDefine")));
formData.put("equDefine",define != null ? define.getName() : null); formData.put("equDefine", define != null ? define.getName() : null);
} }
//设备类型 台套模版 //设备类型 台套模版
if (formData.containsKey("equCategory") ){ if (formData.containsKey("equCategory")) {
EquipmentCategory category = equipmentCategoryMapper.selectOne(new LambdaQueryWrapper<EquipmentCategory>() EquipmentCategory category = equipmentCategoryMapper.selectOne(new LambdaQueryWrapper<EquipmentCategory>()
.eq(EquipmentCategory::getCode, formData.getString("equCategory"))); .eq(EquipmentCategory::getCode, formData.getString("equCategory")));
formData.put("equCategory",category != null ? category.getName() : null); formData.put("equCategory", category != null ? category.getName() : null);
} }
//设备类型 车用气瓶模版 单位模版 //设备类型 车用气瓶模版 单位模版
if (formData.containsKey("EQU_CATEGORY_CODE") ){ if (formData.containsKey("EQU_CATEGORY_CODE")) {
EquipmentCategory category = equipmentCategoryMapper.selectOne(new LambdaQueryWrapper<EquipmentCategory>() EquipmentCategory category = equipmentCategoryMapper.selectOne(new LambdaQueryWrapper<EquipmentCategory>()
.eq(EquipmentCategory::getCode, formData.getString("EQU_CATEGORY_CODE"))); .eq(EquipmentCategory::getCode, formData.getString("EQU_CATEGORY_CODE")));
formData.put("equCategory",category != null ? category.getName() : null); formData.put("equCategory", category != null ? category.getName() : null);
} }
//检验类型 台套模版 //检验类型 台套模版
if (formData.containsKey("inspectType") ){ if (formData.containsKey("inspectType")) {
formData.put("inspectType", JYJCBusinessTypeEnum.getNameByCode(formData.getString("inspectType")).getName()); formData.put("inspectType", JYJCBusinessTypeEnum.getNameByCode(formData.getString("inspectType")).getName());
} }
//检验结论 台套模版 //检验结论 台套模版
if (formData.containsKey("inspectConclusion") ){ if (formData.containsKey("inspectConclusion")) {
formData.put("inspectConclusion",JYJCResultEnum.getNameByCode(formData.getString("inspectConclusion")).getName()); formData.put("inspectConclusion", JYJCResultEnum.getNameByCode(formData.getString("inspectConclusion")).getName());
} }
if (formData.containsKey("equipId") ){ if (formData.containsKey("equipId")) {
//施工单位名称 //施工单位名称
LambdaQueryWrapper<ConstructionInfo> wrapper = new LambdaQueryWrapper<>(); LambdaQueryWrapper<ConstructionInfo> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(AbstractEquipBaseEntity::getRecord,formData.getString("equipId")); wrapper.eq(AbstractEquipBaseEntity::getRecord, formData.getString("equipId"));
wrapper.orderByDesc(AbstractEquipBaseEntity::getRecDate); wrapper.orderByDesc(AbstractEquipBaseEntity::getRecDate);
wrapper.last("limit 1"); wrapper.last("limit 1");
ConstructionInfo constructionInfo = constructionInfoMapper.selectOne(wrapper); ConstructionInfo constructionInfo = constructionInfoMapper.selectOne(wrapper);
if (Objects.nonNull(constructionInfo) && StringUtils.isNotEmpty(constructionInfo.getUscUnitName())){ if (Objects.nonNull(constructionInfo) && StringUtils.isNotEmpty(constructionInfo.getUscUnitName())) {
formData.put("uscUnitName",constructionInfo.getUscUnitName()); formData.put("uscUnitName", constructionInfo.getUscUnitName());
} }
} }
if (formData.containsKey("useUnitCreditCode") ){ if (formData.containsKey("useUnitCreditCode")) {
LambdaQueryWrapper<TzBaseEnterpriseInfo> wrapper = new LambdaQueryWrapper<>(); LambdaQueryWrapper<TzBaseEnterpriseInfo> wrapper = new LambdaQueryWrapper<>();
wrapper.eq(TzBaseEnterpriseInfo::getUseUnitCode,formData.getString("useUnitCreditCode").split("_")[0]); wrapper.eq(TzBaseEnterpriseInfo::getUseUnitCode, formData.getString("useUnitCreditCode").split("_")[0]);
TzBaseEnterpriseInfo tzBaseEnterpriseInfo = enterpriseInfoMapper.selectOne(wrapper); TzBaseEnterpriseInfo tzBaseEnterpriseInfo = enterpriseInfoMapper.selectOne(wrapper);
//使用单位地址 //使用单位地址
if (Objects.nonNull(tzBaseEnterpriseInfo) && StringUtils.isNotEmpty(tzBaseEnterpriseInfo.getAddress())){ if (Objects.nonNull(tzBaseEnterpriseInfo) && StringUtils.isNotEmpty(tzBaseEnterpriseInfo.getAddress())) {
formData.put("useUnitAddress",tzBaseEnterpriseInfo.getAddress()); formData.put("useUnitAddress", tzBaseEnterpriseInfo.getAddress());
} }
} }
//右下角日期 //右下角日期
formData.put("cruDate",DateUtils.convertDateToString(new Date(), DateUtils.CHN_DATE_PATTERN)); formData.put("cruDate", DateUtils.convertDateToString(new Date(), DateUtils.CHN_DATE_PATTERN));
return formData; return formData;
} }
public List<JSONObject> buildFileForOverDesign(JSONObject jsonObject) {
List<JSONObject> formDataList = new ArrayList<>();
JSONObject formData = new JSONObject();
formData.putAll(jsonObject);
formData.entrySet().removeIf(entry -> entry.getValue() == null);
DateTimeFormatter inputFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd HH:mm:ss");
DateTimeFormatter outputFormatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
if (formData.containsKey("type")) {
formData.put("registrationType", RegistrationTypeEnum.getNameByType(formData.getString("type")));
}
if (formData.containsKey("equListCode")) {
formData.put("equList", EquipmentClassifityEnum.getNameByCode(formData.getString("equListCode")));
}
//多个证进行批量生成
if (formData.containsKey("equipmentLists")) {
JSONArray equipmentLists = formData.getJSONArray("equipmentLists");
List<Map<String, Object>> equips = equipmentLists.stream()
.filter(obj -> obj instanceof Map)
.map(obj -> (Map<String, Object>) obj).collect(Collectors.toList());
if (!CollectionUtils.isEmpty(equips)) {
formData.put("equDefine", equips.get(0).get("EQU_DEFINE"));
formData.put("equCategory", equips.get(0).get("EQU_CATEGORY"));
equips.forEach(v -> {
String useRegistrationCode = Objects.toString(v.get("USE_ORG_CODE"),"");
JgUseRegistrationManage manage = jgUseRegistrationManageService.lambdaQuery()
.eq(JgUseRegistrationManage::getUseRegistrationCode, useRegistrationCode)
.eq(JgUseRegistrationManage::getIsDelete, 0)
.eq(JgUseRegistrationManage::getCertificateStatus,CertificateStatusEnum.YIDENGJI.getName()).one();
formData.put("equCode", v.get("EQU_CODE"));
formData.put("useRegistrationCode", v.get("USE_ORG_CODE"));
formData.put("produceUnitName", v.get("PRODUCE_UNIT_NAME"));
formData.put("produceDate", LocalDateTime.parse(Objects.toString(v.get("PRODUCE_DATE")), inputFormatter).format(outputFormatter));
formData.put("factoryNum", v.get("FACTORY_NUM"));
formData.put("productName", v.get("PRODUCT_NAME"));
formData.put("useUnitName", v.get("USE_UNIT_NAME"));
formData.put("auditPassDate", new SimpleDateFormat("yyyy-MM-dd").format( manage.getAuditPassDate()));
formData.put("receiveCompanyOrgName", manage.getReceiveOrgName());
formData.put("applyNo", manage.getApplyNo());
});
}
}
formData.put("cruDate", DateUtils.convertDateToString(new Date(), DateUtils.CHN_DATE_PATTERN));
formDataList.add(formData);
return formDataList;
}
@Override @Override
public Map<String, Object> getRegistrationFormUrl(String manageType, JSONObject jsonObject) { public Map<String, Object> getRegistrationFormUrl(String manageType, JSONObject jsonObject) {
JSONObject formData = buildFile(manageType, jsonObject); JSONObject formData = buildFile(manageType, jsonObject);
String wordPath; String wordPath;
String fileName; String fileName;
if (UNIT.equals(manageType)){ if (UNIT.equals(manageType)) {
wordPath = "use-registration-form-unit.ftl"; wordPath = "use-registration-form-unit.ftl";
fileName = "台套使用登记表_"; fileName = "台套使用登记表_";
}else if (SET.equals(manageType)){ } else if (SET.equals(manageType)) {
wordPath = "use-registration-form-set.ftl"; wordPath = "use-registration-form-set.ftl";
fileName = "单位使用登记表_"; fileName = "单位使用登记表_";
}else { } else if (OVER_DESIGN.equals(manageType)) {
wordPath = "use-registration-change-certificate.ftl";
fileName = "特种设备使用登记变更证明_";
} else {
wordPath = "use-registration-form-vehicle.ftl"; wordPath = "use-registration-form-vehicle.ftl";
fileName = "车用气瓶使用登记表_"; fileName = "车用气瓶使用登记表_";
formData.put("equipBasicInfoList",formData.containsKey("equipmentLists")?formData.get("equipmentLists"):new JSONArray()); formData.put("equipBasicInfoList", formData.containsKey("equipmentLists") ? formData.get("equipmentLists") : new JSONArray());
} }
// word转pdf // word转pdf
File pdfFile = null; File pdfFile = null;
...@@ -2456,7 +2514,7 @@ public class CommonServiceImpl implements ICommonService { ...@@ -2456,7 +2514,7 @@ public class CommonServiceImpl implements ICommonService {
return MapBuilder.<String, Object>create().put("useRegistrationFormUrl", uploadFile(pdfFile, "useRegistrationFormFiles")).build(); return MapBuilder.<String, Object>create().put("useRegistrationFormUrl", uploadFile(pdfFile, "useRegistrationFormFiles")).build();
} catch (Exception e) { } catch (Exception e) {
throw new RuntimeException(e); throw new RuntimeException(e);
}finally { } finally {
try { try {
Files.deleteIfExists(pdfFile.toPath()); Files.deleteIfExists(pdfFile.toPath());
} catch (Exception e) { } catch (Exception e) {
...@@ -2466,20 +2524,20 @@ public class CommonServiceImpl implements ICommonService { ...@@ -2466,20 +2524,20 @@ public class CommonServiceImpl implements ICommonService {
} }
@Override @Override
public void getRegistrationFormStream(JSONObject formData,String manageType,HttpServletResponse response){ public void getRegistrationFormStream(JSONObject formData, String manageType, HttpServletResponse response) {
formData.putAll( buildFile(manageType, formData));; formData.putAll(buildFile(manageType, formData));
String wordPath; String wordPath;
String fileName; String fileName;
if (UNIT.equals(manageType)){ if (UNIT.equals(manageType)) {
wordPath = "use-registration-form-unit.ftl"; wordPath = "use-registration-form-unit.ftl";
fileName = "台套使用登记表_"; fileName = "台套使用登记表_";
}else if (SET.equals(manageType)){ } else if (SET.equals(manageType)) {
wordPath = "use-registration-form-set.ftl"; wordPath = "use-registration-form-set.ftl";
fileName = "单位使用登记表_"; fileName = "单位使用登记表_";
}else { } else {
wordPath = "use-registration-form-vehicle.ftl"; wordPath = "use-registration-form-vehicle.ftl";
fileName = "车用气瓶使用登记表_"; fileName = "车用气瓶使用登记表_";
formData.put("equipBasicInfoList",formData.get("equipmentLists")); formData.put("equipBasicInfoList", formData.get("equipmentLists"));
} }
// word转pdf // word转pdf
File pdfFile; File pdfFile;
...@@ -2504,71 +2562,67 @@ public class CommonServiceImpl implements ICommonService { ...@@ -2504,71 +2562,67 @@ public class CommonServiceImpl implements ICommonService {
} }
@Override @Override
public Map<String, Object> getRegistrationChangeCertificateUrl(String manageType ,JSONObject jsonObject) { public Map<String, Object> getRegistrationChangeCertificateUrl(JSONObject jsonObject) {
JSONObject formData = buildFile(manageType, jsonObject); List<JSONObject> formDataList = buildFileForOverDesign(jsonObject);
String wordPath; String wordPath = "use-registration-change-certificate.ftl";
String fileName; String fileName = "特种设备使用登记变更证明_";
if (UNIT.equals(manageType)){ List<String> uploadedUrls = new ArrayList<>();
wordPath = "use-registration-form-unit.ftl"; List<File> generatedFiles = new ArrayList<>();
fileName = "台套使用登记表_";
}else if (SET.equals(manageType)){
wordPath = "use-registration-change-certificate.ftl";
fileName = "单位使用登记表_";
}else {
wordPath = "use-registration-form-vehicle.ftl";
fileName = "车用气瓶使用登记表_";
formData.put("equipBasicInfoList",formData.get("equipmentLists"));
}
File pdfFile = null;
try { try {
pdfFile = wordToPdf(fileName, wordPath, formData); for (JSONObject formData : formDataList) {
return MapBuilder.<String, Object>create().put("useRegistrationFormUrl", "").build(); File pdfFile = wordToPdf(fileName, wordPath, formData);
generatedFiles.add(pdfFile);
uploadedUrls.add(uploadFile(pdfFile, "useRegistrationFormFiles"));
}
return MapBuilder.<String, Object>create().put("useRegistrationFormUrl", uploadedUrls).build();
} catch (Exception e) { } catch (Exception e) {
throw new RuntimeException(e); throw new RuntimeException(e);
}finally { } finally {
try { for (File file : generatedFiles) {
Files.deleteIfExists(pdfFile.toPath()); try {
} catch (Exception e) { Files.deleteIfExists(file.toPath());
log.error("文件找不到,删除失败:{}", e); } catch (Exception e) {
log.error("文件找不到,删除失败:{}", e);
}
} }
} }
} }
@Override @Override
public List<EquipmentClassifyDto> getEquClassifyByCode(String parentCode) { public List<EquipmentClassifyDto> getEquClassifyByCode(String parentCode) {
List<EquipmentClassifyDto> equipmentCategoryDtos = commonMapper.getEquClassifyByCode(parentCode); List<EquipmentClassifyDto> equipmentCategoryDtos = commonMapper.getEquClassifyByCode(parentCode);
if (ValidationUtil.isEmpty(equipmentCategoryDtos)) { if (ValidationUtil.isEmpty(equipmentCategoryDtos)) {
return new ArrayList<>(); return new ArrayList<>();
}
Map<String, EquipmentClassifyDto> idToDtoMap = equipmentCategoryDtos.stream()
.collect(Collectors.toMap(EquipmentClassifyDto::getCode, dto -> dto));
List<EquipmentClassifyDto> rootNodes = equipmentCategoryDtos.stream()
.filter(dto -> dto.getParentId().equals("0"))
.collect(Collectors.toList());
equipmentCategoryDtos.forEach(dto -> {
String parentId = dto.getParentId();
if (!ValidationUtil.isEmpty(parentId)) {
EquipmentClassifyDto parent = idToDtoMap.get(parentId);
if (parent != null) {
if (parent.getChildren() == null) {
parent.setChildren(new ArrayList<>());
}
parent.getChildren().add(dto);
}
} }
});
if (!ValidationUtil.isEmpty(parentCode)) { Map<String, EquipmentClassifyDto> idToDtoMap = equipmentCategoryDtos.stream()
return rootNodes.stream() .collect(Collectors.toMap(EquipmentClassifyDto::getCode, dto -> dto));
.flatMap(root -> root.getChildren().stream())
List<EquipmentClassifyDto> rootNodes = equipmentCategoryDtos.stream()
.filter(dto -> dto.getParentId().equals("0"))
.collect(Collectors.toList()); .collect(Collectors.toList());
}
return rootNodes; equipmentCategoryDtos.forEach(dto -> {
} String parentId = dto.getParentId();
if (!ValidationUtil.isEmpty(parentId)) {
EquipmentClassifyDto parent = idToDtoMap.get(parentId);
if (parent != null) {
if (parent.getChildren() == null) {
parent.setChildren(new ArrayList<>());
}
parent.getChildren().add(dto);
}
}
});
if (!ValidationUtil.isEmpty(parentCode)) {
return rootNodes.stream()
.flatMap(root -> root.getChildren().stream())
.collect(Collectors.toList());
}
return rootNodes;
}
/** /**
...@@ -2765,7 +2819,7 @@ public List<EquipmentClassifyDto> getEquClassifyByCode(String parentCode) { ...@@ -2765,7 +2819,7 @@ public List<EquipmentClassifyDto> getEquClassifyByCode(String parentCode) {
// return jgUseRegistrationManageMapper.selectList(queryWrapper).stream() // return jgUseRegistrationManageMapper.selectList(queryWrapper).stream()
// .findFirst() // .findFirst()
// .orElse(null); // .orElse(null);
return jgUseRegistrationManageMapper.getLatestJgUseRegistrationManage(useUnitCreditCode,equDefineCode); return jgUseRegistrationManageMapper.getLatestJgUseRegistrationManage(useUnitCreditCode, equDefineCode);
} }
/** /**
......
...@@ -8,6 +8,7 @@ import com.alibaba.fastjson.JSONObject; ...@@ -8,6 +8,7 @@ import com.alibaba.fastjson.JSONObject;
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper; import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper; import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
import com.yeejoin.amos.boot.biz.common.bo.CompanyBo;
import com.yeejoin.amos.boot.biz.common.bo.ReginParams; import com.yeejoin.amos.boot.biz.common.bo.ReginParams;
import com.yeejoin.amos.boot.biz.common.entity.TzsBaseEntity; import com.yeejoin.amos.boot.biz.common.entity.TzsBaseEntity;
import com.yeejoin.amos.boot.biz.common.utils.RedisKey; import com.yeejoin.amos.boot.biz.common.utils.RedisKey;
...@@ -15,14 +16,25 @@ import com.yeejoin.amos.boot.biz.common.utils.RedisUtils; ...@@ -15,14 +16,25 @@ import com.yeejoin.amos.boot.biz.common.utils.RedisUtils;
import com.yeejoin.amos.boot.module.jg.api.dto.*; import com.yeejoin.amos.boot.module.jg.api.dto.*;
import com.yeejoin.amos.boot.module.jg.api.entity.*; import com.yeejoin.amos.boot.module.jg.api.entity.*;
import com.yeejoin.amos.boot.module.jg.api.enums.BusinessTypeEnum; import com.yeejoin.amos.boot.module.jg.api.enums.BusinessTypeEnum;
import com.yeejoin.amos.boot.module.jg.api.enums.CompanyTypeEnum;
import com.yeejoin.amos.boot.module.jg.api.enums.WorkFlowStatusEnum; import com.yeejoin.amos.boot.module.jg.api.enums.WorkFlowStatusEnum;
import com.yeejoin.amos.boot.module.jg.api.mapper.JgOverDesignServiceLifeEqMapper; import com.yeejoin.amos.boot.module.jg.api.mapper.JgOverDesignServiceLifeEqMapper;
import com.yeejoin.amos.boot.module.jg.api.mapper.JgOverDesignServiceLifeMapper; import com.yeejoin.amos.boot.module.jg.api.mapper.JgOverDesignServiceLifeMapper;
import com.yeejoin.amos.boot.module.jg.api.service.IJgOverDesignServiceLifeService; import com.yeejoin.amos.boot.module.jg.api.service.IJgOverDesignServiceLifeService;
import com.yeejoin.amos.boot.module.jg.biz.config.LocalBadRequest;
import com.yeejoin.amos.boot.module.jg.biz.context.EquipUsedCheckStrategyContext; import com.yeejoin.amos.boot.module.jg.biz.context.EquipUsedCheckStrategyContext;
import com.yeejoin.amos.boot.module.jg.biz.context.FlowingEquipRedisContext;
import com.yeejoin.amos.boot.module.jg.biz.feign.TzsServiceFeignClient;
import com.yeejoin.amos.boot.module.jg.biz.service.ICmWorkflowService;
import com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgInspectionDetectionInfo;
import com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgRegisterInfo; import com.yeejoin.amos.boot.module.ymt.api.entity.IdxBizJgRegisterInfo;
import com.yeejoin.amos.boot.module.ymt.api.enums.ApplicationFormTypeEnum;
import com.yeejoin.amos.boot.module.ymt.api.enums.FlowStatusEnum; import com.yeejoin.amos.boot.module.ymt.api.enums.FlowStatusEnum;
import com.yeejoin.amos.feign.privilege.Privilege;
import com.yeejoin.amos.feign.privilege.model.CompanyModel;
import com.yeejoin.amos.feign.systemctl.model.TaskV2Model; import com.yeejoin.amos.feign.systemctl.model.TaskV2Model;
import com.yeejoin.amos.feign.workflow.model.ActWorkflowBatchDTO;
import com.yeejoin.amos.feign.workflow.model.ActWorkflowStartDTO;
import com.yeejoin.amos.feign.workflow.model.ProcessTaskDTO; import com.yeejoin.amos.feign.workflow.model.ProcessTaskDTO;
import com.yeejoin.amos.feign.workflow.model.TaskResultDTO; import com.yeejoin.amos.feign.workflow.model.TaskResultDTO;
import io.seata.spring.annotation.GlobalTransactional; import io.seata.spring.annotation.GlobalTransactional;
...@@ -30,15 +42,20 @@ import org.redisson.api.RLock; ...@@ -30,15 +42,20 @@ import org.redisson.api.RLock;
import org.redisson.api.RedissonClient; import org.redisson.api.RedissonClient;
import org.springframework.beans.BeanUtils; import org.springframework.beans.BeanUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.http.HttpStatus;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import org.springframework.util.CollectionUtils;
import org.springframework.util.ObjectUtils; import org.springframework.util.ObjectUtils;
import org.springframework.util.StringUtils;
import org.typroject.tyboot.core.foundation.context.RequestContext; import org.typroject.tyboot.core.foundation.context.RequestContext;
import org.typroject.tyboot.core.rdbms.service.BaseService; import org.typroject.tyboot.core.rdbms.service.BaseService;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page; import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.typroject.tyboot.core.restful.exception.instance.BadRequest; import org.typroject.tyboot.core.restful.exception.instance.BadRequest;
import org.typroject.tyboot.core.restful.utils.ResponseModel;
import java.util.*; import java.util.*;
import java.util.concurrent.TimeUnit; import java.util.concurrent.TimeUnit;
import java.util.stream.Collectors;
import static java.util.stream.Collectors.toList; import static java.util.stream.Collectors.toList;
/** /**
...@@ -51,6 +68,8 @@ import static java.util.stream.Collectors.toList; ...@@ -51,6 +68,8 @@ import static java.util.stream.Collectors.toList;
public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesignServiceLife,JgOverDesignServiceLife,JgOverDesignServiceLifeMapper> implements IJgOverDesignServiceLifeService { public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesignServiceLife,JgOverDesignServiceLife,JgOverDesignServiceLifeMapper> implements IJgOverDesignServiceLifeService {
private static final String DEFINITION_KEY = "overDesignServiceLife"; private static final String DEFINITION_KEY = "overDesignServiceLife";
public static final String SUBMIT_TYPE_FLOW = "1";
public static final String SUBMIT_DATA = "0";
private final List<String> NOT_FLOWING_STATE = Arrays.asList("使用单位待提交", "一级受理已驳回", "使用单位已撤回", "已作废"); private final List<String> NOT_FLOWING_STATE = Arrays.asList("使用单位待提交", "一级受理已驳回", "使用单位已撤回", "已作废");
@Autowired @Autowired
private CommonServiceImpl commonService; private CommonServiceImpl commonService;
...@@ -70,6 +89,12 @@ public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesign ...@@ -70,6 +89,12 @@ public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesign
private JgOverDesignServiceLifeEqMapper jgOverDesignServiceLifeEqMapper; private JgOverDesignServiceLifeEqMapper jgOverDesignServiceLifeEqMapper;
@Autowired @Autowired
private IdxBizJgRegisterInfoServiceImpl idxBizJgRegisterInfoService; private IdxBizJgRegisterInfoServiceImpl idxBizJgRegisterInfoService;
@Autowired
private IdxBizJgInspectionDetectionInfoServiceImpl idxBizJgInspectionDetectionInfoService;
@Autowired
private TzsServiceFeignClient tzsServiceFeignClient;
@Autowired
private ICmWorkflowService workflowService;
/** /**
* 分页查询 * 分页查询
...@@ -85,6 +110,192 @@ public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesign ...@@ -85,6 +110,192 @@ public class JgOverDesignServiceLifeServiceImpl extends BaseService<JgOverDesign
return this.queryForList("" , false); return this.queryForList("" , false);
} }
/**
* 新增(提交)车用气瓶
*
* @param map map
* @return list
*/
@Transactional(rollbackFor = Exception.class)
@GlobalTransactional(rollbackFor = Exception.class)
public List<JgOverDesignServiceLife> saveOrUpdate(JSONObject map, ReginParams reginParams) {
CompanyBo company = reginParams.getCompany();
try {
if(SUBMIT_TYPE_FLOW.equals(map.get("submit"))){
JSONArray useRegistrationFormFile = map.getJSONArray("useRegistrationFormFile");
if(CollUtil.isEmpty(useRegistrationFormFile)){
throw new BadRequest("特种设备使用登记变更证明(签章后)为空");
}
}
JgOverDesignServiceLifeDto overDesignDto = JSON.parseObject(JSON.toJSONString(map), JgOverDesignServiceLifeDto.class);
//新增使用登记表字段
Optional.ofNullable(map.get("useRegistrationFormFile"))
.map(JSONObject::toJSONString)
.ifPresent(overDesignDto::setUseRegistrationFormFile);
map.put("userName",reginParams.getUserModel().getRealName());
Map<String, Object> overDesign = commonService.getRegistrationFormUrl("vehicle", map);
if(Objects.nonNull(overDesign)){
overDesignDto.setUseRegistrationFormUrl(String.valueOf(overDesign.get("useRegistrationFormUrl")));
}
List<Map<String, Object>> equipmentLists = (List<Map<String, Object>>) map.get("equipmentLists");
if (CollectionUtils.isEmpty(equipmentLists)) {
throw new BadRequest("请选择设备信息!");
}
if (SUBMIT_TYPE_FLOW.equals(map.get("submit"))) {
this.repeatUsedEquipCheck(equipmentLists,
CompanyTypeEnum.INDIVIDUAL.getName().equals(company.getCompanyType()) ? company.getCompanyCode().split("_")[1] : company.getCompanyCode());
}
List<IdxBizJgInspectionDetectionInfo> inspectionDetectionInfoList = idxBizJgInspectionDetectionInfoService.checkInspectionInfo(
equipmentLists.stream()
.map(v -> (String) v.get("record"))
.collect(Collectors.toList())
);
if (inspectionDetectionInfoList.stream().anyMatch(info ->
ObjectUtils.isEmpty(info) || ObjectUtils.isEmpty(info.getInspectType()) ||
ObjectUtils.isEmpty(info.getInspectConclusion()) || ObjectUtils.isEmpty(info.getInspectOrgCode()))) {
throw new BadRequest("请补充设备检验检测信息后提交!");
}
overDesignDto.setCreateDate(new Date());
overDesignDto.setPromoter(reginParams.getUserModel().getUserId());
if ("个人主体".equals(company.getCompanyType())) {
overDesignDto.setUseUnitName(company.getCompanyName().split("_")[1]);
overDesignDto.setUseUnitCreditCode(company.getCompanyCode().split("_")[1]);
} else {
overDesignDto.setUseUnitName(company.getCompanyName());
overDesignDto.setUseUnitCreditCode(company.getCompanyCode());
}
if (!StringUtils.isEmpty(overDesignDto.getReceiveOrgCode())) {
String[] splitReceiveOrgCode = overDesignDto.getReceiveOrgCode().split("_");
CompanyModel result = Privilege.companyClient.queryByCompanyCode(splitReceiveOrgCode[0]).getResult();
overDesignDto.setReceiveOrgCode(splitReceiveOrgCode[0]);
overDesignDto.setReceiveOrgName(splitReceiveOrgCode[1]);
overDesignDto.setReceiveCompanyCode(result.getCompanyCode());
}
if (!ObjectUtils.isEmpty(map.get("otherAccessories"))) {
overDesignDto.setOtherAccessories(JSONObject.toJSONString(map.get("otherAccessories")));
}
JgOverDesignServiceLife overDesignServiceLife = new JgOverDesignServiceLife();
BeanUtils.copyProperties(overDesignDto, overDesignServiceLife);
overDesignServiceLife.setCreateUserId(reginParams.getUserModel().getUserId());
overDesignServiceLife.setCreateUserName(reginParams.getUserModel().getRealName());
boolean hasId = StringUtils.isEmpty(overDesignDto.getSequenceNbr());
//新增
if (hasId) {
ResponseModel<List<String>> listResponseModel = tzsServiceFeignClient.applicationFormCode(ApplicationFormTypeEnum.CSJ.getCode(), 1);
if (!ObjectUtils.isEmpty(listResponseModel) && listResponseModel.getStatus() != HttpStatus.OK.value()) {
throw new BadRequest("超设计使用年限登记申请单单号获取失败!");
}
String applyNo = listResponseModel.getResult().get(0);
overDesignServiceLife.setApplyNo(applyNo);
overDesignServiceLife.setStatus(SUBMIT_DATA.equals(map.get("submit")) ? WorkFlowStatusEnum.USE_SUBMIT.getPass() : WorkFlowStatusEnum.USE_RECEIVE.getPass());
this.save(overDesignServiceLife);
} else {
// 删除以前设备关联关系
this.getBaseMapper().updateById(overDesignServiceLife);
LambdaQueryWrapper<JgOverDesignServiceLifeEq> lambda = new QueryWrapper<JgOverDesignServiceLifeEq>().lambda();
lambda.eq(JgOverDesignServiceLifeEq::getOverDesignId, overDesignServiceLife.getSequenceNbr());
jgOverDesignServiceLifeEqService.getBaseMapper().delete(lambda);
}
// 更新关联气瓶信息
if (!CollectionUtils.isEmpty(equipmentLists)) {
List<JgOverDesignServiceLifeEq> equipList = new ArrayList<>();
equipmentLists.forEach(device -> {
JgOverDesignServiceLifeEq equip = JSON.parseObject(JSON.toJSONString(device), JgOverDesignServiceLifeEq.class);
equip.setEquId(String.valueOf(device.get("record")));
equip.setOverDesignId(Objects.toString(overDesignServiceLife.getSequenceNbr()));
equip.setDeviceInfo(JSONObject.toJSONString(device));
equip.setUseRegistrationCode(Objects.toString(device.get("USE_ORG_CODE")));
if (!ObjectUtils.isEmpty(device.get("SAFETY_ASSESSMENT_REPORT"))) {
equip.setSafetyAssessmentReport(JSONObject.toJSONString(device.get("SAFETY_ASSESSMENT_REPORT")));
}
equipList.add(equip);
});
jgOverDesignServiceLifeEqService.saveBatch(equipList);
}
if (SUBMIT_TYPE_FLOW.equals(map.get("submit"))) {
List<String> roleListNext = new ArrayList<>();
List<String> roleListAll = new ArrayList<>();
if (StringUtils.isEmpty(overDesignServiceLife.getInstanceId())) {
ActWorkflowBatchDTO actWorkflowBatchDTO = new ActWorkflowBatchDTO();
List<ActWorkflowStartDTO> list = new ArrayList<>();
ActWorkflowStartDTO dto = new ActWorkflowStartDTO();
dto.setProcessDefinitionKey(DEFINITION_KEY);
dto.setBusinessKey(overDesignServiceLife.getApplyNo());
dto.setCompleteFirstTask(Boolean.TRUE);
dto.setNextExecuteUserCompanyCode(overDesignServiceLife.getReceiveCompanyCode());
list.add(dto);
actWorkflowBatchDTO.setProcess(list);
List<ProcessTaskDTO> processTasks = workflowService.startBatch(actWorkflowBatchDTO);
this.buildRoleList(processTasks, roleListNext, roleListAll);
List<WorkflowResultDto> workflowResultDtoList = commonService.buildWorkFlowInfo(processTasks);
if (!ObjectUtils.isEmpty(workflowResultDtoList) && !ObjectUtils.isEmpty(workflowResultDtoList.get(0))) {
WorkflowResultDto workflowResultDto = workflowResultDtoList.get(0);
this.updateData(overDesignServiceLife.getSequenceNbr(), "0", workflowResultDto, Boolean.TRUE, String.valueOf(map.get("equDefineCode")));
}
} else {
// 执行流程
flowExecute(overDesignServiceLife.getSequenceNbr(), overDesignServiceLife.getInstanceId(), "0", "", String.valueOf(map.get("nextTaskId")), String.valueOf(map.get("equDefineCode")));
}
} else {
if (ObjectUtils.isEmpty(map.get("instanceId"))) {
ArrayList<TaskModelDto> list = new ArrayList<>();
TaskModelDto dto = new TaskModelDto();
TaskMessageDto taskMessageDto = new TaskMessageDto();
BeanUtil.copyProperties(overDesignServiceLife, taskMessageDto);
taskMessageDto.setEquipId(String.valueOf(map.get("equipId")));
dto.setModel(taskMessageDto);
dto.setTaskContent("来自超设计使用年限登记业务办理," + "【申请单号:" + overDesignServiceLife.getApplyNo() + "】");
dto.setTaskCode(overDesignServiceLife.getApplyNo());
dto.setTaskType(String.valueOf(BusinessTypeEnum.JG_OVER_DESIGN_SERVICE_LIFE.getCode()));
dto.setRelationId(String.valueOf(overDesignServiceLife.getSequenceNbr()));
dto.setNextExecuteUser("");
list.add(dto);
commonService.buildTaskModel(list);
}
}
commonService.saveOrUpdateHistory(BusinessTypeEnum.JG_OVER_DESIGN_SERVICE_LIFE.getName(), JSON.parseArray(JSON.toJSONString(equipmentLists)), null, overDesignServiceLife.getSequenceNbr() + "");
return Collections.singletonList(overDesignServiceLife);
} catch (BadRequest | LocalBadRequest e) {
log.error(e.getMessage(), e);
this.rollBackForDelRedisData();
throw e;
} catch (Exception e) {
log.error(e.getMessage(), e);
this.rollBackForDelRedisData();
throw new BadRequest("保存失败!");
} finally {
FlowingEquipRedisContext.clean();
}
}
private void buildRoleList(List<ProcessTaskDTO> processTasks, List<String> roleListNext, List<String> roleListAll) {
processTasks.forEach(p -> {
p.getNextCandidateGroups().values().forEach(e -> {
roleListNext.addAll(e);
roleListAll.addAll(e);
});
roleListAll.addAll(p.getCandidateGroups());
});
}
private void rollBackForDelRedisData() {
FlowingEquipRedisContext.getContext().forEach(e -> {
EquipUsedCheckStrategyContext.getUsedStrategy(DEFINITION_KEY)
.delDataForCheckWithKey(e.getData(), e.getRedisKey());
});
}
private void repeatUsedEquipCheck(List<Map<String, Object>> equipList, String companyCode) {
equipList.forEach(equipMap -> EquipUsedCheckStrategyContext.getUsedStrategy(DEFINITION_KEY)
.equipRepeatUsedCheck(String.valueOf(equipMap.get("record")), companyCode));
}
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@GlobalTransactional(rollbackFor = Exception.class) @GlobalTransactional(rollbackFor = Exception.class)
public Boolean deleteBatchBySequenceNbrs(List<Long> sequenceNbrs) { public Boolean deleteBatchBySequenceNbrs(List<Long> sequenceNbrs) {
......
...@@ -11,9 +11,9 @@ ...@@ -11,9 +11,9 @@
<o:Author>刘林</o:Author> <o:Author>刘林</o:Author>
<o:LastAuthor>刘林</o:LastAuthor> <o:LastAuthor>刘林</o:LastAuthor>
<o:Revision>1</o:Revision> <o:Revision>1</o:Revision>
<o:Created>2025-03-19T18:02:00Z</o:Created> <o:Created>2025-03-20T10:02:00Z</o:Created>
<o:LastSaved>2025-03-19T10:53:01Z</o:LastSaved> <o:LastSaved>2025-03-20T17:51:36Z</o:LastSaved>
<o:TotalTime>0</o:TotalTime> <o:TotalTime>40320</o:TotalTime>
<o:Pages>1</o:Pages> <o:Pages>1</o:Pages>
<o:Words>172</o:Words> <o:Words>172</o:Words>
<o:Characters>202</o:Characters> <o:Characters>202</o:Characters>
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
</o:DocumentProperties> </o:DocumentProperties>
<o:CustomDocumentProperties> <o:CustomDocumentProperties>
<o:KSOProductBuildVer dt:dt="string">2052-5.5.1.7991</o:KSOProductBuildVer> <o:KSOProductBuildVer dt:dt="string">2052-5.5.1.7991</o:KSOProductBuildVer>
<o:ICV dt:dt="string">87E155835A6450E38231DA67FCE8BD60_42</o:ICV> <o:ICV dt:dt="string">57F5FE26FB0EA6111DE5DB67C6F321A0_42</o:ICV>
</o:CustomDocumentProperties> </o:CustomDocumentProperties>
<w:fonts> <w:fonts>
<w:defaultFonts w:ascii="Calibri" w:fareast="宋体" w:h-ansi="Calibri" w:cs="Times New Roman"/> <w:defaultFonts w:ascii="Calibri" w:fareast="宋体" w:h-ansi="Calibri" w:cs="Times New Roman"/>
...@@ -589,7 +589,7 @@ ...@@ -589,7 +589,7 @@
<w:p> <w:p>
<w:pPr> <w:pPr>
<w:spacing w:before="78" w:line="213" w:line-rule="auto"/> <w:spacing w:before="78" w:line="213" w:line-rule="auto"/>
<w:ind w:first-line="6200" w:first-line-chars="2500"/> <w:ind w:first-line="5952" w:first-line-chars="2400"/>
<w:rPr> <w:rPr>
<w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:fareast="宋体" w:cs="Arial" w:hint="default"/> <w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:fareast="宋体" w:cs="Arial" w:hint="default"/>
<w:sz w:val="20"/> <w:sz w:val="20"/>
...@@ -842,7 +842,7 @@ ...@@ -842,7 +842,7 @@
<w:spacing w:val="-1"/> <w:spacing w:val="-1"/>
<w:lang w:val="EN-US" w:fareast="ZH-CN"/> <w:lang w:val="EN-US" w:fareast="ZH-CN"/>
</w:rPr> </w:rPr>
<w:t>${(equDefine)!''}</w:t> <w:t>${(equDefine)!'——'}</w:t>
</w:r> </w:r>
</w:p> </w:p>
</w:tc> </w:tc>
...@@ -1457,7 +1457,7 @@ ...@@ -1457,7 +1457,7 @@
<w:spacing w:val="-1"/> <w:spacing w:val="-1"/>
<w:lang w:val="EN-US" w:fareast="ZH-CN"/> <w:lang w:val="EN-US" w:fareast="ZH-CN"/>
</w:rPr> </w:rPr>
<w:t>${(changeCategory)!''}</w:t> <w:t>${(registrationType)!''}</w:t>
</w:r> </w:r>
</w:p> </w:p>
</w:tc> </w:tc>
...@@ -1480,7 +1480,7 @@ ...@@ -1480,7 +1480,7 @@
</w:tblCellMar> </w:tblCellMar>
</w:tblPrEx> </w:tblPrEx>
<w:trPr> <w:trPr>
<w:trHeight w:val="6433" w:h-rule="atLeast"/> <w:trHeight w:val="5950" w:h-rule="atLeast"/>
</w:trPr> </w:trPr>
<w:tc> <w:tc>
<w:tcPr> <w:tcPr>
...@@ -1663,42 +1663,6 @@ ...@@ -1663,42 +1663,6 @@
</w:p> </w:p>
<w:p> <w:p>
<w:pPr> <w:pPr>
<w:kinsoku w:val="off"/>
<w:autoSpaceDE w:val="off"/>
<w:autoSpaceDN w:val="off"/>
<w:adjustRightInd w:val="off"/>
<w:snapToGrid w:val="off"/>
<w:spacing w:line="249" w:line-rule="auto"/>
<w:jc w:val="left"/>
<w:textAlignment w:val="baseline"/>
<w:rPr>
<w:rFonts w:ascii="Arial" w:hint="default"/>
<w:sz w:val="21"/>
</w:rPr>
</w:pPr>
</w:p>
<w:p>
<w:pPr>
<w:pStyle w:val="a5"/>
<w:spacing w:before="78" w:line="219" w:line-rule="auto"/>
<w:ind w:left="4962"/>
<w:rPr>
<w:spacing w:val="4"/>
</w:rPr>
</w:pPr>
</w:p>
<w:p>
<w:pPr>
<w:pStyle w:val="a5"/>
<w:spacing w:before="78" w:line="219" w:line-rule="auto"/>
<w:ind w:left="4962"/>
<w:rPr>
<w:spacing w:val="4"/>
</w:rPr>
</w:pPr>
</w:p>
<w:p>
<w:pPr>
<w:pStyle w:val="a5"/> <w:pStyle w:val="a5"/>
<w:spacing w:before="78" w:line="219" w:line-rule="auto"/> <w:spacing w:before="78" w:line="219" w:line-rule="auto"/>
<w:ind w:left="4962"/> <w:ind w:left="4962"/>
...@@ -1721,7 +1685,7 @@ ...@@ -1721,7 +1685,7 @@
<w:pPr> <w:pPr>
<w:pStyle w:val="a5"/> <w:pStyle w:val="a5"/>
<w:spacing w:before="78" w:line="219" w:line-rule="auto"/> <w:spacing w:before="78" w:line="219" w:line-rule="auto"/>
<w:ind w:left="4962"/> <w:ind w:first-line="3720" w:first-line-chars="1500"/>
<w:rPr> <w:rPr>
<w:spacing w:val="4"/> <w:spacing w:val="4"/>
</w:rPr> </w:rPr>
...@@ -1731,7 +1695,7 @@ ...@@ -1731,7 +1695,7 @@
<w:pPr> <w:pPr>
<w:pStyle w:val="a5"/> <w:pStyle w:val="a5"/>
<w:spacing w:before="78" w:line="219" w:line-rule="auto"/> <w:spacing w:before="78" w:line="219" w:line-rule="auto"/>
<w:ind w:left="4962"/> <w:ind w:first-line="3720" w:first-line-chars="1500"/>
<w:rPr> <w:rPr>
<w:spacing w:val="4"/> <w:spacing w:val="4"/>
</w:rPr> </w:rPr>
...@@ -1741,7 +1705,7 @@ ...@@ -1741,7 +1705,7 @@
<w:pPr> <w:pPr>
<w:pStyle w:val="a5"/> <w:pStyle w:val="a5"/>
<w:spacing w:before="78" w:line="219" w:line-rule="auto"/> <w:spacing w:before="78" w:line="219" w:line-rule="auto"/>
<w:ind w:left="4962"/> <w:ind w:first-line="3720" w:first-line-chars="1500"/>
<w:rPr> <w:rPr>
<w:spacing w:val="4"/> <w:spacing w:val="4"/>
</w:rPr> </w:rPr>
...@@ -1751,9 +1715,10 @@ ...@@ -1751,9 +1715,10 @@
<w:pPr> <w:pPr>
<w:pStyle w:val="a5"/> <w:pStyle w:val="a5"/>
<w:spacing w:before="78" w:line="219" w:line-rule="auto"/> <w:spacing w:before="78" w:line="219" w:line-rule="auto"/>
<w:ind w:left="4962"/> <w:ind w:first-line="3968" w:first-line-chars="1600"/>
<w:rPr> <w:rPr>
<w:rFonts w:hint="fareast"/> <w:rFonts w:ascii="宋体" w:h-ansi="宋体" w:fareast="宋体" w:cs="宋体"
w:hint="fareast"/>
<w:spacing w:val="-1"/> <w:spacing w:val="-1"/>
<w:lang w:val="EN-US" w:fareast="ZH-CN"/> <w:lang w:val="EN-US" w:fareast="ZH-CN"/>
</w:rPr> </w:rPr>
...@@ -1780,7 +1745,8 @@ ...@@ -1780,7 +1745,8 @@
<w:spacing w:before="78" w:line="219" w:line-rule="auto"/> <w:spacing w:before="78" w:line="219" w:line-rule="auto"/>
<w:ind w:left="4962"/> <w:ind w:left="4962"/>
<w:rPr> <w:rPr>
<w:rFonts w:hint="default"/> <w:rFonts w:ascii="宋体" w:h-ansi="宋体" w:fareast="宋体" w:cs="宋体"
w:hint="fareast"/>
<w:spacing w:val="-1"/> <w:spacing w:val="-1"/>
<w:lang w:val="EN-US" w:fareast="ZH-CN"/> <w:lang w:val="EN-US" w:fareast="ZH-CN"/>
</w:rPr> </w:rPr>
...@@ -1789,8 +1755,8 @@ ...@@ -1789,8 +1755,8 @@
<w:p> <w:p>
<w:pPr> <w:pPr>
<w:pStyle w:val="a5"/> <w:pStyle w:val="a5"/>
<w:spacing w:before="20" w:line="228" w:line-rule="auto"/> <w:spacing w:before="78" w:line="219" w:line-rule="auto"/>
<w:ind w:left="6324"/> <w:ind w:first-line="6426" w:first-line-chars="2700"/>
<w:rPr> <w:rPr>
<w:sz w:val="20"/> <w:sz w:val="20"/>
<w:sz-cs w:val="20"/> <w:sz-cs w:val="20"/>
...@@ -1798,92 +1764,22 @@ ...@@ -1798,92 +1764,22 @@
</w:pPr> </w:pPr>
<w:r> <w:r>
<w:rPr> <w:rPr>
<w:spacing w:val="6"/> <w:rFonts w:ascii="宋体" w:h-ansi="宋体" w:fareast="宋体" w:cs="宋体"
<w:sz w:val="20"/> w:hint="fareast"/>
<w:sz-cs w:val="20"/> <w:spacing w:val="-1"/>
</w:rPr>
<w:t></w:t>
</w:r>
<w:r>
<w:rPr>
<w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:fareast="Arial" w:cs="Arial"
w:hint="default"/>
<w:spacing w:val="6"/>
<w:sz w:val="20"/>
<w:sz-cs w:val="20"/>
</w:rPr>
<w:t></w:t>
</w:r>
<w:r>
<w:rPr>
<w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:fareast="Arial" w:cs="Arial"
w:hint="default"/>
<w:spacing w:val="6"/>
<w:sz w:val="20"/>
<w:sz-cs w:val="20"/>
</w:rPr>
<w:t></w:t>
</w:r>
<w:r>
<w:rPr>
<w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:cs="Arial" w:hint="fareast"/>
<w:spacing w:val="6"/>
<w:sz w:val="20"/>
<w:sz-cs w:val="20"/>
<w:lang w:val="EN-US" w:fareast="ZH-CN"/>
</w:rPr>
<w:t></w:t>
</w:r>
<w:r>
<w:rPr>
<w:spacing w:val="6"/>
<w:sz w:val="20"/>
<w:sz-cs w:val="20"/>
</w:rPr>
<w:t></w:t>
</w:r>
<w:r>
<w:rPr>
<w:rFonts w:hint="fareast"/>
<w:spacing w:val="6"/>
<w:sz w:val="20"/>
<w:sz-cs w:val="20"/>
<w:lang w:val="EN-US" w:fareast="ZH-CN"/> <w:lang w:val="EN-US" w:fareast="ZH-CN"/>
</w:rPr> </w:rPr>
<w:t></w:t> <w:t>${(cruDate)!''}</w:t>
</w:r>
<w:r>
<w:rPr>
<w:rFonts w:hint="default"/>
<w:spacing w:val="6"/>
<w:sz w:val="20"/>
<w:sz-cs w:val="20"/>
<w:lang w:fareast="ZH-CN"/>
</w:rPr>
<w:t></w:t>
</w:r>
<w:r>
<w:rPr>
<w:rFonts w:ascii="Arial" w:h-ansi="Arial" w:fareast="Arial" w:cs="Arial"
w:hint="default"/>
<w:spacing w:val="6"/>
<w:sz w:val="20"/>
<w:sz-cs w:val="20"/>
</w:rPr>
<w:t></w:t>
</w:r>
<w:r>
<w:rPr>
<w:spacing w:val="6"/>
<w:sz w:val="20"/>
<w:sz-cs w:val="20"/>
</w:rPr>
<w:t></w:t>
</w:r> </w:r>
</w:p> </w:p>
</w:tc> </w:tc>
</w:tr> </w:tr>
</w:tbl> </w:tbl>
<w:p/> <w:p/>
<w:sectPr>
<w:pgSz w:w="11906" w:h="16838"/>
<w:cols w:space="0"/>
<w:docGrid w:type="lines" w:line-pitch="312"/>
</w:sectPr>
</wx:sect> </wx:sect>
</w:body></w:wordDocument> </w:body></w:wordDocument>
\ No newline at end of file
...@@ -34,6 +34,7 @@ public enum ApplicationFormTypeEnum { ...@@ -34,6 +34,7 @@ public enum ApplicationFormTypeEnum {
BF("BF", "BF_ZX"),//电梯(设备)报废注销 BF("BF", "BF_ZX"),//电梯(设备)报废注销
GMBG("GMBG", "DJ_GM"),//更名变更 GMBG("GMBG", "DJ_GM"),//更名变更
SBQY("SBQY", "SB_QY"),//设备启用 SBQY("SBQY", "SB_QY"),//设备启用
CSJ("CSJ", "DJ_CSJ"),//超设计年限
SBTY("SBTY", "SB_TY");//设备启用 SBTY("SBTY", "SB_TY");//设备启用
/** /**
......
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