Compare commits

...

3 Commits

24 changed files with 1428 additions and 348 deletions

View File

@@ -154,7 +154,7 @@ public interface ErrorCodeConstants {
ErrorCode DEVICE_PRODUCT_NOT_EXISTS = new ErrorCode(1_032_150_000, "设备_设备大类不存在");
ErrorCode DEVICE_MAINTAIN_NOT_EXISTS = new ErrorCode(1_032_150_000, "设备维护数据不存在");
ErrorCode DEVICE_MAINTAIN_ITEM_NOT_EXISTS = new ErrorCode(1_032_150_000, "设备维护项不存在");
ErrorCode DEVICE_CONFIG_BUSINESS_RULE_NOT_EXISTS = new ErrorCode(1_032_150_000, "设备业务配置不存在");
ErrorCode DEVICE_CONFIG_BUSINESS_ITEM_NOT_EXISTS = new ErrorCode(1_032_150_000, "设备业务配置项不存在");
ErrorCode DEVICE_PERIOD_CHECK_NOT_EXISTS = new ErrorCode(1_032_150_000, "期间核查数据不存在");
@@ -166,7 +166,8 @@ public interface ErrorCodeConstants {
ErrorCode DEVICE_CALIBRATION_NOT_EXISTS = new ErrorCode(1_032_150_000, "检定校准数据不存在");
ErrorCode DEVICE_USE_RECORD_NOT_EXISTS = new ErrorCode(1_032_150_000, "设备使用记录不存在");
ErrorCode DEVICE_AFFILIATION_RELATIVITY_NOT_EXISTS = new ErrorCode(1_032_150_000, "附属设备关系不存在");
ErrorCode DEVICE_APPLY_DETAIL_NOT_EXISTS = new ErrorCode(1_032_150_000, "设备申请数据不存在");
ErrorCode DEVICE_APPLY_DETAIL_NOT_EXISTS = new ErrorCode(1_032_150_000, "设备申请明细数据不存在");
ErrorCode DEVICE_APPLY_NOT_EXISTS = new ErrorCode(1_032_150_000, "设备申请数据不存在");
// -------------物料试剂-------------

View File

@@ -3,6 +3,8 @@ package com.zt.plat.module.qms.business.reportdoc.controller.admin;
import com.zt.plat.module.qms.business.reportdoc.controller.vo.ReportDocumentFilePageReqVO;
import com.zt.plat.module.qms.business.reportdoc.controller.vo.ReportDocumentFileRespVO;
import com.zt.plat.module.qms.business.reportdoc.controller.vo.ReportDocumentFileSaveReqVO;
import com.zt.plat.module.qms.business.reportdoc.dal.dataobject.ReportDocumentMainDO;
import com.zt.plat.module.qms.business.reportdoc.service.ReportDocumentMainService;
import org.springframework.web.bind.annotation.*;
import jakarta.annotation.Resource;
import org.springframework.validation.annotation.Validated;
@@ -49,8 +51,8 @@ public class ReportDocumentFileController extends AbstractFileUploadController i
}
}
@Resource
private ReportDocumentFileService reportDocumentFileService;
@Resource private ReportDocumentFileService reportDocumentFileService;
@Resource private ReportDocumentMainService reportDocumentMainService;
@PostMapping("/create")
@Operation(summary = "创建检测报告附件")
@@ -94,6 +96,23 @@ public class ReportDocumentFileController extends AbstractFileUploadController i
return success(BeanUtils.toBean(reportDocumentFile, ReportDocumentFileRespVO.class));
}
@GetMapping("/getPdfFileObjByMainId")
@Operation(summary = "获得检测报告附件")
@Parameter(name = "id", description = "编号", required = true, example = "1024")
public CommonResult<ReportDocumentFileRespVO> getPdfFileObjByMainId(ReportDocumentFileSaveReqVO vo) {
Long mainId = vo.getMainId();
Integer version = vo.getVersion();
if(version == null){
ReportDocumentMainDO mainDO = reportDocumentMainService.getReportDocumentMain(mainId);
version = mainDO.getDocumentVersion();
}
ReportDocumentFileDO entity = reportDocumentFileService.getByMainIdAndVersion(mainId, version);
if(entity == null){
return CommonResult.success(null);
}
return success(BeanUtils.toBean(entity, ReportDocumentFileRespVO.class));
}
@GetMapping("/page")
@Operation(summary = "获得检测报告附件分页")
@PreAuthorize("@ss.hasPermission('qms:report-document-file:query')")

View File

@@ -7,6 +7,8 @@ import com.zt.plat.module.qms.business.reportdoc.controller.vo.ReportDocumentFil
import com.zt.plat.module.qms.business.reportdoc.dal.dataobject.ReportDocumentFileDO;
import org.apache.ibatis.annotations.Mapper;
import java.util.List;
/**
* 检测报告附件 Mapper
*
@@ -30,4 +32,19 @@ public interface ReportDocumentFileMapper extends BaseMapperX<ReportDocumentFile
.orderByDesc(ReportDocumentFileDO::getId));
}
default List<ReportDocumentFileDO> selectList(ReportDocumentFileDO reqVO) {
LambdaQueryWrapperX<ReportDocumentFileDO> query = new LambdaQueryWrapperX<>();
query.eqIfPresent(ReportDocumentFileDO::getMainId, reqVO.getMainId())
.eqIfPresent(ReportDocumentFileDO::getFileId, reqVO.getFileId())
.likeIfPresent(ReportDocumentFileDO::getName, reqVO.getName())
.eqIfPresent(ReportDocumentFileDO::getPath, reqVO.getPath())
.eqIfPresent(ReportDocumentFileDO::getUrl, reqVO.getUrl())
.eqIfPresent(ReportDocumentFileDO::getType, reqVO.getType())
.eqIfPresent(ReportDocumentFileDO::getVersion, reqVO.getVersion())
.eqIfPresent(ReportDocumentFileDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
.eqIfPresent(ReportDocumentFileDO::getRemark, reqVO.getRemark())
.orderByDesc(ReportDocumentFileDO::getId);
return selectList(query);
}
}

View File

@@ -0,0 +1,84 @@
package com.zt.plat.module.qms.resource.device.controller.vo;
import lombok.*;
import io.swagger.v3.oas.annotations.media.Schema;
import com.zt.plat.framework.common.pojo.PageParam;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import static com.zt.plat.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
@Schema(description = "管理后台 - 设备通用流程,验收、降级、停用、报废、还原、启用分页 Request VO")
@Data
public class DeviceApplyPageReqVO extends PageParam {
@Schema(description = "业务名称,【字典】【jy_device_lifecycle_bsn_type】验收、降级、停用、报废、还原、启用等", example = "ZT")
private String businessName;
@Schema(description = "申请部门", example = "王五")
private String applyDepartmentName;
@Schema(description = "申请部门ID")
private String applyDepartment;
@Schema(description = "申请人", example = "王五")
private String applyUserName;
@Schema(description = "申请人ID")
private String applyUser;
@Schema(description = "业务编码")
private String businessCode;
@Schema(description = "业务日期")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] businessDate;
@Schema(description = "业务原因")
private String businessReason;
@Schema(description = "业务状态", example = "1")
private String businessStatus;
@Schema(description = "借用人")
private String businessUser;
@Schema(description = "借用人id", example = "14524")
private Long businessUserId;
@Schema(description = "借用部门")
private String businessDepartment;
@Schema(description = "借用部门id", example = "894")
private Long businessDepartmentId;
@Schema(description = "计划归还日期")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] planGivebackDate;
@Schema(description = "归还接收人")
private String givebackReceiveUser;
@Schema(description = "归还接收人id", example = "1528")
private Long givebackReceiveUserId;
@Schema(description = "数据集配置ID", example = "12435")
private Long dataCollectionId;
@Schema(description = "表单数据")
private String formData;
@Schema(description = "流程实例id", example = "15634")
private String flowInstanceId;
@Schema(description = "所属部门")
private String systemDepartmentCode;
@Schema(description = "备注")
private String remark;
@Schema(description = "创建时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] createTime;
}

View File

@@ -0,0 +1,78 @@
package com.zt.plat.module.qms.resource.device.controller.vo;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.*;
import java.time.LocalDateTime;
@Schema(description = "管理后台 - 设备通用流程,验收、降级、停用、报废、还原、启用新增/修改 Request VO")
@Data
public class DeviceApplySaveReqVO {
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "20295")
private Long id;
@Schema(description = "业务名称,【字典】【jy_device_lifecycle_bsn_type】验收、降级、停用、报废、还原、启用等", example = "ZT")
private String businessName;
@Schema(description = "申请部门", example = "王五")
private String applyDepartmentName;
@Schema(description = "申请部门ID")
private String applyDepartment;
@Schema(description = "申请人", example = "王五")
private String applyUserName;
@Schema(description = "申请人ID")
private String applyUser;
@Schema(description = "业务编码")
private String businessCode;
@Schema(description = "业务日期")
private LocalDateTime businessDate;
@Schema(description = "业务原因")
private String businessReason;
@Schema(description = "业务状态", example = "1")
private String businessStatus;
@Schema(description = "借用人")
private String businessUser;
@Schema(description = "借用人id", example = "14524")
private Long businessUserId;
@Schema(description = "借用部门")
private String businessDepartment;
@Schema(description = "借用部门id", example = "894")
private Long businessDepartmentId;
@Schema(description = "计划归还日期")
private LocalDateTime planGivebackDate;
@Schema(description = "归还接收人")
private String givebackReceiveUser;
@Schema(description = "归还接收人id", example = "1528")
private Long givebackReceiveUserId;
@Schema(description = "数据集配置ID", example = "12435")
private Long dataCollectionId;
@Schema(description = "表单数据")
private String formData;
@Schema(description = "流程实例id", example = "15634")
private String flowInstanceId;
@Schema(description = "所属部门")
private String systemDepartmentCode;
@Schema(description = "备注")
private String remark;
}

View File

@@ -0,0 +1,64 @@
package com.zt.plat.module.qms.resource.device.controller.vo;
import lombok.*;
import io.swagger.v3.oas.annotations.media.Schema;
import com.zt.plat.framework.common.pojo.PageParam;
import org.springframework.format.annotation.DateTimeFormat;
import java.time.LocalDateTime;
import static com.zt.plat.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
@Schema(description = "管理后台 - 设备-业务配置分页 Request VO")
@Data
public class DeviceConfigBusinessRulePageReqVO extends PageParam {
@Schema(description = "产品id", example = "28944")
private Long productId;
@Schema(description = "业务领域")
private String businessDomain;
@Schema(description = "是否需要")
private String requireFlag;
@Schema(description = "子业务类型", example = "2")
private String subitemDomainType;
@Schema(description = "频次类型", example = "2")
private String frequencyType;
@Schema(description = "频次")
private String frequency;
@Schema(description = "频次说明")
private String frequencyRemark;
@Schema(description = "报表模板")
private String reportTemplateKey;
@Schema(description = "表单组件")
private String formComponent;
@Schema(description = "处理方法")
private String treatmentMethod;
@Schema(description = "处理人")
private String treatmentUser;
@Schema(description = "检定/校准类型", example = "1")
private String calibrationCheckType;
@Schema(description = "标准/规范")
private String standard;
@Schema(description = "所属部门")
private String systemDepartmentCode;
@Schema(description = "备注")
private String remark;
@Schema(description = "创建时间")
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
private LocalDateTime[] createTime;
}

Some files were not shown because too many files have changed in this diff Show More