尝试代码合并
This commit is contained in:
19
pom.xml
19
pom.xml
@@ -8,12 +8,7 @@
|
|||||||
<version>${revision}</version>
|
<version>${revision}</version>
|
||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
<modules>
|
<modules>
|
||||||
<module>yudao-module-jy-business</module>
|
<module>yudao-dependencies</module>
|
||||||
<module>yudao-module-jy-manage</module>
|
|
||||||
<module>yudao-module-jy-resource</module>
|
|
||||||
<module>yudao-module-jy-office</module>
|
|
||||||
<module>yudao-module-jy-report</module>
|
|
||||||
<module>yudao-module-jy-iot</module>
|
|
||||||
<module>qms-server</module>
|
<module>qms-server</module>
|
||||||
</modules>
|
</modules>
|
||||||
|
|
||||||
@@ -155,7 +150,6 @@
|
|||||||
<name>aliyun</name>
|
<name>aliyun</name>
|
||||||
<url>https://maven.aliyun.com/repository/public</url>
|
<url>https://maven.aliyun.com/repository/public</url>
|
||||||
</repository>
|
</repository>
|
||||||
|
|
||||||
<repository>
|
<repository>
|
||||||
<id>spring-milestones</id>
|
<id>spring-milestones</id>
|
||||||
<name>Spring Milestones</name>
|
<name>Spring Milestones</name>
|
||||||
@@ -176,9 +170,14 @@
|
|||||||
<id>ZT</id>
|
<id>ZT</id>
|
||||||
<name>中铜 ZStack 私服</name>
|
<name>中铜 ZStack 私服</name>
|
||||||
<url>http://172.16.46.63:30708/repository/maven-hosted/</url>
|
<url>http://172.16.46.63:30708/repository/maven-hosted/</url>
|
||||||
<releases>
|
<!-- <releases>-->
|
||||||
<enabled>false</enabled>
|
<!-- <enabled>false</enabled>-->
|
||||||
</releases>
|
<!-- </releases>-->
|
||||||
|
</repository>
|
||||||
|
<repository>
|
||||||
|
<id>zzjc-release</id>
|
||||||
|
<name>Release Repository</name>
|
||||||
|
<url>https://nexus.will-way.cn/repository/zzjc-releases/</url>
|
||||||
</repository>
|
</repository>
|
||||||
</repositories>
|
</repositories>
|
||||||
|
|
||||||
|
|||||||
@@ -9,109 +9,13 @@
|
|||||||
</parent>
|
</parent>
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<artifactId>qms-server</artifactId>
|
<artifactId>qms-server</artifactId>
|
||||||
<packaging>jar</packaging>
|
<packaging>pom</packaging>
|
||||||
|
|
||||||
<name>qms-server</name>
|
<name>qms-server</name>
|
||||||
<description>Qms 服务器</description>
|
<description>Qms 服务器</description>
|
||||||
|
<modules>
|
||||||
<dependencies>
|
<module>yudao-module-qms-api</module>
|
||||||
<dependency>
|
<module>yudao-module-qms-server</module>
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
</modules>
|
||||||
<artifactId>yudao-module-system-api</artifactId>
|
|
||||||
<version>${revision}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
|
||||||
<artifactId>yudao-module-infra-api</artifactId>
|
|
||||||
<version>${revision}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
|
||||||
<artifactId>yudao-module-jy-business-server</artifactId>
|
|
||||||
<version>${revision}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
|
||||||
<artifactId>yudao-module-jy-manage-server</artifactId>
|
|
||||||
<version>${revision}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
|
||||||
<artifactId>yudao-module-jy-resource-server</artifactId>
|
|
||||||
<version>${revision}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
|
||||||
<artifactId>yudao-module-jy-office-server</artifactId>
|
|
||||||
<version>${revision}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
|
||||||
<artifactId>yudao-module-jy-report-server</artifactId>
|
|
||||||
<version>${revision}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
|
||||||
<artifactId>yudao-module-jy-iot-server</artifactId>
|
|
||||||
<version>${revision}</version>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>org.springframework.boot</groupId>
|
|
||||||
<artifactId>spring-boot-configuration-processor</artifactId>
|
|
||||||
<optional>true</optional>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<!-- 服务保障相关 -->
|
|
||||||
<dependency>
|
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
|
||||||
<artifactId>yudao-spring-boot-starter-protection</artifactId>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<!-- Registry 注册中心相关 -->
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.alibaba.cloud</groupId>
|
|
||||||
<artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<!-- Config 配置中心相关 -->
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.alibaba.cloud</groupId>
|
|
||||||
<artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
<!-- RPC 远程调用相关 -->
|
|
||||||
<dependency>
|
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
|
||||||
<artifactId>yudao-spring-boot-starter-rpc</artifactId>
|
|
||||||
<!-- 目的:yudao-server 单体启动,禁用 openfeign -->
|
|
||||||
<exclusions>
|
|
||||||
<exclusion>
|
|
||||||
<groupId>org.springframework.cloud</groupId>
|
|
||||||
<artifactId>spring-cloud-starter-openfeign</artifactId>
|
|
||||||
</exclusion>
|
|
||||||
</exclusions>
|
|
||||||
</dependency>
|
|
||||||
|
|
||||||
</dependencies>
|
|
||||||
|
|
||||||
<build>
|
|
||||||
<!-- 设置构建的 jar 包名 -->
|
|
||||||
<finalName>${project.artifactId}</finalName>
|
|
||||||
<plugins>
|
|
||||||
<!-- 打包 -->
|
|
||||||
<plugin>
|
|
||||||
<groupId>org.springframework.boot</groupId>
|
|
||||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
|
||||||
<version>${spring.boot.version}</version>
|
|
||||||
<executions>
|
|
||||||
<execution>
|
|
||||||
<goals>
|
|
||||||
<goal>repackage</goal> <!-- 将引入的 jar 打入其中 -->
|
|
||||||
</goals>
|
|
||||||
</execution>
|
|
||||||
</executions>
|
|
||||||
</plugin>
|
|
||||||
</plugins>
|
|
||||||
</build>
|
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
87
qms-server/pom_bak.xml
Normal file
87
qms-server/pom_bak.xml
Normal file
@@ -0,0 +1,87 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<project xmlns="http://maven.apache.org/POM/4.0.0"
|
||||||
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
|
<parent>
|
||||||
|
<groupId>cn.iocoder.cloud</groupId>
|
||||||
|
<artifactId>dsc-qms</artifactId>
|
||||||
|
<version>${revision}</version>
|
||||||
|
</parent>
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<artifactId>qms-server</artifactId>
|
||||||
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
|
<name>qms-server</name>
|
||||||
|
<description>Qms 服务器</description>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<dependency>
|
||||||
|
<groupId>cn.iocoder.cloud</groupId>
|
||||||
|
<artifactId>yudao-module-system-api</artifactId>
|
||||||
|
<version>${revision}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>cn.iocoder.cloud</groupId>
|
||||||
|
<artifactId>yudao-module-infra-api</artifactId>
|
||||||
|
<version>${revision}</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-configuration-processor</artifactId>
|
||||||
|
<optional>true</optional>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- 服务保障相关 -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>cn.iocoder.cloud</groupId>
|
||||||
|
<artifactId>yudao-spring-boot-starter-protection</artifactId>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- Registry 注册中心相关 -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.alibaba.cloud</groupId>
|
||||||
|
<artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- Config 配置中心相关 -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.alibaba.cloud</groupId>
|
||||||
|
<artifactId>spring-cloud-starter-alibaba-nacos-config</artifactId>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- RPC 远程调用相关 -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>cn.iocoder.cloud</groupId>
|
||||||
|
<artifactId>yudao-spring-boot-starter-rpc</artifactId>
|
||||||
|
<!-- 目的:yudao-server 单体启动,禁用 openfeign -->
|
||||||
|
<exclusions>
|
||||||
|
<exclusion>
|
||||||
|
<groupId>org.springframework.cloud</groupId>
|
||||||
|
<artifactId>spring-cloud-starter-openfeign</artifactId>
|
||||||
|
</exclusion>
|
||||||
|
</exclusions>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
</dependencies>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<!-- 设置构建的 jar 包名 -->
|
||||||
|
<finalName>${project.artifactId}</finalName>
|
||||||
|
<plugins>
|
||||||
|
<!-- 打包 -->
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||||
|
<version>${spring.boot.version}</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<goals>
|
||||||
|
<goal>repackage</goal> <!-- 将引入的 jar 打入其中 -->
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
</project>
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
package cn.iocoder.yudao.qms.controller.qms;
|
package cn.iocoder.yudao.qms.controller.qms;
|
||||||
|
|
||||||
import io.swagger.v3.oas.annotations.Operation;
|
//import io.swagger.v3.oas.annotations.Operation;
|
||||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
//import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
import org.springframework.web.bind.annotation.GetMapping;
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
import org.springframework.web.bind.annotation.RequestMapping;
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
@@ -15,13 +15,13 @@ import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
|||||||
*
|
*
|
||||||
* @author ZT
|
* @author ZT
|
||||||
*/
|
*/
|
||||||
@Tag(name = "qms")
|
//@Tag(name = "qms")
|
||||||
@RestController
|
@RestController
|
||||||
@RequestMapping("/qms")
|
@RequestMapping("/qms")
|
||||||
public class QmsController {
|
public class QmsController {
|
||||||
|
|
||||||
@GetMapping("/hello")
|
@GetMapping("/hello")
|
||||||
@Operation(summary = "Hello qms")
|
// @Operation(summary = "Hello qms")
|
||||||
public CommonResult<String> hello() {
|
public CommonResult<String> hello() {
|
||||||
return success("Hello, qms!");
|
return success("Hello, qms!");
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,12 +3,12 @@
|
|||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
<parent>
|
<parent>
|
||||||
<artifactId>yudao-module-jy-iot</artifactId>
|
<artifactId>qms-server</artifactId>
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
<groupId>cn.iocoder.cloud</groupId>
|
||||||
<version>${revision}</version>
|
<version>${revision}</version>
|
||||||
</parent>
|
</parent>
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<artifactId>yudao-module-jy-iot-api</artifactId>
|
<artifactId>yudao-module-qms-api</artifactId>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<name>${project.artifactId}</name>
|
<name>${project.artifactId}</name>
|
||||||
@@ -0,0 +1,83 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.enums;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.exception.ErrorCode;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>ErrorCodeConstants</b>
|
||||||
|
* 错误码枚举类
|
||||||
|
* qms 系统,使用 1_200_000_000 段
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年8月29日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年8月28日
|
||||||
|
*/
|
||||||
|
public interface ErrorCodeConstants {
|
||||||
|
|
||||||
|
/*==============================common===============================*/
|
||||||
|
ErrorCode MISS_PARAMETER = new ErrorCode(500, "缺少参数");
|
||||||
|
ErrorCode SQL_INJECTION_EXCEPTION = new ErrorCode(500, "表名不合法,存在SQL注入风险,联系管理员处理");
|
||||||
|
|
||||||
|
ErrorCode DATA_COLLECTION_NOT_EXISTS = new ErrorCode(1_200_000_000, "数据集不存在");
|
||||||
|
ErrorCode DATA_COLLECTION_CLASSIFY_DUPLICATE = new ErrorCode(500, "分类名称重复,请重新输入");
|
||||||
|
ErrorCode DATA_COLLECTION_CLASSIFY_PARENT_ERROR = new ErrorCode(800, "上级分类不能设置为当前分类及其的后代分类");
|
||||||
|
ErrorCode DATA_COLLECTION_FIELD_NOT_EXISTS = new ErrorCode(1_200_000_000, "数据集字段不存在");
|
||||||
|
|
||||||
|
ErrorCode DICTIONARY_BUSINESS_NOT_EXISTS = new ErrorCode(500, "业务参数字典不存在");
|
||||||
|
|
||||||
|
ErrorCode DICTIONARY_BUSINESS_DATA_MORE_THAN_ONE = new ErrorCode(500, "业务参数字典[数据]key重名,请联系管理员处理!");
|
||||||
|
ErrorCode DICTIONARY_BUSINESS_CATEGORY_MORE_THAN_ONE = new ErrorCode(500, "业务参数字典[分类]key重名,请联系管理员处理!");
|
||||||
|
ErrorCode DICTIONARY_BUSINESS_CLASSIFY_DUPLICATE = new ErrorCode(500, "分类名称重复,请重新输入");
|
||||||
|
|
||||||
|
|
||||||
|
/*==============================config===============================*/
|
||||||
|
ErrorCode CONFIG_REPORT_TEMPLATE_NOT_EXISTS = new ErrorCode(1_200_000_000, "报表模版配置不存在");
|
||||||
|
ErrorCode CONFIG_ASSAY_METHOD_NOT_EXISTS = new ErrorCode(1_200_000_000, "检测方法配置不存在");
|
||||||
|
ErrorCode CONFIG_ASSAY_METHOD_PROJECT_NOT_EXISTS = new ErrorCode(1_200_000_000, "检测方法分析项目配置不存在");
|
||||||
|
ErrorCode CONFIG_REPORT_FIELD_NOT_EXISTS = new ErrorCode(1_200_000_000, "报表字段配置不存在");
|
||||||
|
ErrorCode CONFIG_STANDARD_SAMPLE_TYPE_NOT_EXISTS = new ErrorCode(1_200_000_000, "标准样类型配置不存在");
|
||||||
|
ErrorCode CONFIG_STANDARD_SAMPLE_PROJECT_NOT_EXISTS = new ErrorCode(1_200_000_000, "标准样检测项目配置不存在");
|
||||||
|
ErrorCode CONFIG_SUB_SAMPLE_PARENT_NOT_EXISTS = new ErrorCode(1_200_000_000, "分样配置不存在");
|
||||||
|
ErrorCode CONFIG_SUB_SAMPLE_METHOD_NOT_EXISTS = new ErrorCode(1_200_000_000, "子样与检测方法配置不存在");
|
||||||
|
ErrorCode CONFIG_SUB_SAMPLE_NOT_EXISTS = new ErrorCode(1_200_000_000, "子样配置不存在");
|
||||||
|
ErrorCode CONFIG_SAMPLE_REPORT_NOT_EXISTS = new ErrorCode(1_200_000_000, "样品报表关系不存在");
|
||||||
|
ErrorCode CONFIG_SAMPLE_FLOW_NOT_EXISTS = new ErrorCode(1_200_000_000, "样品流程配置不存在");
|
||||||
|
ErrorCode CONFIG_REPORT_TYPE_NOT_EXISTS = new ErrorCode(1_200_000_000, "报表类型配置不存在");
|
||||||
|
ErrorCode CONFIG_PROJECT_NOT_EXISTS = new ErrorCode(1_200_000_000, "检测项目配置不存在");
|
||||||
|
ErrorCode CONFIG_ENTRUST_SOURCE_NOT_EXISTS = new ErrorCode(1_200_000_000, "检验委托来源配置不存在");
|
||||||
|
ErrorCode CONFIG_DOCUMENT_TYPE_NOT_EXISTS = new ErrorCode(1_200_000_000, "报告类型配置不存在");
|
||||||
|
ErrorCode CONFIG_BASE_SAMPLE_NOT_EXISTS = new ErrorCode(1_200_000_000, "主样配置不存在");
|
||||||
|
ErrorCode CONFIG_ASSAY_METHOD_PROJECT_PARAMETER_NOT_EXISTS = new ErrorCode(1_200_000_000, "检测方法分析项目参数配置不存在");
|
||||||
|
ErrorCode CONFIG_WAREHOUSE_LOCATION_INFOMATION_NOT_EXISTS = new ErrorCode(1_200_000_000, "样品库位信息不存在");
|
||||||
|
ErrorCode CONFIG_SIMPLE_FLOW_RULE_NOT_EXISTS = new ErrorCode(1_200_000_000, "LiteFlow规则配置不存在");
|
||||||
|
ErrorCode CONFIG_SIMPLE_FLOW_CODE_NOT_EXISTS = new ErrorCode(1_200_000_000, "LiteFlow脚本配置不存在");
|
||||||
|
|
||||||
|
ErrorCode BASE_SAMPLE_NOT_EXISTS = new ErrorCode(500, "样品大类管理不存在");
|
||||||
|
ErrorCode MATERIAL_ASSAY_STANDARD_DETAIL_NOT_EXISTS = new ErrorCode(500, "检测标准明细不存在");
|
||||||
|
ErrorCode MATERIAL_ASSAY_STANDARD_NOT_EXISTS = new ErrorCode(500, "检测标准不存在");
|
||||||
|
ErrorCode MATERIAL_ASSAY_STANDARD_METHOD_NOT_EXISTS = new ErrorCode(500, "检测标准方法不存在");
|
||||||
|
|
||||||
|
|
||||||
|
/*==============================dictionary===============================*/
|
||||||
|
ErrorCode DICTIONARY_SAMPLE_FLOW_NODE_NOT_EXISTS = new ErrorCode(1_200_000_000, "样品流程节点字典不存在");
|
||||||
|
ErrorCode DICTIONARY_PARAMETER_NOT_EXISTS = new ErrorCode(1_200_000_000, "检测参数字典不存在");
|
||||||
|
ErrorCode DICTIONARY_PROJECT_NOT_EXISTS = new ErrorCode(1_200_000_000, "检测项目字典不存在");
|
||||||
|
ErrorCode DICTIONARY_SAMPLE_TYPE_NOT_EXISTS = new ErrorCode(1_200_000_000, "样品类型字典不存在");
|
||||||
|
|
||||||
|
/*=================================bus==================================*/
|
||||||
|
ErrorCode BUSINESS_SAMPLE_ENTRUST_REGISTRATION_NOT_EXISTS = new ErrorCode(1_200_000_000, "委检登记业务不存在");
|
||||||
|
ErrorCode BUSINESS_SAMPLE_ENTRUST_DETAIL_NOT_EXISTS = new ErrorCode(1_200_000_000, "委检登记样品明细不存在");
|
||||||
|
ErrorCode BUSINESS_SAMPLE_ENTRUST_PROJECT_NOT_EXISTS = new ErrorCode(1_200_000_000, "委检样品检测项目业务不存在");
|
||||||
|
|
||||||
|
ErrorCode BUSINESS_BASE_SAMPLE_NOT_EXISTS = new ErrorCode(1_200_000_000, "主样业务不存在");
|
||||||
|
ErrorCode BUSINESS_SUB_PARENT_SAMPLE_NOT_EXISTS = new ErrorCode(1_200_000_000, "分样业务不存在");
|
||||||
|
ErrorCode BUSINESS_SUB_SAMPLE_NOT_EXISTS = new ErrorCode(1_200_000_000, "子样业务不存在");
|
||||||
|
ErrorCode BUSINESS_HANDOVER_RECORD_SUB_NOT_EXISTS = new ErrorCode(1_200_000_000, "子样交接记录业务不存在");
|
||||||
|
ErrorCode BUSINESS_SAMPLE_ASSAY_RESULT_NOT_EXISTS = new ErrorCode(1_200_000_000, "委检登记来样品位不存在");
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -3,18 +3,18 @@
|
|||||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
<parent>
|
<parent>
|
||||||
<artifactId>yudao-module-jy-resource</artifactId>
|
<artifactId>qms-server</artifactId>
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
<groupId>cn.iocoder.cloud</groupId>
|
||||||
<version>${revision}</version>
|
<version>${revision}</version>
|
||||||
</parent>
|
</parent>
|
||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
<packaging>jar</packaging>
|
<packaging>jar</packaging>
|
||||||
|
|
||||||
<artifactId>yudao-module-jy-resource-server</artifactId>
|
<artifactId>yudao-module-qms-server</artifactId>
|
||||||
|
|
||||||
<name>${project.artifactId}</name>
|
<name>${project.artifactId}</name>
|
||||||
<description>
|
<description>
|
||||||
JyResource 模块。
|
样例模块。
|
||||||
</description>
|
</description>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
@@ -38,7 +38,7 @@
|
|||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
<groupId>cn.iocoder.cloud</groupId>
|
||||||
<artifactId>yudao-module-jy-resource-api</artifactId>
|
<artifactId>yudao-module-qms-api</artifactId>
|
||||||
<version>${revision}</version>
|
<version>${revision}</version>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
@@ -116,6 +116,60 @@
|
|||||||
<artifactId>yudao-spring-boot-starter-excel</artifactId>
|
<artifactId>yudao-spring-boot-starter-excel</artifactId>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.apache.commons</groupId>
|
||||||
|
<artifactId>commons-text</artifactId>
|
||||||
|
<version>1.14.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- gridreport -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>cn.rubylong</groupId>
|
||||||
|
<artifactId>gridreport</artifactId>
|
||||||
|
<version>20230309.RELEASE</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- liteflow -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.yomahub</groupId>
|
||||||
|
<artifactId>liteflow-spring-boot-starter</artifactId>
|
||||||
|
<version>2.15.0</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.yomahub</groupId>
|
||||||
|
<artifactId>liteflow-script-javax-pro</artifactId>
|
||||||
|
<version>2.15.0</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.yomahub</groupId>
|
||||||
|
<artifactId>liteflow-script-groovy</artifactId>
|
||||||
|
<version>2.15.0</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.yomahub</groupId>
|
||||||
|
<artifactId>liteflow-script-qlexpress</artifactId>
|
||||||
|
<version>2.15.0</version>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.yomahub</groupId>
|
||||||
|
<artifactId>liteflow-script-graaljs</artifactId>
|
||||||
|
<version>2.15.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- pdfbox -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.apache.pdfbox</groupId>
|
||||||
|
<artifactId>pdfbox</artifactId>
|
||||||
|
<version>2.0.33</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- Spire.PDF -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>e-iceblue</groupId>
|
||||||
|
<artifactId>spire.pdf.free</artifactId>
|
||||||
|
<version>9.13.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
<!-- 监控相关 -->
|
<!-- 监控相关 -->
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>cn.iocoder.cloud</groupId>
|
<groupId>cn.iocoder.cloud</groupId>
|
||||||
@@ -147,5 +201,4 @@
|
|||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms;
|
||||||
|
|
||||||
|
import org.springframework.boot.SpringApplication;
|
||||||
|
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 项目的启动类
|
||||||
|
*/
|
||||||
|
@SpringBootApplication
|
||||||
|
public class QmsServerApplication {
|
||||||
|
|
||||||
|
public static void main(String[] args) {
|
||||||
|
SpringApplication.run(QmsServerApplication.class, args);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,106 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import cn.iocoder.yudao.framework.business.interceptor.BusinessControllerMarker;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import jakarta.servlet.http.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.vo.BatchDeleteReqVO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessBaseSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.BusinessBaseSampleService;
|
||||||
|
import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
|
||||||
|
import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
||||||
|
|
||||||
|
@Tag(name = "管理后台 - 主样业务")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/business-base-sample")
|
||||||
|
@Validated
|
||||||
|
public class BusinessBaseSampleController implements BusinessControllerMarker {
|
||||||
|
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessBaseSampleService businessBaseSampleService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建主样业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-base-sample:create')")
|
||||||
|
public CommonResult<BusinessBaseSampleRespVO> createBusinessBaseSample(@Valid @RequestBody BusinessBaseSampleSaveReqVO createReqVO) {
|
||||||
|
return success(businessBaseSampleService.createBusinessBaseSample(createReqVO));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PutMapping("/update")
|
||||||
|
@Operation(summary = "更新主样业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-base-sample:update')")
|
||||||
|
public CommonResult<Boolean> updateBusinessBaseSample(@Valid @RequestBody BusinessBaseSampleSaveReqVO updateReqVO) {
|
||||||
|
businessBaseSampleService.updateBusinessBaseSample(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除主样业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-base-sample:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessBaseSample(@RequestParam("id") Long id) {
|
||||||
|
businessBaseSampleService.deleteBusinessBaseSample(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "编号", required = true)
|
||||||
|
@Operation(summary = "批量删除主样业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-base-sample:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessBaseSampleList(@RequestBody BatchDeleteReqVO req) {
|
||||||
|
businessBaseSampleService.deleteBusinessBaseSampleListByIds(req.getIds());
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/get")
|
||||||
|
@Operation(summary = "获得主样业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-base-sample:query')")
|
||||||
|
public CommonResult<BusinessBaseSampleRespVO> getBusinessBaseSample(@RequestParam("id") Long id) {
|
||||||
|
BusinessBaseSampleDO businessBaseSample = businessBaseSampleService.getBusinessBaseSample(id);
|
||||||
|
return success(BeanUtils.toBean(businessBaseSample, BusinessBaseSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/page")
|
||||||
|
@Operation(summary = "获得主样业务分页")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-base-sample:query')")
|
||||||
|
public CommonResult<PageResult<BusinessBaseSampleRespVO>> getBusinessBaseSamplePage(@Valid BusinessBaseSamplePageReqVO pageReqVO) {
|
||||||
|
PageResult<BusinessBaseSampleDO> pageResult = businessBaseSampleService.getBusinessBaseSamplePage(pageReqVO);
|
||||||
|
return success(BeanUtils.toBean(pageResult, BusinessBaseSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/export-excel")
|
||||||
|
@Operation(summary = "导出主样业务 Excel")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-base-sample:export')")
|
||||||
|
@ApiAccessLog(operateType = EXPORT)
|
||||||
|
public void exportBusinessBaseSampleExcel(@Valid BusinessBaseSamplePageReqVO pageReqVO,
|
||||||
|
HttpServletResponse response) throws IOException {
|
||||||
|
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||||
|
List<BusinessBaseSampleDO> list = businessBaseSampleService.getBusinessBaseSamplePage(pageReqVO).getList();
|
||||||
|
// 导出 Excel
|
||||||
|
ExcelUtils.write(response, "主样业务.xls", "数据", BusinessBaseSampleRespVO.class,
|
||||||
|
BeanUtils.toBean(list, BusinessBaseSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,106 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import cn.iocoder.yudao.framework.business.interceptor.BusinessControllerMarker;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import jakarta.servlet.http.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.vo.BatchDeleteReqVO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessHandoverRecordSubDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.BusinessHandoverRecordSubService;
|
||||||
|
import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
|
||||||
|
import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
||||||
|
|
||||||
|
@Tag(name = "管理后台 - 子样交接记录业务")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/business-handover-record-sub")
|
||||||
|
@Validated
|
||||||
|
public class BusinessHandoverRecordSubController implements BusinessControllerMarker {
|
||||||
|
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessHandoverRecordSubService businessHandoverRecordSubService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建子样交接记录业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-handover-record-sub:create')")
|
||||||
|
public CommonResult<BusinessHandoverRecordSubRespVO> createBusinessHandoverRecordSub(@Valid @RequestBody BusinessHandoverRecordSubSaveReqVO createReqVO) {
|
||||||
|
return success(businessHandoverRecordSubService.createBusinessHandoverRecordSub(createReqVO));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PutMapping("/update")
|
||||||
|
@Operation(summary = "更新子样交接记录业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-handover-record-sub:update')")
|
||||||
|
public CommonResult<Boolean> updateBusinessHandoverRecordSub(@Valid @RequestBody BusinessHandoverRecordSubSaveReqVO updateReqVO) {
|
||||||
|
businessHandoverRecordSubService.updateBusinessHandoverRecordSub(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除子样交接记录业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-handover-record-sub:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessHandoverRecordSub(@RequestParam("id") Long id) {
|
||||||
|
businessHandoverRecordSubService.deleteBusinessHandoverRecordSub(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "编号", required = true)
|
||||||
|
@Operation(summary = "批量删除子样交接记录业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-handover-record-sub:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessHandoverRecordSubList(@RequestBody BatchDeleteReqVO req) {
|
||||||
|
businessHandoverRecordSubService.deleteBusinessHandoverRecordSubListByIds(req.getIds());
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/get")
|
||||||
|
@Operation(summary = "获得子样交接记录业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-handover-record-sub:query')")
|
||||||
|
public CommonResult<BusinessHandoverRecordSubRespVO> getBusinessHandoverRecordSub(@RequestParam("id") Long id) {
|
||||||
|
BusinessHandoverRecordSubDO businessHandoverRecordSub = businessHandoverRecordSubService.getBusinessHandoverRecordSub(id);
|
||||||
|
return success(BeanUtils.toBean(businessHandoverRecordSub, BusinessHandoverRecordSubRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/page")
|
||||||
|
@Operation(summary = "获得子样交接记录业务分页")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-handover-record-sub:query')")
|
||||||
|
public CommonResult<PageResult<BusinessHandoverRecordSubRespVO>> getBusinessHandoverRecordSubPage(@Valid BusinessHandoverRecordSubPageReqVO pageReqVO) {
|
||||||
|
PageResult<BusinessHandoverRecordSubDO> pageResult = businessHandoverRecordSubService.getBusinessHandoverRecordSubPage(pageReqVO);
|
||||||
|
return success(BeanUtils.toBean(pageResult, BusinessHandoverRecordSubRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/export-excel")
|
||||||
|
@Operation(summary = "导出子样交接记录业务 Excel")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-handover-record-sub:export')")
|
||||||
|
@ApiAccessLog(operateType = EXPORT)
|
||||||
|
public void exportBusinessHandoverRecordSubExcel(@Valid BusinessHandoverRecordSubPageReqVO pageReqVO,
|
||||||
|
HttpServletResponse response) throws IOException {
|
||||||
|
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||||
|
List<BusinessHandoverRecordSubDO> list = businessHandoverRecordSubService.getBusinessHandoverRecordSubPage(pageReqVO).getList();
|
||||||
|
// 导出 Excel
|
||||||
|
ExcelUtils.write(response, "子样交接记录业务.xls", "数据", BusinessHandoverRecordSubRespVO.class,
|
||||||
|
BeanUtils.toBean(list, BusinessHandoverRecordSubRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,106 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import cn.iocoder.yudao.framework.business.interceptor.BusinessControllerMarker;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import jakarta.servlet.http.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.vo.BatchDeleteReqVO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleAssayResultDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.BusinessSampleAssayResultService;
|
||||||
|
import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
|
||||||
|
import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
||||||
|
|
||||||
|
@Tag(name = "管理后台 - 委检登记来样品位")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/business-sample-assay-result")
|
||||||
|
@Validated
|
||||||
|
public class BusinessSampleAssayResultController implements BusinessControllerMarker {
|
||||||
|
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleAssayResultService businessSampleAssayResultService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建委检登记来样品位")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-assay-result:create')")
|
||||||
|
public CommonResult<BusinessSampleAssayResultRespVO> createBusinessSampleAssayResult(@Valid @RequestBody BusinessSampleAssayResultSaveReqVO createReqVO) {
|
||||||
|
return success(businessSampleAssayResultService.createBusinessSampleAssayResult(createReqVO));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PutMapping("/update")
|
||||||
|
@Operation(summary = "更新委检登记来样品位")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-assay-result:update')")
|
||||||
|
public CommonResult<Boolean> updateBusinessSampleAssayResult(@Valid @RequestBody BusinessSampleAssayResultSaveReqVO updateReqVO) {
|
||||||
|
businessSampleAssayResultService.updateBusinessSampleAssayResult(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除委检登记来样品位")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-assay-result:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSampleAssayResult(@RequestParam("id") Long id) {
|
||||||
|
businessSampleAssayResultService.deleteBusinessSampleAssayResult(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "编号", required = true)
|
||||||
|
@Operation(summary = "批量删除委检登记来样品位")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-assay-result:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSampleAssayResultList(@RequestBody BatchDeleteReqVO req) {
|
||||||
|
businessSampleAssayResultService.deleteBusinessSampleAssayResultListByIds(req.getIds());
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/get")
|
||||||
|
@Operation(summary = "获得委检登记来样品位")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-assay-result:query')")
|
||||||
|
public CommonResult<BusinessSampleAssayResultRespVO> getBusinessSampleAssayResult(@RequestParam("id") Long id) {
|
||||||
|
BusinessSampleAssayResultDO businessSampleAssayResult = businessSampleAssayResultService.getBusinessSampleAssayResult(id);
|
||||||
|
return success(BeanUtils.toBean(businessSampleAssayResult, BusinessSampleAssayResultRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/page")
|
||||||
|
@Operation(summary = "获得委检登记来样品位分页")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-assay-result:query')")
|
||||||
|
public CommonResult<PageResult<BusinessSampleAssayResultRespVO>> getBusinessSampleAssayResultPage(@Valid BusinessSampleAssayResultPageReqVO pageReqVO) {
|
||||||
|
PageResult<BusinessSampleAssayResultDO> pageResult = businessSampleAssayResultService.getBusinessSampleAssayResultPage(pageReqVO);
|
||||||
|
return success(BeanUtils.toBean(pageResult, BusinessSampleAssayResultRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/export-excel")
|
||||||
|
@Operation(summary = "导出委检登记来样品位 Excel")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-assay-result:export')")
|
||||||
|
@ApiAccessLog(operateType = EXPORT)
|
||||||
|
public void exportBusinessSampleAssayResultExcel(@Valid BusinessSampleAssayResultPageReqVO pageReqVO,
|
||||||
|
HttpServletResponse response) throws IOException {
|
||||||
|
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||||
|
List<BusinessSampleAssayResultDO> list = businessSampleAssayResultService.getBusinessSampleAssayResultPage(pageReqVO).getList();
|
||||||
|
// 导出 Excel
|
||||||
|
ExcelUtils.write(response, "委检登记来样品位.xls", "数据", BusinessSampleAssayResultRespVO.class,
|
||||||
|
BeanUtils.toBean(list, BusinessSampleAssayResultRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,106 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import cn.iocoder.yudao.framework.business.interceptor.BusinessControllerMarker;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import jakarta.servlet.http.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.vo.BatchDeleteReqVO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.BusinessSampleEntrustDetailService;
|
||||||
|
import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
|
||||||
|
import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
||||||
|
|
||||||
|
@Tag(name = "管理后台 - 委检登记样品明细")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/business-sample-entrust-detail")
|
||||||
|
@Validated
|
||||||
|
public class BusinessSampleEntrustDetailController implements BusinessControllerMarker {
|
||||||
|
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustDetailService businessSampleEntrustDetailService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建委检登记样品明细")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-detail:create')")
|
||||||
|
public CommonResult<BusinessSampleEntrustDetailRespVO> createBusinessSampleEntrustDetail(@Valid @RequestBody BusinessSampleEntrustDetailSaveReqVO createReqVO) {
|
||||||
|
return success(businessSampleEntrustDetailService.createBusinessSampleEntrustDetail(createReqVO));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PutMapping("/update")
|
||||||
|
@Operation(summary = "更新委检登记样品明细")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-detail:update')")
|
||||||
|
public CommonResult<Boolean> updateBusinessSampleEntrustDetail(@Valid @RequestBody BusinessSampleEntrustDetailSaveReqVO updateReqVO) {
|
||||||
|
businessSampleEntrustDetailService.updateBusinessSampleEntrustDetail(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除委检登记样品明细")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-detail:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSampleEntrustDetail(@RequestParam("id") Long id) {
|
||||||
|
businessSampleEntrustDetailService.deleteBusinessSampleEntrustDetail(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "编号", required = true)
|
||||||
|
@Operation(summary = "批量删除委检登记样品明细")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-detail:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSampleEntrustDetailList(@RequestBody BatchDeleteReqVO req) {
|
||||||
|
businessSampleEntrustDetailService.deleteBusinessSampleEntrustDetailListByIds(req.getIds());
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/get")
|
||||||
|
@Operation(summary = "获得委检登记样品明细")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-detail:query')")
|
||||||
|
public CommonResult<BusinessSampleEntrustDetailRespVO> getBusinessSampleEntrustDetail(@RequestParam("id") Long id) {
|
||||||
|
BusinessSampleEntrustDetailDO businessSampleEntrustDetail = businessSampleEntrustDetailService.getBusinessSampleEntrustDetail(id);
|
||||||
|
return success(BeanUtils.toBean(businessSampleEntrustDetail, BusinessSampleEntrustDetailRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/page")
|
||||||
|
@Operation(summary = "获得委检登记样品明细分页")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-detail:query')")
|
||||||
|
public CommonResult<PageResult<BusinessSampleEntrustDetailRespVO>> getBusinessSampleEntrustDetailPage(@Valid BusinessSampleEntrustDetailPageReqVO pageReqVO) {
|
||||||
|
PageResult<BusinessSampleEntrustDetailDO> pageResult = businessSampleEntrustDetailService.getBusinessSampleEntrustDetailPage(pageReqVO);
|
||||||
|
return success(BeanUtils.toBean(pageResult, BusinessSampleEntrustDetailRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/export-excel")
|
||||||
|
@Operation(summary = "导出委检登记样品明细 Excel")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-detail:export')")
|
||||||
|
@ApiAccessLog(operateType = EXPORT)
|
||||||
|
public void exportBusinessSampleEntrustDetailExcel(@Valid BusinessSampleEntrustDetailPageReqVO pageReqVO,
|
||||||
|
HttpServletResponse response) throws IOException {
|
||||||
|
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||||
|
List<BusinessSampleEntrustDetailDO> list = businessSampleEntrustDetailService.getBusinessSampleEntrustDetailPage(pageReqVO).getList();
|
||||||
|
// 导出 Excel
|
||||||
|
ExcelUtils.write(response, "委检登记样品明细.xls", "数据", BusinessSampleEntrustDetailRespVO.class,
|
||||||
|
BeanUtils.toBean(list, BusinessSampleEntrustDetailRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,106 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import cn.iocoder.yudao.framework.business.interceptor.BusinessControllerMarker;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import jakarta.servlet.http.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.vo.BatchDeleteReqVO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustProjectDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.BusinessSampleEntrustProjectService;
|
||||||
|
import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
|
||||||
|
import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
||||||
|
|
||||||
|
@Tag(name = "管理后台 - 委检样品检测项目业务")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/business-sample-entrust-project")
|
||||||
|
@Validated
|
||||||
|
public class BusinessSampleEntrustProjectController implements BusinessControllerMarker {
|
||||||
|
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustProjectService businessSampleEntrustProjectService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建委检样品检测项目业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-project:create')")
|
||||||
|
public CommonResult<BusinessSampleEntrustProjectRespVO> createBusinessSampleEntrustProject(@Valid @RequestBody BusinessSampleEntrustProjectSaveReqVO createReqVO) {
|
||||||
|
return success(businessSampleEntrustProjectService.createBusinessSampleEntrustProject(createReqVO));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PutMapping("/update")
|
||||||
|
@Operation(summary = "更新委检样品检测项目业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-project:update')")
|
||||||
|
public CommonResult<Boolean> updateBusinessSampleEntrustProject(@Valid @RequestBody BusinessSampleEntrustProjectSaveReqVO updateReqVO) {
|
||||||
|
businessSampleEntrustProjectService.updateBusinessSampleEntrustProject(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除委检样品检测项目业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-project:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSampleEntrustProject(@RequestParam("id") Long id) {
|
||||||
|
businessSampleEntrustProjectService.deleteBusinessSampleEntrustProject(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "编号", required = true)
|
||||||
|
@Operation(summary = "批量删除委检样品检测项目业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-project:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSampleEntrustProjectList(@RequestBody BatchDeleteReqVO req) {
|
||||||
|
businessSampleEntrustProjectService.deleteBusinessSampleEntrustProjectListByIds(req.getIds());
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/get")
|
||||||
|
@Operation(summary = "获得委检样品检测项目业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-project:query')")
|
||||||
|
public CommonResult<BusinessSampleEntrustProjectRespVO> getBusinessSampleEntrustProject(@RequestParam("id") Long id) {
|
||||||
|
BusinessSampleEntrustProjectDO businessSampleEntrustProject = businessSampleEntrustProjectService.getBusinessSampleEntrustProject(id);
|
||||||
|
return success(BeanUtils.toBean(businessSampleEntrustProject, BusinessSampleEntrustProjectRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/page")
|
||||||
|
@Operation(summary = "获得委检样品检测项目业务分页")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-project:query')")
|
||||||
|
public CommonResult<PageResult<BusinessSampleEntrustProjectRespVO>> getBusinessSampleEntrustProjectPage(@Valid BusinessSampleEntrustProjectPageReqVO pageReqVO) {
|
||||||
|
PageResult<BusinessSampleEntrustProjectDO> pageResult = businessSampleEntrustProjectService.getBusinessSampleEntrustProjectPage(pageReqVO);
|
||||||
|
return success(BeanUtils.toBean(pageResult, BusinessSampleEntrustProjectRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/export-excel")
|
||||||
|
@Operation(summary = "导出委检样品检测项目业务 Excel")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-project:export')")
|
||||||
|
@ApiAccessLog(operateType = EXPORT)
|
||||||
|
public void exportBusinessSampleEntrustProjectExcel(@Valid BusinessSampleEntrustProjectPageReqVO pageReqVO,
|
||||||
|
HttpServletResponse response) throws IOException {
|
||||||
|
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||||
|
List<BusinessSampleEntrustProjectDO> list = businessSampleEntrustProjectService.getBusinessSampleEntrustProjectPage(pageReqVO).getList();
|
||||||
|
// 导出 Excel
|
||||||
|
ExcelUtils.write(response, "委检样品检测项目业务.xls", "数据", BusinessSampleEntrustProjectRespVO.class,
|
||||||
|
BeanUtils.toBean(list, BusinessSampleEntrustProjectRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,107 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import cn.iocoder.yudao.framework.business.interceptor.BusinessControllerMarker;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import jakarta.servlet.http.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.vo.BatchDeleteReqVO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.BusinessSampleEntrustRegistrationService;
|
||||||
|
import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
|
||||||
|
import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
||||||
|
|
||||||
|
|
||||||
|
@Tag(name = "管理后台 - 委检登记业务")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/business-sample-entrust-registration")
|
||||||
|
@Validated
|
||||||
|
public class BusinessSampleEntrustRegistrationController implements BusinessControllerMarker {
|
||||||
|
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustRegistrationService businessSampleEntrustRegistrationService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建委检登记业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-registration:create')")
|
||||||
|
public CommonResult<BusinessSampleEntrustRegistrationRespVO> createBusinessSampleEntrustRegistration(@Valid @RequestBody BusinessSampleEntrustRegistrationSaveReqVO createReqVO) {
|
||||||
|
return success(businessSampleEntrustRegistrationService.createBusinessSampleEntrustRegistration(createReqVO));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PutMapping("/update")
|
||||||
|
@Operation(summary = "更新委检登记业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-registration:update')")
|
||||||
|
public CommonResult<Boolean> updateBusinessSampleEntrustRegistration(@Valid @RequestBody BusinessSampleEntrustRegistrationSaveReqVO updateReqVO) {
|
||||||
|
businessSampleEntrustRegistrationService.updateBusinessSampleEntrustRegistration(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除委检登记业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-registration:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSampleEntrustRegistration(@RequestParam("id") Long id) {
|
||||||
|
businessSampleEntrustRegistrationService.deleteBusinessSampleEntrustRegistration(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "编号", required = true)
|
||||||
|
@Operation(summary = "批量删除委检登记业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-registration:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSampleEntrustRegistrationList(@RequestBody BatchDeleteReqVO req) {
|
||||||
|
businessSampleEntrustRegistrationService.deleteBusinessSampleEntrustRegistrationListByIds(req.getIds());
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/get")
|
||||||
|
@Operation(summary = "获得委检登记业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-registration:query')")
|
||||||
|
public CommonResult<BusinessSampleEntrustRegistrationRespVO> getBusinessSampleEntrustRegistration(@RequestParam("id") Long id) {
|
||||||
|
BusinessSampleEntrustRegistrationDO businessSampleEntrustRegistration = businessSampleEntrustRegistrationService.getBusinessSampleEntrustRegistration(id);
|
||||||
|
return success(BeanUtils.toBean(businessSampleEntrustRegistration, BusinessSampleEntrustRegistrationRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/page")
|
||||||
|
@Operation(summary = "获得委检登记业务分页")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-registration:query')")
|
||||||
|
public CommonResult<PageResult<BusinessSampleEntrustRegistrationRespVO>> getBusinessSampleEntrustRegistrationPage(@Valid BusinessSampleEntrustRegistrationPageReqVO pageReqVO) {
|
||||||
|
PageResult<BusinessSampleEntrustRegistrationDO> pageResult = businessSampleEntrustRegistrationService.getBusinessSampleEntrustRegistrationPage(pageReqVO);
|
||||||
|
return success(BeanUtils.toBean(pageResult, BusinessSampleEntrustRegistrationRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/export-excel")
|
||||||
|
@Operation(summary = "导出委检登记业务 Excel")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sample-entrust-registration:export')")
|
||||||
|
@ApiAccessLog(operateType = EXPORT)
|
||||||
|
public void exportBusinessSampleEntrustRegistrationExcel(@Valid BusinessSampleEntrustRegistrationPageReqVO pageReqVO,
|
||||||
|
HttpServletResponse response) throws IOException {
|
||||||
|
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||||
|
List<BusinessSampleEntrustRegistrationDO> list = businessSampleEntrustRegistrationService.getBusinessSampleEntrustRegistrationPage(pageReqVO).getList();
|
||||||
|
// 导出 Excel
|
||||||
|
ExcelUtils.write(response, "委检登记业务.xls", "数据", BusinessSampleEntrustRegistrationRespVO.class,
|
||||||
|
BeanUtils.toBean(list, BusinessSampleEntrustRegistrationRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,106 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import cn.iocoder.yudao.framework.business.interceptor.BusinessControllerMarker;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import jakarta.servlet.http.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.vo.BatchDeleteReqVO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubParentSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.BusinessSubParentSampleService;
|
||||||
|
import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
|
||||||
|
import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
||||||
|
|
||||||
|
@Tag(name = "管理后台 - 分样业务")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/business-sub-parent-sample")
|
||||||
|
@Validated
|
||||||
|
public class BusinessSubParentSampleController implements BusinessControllerMarker {
|
||||||
|
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSubParentSampleService businessSubParentSampleService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建分样业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sub-parent-sample:create')")
|
||||||
|
public CommonResult<BusinessSubParentSampleRespVO> createBusinessSubParentSample(@Valid @RequestBody BusinessSubParentSampleSaveReqVO createReqVO) {
|
||||||
|
return success(businessSubParentSampleService.createBusinessSubParentSample(createReqVO));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PutMapping("/update")
|
||||||
|
@Operation(summary = "更新分样业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sub-parent-sample:update')")
|
||||||
|
public CommonResult<Boolean> updateBusinessSubParentSample(@Valid @RequestBody BusinessSubParentSampleSaveReqVO updateReqVO) {
|
||||||
|
businessSubParentSampleService.updateBusinessSubParentSample(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除分样业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sub-parent-sample:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSubParentSample(@RequestParam("id") Long id) {
|
||||||
|
businessSubParentSampleService.deleteBusinessSubParentSample(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "编号", required = true)
|
||||||
|
@Operation(summary = "批量删除分样业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sub-parent-sample:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBusinessSubParentSampleList(@RequestBody BatchDeleteReqVO req) {
|
||||||
|
businessSubParentSampleService.deleteBusinessSubParentSampleListByIds(req.getIds());
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/get")
|
||||||
|
@Operation(summary = "获得分样业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sub-parent-sample:query')")
|
||||||
|
public CommonResult<BusinessSubParentSampleRespVO> getBusinessSubParentSample(@RequestParam("id") Long id) {
|
||||||
|
BusinessSubParentSampleDO businessSubParentSample = businessSubParentSampleService.getBusinessSubParentSample(id);
|
||||||
|
return success(BeanUtils.toBean(businessSubParentSample, BusinessSubParentSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/page")
|
||||||
|
@Operation(summary = "获得分样业务分页")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sub-parent-sample:query')")
|
||||||
|
public CommonResult<PageResult<BusinessSubParentSampleRespVO>> getBusinessSubParentSamplePage(@Valid BusinessSubParentSamplePageReqVO pageReqVO) {
|
||||||
|
PageResult<BusinessSubParentSampleDO> pageResult = businessSubParentSampleService.getBusinessSubParentSamplePage(pageReqVO);
|
||||||
|
return success(BeanUtils.toBean(pageResult, BusinessSubParentSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/export-excel")
|
||||||
|
@Operation(summary = "导出分样业务 Excel")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:business-sub-parent-sample:export')")
|
||||||
|
@ApiAccessLog(operateType = EXPORT)
|
||||||
|
public void exportBusinessSubParentSampleExcel(@Valid BusinessSubParentSamplePageReqVO pageReqVO,
|
||||||
|
HttpServletResponse response) throws IOException {
|
||||||
|
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||||
|
List<BusinessSubParentSampleDO> list = businessSubParentSampleService.getBusinessSubParentSamplePage(pageReqVO).getList();
|
||||||
|
// 导出 Excel
|
||||||
|
ExcelUtils.write(response, "分样业务.xls", "数据", BusinessSubParentSampleRespVO.class,
|
||||||
|
BeanUtils.toBean(list, BusinessSubParentSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,107 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import cn.iocoder.yudao.framework.business.interceptor.BusinessControllerMarker;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import jakarta.servlet.http.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSamplePageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSampleRespVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSampleSaveReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.BusinessSubSampleService;
|
||||||
|
import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
|
||||||
|
import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
||||||
|
|
||||||
|
@Tag(name = "管理后台 - 子样业务")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/bus/iness-sub-sample")
|
||||||
|
@Validated
|
||||||
|
public class BusinessSubSampleController implements BusinessControllerMarker {
|
||||||
|
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSubSampleService businessSubSampleService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建子样业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('bus:iness-sub-sample:create')")
|
||||||
|
public CommonResult<BusinessSubSampleRespVO> createinessSubSample(@Valid @RequestBody BusinessSubSampleSaveReqVO createReqVO) {
|
||||||
|
return success(businessSubSampleService.createinessSubSample(createReqVO));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PutMapping("/update")
|
||||||
|
@Operation(summary = "更新子样业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('bus:iness-sub-sample:update')")
|
||||||
|
public CommonResult<Boolean> updateinessSubSample(@Valid @RequestBody BusinessSubSampleSaveReqVO updateReqVO) {
|
||||||
|
businessSubSampleService.updateinessSubSample(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除子样业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@PreAuthorize("@ss.hasPermission('bus:iness-sub-sample:delete')")
|
||||||
|
public CommonResult<Boolean> deleteinessSubSample(@RequestParam("id") Long id) {
|
||||||
|
businessSubSampleService.deleteinessSubSample(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "编号", required = true)
|
||||||
|
@Operation(summary = "批量删除子样业务")
|
||||||
|
@PreAuthorize("@ss.hasPermission('bus:iness-sub-sample:delete')")
|
||||||
|
public CommonResult<Boolean> deleteinessSubSampleList(@RequestParam("ids") List<Long> ids) {
|
||||||
|
businessSubSampleService.deleteinessSubSampleListByIds(ids);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/get")
|
||||||
|
@Operation(summary = "获得子样业务")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
||||||
|
@PreAuthorize("@ss.hasPermission('bus:iness-sub-sample:query')")
|
||||||
|
public CommonResult<BusinessSubSampleRespVO> getinessSubSample(@RequestParam("id") Long id) {
|
||||||
|
BusinessSubSampleDO inessSubSample = businessSubSampleService.getinessSubSample(id);
|
||||||
|
return success(BeanUtils.toBean(inessSubSample, BusinessSubSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/page")
|
||||||
|
@Operation(summary = "获得子样业务分页")
|
||||||
|
@PreAuthorize("@ss.hasPermission('bus:iness-sub-sample:query')")
|
||||||
|
public CommonResult<PageResult<BusinessSubSampleRespVO>> getinessSubSamplePage(@Valid BusinessSubSamplePageReqVO pageReqVO) {
|
||||||
|
PageResult<BusinessSubSampleDO> pageResult = businessSubSampleService.getinessSubSamplePage(pageReqVO);
|
||||||
|
return success(BeanUtils.toBean(pageResult, BusinessSubSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/export-excel")
|
||||||
|
@Operation(summary = "导出子样业务 Excel")
|
||||||
|
@PreAuthorize("@ss.hasPermission('bus:iness-sub-sample:export')")
|
||||||
|
@ApiAccessLog(operateType = EXPORT)
|
||||||
|
public void exportinessSubSampleExcel(@Valid BusinessSubSamplePageReqVO pageReqVO,
|
||||||
|
HttpServletResponse response) throws IOException {
|
||||||
|
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||||
|
List<BusinessSubSampleDO> list = businessSubSampleService.getinessSubSamplePage(pageReqVO).getList();
|
||||||
|
// 导出 Excel
|
||||||
|
ExcelUtils.write(response, "子样业务.xls", "数据", BusinessSubSampleRespVO.class,
|
||||||
|
BeanUtils.toBean(list, BusinessSubSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,185 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.error;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.PostMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestBody;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson2.JSON;
|
||||||
|
import com.yomahub.liteflow.core.FlowExecutor;
|
||||||
|
import com.yomahub.liteflow.flow.LiteflowResponse;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleEntrustDetail;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleEntrustDetailProject;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleEntrustParam;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleFlowParam;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleEntrustContext;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleFlowContext;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.SampleEntrustService;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import jakarta.validation.Valid;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustController</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@Tag(name = "管理后台 - 样品委托")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/bus/sample/entrust")
|
||||||
|
@Validated
|
||||||
|
public class SampleEntrustController {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private FlowExecutor flowExecutor;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private SampleEntrustService sampleEntrustService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建委托登记")
|
||||||
|
public CommonResult<?> create(@Valid @RequestBody SampleEntrustParam sampleEntrustParam) {
|
||||||
|
LiteflowResponse response = sampleEntrustService.create(sampleEntrustParam);
|
||||||
|
if (response.isSuccess()) {
|
||||||
|
return success(response.getContextBean(SampleEntrustContext.class));
|
||||||
|
} else {
|
||||||
|
return error(500, response.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/detail")
|
||||||
|
@Operation(summary = "委托登记详情")
|
||||||
|
public CommonResult<?> detail(@RequestParam("id") Long id) {
|
||||||
|
BusinessSampleEntrustRegistrationExtendRespVO sampleEntrustRegistration = sampleEntrustService.detail(id);
|
||||||
|
return success(sampleEntrustRegistration);
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/update")
|
||||||
|
@Operation(summary = "修改委托登记")
|
||||||
|
public CommonResult<?> update(@Valid @RequestBody SampleEntrustParam sampleEntrustParam) {
|
||||||
|
LiteflowResponse response = sampleEntrustService.update(sampleEntrustParam);
|
||||||
|
if (response.isSuccess()) {
|
||||||
|
return success(response.getContextBean(SampleEntrustContext.class));
|
||||||
|
} else {
|
||||||
|
return error(500, response.getMessage());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/submit")
|
||||||
|
@Operation(summary = "提交托登记")
|
||||||
|
public CommonResult<?> submit(@Valid @RequestBody BusinessSampleEntrustRegistrationSubmitReqVO req) {
|
||||||
|
//如果仅勾选了送样,则需要把收样也勾选
|
||||||
|
if (req.getIsSendSample().equals(1) && req.getIsReceiveSample().equals(0)) {
|
||||||
|
req.setIsReceiveSample(1);
|
||||||
|
}
|
||||||
|
sampleEntrustService.submit(req);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除委托登记")
|
||||||
|
@Parameter(name = "id", description = "ID", required = true)
|
||||||
|
public CommonResult<Boolean> delete(@RequestParam("id") Long id) {
|
||||||
|
sampleEntrustService.delete(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "ID", required = true)
|
||||||
|
@Operation(summary = "批量删除委托登记")
|
||||||
|
public CommonResult<Boolean> deleteList(@RequestParam("ids") List<Long> ids) {
|
||||||
|
sampleEntrustService.deleteList(ids);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/test")
|
||||||
|
public CommonResult<?> test() {
|
||||||
|
|
||||||
|
Long tenantId = TenantContextHolder.getRequiredTenantId();
|
||||||
|
|
||||||
|
SampleEntrustDetail sampleEntrustDetail_1 = new SampleEntrustDetail();
|
||||||
|
sampleEntrustDetail_1.setBaseSampleId(1000000000000000001L);//铜精矿(结算样)
|
||||||
|
sampleEntrustDetail_1.setDictionaryBusinessId(1965289473129664514L);
|
||||||
|
sampleEntrustDetail_1.setSampleName("铜精矿");
|
||||||
|
sampleEntrustDetail_1.setEntrustSampleCode("SRC0001");
|
||||||
|
sampleEntrustDetail_1.setEntrustSampleName("来样名称-铜精矿");
|
||||||
|
sampleEntrustDetail_1.setSort(1);
|
||||||
|
sampleEntrustDetail_1.setAssayProject("");
|
||||||
|
sampleEntrustDetail_1.setForecastResult("");
|
||||||
|
sampleEntrustDetail_1.setRemark("");
|
||||||
|
|
||||||
|
List<SampleEntrustDetailProject> sampleEntrustDetailProjectList_1 = new ArrayList<>();
|
||||||
|
SampleEntrustDetailProject sampleEntrustDetailProject_1_1 = new SampleEntrustDetailProject();
|
||||||
|
sampleEntrustDetailProject_1_1.setMaterialAssayStandardDetailId(1000000000000000001L);
|
||||||
|
sampleEntrustDetailProject_1_1.setIsEnabled(1);
|
||||||
|
sampleEntrustDetailProjectList_1.add(sampleEntrustDetailProject_1_1);
|
||||||
|
sampleEntrustDetail_1.setSampleEntrustDetailProjectList(sampleEntrustDetailProjectList_1);
|
||||||
|
|
||||||
|
SampleEntrustDetail sampleEntrustDetail_2 = new SampleEntrustDetail();
|
||||||
|
sampleEntrustDetail_2.setBaseSampleId(1000000000000000001L);//铜精矿(结算样)
|
||||||
|
sampleEntrustDetail_2.setDictionaryBusinessId(1965289473129664514L);
|
||||||
|
sampleEntrustDetail_2.setSampleName("铜精矿");
|
||||||
|
sampleEntrustDetail_2.setEntrustSampleCode("SRC0002");
|
||||||
|
sampleEntrustDetail_2.setEntrustSampleName("来样名称-铜精矿");
|
||||||
|
sampleEntrustDetail_2.setSort(2);
|
||||||
|
sampleEntrustDetail_2.setAssayProject("");
|
||||||
|
sampleEntrustDetail_2.setForecastResult("");
|
||||||
|
sampleEntrustDetail_2.setRemark("");
|
||||||
|
|
||||||
|
List<SampleEntrustDetailProject> sampleEntrustDetailProjectList_2 = new ArrayList<>();
|
||||||
|
SampleEntrustDetailProject sampleEntrustDetailProject_2_1 = new SampleEntrustDetailProject();
|
||||||
|
sampleEntrustDetailProject_2_1.setMaterialAssayStandardDetailId(1000000000000000001L);
|
||||||
|
sampleEntrustDetailProject_2_1.setIsEnabled(1);
|
||||||
|
sampleEntrustDetailProjectList_2.add(sampleEntrustDetailProject_2_1);
|
||||||
|
sampleEntrustDetail_2.setSampleEntrustDetailProjectList(sampleEntrustDetailProjectList_2);
|
||||||
|
|
||||||
|
List<SampleEntrustDetail> sampleEntrustDetailList = new ArrayList<>();
|
||||||
|
sampleEntrustDetailList.add(sampleEntrustDetail_1);
|
||||||
|
sampleEntrustDetailList.add(sampleEntrustDetail_2);
|
||||||
|
|
||||||
|
|
||||||
|
SampleEntrustParam sampleEntrustParam = new SampleEntrustParam();
|
||||||
|
sampleEntrustParam.setEntrustUnit("西南铜业");
|
||||||
|
sampleEntrustParam.setSampleSender("送样人");
|
||||||
|
sampleEntrustParam.setConfigEntrustSourceId(1000000000000000001L);
|
||||||
|
sampleEntrustParam.setSampleSendDate(LocalDateTime.now());
|
||||||
|
sampleEntrustParam.setSampleQuantity(2);
|
||||||
|
sampleEntrustParam.setRemaineSampleRequirement("放弃");
|
||||||
|
sampleEntrustParam.setSampleEntrustDetailList(sampleEntrustDetailList);
|
||||||
|
|
||||||
|
String jsonString = JSON.toJSONString(sampleEntrustParam);
|
||||||
|
System.out.println(jsonString);
|
||||||
|
|
||||||
|
LiteflowResponse response = flowExecutor.execute2Resp("sampleEntrustChain" + tenantId, sampleEntrustParam, SampleEntrustContext.class);
|
||||||
|
if (response.isSuccess()) {
|
||||||
|
return success(response.getContextBean(SampleEntrustContext.class));
|
||||||
|
} else {
|
||||||
|
return error(500, response.getMessage());
|
||||||
|
}
|
||||||
|
//return success(FlowBus.getNodeMap());
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -0,0 +1,71 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.admin;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.core.FlowExecutor;
|
||||||
|
import com.yomahub.liteflow.flow.FlowBus;
|
||||||
|
import com.yomahub.liteflow.flow.LiteflowResponse;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleFlowParam;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleFlowContext;
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.error;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleFlowController</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月6日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月6日
|
||||||
|
*/
|
||||||
|
@Tag(name = "管理后台 - 样品流转")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/bus/sample/flow")
|
||||||
|
@Validated
|
||||||
|
public class SampleFlowController {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private FlowExecutor flowExecutor;
|
||||||
|
|
||||||
|
|
||||||
|
@GetMapping("/test")
|
||||||
|
public CommonResult<?> test() {
|
||||||
|
|
||||||
|
Long tenantId = TenantContextHolder.getRequiredTenantId();
|
||||||
|
|
||||||
|
List<Long> sampleIdList = new ArrayList<>();
|
||||||
|
sampleIdList.add(1111L);
|
||||||
|
|
||||||
|
SampleFlowParam sampleFlowParam = new SampleFlowParam();
|
||||||
|
sampleFlowParam.setSampleSourceType(2);
|
||||||
|
sampleFlowParam.setSampleProcessNo("P3000");
|
||||||
|
sampleFlowParam.setSampleIdList(sampleIdList);
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
LiteflowResponse response = flowExecutor.execute2Resp("sampleFlowChain" + tenantId, sampleFlowParam, SampleFlowContext.class);
|
||||||
|
if (response.isSuccess()) {
|
||||||
|
return success(response.getContextBean(SampleFlowContext.class));
|
||||||
|
} else {
|
||||||
|
return error(500, response.getMessage());
|
||||||
|
}
|
||||||
|
//return success(FlowBus.getNodeMap());
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,68 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 主样业务分页 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessBaseSamplePageReqVO extends PageParam {
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", example = "芋艿")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "主样配置ID", example = "26608")
|
||||||
|
private Long configBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "主样类型ID,字典表:【T_DIC_BSN】结算样、抽查样、委检样", example = "27887")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "样品生成时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] sampleTime;
|
||||||
|
|
||||||
|
@Schema(description = "打印次数", example = "20143")
|
||||||
|
private Integer printCount;
|
||||||
|
|
||||||
|
@Schema(description = "末次打印时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] printLastTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程ID", example = "25222")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程KEY")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程节点时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] sampleFlowTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废", example = "1")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建人名称")
|
||||||
|
private String operator;
|
||||||
|
|
||||||
|
@Schema(description = "创建日期")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", example = "13116")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,83 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.alibaba.excel.annotation.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 主样业务 Response VO")
|
||||||
|
@Data
|
||||||
|
@ExcelIgnoreUnannotated
|
||||||
|
public class BusinessBaseSampleRespVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "14424")
|
||||||
|
@ExcelProperty("ID")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "芋艿")
|
||||||
|
@ExcelProperty("样品名称")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "主样配置ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "26608")
|
||||||
|
@ExcelProperty("主样配置ID")
|
||||||
|
private Long configBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "主样类型ID,字典表:【T_DIC_BSN】结算样、抽查样、委检样", requiredMode = Schema.RequiredMode.REQUIRED, example = "27887")
|
||||||
|
@ExcelProperty("主样类型ID,字典表:【T_DIC_BSN】结算样、抽查样、委检样")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "样品生成时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品生成时间")
|
||||||
|
private LocalDateTime sampleTime;
|
||||||
|
|
||||||
|
@Schema(description = "打印次数", requiredMode = Schema.RequiredMode.REQUIRED, example = "20143")
|
||||||
|
@ExcelProperty("打印次数")
|
||||||
|
private Integer printCount;
|
||||||
|
|
||||||
|
@Schema(description = "末次打印时间")
|
||||||
|
@ExcelProperty("末次打印时间")
|
||||||
|
private LocalDateTime printLastTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "25222")
|
||||||
|
@ExcelProperty("样品流程ID")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程KEY", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品流程KEY")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程节点时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品流程节点时间")
|
||||||
|
private LocalDateTime sampleFlowTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
|
||||||
|
@ExcelProperty("样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建人名称", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("创建人名称")
|
||||||
|
private String operator;
|
||||||
|
|
||||||
|
@Schema(description = "创建日期", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("创建日期")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "13116")
|
||||||
|
@ExcelProperty("乐观锁")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
@ExcelProperty("备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,75 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 主样业务新增/修改 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessBaseSampleSaveReqVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "14424")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "芋艿")
|
||||||
|
@NotEmpty(message = "样品名称不能为空")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "样品编号不能为空")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "主样配置ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "26608")
|
||||||
|
@NotNull(message = "主样配置ID不能为空")
|
||||||
|
private Long configBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "主样类型ID,字典表:【T_DIC_BSN】结算样、抽查样、委检样", requiredMode = Schema.RequiredMode.REQUIRED, example = "27887")
|
||||||
|
@NotNull(message = "主样类型ID,字典表:【T_DIC_BSN】结算样、抽查样、委检样不能为空")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "样品生成时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "样品生成时间不能为空")
|
||||||
|
private LocalDateTime sampleTime;
|
||||||
|
|
||||||
|
@Schema(description = "打印次数", requiredMode = Schema.RequiredMode.REQUIRED, example = "20143")
|
||||||
|
@NotNull(message = "打印次数不能为空")
|
||||||
|
private Integer printCount;
|
||||||
|
|
||||||
|
@Schema(description = "末次打印时间")
|
||||||
|
private LocalDateTime printLastTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "25222")
|
||||||
|
@NotNull(message = "样品流程ID不能为空")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程KEY", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "样品流程KEY不能为空")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程节点时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "样品流程节点时间不能为空")
|
||||||
|
private LocalDateTime sampleFlowTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废", requiredMode = Schema.RequiredMode.REQUIRED, example = "1")
|
||||||
|
@NotEmpty(message = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废不能为空")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "所属部门不能为空")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建人名称", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "创建人名称不能为空")
|
||||||
|
private String operator;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "13116")
|
||||||
|
@NotNull(message = "乐观锁不能为空")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,58 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 子样交接记录业务分页 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessHandoverRecordSubPageReqVO extends PageParam {
|
||||||
|
|
||||||
|
@Schema(description = "样品子样ID", example = "7268")
|
||||||
|
private Long businessSubSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程ID", example = "27410")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程KEY")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品重量")
|
||||||
|
private BigDecimal sampleWeight;
|
||||||
|
|
||||||
|
@Schema(description = "操作时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] operationTime;
|
||||||
|
|
||||||
|
@Schema(description = "操作人")
|
||||||
|
private String operator;
|
||||||
|
|
||||||
|
@Schema(description = "操作人ID", example = "9370")
|
||||||
|
private Long operatorId;
|
||||||
|
|
||||||
|
@Schema(description = "送样人")
|
||||||
|
private String sendSampleOperator;
|
||||||
|
|
||||||
|
@Schema(description = "收样人")
|
||||||
|
private String receiveSampleOperator;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建日期")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,72 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.alibaba.excel.annotation.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 子样交接记录业务 Response VO")
|
||||||
|
@Data
|
||||||
|
@ExcelIgnoreUnannotated
|
||||||
|
public class BusinessHandoverRecordSubRespVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "3962")
|
||||||
|
@ExcelProperty("ID")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品子样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "7268")
|
||||||
|
@ExcelProperty("样品子样ID")
|
||||||
|
private Long businessSubSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "27410")
|
||||||
|
@ExcelProperty("样品流程ID")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程KEY", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品流程KEY")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
@ExcelProperty("样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品重量")
|
||||||
|
@ExcelProperty("样品重量")
|
||||||
|
private BigDecimal sampleWeight;
|
||||||
|
|
||||||
|
@Schema(description = "操作时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("操作时间")
|
||||||
|
private LocalDateTime operationTime;
|
||||||
|
|
||||||
|
@Schema(description = "操作人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("操作人")
|
||||||
|
private String operator;
|
||||||
|
|
||||||
|
@Schema(description = "操作人ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "9370")
|
||||||
|
@ExcelProperty("操作人ID")
|
||||||
|
private Long operatorId;
|
||||||
|
|
||||||
|
@Schema(description = "送样人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("送样人")
|
||||||
|
private String sendSampleOperator;
|
||||||
|
|
||||||
|
@Schema(description = "收样人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("收样人")
|
||||||
|
private String receiveSampleOperator;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建日期", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("创建日期")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
@ExcelProperty("备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,63 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 子样交接记录业务新增/修改 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessHandoverRecordSubSaveReqVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "3962")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品子样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "7268")
|
||||||
|
@NotNull(message = "样品子样ID不能为空")
|
||||||
|
private Long businessSubSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "27410")
|
||||||
|
@NotNull(message = "样品流程ID不能为空")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程KEY", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "样品流程KEY不能为空")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品重量")
|
||||||
|
private BigDecimal sampleWeight;
|
||||||
|
|
||||||
|
@Schema(description = "操作时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "操作时间不能为空")
|
||||||
|
private LocalDateTime operationTime;
|
||||||
|
|
||||||
|
@Schema(description = "操作人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "操作人不能为空")
|
||||||
|
private String operator;
|
||||||
|
|
||||||
|
@Schema(description = "操作人ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "9370")
|
||||||
|
@NotNull(message = "操作人ID不能为空")
|
||||||
|
private Long operatorId;
|
||||||
|
|
||||||
|
@Schema(description = "送样人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "送样人不能为空")
|
||||||
|
private String sendSampleOperator;
|
||||||
|
|
||||||
|
@Schema(description = "收样人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "收样人不能为空")
|
||||||
|
private String receiveSampleOperator;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "所属部门不能为空")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检登记来样品位分页 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleAssayResultPageReqVO extends PageParam {
|
||||||
|
|
||||||
|
@Schema(description = "委托登记样品明细ID", example = "5711")
|
||||||
|
private Long businessSampleEntrustDetailId;
|
||||||
|
|
||||||
|
@Schema(description = "样品主样ID", example = "22353")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "来样品位")
|
||||||
|
private String data;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", example = "18328")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,47 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.alibaba.excel.annotation.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检登记来样品位 Response VO")
|
||||||
|
@Data
|
||||||
|
@ExcelIgnoreUnannotated
|
||||||
|
public class BusinessSampleAssayResultRespVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "31437")
|
||||||
|
@ExcelProperty("ID")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "委托登记样品明细ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "5711")
|
||||||
|
@ExcelProperty("委托登记样品明细ID")
|
||||||
|
private Long businessSampleEntrustDetailId;
|
||||||
|
|
||||||
|
@Schema(description = "样品主样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "22353")
|
||||||
|
@ExcelProperty("样品主样ID")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "来样品位", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("来样品位")
|
||||||
|
private String data;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("创建时间")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "18328")
|
||||||
|
@ExcelProperty("乐观锁")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
@ExcelProperty("备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检登记来样品位新增/修改 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleAssayResultSaveReqVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "31437")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "委托登记样品明细ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "5711")
|
||||||
|
@NotNull(message = "委托登记样品明细ID不能为空")
|
||||||
|
private Long businessSampleEntrustDetailId;
|
||||||
|
|
||||||
|
@Schema(description = "样品主样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "22353")
|
||||||
|
@NotNull(message = "样品主样ID不能为空")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "来样品位", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "来样品位不能为空")
|
||||||
|
private String data;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "所属部门不能为空")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "18328")
|
||||||
|
@NotNull(message = "乐观锁不能为空")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,24 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>BusinessSampleEntrustDetailExtendRespVO</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月10日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月10日
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustDetailExtendRespVO extends BusinessSampleEntrustDetailRespVO {
|
||||||
|
|
||||||
|
private List<BusinessSampleEntrustProjectExtendRespVO> sampleEntrustDetailProjectList;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,65 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检登记样品明细分页 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustDetailPageReqVO extends PageParam {
|
||||||
|
|
||||||
|
@Schema(description = "检验委托登记ID", example = "3509")
|
||||||
|
private Long businessSampleEntrustRegistrationId;
|
||||||
|
|
||||||
|
@Schema(description = "主样业务ID", example = "24710")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品大类ID", example = "10243")
|
||||||
|
private Long baseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品类型ID,字典表:【T_DIC_BSN】结算样、委检样、生产样等", example = "27392")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", example = "芋艿")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "委托样品名称", example = "赵六")
|
||||||
|
private String entrustSampleName;
|
||||||
|
|
||||||
|
@Schema(description = "委托样品编号")
|
||||||
|
private String entrustSampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "排序")
|
||||||
|
private Integer sort;
|
||||||
|
|
||||||
|
@Schema(description = "检测项目")
|
||||||
|
private String assayProject;
|
||||||
|
|
||||||
|
@Schema(description = "预报结果")
|
||||||
|
private String forecastResult;
|
||||||
|
|
||||||
|
@Schema(description = "是否称重,1-启用,0-不启用")
|
||||||
|
private Integer isWeighing;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", example = "12540")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,83 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.alibaba.excel.annotation.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检登记样品明细 Response VO")
|
||||||
|
@Data
|
||||||
|
@ExcelIgnoreUnannotated
|
||||||
|
public class BusinessSampleEntrustDetailRespVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "12340")
|
||||||
|
@ExcelProperty("ID")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "检验委托登记ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "3509")
|
||||||
|
@ExcelProperty("检验委托登记ID")
|
||||||
|
private Long businessSampleEntrustRegistrationId;
|
||||||
|
|
||||||
|
@Schema(description = "主样业务ID", example = "24710")
|
||||||
|
@ExcelProperty("主样业务ID")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品大类ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "10243")
|
||||||
|
@ExcelProperty("样品大类ID")
|
||||||
|
private Long baseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品类型ID,字典表:【T_DIC_BSN】结算样、委检样、生产样等", requiredMode = Schema.RequiredMode.REQUIRED, example = "27392")
|
||||||
|
@ExcelProperty("样品类型ID,字典表:【T_DIC_BSN】结算样、委检样、生产样等")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", example = "芋艿")
|
||||||
|
@ExcelProperty("样品名称")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
@ExcelProperty("样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "委托样品名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "赵六")
|
||||||
|
@ExcelProperty("委托样品名称")
|
||||||
|
private String entrustSampleName;
|
||||||
|
|
||||||
|
@Schema(description = "委托样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("委托样品编号")
|
||||||
|
private String entrustSampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "排序", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("排序")
|
||||||
|
private Integer sort;
|
||||||
|
|
||||||
|
@Schema(description = "检测项目")
|
||||||
|
@ExcelProperty("检测项目")
|
||||||
|
private String assayProject;
|
||||||
|
|
||||||
|
@Schema(description = "预报结果")
|
||||||
|
@ExcelProperty("预报结果")
|
||||||
|
private String forecastResult;
|
||||||
|
|
||||||
|
@Schema(description = "是否称重,1-启用,0-不启用", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("是否称重,1-启用,0-不启用")
|
||||||
|
private Integer isWeighing;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
@ExcelProperty("所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("创建时间")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", example = "12540")
|
||||||
|
@ExcelProperty("乐观锁")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
@ExcelProperty("备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,67 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检登记样品明细新增/修改 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustDetailSaveReqVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "12340")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "检验委托登记ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "3509")
|
||||||
|
@NotNull(message = "检验委托登记ID不能为空")
|
||||||
|
private Long businessSampleEntrustRegistrationId;
|
||||||
|
|
||||||
|
@Schema(description = "主样业务ID", example = "24710")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品大类ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "10243")
|
||||||
|
@NotNull(message = "样品大类ID不能为空")
|
||||||
|
private Long baseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品类型ID,字典表:【T_DIC_BSN】结算样、委检样、生产样等", requiredMode = Schema.RequiredMode.REQUIRED, example = "27392")
|
||||||
|
@NotNull(message = "样品类型ID,字典表:【T_DIC_BSN】结算样、委检样、生产样等不能为空")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", example = "芋艿")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "委托样品名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "赵六")
|
||||||
|
@NotEmpty(message = "委托样品名称不能为空")
|
||||||
|
private String entrustSampleName;
|
||||||
|
|
||||||
|
@Schema(description = "委托样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "委托样品编号不能为空")
|
||||||
|
private String entrustSampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "排序", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "排序不能为空")
|
||||||
|
private Integer sort;
|
||||||
|
|
||||||
|
@Schema(description = "检测项目")
|
||||||
|
private String assayProject;
|
||||||
|
|
||||||
|
@Schema(description = "预报结果")
|
||||||
|
private String forecastResult;
|
||||||
|
|
||||||
|
@Schema(description = "是否称重,1-启用,0-不启用", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "是否称重,1-启用,0-不启用不能为空")
|
||||||
|
private Integer isWeighing;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", example = "12540")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,31 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>BusinessSampleEntrustProjectExtendRespVO</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月10日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月10日
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustProjectExtendRespVO extends BusinessSampleEntrustProjectRespVO {
|
||||||
|
|
||||||
|
/** 检测项目编码 **/
|
||||||
|
private String projectCode;
|
||||||
|
|
||||||
|
/** 检测项目名称 **/
|
||||||
|
private String projectName;
|
||||||
|
|
||||||
|
/** 检测项目缩写 **/
|
||||||
|
private String projectSimpleName;
|
||||||
|
|
||||||
|
/** 检测项目显示名称 **/
|
||||||
|
private String projectShowName;
|
||||||
|
}
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检样品检测项目业务分页 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustProjectPageReqVO extends PageParam {
|
||||||
|
|
||||||
|
@Schema(description = "样品检验委托明细ID", example = "31234")
|
||||||
|
private Long businessSampleEntrustDetailId;
|
||||||
|
|
||||||
|
@Schema(description = "物料检测标准检测项目ID", example = "1780")
|
||||||
|
private Long materialAssayStandardDetailId;
|
||||||
|
|
||||||
|
@Schema(description = "检测项目ID,字典表:【T_DIC_PRJ】", example = "29566")
|
||||||
|
private Long dictionaryProjectId;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用,1-启用,0-不启用")
|
||||||
|
private Integer isEnabled;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", example = "22753")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,51 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.alibaba.excel.annotation.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检样品检测项目业务 Response VO")
|
||||||
|
@Data
|
||||||
|
@ExcelIgnoreUnannotated
|
||||||
|
public class BusinessSampleEntrustProjectRespVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "6960")
|
||||||
|
@ExcelProperty("ID")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品检验委托明细ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "31234")
|
||||||
|
@ExcelProperty("样品检验委托明细ID")
|
||||||
|
private Long businessSampleEntrustDetailId;
|
||||||
|
|
||||||
|
@Schema(description = "物料检测标准检测项目ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "1780")
|
||||||
|
@ExcelProperty("物料检测标准检测项目ID")
|
||||||
|
private Long materialAssayStandardDetailId;
|
||||||
|
|
||||||
|
@Schema(description = "检测项目ID,字典表:【T_DIC_PRJ】", requiredMode = Schema.RequiredMode.REQUIRED, example = "29566")
|
||||||
|
@ExcelProperty("检测项目ID,字典表:【T_DIC_PRJ】")
|
||||||
|
private Long dictionaryProjectId;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用,1-启用,0-不启用", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("是否启用,1-启用,0-不启用")
|
||||||
|
private Integer isEnabled;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("创建时间")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "22753")
|
||||||
|
@ExcelProperty("乐观锁")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
@ExcelProperty("备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,42 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检样品检测项目业务新增/修改 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustProjectSaveReqVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "6960")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品检验委托明细ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "31234")
|
||||||
|
@NotNull(message = "样品检验委托明细ID不能为空")
|
||||||
|
private Long businessSampleEntrustDetailId;
|
||||||
|
|
||||||
|
@Schema(description = "物料检测标准检测项目ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "1780")
|
||||||
|
@NotNull(message = "物料检测标准检测项目ID不能为空")
|
||||||
|
private Long materialAssayStandardDetailId;
|
||||||
|
|
||||||
|
@Schema(description = "检测项目ID,字典表:【T_DIC_PRJ】", requiredMode = Schema.RequiredMode.REQUIRED, example = "29566")
|
||||||
|
@NotNull(message = "检测项目ID,字典表:【T_DIC_PRJ】不能为空")
|
||||||
|
private Long dictionaryProjectId;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用,1-启用,0-不启用", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "是否启用,1-启用,0-不启用不能为空")
|
||||||
|
private Integer isEnabled;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "所属部门不能为空")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "22753")
|
||||||
|
@NotNull(message = "乐观锁不能为空")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,23 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>BusinessSampleEntrustRegistrationExtendRespVO</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月10日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月10日
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustRegistrationExtendRespVO extends BusinessSampleEntrustRegistrationRespVO {
|
||||||
|
|
||||||
|
private List<BusinessSampleEntrustDetailExtendRespVO> sampleEntrustDetailList;
|
||||||
|
}
|
||||||
@@ -0,0 +1,135 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检登记业务分页 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustRegistrationPageReqVO extends PageParam {
|
||||||
|
|
||||||
|
@Schema(description = "委托ID", example = "8324")
|
||||||
|
private Long entrustId;
|
||||||
|
|
||||||
|
@Schema(description = "委托单号")
|
||||||
|
private String entrustNumber;
|
||||||
|
|
||||||
|
@Schema(description = "委托单位/送样单位")
|
||||||
|
private String entrustUnit;
|
||||||
|
|
||||||
|
@Schema(description = "委托来源,西南铜委托、商检委托、内部委托、抽查委托、内审委托、生产委托", example = "25366")
|
||||||
|
private Long configEntrustSourceId;
|
||||||
|
|
||||||
|
@Schema(description = "样品数量")
|
||||||
|
private Integer sampleQuantity;
|
||||||
|
|
||||||
|
@Schema(description = "任务数量")
|
||||||
|
private Integer taskQuantity;
|
||||||
|
|
||||||
|
@Schema(description = "已完成任务数量")
|
||||||
|
private Integer taskFinishedQuantity;
|
||||||
|
|
||||||
|
@Schema(description = "余样要求,【字典】【jy_sample_entrust_remaine_requirement】余样返回、放弃")
|
||||||
|
private String remaineSampleRequirement;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_entrust_status】块状、粉末、颗粒、液体", example = "2")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "电话")
|
||||||
|
private String tel;
|
||||||
|
|
||||||
|
@Schema(description = "传真")
|
||||||
|
private String fax;
|
||||||
|
|
||||||
|
@Schema(description = "通讯地址")
|
||||||
|
private String address;
|
||||||
|
|
||||||
|
@Schema(description = "邮编")
|
||||||
|
private String postal;
|
||||||
|
|
||||||
|
@Schema(description = "E-mail")
|
||||||
|
private String email;
|
||||||
|
|
||||||
|
@Schema(description = "委托检测类别,【字典】【jy_sample_entrust_category】一般委托、仲裁委托")
|
||||||
|
private String entrustCategory;
|
||||||
|
|
||||||
|
@Schema(description = "样品类别(装港/卸港),【字典】【jy_sample_entrust_category】装港样、卸港样")
|
||||||
|
private String sampleCategory;
|
||||||
|
|
||||||
|
@Schema(description = "样品来源,【字典】【jy_sample_entrust_origin】送样、邮寄、现场取样")
|
||||||
|
private String sampleOrigin;
|
||||||
|
|
||||||
|
@Schema(description = "保密要求,【字典】【jy_sample_entrust_secrecy_requirement】要求对样品和文件保密、无保密要求")
|
||||||
|
private String secrecyRequire;
|
||||||
|
|
||||||
|
@Schema(description = "检测方法,【字典】【jy_sample_entrust_assay_method】国标、行标、客户要求、检测方依据样品选择")
|
||||||
|
private String assayMethod;
|
||||||
|
|
||||||
|
@Schema(description = "送样人")
|
||||||
|
private String sampleSender;
|
||||||
|
|
||||||
|
@Schema(description = "送样日期")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] sampleSendDate;
|
||||||
|
|
||||||
|
@Schema(description = "收样人")
|
||||||
|
private String sampleReceiver;
|
||||||
|
|
||||||
|
@Schema(description = "收样日期")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] sampleReceiveDate;
|
||||||
|
|
||||||
|
@Schema(description = "登记状态,register-登记中、submitted-已提交", example = "1")
|
||||||
|
private String registrationStatus;
|
||||||
|
|
||||||
|
@Schema(description = "数据校验状态,success-数据校验成功、fail-数据校验失败", example = "2")
|
||||||
|
private String dataCheckStatus;
|
||||||
|
|
||||||
|
@Schema(description = "检验状态,unchecked-未检验;checked-已检验", example = "1")
|
||||||
|
private String assayStatus;
|
||||||
|
|
||||||
|
@Schema(description = "数据回报状态,unreturned-未回报;returned-已回报", example = "1")
|
||||||
|
private String dataStatus;
|
||||||
|
|
||||||
|
@Schema(description = "报告IDs", example = "17931")
|
||||||
|
private String documentMainId;
|
||||||
|
|
||||||
|
@Schema(description = "报告发送方式,【字典】【jy_sample_entrust_send_way】自取、邮寄、电话、传真、E-mail")
|
||||||
|
private String documentSendWay;
|
||||||
|
|
||||||
|
@Schema(description = "报告发送人")
|
||||||
|
private String documentPublisher;
|
||||||
|
|
||||||
|
@Schema(description = "报告发送日期")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] documentPublisherDate;
|
||||||
|
|
||||||
|
@Schema(description = "报告接收人")
|
||||||
|
private String documentReceiver;
|
||||||
|
|
||||||
|
@Schema(description = "报告接收日期")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] documentReceiveDate;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", example = "6291")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
@Schema(description = "扩展信息")
|
||||||
|
private String externalInfomation;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,171 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.alibaba.excel.annotation.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检登记业务 Response VO")
|
||||||
|
@Data
|
||||||
|
@ExcelIgnoreUnannotated
|
||||||
|
public class BusinessSampleEntrustRegistrationRespVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "9288")
|
||||||
|
@ExcelProperty("ID")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "委托ID", example = "8324")
|
||||||
|
@ExcelProperty("委托ID")
|
||||||
|
private Long entrustId;
|
||||||
|
|
||||||
|
@Schema(description = "委托单号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("委托单号")
|
||||||
|
private String entrustNumber;
|
||||||
|
|
||||||
|
@Schema(description = "委托单位/送样单位", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("委托单位/送样单位")
|
||||||
|
private String entrustUnit;
|
||||||
|
|
||||||
|
@Schema(description = "委托来源,西南铜委托、商检委托、内部委托、抽查委托、内审委托、生产委托", requiredMode = Schema.RequiredMode.REQUIRED, example = "25366")
|
||||||
|
@ExcelProperty("委托来源,西南铜委托、商检委托、内部委托、抽查委托、内审委托、生产委托")
|
||||||
|
private Long configEntrustSourceId;
|
||||||
|
|
||||||
|
@Schema(description = "样品数量", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品数量")
|
||||||
|
private Integer sampleQuantity;
|
||||||
|
|
||||||
|
@Schema(description = "任务数量", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("任务数量")
|
||||||
|
private Integer taskQuantity;
|
||||||
|
|
||||||
|
@Schema(description = "已完成任务数量")
|
||||||
|
@ExcelProperty("已完成任务数量")
|
||||||
|
private Integer taskFinishedQuantity;
|
||||||
|
|
||||||
|
@Schema(description = "余样要求,【字典】【jy_sample_entrust_remaine_requirement】余样返回、放弃", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("余样要求,【字典】【jy_sample_entrust_remaine_requirement】余样返回、放弃")
|
||||||
|
private String remaineSampleRequirement;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_entrust_status】块状、粉末、颗粒、液体", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
|
||||||
|
@ExcelProperty("样品状态,【字典】【jy_sample_entrust_status】块状、粉末、颗粒、液体")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "电话")
|
||||||
|
@ExcelProperty("电话")
|
||||||
|
private String tel;
|
||||||
|
|
||||||
|
@Schema(description = "传真")
|
||||||
|
@ExcelProperty("传真")
|
||||||
|
private String fax;
|
||||||
|
|
||||||
|
@Schema(description = "通讯地址")
|
||||||
|
@ExcelProperty("通讯地址")
|
||||||
|
private String address;
|
||||||
|
|
||||||
|
@Schema(description = "邮编")
|
||||||
|
@ExcelProperty("邮编")
|
||||||
|
private String postal;
|
||||||
|
|
||||||
|
@Schema(description = "E-mail")
|
||||||
|
@ExcelProperty("E-mail")
|
||||||
|
private String email;
|
||||||
|
|
||||||
|
@Schema(description = "委托检测类别,【字典】【jy_sample_entrust_category】一般委托、仲裁委托")
|
||||||
|
@ExcelProperty("委托检测类别,【字典】【jy_sample_entrust_category】一般委托、仲裁委托")
|
||||||
|
private String entrustCategory;
|
||||||
|
|
||||||
|
@Schema(description = "样品类别(装港/卸港),【字典】【jy_sample_entrust_category】装港样、卸港样")
|
||||||
|
@ExcelProperty("样品类别(装港/卸港),【字典】【jy_sample_entrust_category】装港样、卸港样")
|
||||||
|
private String sampleCategory;
|
||||||
|
|
||||||
|
@Schema(description = "样品来源,【字典】【jy_sample_entrust_origin】送样、邮寄、现场取样", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品来源,【字典】【jy_sample_entrust_origin】送样、邮寄、现场取样")
|
||||||
|
private String sampleOrigin;
|
||||||
|
|
||||||
|
@Schema(description = "保密要求,【字典】【jy_sample_entrust_secrecy_requirement】要求对样品和文件保密、无保密要求", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("保密要求,【字典】【jy_sample_entrust_secrecy_requirement】要求对样品和文件保密、无保密要求")
|
||||||
|
private String secrecyRequire;
|
||||||
|
|
||||||
|
@Schema(description = "检测方法,【字典】【jy_sample_entrust_assay_method】国标、行标、客户要求、检测方依据样品选择", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("检测方法,【字典】【jy_sample_entrust_assay_method】国标、行标、客户要求、检测方依据样品选择")
|
||||||
|
private String assayMethod;
|
||||||
|
|
||||||
|
@Schema(description = "送样人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("送样人")
|
||||||
|
private String sampleSender;
|
||||||
|
|
||||||
|
@Schema(description = "送样日期", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("送样日期")
|
||||||
|
private LocalDateTime sampleSendDate;
|
||||||
|
|
||||||
|
@Schema(description = "收样人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("收样人")
|
||||||
|
private String sampleReceiver;
|
||||||
|
|
||||||
|
@Schema(description = "收样日期", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("收样日期")
|
||||||
|
private LocalDateTime sampleReceiveDate;
|
||||||
|
|
||||||
|
@Schema(description = "登记状态,register-登记中、submitted-已提交", example = "1")
|
||||||
|
@ExcelProperty("登记状态,register-登记中、submitted-已提交")
|
||||||
|
private String registrationStatus;
|
||||||
|
|
||||||
|
@Schema(description = "数据校验状态,success-数据校验成功、fail-数据校验失败", example = "2")
|
||||||
|
@ExcelProperty("数据校验状态,success-数据校验成功、fail-数据校验失败")
|
||||||
|
private String dataCheckStatus;
|
||||||
|
|
||||||
|
@Schema(description = "检验状态,unchecked-未检验;checked-已检验", example = "1")
|
||||||
|
@ExcelProperty("检验状态,unchecked-未检验;checked-已检验")
|
||||||
|
private String assayStatus;
|
||||||
|
|
||||||
|
@Schema(description = "数据回报状态,unreturned-未回报;returned-已回报", example = "1")
|
||||||
|
@ExcelProperty("数据回报状态,unreturned-未回报;returned-已回报")
|
||||||
|
private String dataStatus;
|
||||||
|
|
||||||
|
@Schema(description = "报告IDs", example = "17931")
|
||||||
|
@ExcelProperty("报告IDs")
|
||||||
|
private String documentMainId;
|
||||||
|
|
||||||
|
@Schema(description = "报告发送方式,【字典】【jy_sample_entrust_send_way】自取、邮寄、电话、传真、E-mail")
|
||||||
|
@ExcelProperty("报告发送方式,【字典】【jy_sample_entrust_send_way】自取、邮寄、电话、传真、E-mail")
|
||||||
|
private String documentSendWay;
|
||||||
|
|
||||||
|
@Schema(description = "报告发送人")
|
||||||
|
@ExcelProperty("报告发送人")
|
||||||
|
private String documentPublisher;
|
||||||
|
|
||||||
|
@Schema(description = "报告发送日期")
|
||||||
|
@ExcelProperty("报告发送日期")
|
||||||
|
private LocalDateTime documentPublisherDate;
|
||||||
|
|
||||||
|
@Schema(description = "报告接收人")
|
||||||
|
@ExcelProperty("报告接收人")
|
||||||
|
private String documentReceiver;
|
||||||
|
|
||||||
|
@Schema(description = "报告接收日期")
|
||||||
|
@ExcelProperty("报告接收日期")
|
||||||
|
private LocalDateTime documentReceiveDate;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("创建时间")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "6291")
|
||||||
|
@ExcelProperty("乐观锁")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
@Schema(description = "扩展信息")
|
||||||
|
@ExcelProperty("扩展信息")
|
||||||
|
private String externalInfomation;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,145 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 委检登记业务新增/修改 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustRegistrationSaveReqVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "9288")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "委托ID", example = "8324")
|
||||||
|
private Long entrustId;
|
||||||
|
|
||||||
|
@Schema(description = "委托单号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "委托单号不能为空")
|
||||||
|
private String entrustNumber;
|
||||||
|
|
||||||
|
@Schema(description = "委托单位/送样单位", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "委托单位/送样单位不能为空")
|
||||||
|
private String entrustUnit;
|
||||||
|
|
||||||
|
@Schema(description = "委托来源,西南铜委托、商检委托、内部委托、抽查委托、内审委托、生产委托", requiredMode = Schema.RequiredMode.REQUIRED, example = "25366")
|
||||||
|
@NotNull(message = "委托来源,西南铜委托、商检委托、内部委托、抽查委托、内审委托、生产委托不能为空")
|
||||||
|
private Long configEntrustSourceId;
|
||||||
|
|
||||||
|
@Schema(description = "样品数量", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "样品数量不能为空")
|
||||||
|
private Integer sampleQuantity;
|
||||||
|
|
||||||
|
@Schema(description = "任务数量", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "任务数量不能为空")
|
||||||
|
private Integer taskQuantity;
|
||||||
|
|
||||||
|
@Schema(description = "已完成任务数量")
|
||||||
|
private Integer taskFinishedQuantity;
|
||||||
|
|
||||||
|
@Schema(description = "余样要求,【字典】【jy_sample_entrust_remaine_requirement】余样返回、放弃", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "余样要求,【字典】【jy_sample_entrust_remaine_requirement】余样返回、放弃不能为空")
|
||||||
|
private String remaineSampleRequirement;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_entrust_status】块状、粉末、颗粒、液体", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
|
||||||
|
@NotEmpty(message = "样品状态,【字典】【jy_sample_entrust_status】块状、粉末、颗粒、液体不能为空")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "电话")
|
||||||
|
private String tel;
|
||||||
|
|
||||||
|
@Schema(description = "传真")
|
||||||
|
private String fax;
|
||||||
|
|
||||||
|
@Schema(description = "通讯地址")
|
||||||
|
private String address;
|
||||||
|
|
||||||
|
@Schema(description = "邮编")
|
||||||
|
private String postal;
|
||||||
|
|
||||||
|
@Schema(description = "E-mail")
|
||||||
|
private String email;
|
||||||
|
|
||||||
|
@Schema(description = "委托检测类别,【字典】【jy_sample_entrust_category】一般委托、仲裁委托")
|
||||||
|
private String entrustCategory;
|
||||||
|
|
||||||
|
@Schema(description = "样品类别(装港/卸港),【字典】【jy_sample_entrust_category】装港样、卸港样")
|
||||||
|
private String sampleCategory;
|
||||||
|
|
||||||
|
@Schema(description = "样品来源,【字典】【jy_sample_entrust_origin】送样、邮寄、现场取样", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "样品来源,【字典】【jy_sample_entrust_origin】送样、邮寄、现场取样不能为空")
|
||||||
|
private String sampleOrigin;
|
||||||
|
|
||||||
|
@Schema(description = "保密要求,【字典】【jy_sample_entrust_secrecy_requirement】要求对样品和文件保密、无保密要求", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "保密要求,【字典】【jy_sample_entrust_secrecy_requirement】要求对样品和文件保密、无保密要求不能为空")
|
||||||
|
private String secrecyRequire;
|
||||||
|
|
||||||
|
@Schema(description = "检测方法,【字典】【jy_sample_entrust_assay_method】国标、行标、客户要求、检测方依据样品选择", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "检测方法,【字典】【jy_sample_entrust_assay_method】国标、行标、客户要求、检测方依据样品选择不能为空")
|
||||||
|
private String assayMethod;
|
||||||
|
|
||||||
|
@Schema(description = "送样人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "送样人不能为空")
|
||||||
|
private String sampleSender;
|
||||||
|
|
||||||
|
@Schema(description = "送样日期", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "送样日期不能为空")
|
||||||
|
private LocalDateTime sampleSendDate;
|
||||||
|
|
||||||
|
@Schema(description = "收样人", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "收样人不能为空")
|
||||||
|
private String sampleReceiver;
|
||||||
|
|
||||||
|
@Schema(description = "收样日期", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "收样日期不能为空")
|
||||||
|
private LocalDateTime sampleReceiveDate;
|
||||||
|
|
||||||
|
@Schema(description = "登记状态,register-登记中、submitted-已提交", example = "1")
|
||||||
|
private String registrationStatus;
|
||||||
|
|
||||||
|
@Schema(description = "数据校验状态,success-数据校验成功、fail-数据校验失败", example = "2")
|
||||||
|
private String dataCheckStatus;
|
||||||
|
|
||||||
|
@Schema(description = "检验状态,unchecked-未检验;checked-已检验", example = "1")
|
||||||
|
private String assayStatus;
|
||||||
|
|
||||||
|
@Schema(description = "数据回报状态,unreturned-未回报;returned-已回报", example = "1")
|
||||||
|
private String dataStatus;
|
||||||
|
|
||||||
|
@Schema(description = "报告IDs", example = "17931")
|
||||||
|
private String documentMainId;
|
||||||
|
|
||||||
|
@Schema(description = "报告发送方式,【字典】【jy_sample_entrust_send_way】自取、邮寄、电话、传真、E-mail")
|
||||||
|
private String documentSendWay;
|
||||||
|
|
||||||
|
@Schema(description = "报告发送人")
|
||||||
|
private String documentPublisher;
|
||||||
|
|
||||||
|
@Schema(description = "报告发送日期")
|
||||||
|
private LocalDateTime documentPublisherDate;
|
||||||
|
|
||||||
|
@Schema(description = "报告接收人")
|
||||||
|
private String documentReceiver;
|
||||||
|
|
||||||
|
@Schema(description = "报告接收日期")
|
||||||
|
private LocalDateTime documentReceiveDate;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "所属部门不能为空")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "6291")
|
||||||
|
@NotNull(message = "乐观锁不能为空")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "备注不能为空")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
@Schema(description = "扩展信息")
|
||||||
|
private String externalInfomation;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,33 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>BusinessSampleEntrustRegistrationSubmitReqVO</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月10日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月10日
|
||||||
|
*/
|
||||||
|
@Schema(description = "管理后台 - 委检登记业务提交 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSampleEntrustRegistrationSubmitReqVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "9288")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "是否收样", example = "1")
|
||||||
|
private Integer isReceiveSample = 0;
|
||||||
|
|
||||||
|
@Schema(description = "是否送样", example = "1")
|
||||||
|
private Integer isSendSample = 0;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,72 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 分样业务分页 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSubParentSamplePageReqVO extends PageParam {
|
||||||
|
|
||||||
|
@Schema(description = "样品ID", example = "18364")
|
||||||
|
private Long sampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品主样ID", example = "26057")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "分样配置ID", example = "2344")
|
||||||
|
private Long configSubSampleParentId;
|
||||||
|
|
||||||
|
@Schema(description = "分样类型ID,字典表:【T_DIC_BSN】化学样、试金样、仪器样", example = "21472")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", example = "张三")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "子样样品编号")
|
||||||
|
private String subSampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "子样归库码")
|
||||||
|
private String subSampleReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "上报人")
|
||||||
|
private String reporter;
|
||||||
|
|
||||||
|
@Schema(description = "上报时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] reportTime;
|
||||||
|
|
||||||
|
@Schema(description = "审核流程code")
|
||||||
|
private String auditFlowCode;
|
||||||
|
|
||||||
|
@Schema(description = "超差标注", example = "2")
|
||||||
|
private Integer assessmentStatus;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废", example = "2")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用,1-启用,0-不启用")
|
||||||
|
private Integer isEnabled;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建日期")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", example = "4381")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.alibaba.excel.annotation.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 分样业务 Response VO")
|
||||||
|
@Data
|
||||||
|
@ExcelIgnoreUnannotated
|
||||||
|
public class BusinessSubParentSampleRespVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "25832")
|
||||||
|
@ExcelProperty("ID")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "18364")
|
||||||
|
@ExcelProperty("样品ID")
|
||||||
|
private Long sampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品主样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "26057")
|
||||||
|
@ExcelProperty("样品主样ID")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "分样配置ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "2344")
|
||||||
|
@ExcelProperty("分样配置ID")
|
||||||
|
private Long configSubSampleParentId;
|
||||||
|
|
||||||
|
@Schema(description = "分样类型ID,字典表:【T_DIC_BSN】化学样、试金样、仪器样", requiredMode = Schema.RequiredMode.REQUIRED, example = "21472")
|
||||||
|
@ExcelProperty("分样类型ID,字典表:【T_DIC_BSN】化学样、试金样、仪器样")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "张三")
|
||||||
|
@ExcelProperty("样品名称")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "子样样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("子样样品编号")
|
||||||
|
private String subSampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "子样归库码")
|
||||||
|
@ExcelProperty("子样归库码")
|
||||||
|
private String subSampleReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "上报人")
|
||||||
|
@ExcelProperty("上报人")
|
||||||
|
private String reporter;
|
||||||
|
|
||||||
|
@Schema(description = "上报时间")
|
||||||
|
@ExcelProperty("上报时间")
|
||||||
|
private LocalDateTime reportTime;
|
||||||
|
|
||||||
|
@Schema(description = "审核流程code")
|
||||||
|
@ExcelProperty("审核流程code")
|
||||||
|
private String auditFlowCode;
|
||||||
|
|
||||||
|
@Schema(description = "超差标注", example = "2")
|
||||||
|
@ExcelProperty("超差标注")
|
||||||
|
private Integer assessmentStatus;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
|
||||||
|
@ExcelProperty("样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用,1-启用,0-不启用", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("是否启用,1-启用,0-不启用")
|
||||||
|
private Integer isEnabled;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建日期", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("创建日期")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "4381")
|
||||||
|
@ExcelProperty("乐观锁")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
@ExcelProperty("备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 分样业务新增/修改 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSubParentSampleSaveReqVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "25832")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "18364")
|
||||||
|
@NotNull(message = "样品ID不能为空")
|
||||||
|
private Long sampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品主样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "26057")
|
||||||
|
@NotNull(message = "样品主样ID不能为空")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "分样配置ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "2344")
|
||||||
|
@NotNull(message = "分样配置ID不能为空")
|
||||||
|
private Long configSubSampleParentId;
|
||||||
|
|
||||||
|
@Schema(description = "分样类型ID,字典表:【T_DIC_BSN】化学样、试金样、仪器样", requiredMode = Schema.RequiredMode.REQUIRED, example = "21472")
|
||||||
|
@NotNull(message = "分样类型ID,字典表:【T_DIC_BSN】化学样、试金样、仪器样不能为空")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "样品编号不能为空")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "张三")
|
||||||
|
@NotEmpty(message = "样品名称不能为空")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "子样样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "子样样品编号不能为空")
|
||||||
|
private String subSampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "子样归库码")
|
||||||
|
private String subSampleReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "上报人")
|
||||||
|
private String reporter;
|
||||||
|
|
||||||
|
@Schema(description = "上报时间")
|
||||||
|
private LocalDateTime reportTime;
|
||||||
|
|
||||||
|
@Schema(description = "审核流程code")
|
||||||
|
private String auditFlowCode;
|
||||||
|
|
||||||
|
@Schema(description = "超差标注", example = "2")
|
||||||
|
private Integer assessmentStatus;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
|
||||||
|
@NotEmpty(message = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废不能为空")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用,1-启用,0-不启用", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "是否启用,1-启用,0-不启用不能为空")
|
||||||
|
private Integer isEnabled;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "所属部门不能为空")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "4381")
|
||||||
|
@NotNull(message = "乐观锁不能为空")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,121 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 子样业务分页 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSubSamplePageReqVO extends PageParam {
|
||||||
|
|
||||||
|
@Schema(description = "样品主样ID", example = "11587")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品分样ID", example = "2157")
|
||||||
|
private Long businessSubParentSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "子样配置ID", example = "20299")
|
||||||
|
private Long configSubSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "子样类型ID,字典表:【T_DIC_BSN】化学分析样、试金分析样、仪器分析样", example = "30304")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "库位信息ID", example = "28807")
|
||||||
|
private Long configWarehouseLocationInfomationId;
|
||||||
|
|
||||||
|
@Schema(description = "样品ID", example = "13062")
|
||||||
|
private Long sampleId;
|
||||||
|
|
||||||
|
@Schema(description = "组ID,如果是委托创建的,则组ID和样品分样ID一致", example = "29885")
|
||||||
|
private String groupId;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", example = "赵六")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "分析编号")
|
||||||
|
private String sampleAssayCode;
|
||||||
|
|
||||||
|
@Schema(description = "归库编号")
|
||||||
|
private String sampleReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程ID", example = "18294")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程KEY")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
|
||||||
|
@Schema(description = "下一步样品流程名称")
|
||||||
|
private String nextSampleFlow;
|
||||||
|
|
||||||
|
@Schema(description = "是否已生成归库码")
|
||||||
|
private Integer isGenerateReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "任务指派给分析人")
|
||||||
|
private String assayOperator;
|
||||||
|
|
||||||
|
@Schema(description = "是否已指派")
|
||||||
|
private Integer isTasked;
|
||||||
|
|
||||||
|
@Schema(description = "指派时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] taskTime;
|
||||||
|
|
||||||
|
@Schema(description = "是否已上报")
|
||||||
|
private Integer isReported;
|
||||||
|
|
||||||
|
@Schema(description = "上报人")
|
||||||
|
private String reporter;
|
||||||
|
|
||||||
|
@Schema(description = "上报时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] reportTime;
|
||||||
|
|
||||||
|
@Schema(description = "归库时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] returnTime;
|
||||||
|
|
||||||
|
@Schema(description = "归库状态,【字典】【jy_sample_return_status】待归库、已归库、已调拨、已下架、待销毁、已销毁", example = "1")
|
||||||
|
private Integer returnStatus;
|
||||||
|
|
||||||
|
@Schema(description = "打印次数", example = "28859")
|
||||||
|
private Integer returnCodePrintCount;
|
||||||
|
|
||||||
|
@Schema(description = "末次打印时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] printLastTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程节点时间")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] sampleFlowTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废", example = "2")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用,1-启用,0-不启用")
|
||||||
|
private Integer isEnabled;
|
||||||
|
|
||||||
|
@Schema(description = "分析元素备注")
|
||||||
|
private String analysisRemark;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建日期")
|
||||||
|
@DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
|
||||||
|
private LocalDateTime[] createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", example = "8971")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,151 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.alibaba.excel.annotation.*;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 子样业务 Response VO")
|
||||||
|
@Data
|
||||||
|
@ExcelIgnoreUnannotated
|
||||||
|
public class BusinessSubSampleRespVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "18282")
|
||||||
|
@ExcelProperty("ID")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品主样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "11587")
|
||||||
|
@ExcelProperty("样品主样ID")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品分样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "2157")
|
||||||
|
@ExcelProperty("样品分样ID")
|
||||||
|
private Long businessSubParentSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "子样配置ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "20299")
|
||||||
|
@ExcelProperty("子样配置ID")
|
||||||
|
private Long configSubSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "子样类型ID,字典表:【T_DIC_BSN】化学分析样、试金分析样、仪器分析样", requiredMode = Schema.RequiredMode.REQUIRED, example = "30304")
|
||||||
|
@ExcelProperty("子样类型ID,字典表:【T_DIC_BSN】化学分析样、试金分析样、仪器分析样")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "库位信息ID", example = "28807")
|
||||||
|
@ExcelProperty("库位信息ID")
|
||||||
|
private Long configWarehouseLocationInfomationId;
|
||||||
|
|
||||||
|
@Schema(description = "样品ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "13062")
|
||||||
|
@ExcelProperty("样品ID")
|
||||||
|
private Long sampleId;
|
||||||
|
|
||||||
|
@Schema(description = "组ID,如果是委托创建的,则组ID和样品分样ID一致", example = "29885")
|
||||||
|
@ExcelProperty("组ID,如果是委托创建的,则组ID和样品分样ID一致")
|
||||||
|
private String groupId;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "赵六")
|
||||||
|
@ExcelProperty("样品名称")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品编号")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "分析编号")
|
||||||
|
@ExcelProperty("分析编号")
|
||||||
|
private String sampleAssayCode;
|
||||||
|
|
||||||
|
@Schema(description = "归库编号")
|
||||||
|
@ExcelProperty("归库编号")
|
||||||
|
private String sampleReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "18294")
|
||||||
|
@ExcelProperty("样品流程ID")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程KEY", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品流程KEY")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
|
||||||
|
@Schema(description = "下一步样品流程名称", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("下一步样品流程名称")
|
||||||
|
private String nextSampleFlow;
|
||||||
|
|
||||||
|
@Schema(description = "是否已生成归库码", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("是否已生成归库码")
|
||||||
|
private Integer isGenerateReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "任务指派给分析人")
|
||||||
|
@ExcelProperty("任务指派给分析人")
|
||||||
|
private String assayOperator;
|
||||||
|
|
||||||
|
@Schema(description = "是否已指派", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("是否已指派")
|
||||||
|
private Integer isTasked;
|
||||||
|
|
||||||
|
@Schema(description = "指派时间")
|
||||||
|
@ExcelProperty("指派时间")
|
||||||
|
private LocalDateTime taskTime;
|
||||||
|
|
||||||
|
@Schema(description = "是否已上报", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("是否已上报")
|
||||||
|
private Integer isReported;
|
||||||
|
|
||||||
|
@Schema(description = "上报人")
|
||||||
|
@ExcelProperty("上报人")
|
||||||
|
private String reporter;
|
||||||
|
|
||||||
|
@Schema(description = "上报时间")
|
||||||
|
@ExcelProperty("上报时间")
|
||||||
|
private LocalDateTime reportTime;
|
||||||
|
|
||||||
|
@Schema(description = "归库时间")
|
||||||
|
@ExcelProperty("归库时间")
|
||||||
|
private LocalDateTime returnTime;
|
||||||
|
|
||||||
|
@Schema(description = "归库状态,【字典】【jy_sample_return_status】待归库、已归库、已调拨、已下架、待销毁、已销毁", example = "1")
|
||||||
|
@ExcelProperty("归库状态,【字典】【jy_sample_return_status】待归库、已归库、已调拨、已下架、待销毁、已销毁")
|
||||||
|
private Integer returnStatus;
|
||||||
|
|
||||||
|
@Schema(description = "打印次数", requiredMode = Schema.RequiredMode.REQUIRED, example = "28859")
|
||||||
|
@ExcelProperty("打印次数")
|
||||||
|
private Integer returnCodePrintCount;
|
||||||
|
|
||||||
|
@Schema(description = "末次打印时间")
|
||||||
|
@ExcelProperty("末次打印时间")
|
||||||
|
private LocalDateTime printLastTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程节点时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("样品流程节点时间")
|
||||||
|
private LocalDateTime sampleFlowTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
|
||||||
|
@ExcelProperty("样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用,1-启用,0-不启用", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("是否启用,1-启用,0-不启用")
|
||||||
|
private Integer isEnabled;
|
||||||
|
|
||||||
|
@Schema(description = "分析元素备注")
|
||||||
|
@ExcelProperty("分析元素备注")
|
||||||
|
private String analysisRemark;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("所属部门")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "创建日期", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@ExcelProperty("创建日期")
|
||||||
|
private LocalDateTime createTime;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "8971")
|
||||||
|
@ExcelProperty("乐观锁")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
@ExcelProperty("备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,132 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.controller.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.constraints.*;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
|
||||||
|
@Schema(description = "管理后台 - 子样业务新增/修改 Request VO")
|
||||||
|
@Data
|
||||||
|
public class BusinessSubSampleSaveReqVO {
|
||||||
|
|
||||||
|
@Schema(description = "ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "18282")
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
@Schema(description = "样品主样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "11587")
|
||||||
|
@NotNull(message = "样品主样ID不能为空")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "样品分样ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "2157")
|
||||||
|
@NotNull(message = "样品分样ID不能为空")
|
||||||
|
private Long businessSubParentSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "子样配置ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "20299")
|
||||||
|
@NotNull(message = "子样配置ID不能为空")
|
||||||
|
private Long configSubSampleId;
|
||||||
|
|
||||||
|
@Schema(description = "子样类型ID,字典表:【T_DIC_BSN】化学分析样、试金分析样、仪器分析样", requiredMode = Schema.RequiredMode.REQUIRED, example = "30304")
|
||||||
|
@NotNull(message = "子样类型ID,字典表:【T_DIC_BSN】化学分析样、试金分析样、仪器分析样不能为空")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
@Schema(description = "库位信息ID", example = "28807")
|
||||||
|
private Long configWarehouseLocationInfomationId;
|
||||||
|
|
||||||
|
@Schema(description = "样品ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "13062")
|
||||||
|
@NotNull(message = "样品ID不能为空")
|
||||||
|
private Long sampleId;
|
||||||
|
|
||||||
|
@Schema(description = "组ID,如果是委托创建的,则组ID和样品分样ID一致", example = "29885")
|
||||||
|
private String groupId;
|
||||||
|
|
||||||
|
@Schema(description = "样品名称", requiredMode = Schema.RequiredMode.REQUIRED, example = "赵六")
|
||||||
|
@NotEmpty(message = "样品名称不能为空")
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
@Schema(description = "样品编号", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "样品编号不能为空")
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
@Schema(description = "分析编号")
|
||||||
|
private String sampleAssayCode;
|
||||||
|
|
||||||
|
@Schema(description = "归库编号")
|
||||||
|
private String sampleReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程ID", requiredMode = Schema.RequiredMode.REQUIRED, example = "18294")
|
||||||
|
@NotNull(message = "样品流程ID不能为空")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程KEY", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "样品流程KEY不能为空")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
|
||||||
|
@Schema(description = "下一步样品流程名称", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "下一步样品流程名称不能为空")
|
||||||
|
private String nextSampleFlow;
|
||||||
|
|
||||||
|
@Schema(description = "是否已生成归库码", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "是否已生成归库码不能为空")
|
||||||
|
private Integer isGenerateReturnCode;
|
||||||
|
|
||||||
|
@Schema(description = "任务指派给分析人")
|
||||||
|
private String assayOperator;
|
||||||
|
|
||||||
|
@Schema(description = "是否已指派", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "是否已指派不能为空")
|
||||||
|
private Integer isTasked;
|
||||||
|
|
||||||
|
@Schema(description = "指派时间")
|
||||||
|
private LocalDateTime taskTime;
|
||||||
|
|
||||||
|
@Schema(description = "是否已上报", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "是否已上报不能为空")
|
||||||
|
private Integer isReported;
|
||||||
|
|
||||||
|
@Schema(description = "上报人")
|
||||||
|
private String reporter;
|
||||||
|
|
||||||
|
@Schema(description = "上报时间")
|
||||||
|
private LocalDateTime reportTime;
|
||||||
|
|
||||||
|
@Schema(description = "归库时间")
|
||||||
|
private LocalDateTime returnTime;
|
||||||
|
|
||||||
|
@Schema(description = "归库状态,【字典】【jy_sample_return_status】待归库、已归库、已调拨、已下架、待销毁、已销毁", example = "1")
|
||||||
|
private Integer returnStatus;
|
||||||
|
|
||||||
|
@Schema(description = "打印次数", requiredMode = Schema.RequiredMode.REQUIRED, example = "28859")
|
||||||
|
@NotNull(message = "打印次数不能为空")
|
||||||
|
private Integer returnCodePrintCount;
|
||||||
|
|
||||||
|
@Schema(description = "末次打印时间")
|
||||||
|
private LocalDateTime printLastTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品流程节点时间", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "样品流程节点时间不能为空")
|
||||||
|
private LocalDateTime sampleFlowTime;
|
||||||
|
|
||||||
|
@Schema(description = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废", requiredMode = Schema.RequiredMode.REQUIRED, example = "2")
|
||||||
|
@NotEmpty(message = "样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废不能为空")
|
||||||
|
private String sampleStatus;
|
||||||
|
|
||||||
|
@Schema(description = "是否启用,1-启用,0-不启用", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotNull(message = "是否启用,1-启用,0-不启用不能为空")
|
||||||
|
private Integer isEnabled;
|
||||||
|
|
||||||
|
@Schema(description = "分析元素备注")
|
||||||
|
private String analysisRemark;
|
||||||
|
|
||||||
|
@Schema(description = "所属部门", requiredMode = Schema.RequiredMode.REQUIRED)
|
||||||
|
@NotEmpty(message = "所属部门不能为空")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
|
||||||
|
@Schema(description = "乐观锁", requiredMode = Schema.RequiredMode.REQUIRED, example = "8971")
|
||||||
|
@NotNull(message = "乐观锁不能为空")
|
||||||
|
private Integer updateCount;
|
||||||
|
|
||||||
|
@Schema(description = "备注")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,113 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.dataobject;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BusinessBaseDO;
|
||||||
|
/**
|
||||||
|
* 主样业务 DO
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@TableName("t_bsn_bse_smp")
|
||||||
|
@KeySequence("t_bsn_bse_smp_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = true)
|
||||||
|
@ToString(callSuper = true)
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
/**
|
||||||
|
* 支持业务基类继承:isBusiness=true 时继承 BusinessBaseDO,否则继承 BaseDO
|
||||||
|
*/
|
||||||
|
public class BusinessBaseSampleDO extends BusinessBaseDO {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ID
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
/**
|
||||||
|
* 样品名称
|
||||||
|
*/
|
||||||
|
@TableField("SMP_NAME")
|
||||||
|
private String sampleName;
|
||||||
|
/**
|
||||||
|
* 样品编号
|
||||||
|
*/
|
||||||
|
@TableField("SMP_CD")
|
||||||
|
private String sampleCode;
|
||||||
|
/**
|
||||||
|
* 主样配置ID
|
||||||
|
*/
|
||||||
|
@TableField("CFG_BSE_SMP_ID")
|
||||||
|
private Long configBaseSampleId;
|
||||||
|
/**
|
||||||
|
* 主样类型ID,字典表:【T_DIC_BSN】结算样、抽查样、委检样
|
||||||
|
*/
|
||||||
|
@TableField("DIC_BSN_ID")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
/**
|
||||||
|
* 样品生成时间
|
||||||
|
*/
|
||||||
|
@TableField("SMP_TM")
|
||||||
|
private LocalDateTime sampleTime;
|
||||||
|
/**
|
||||||
|
* 打印次数
|
||||||
|
*/
|
||||||
|
@TableField("PRNT_CNT")
|
||||||
|
private Integer printCount;
|
||||||
|
/**
|
||||||
|
* 末次打印时间
|
||||||
|
*/
|
||||||
|
@TableField("PRNT_LST_TM")
|
||||||
|
private LocalDateTime printLastTime;
|
||||||
|
/**
|
||||||
|
* 样品流程ID
|
||||||
|
*/
|
||||||
|
@TableField("SMP_FLW_ID")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
/**
|
||||||
|
* 样品流程KEY
|
||||||
|
*/
|
||||||
|
@TableField("SMP_FLW_KY")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
/**
|
||||||
|
* 样品流程节点时间
|
||||||
|
*/
|
||||||
|
@TableField("SMP_FLW_TM")
|
||||||
|
private LocalDateTime sampleFlowTime;
|
||||||
|
/**
|
||||||
|
* 样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废
|
||||||
|
*/
|
||||||
|
@TableField("SMP_STS")
|
||||||
|
private String sampleStatus;
|
||||||
|
/**
|
||||||
|
* 所属部门
|
||||||
|
*/
|
||||||
|
@TableField("SYS_DEPT_CD")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
/**
|
||||||
|
* 创建人名称
|
||||||
|
*/
|
||||||
|
@TableField("OPTR")
|
||||||
|
private String operator;
|
||||||
|
/**
|
||||||
|
* 乐观锁
|
||||||
|
*/
|
||||||
|
@TableField("UPD_CNT")
|
||||||
|
private Integer updateCount;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
@TableField("RMK")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,97 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.dataobject;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BusinessBaseDO;
|
||||||
|
/**
|
||||||
|
* 子样交接记录业务 DO
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@TableName("t_bsn_hnd_rcd_sb")
|
||||||
|
@KeySequence("t_bsn_hnd_rcd_sb_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = true)
|
||||||
|
@ToString(callSuper = true)
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
/**
|
||||||
|
* 支持业务基类继承:isBusiness=true 时继承 BusinessBaseDO,否则继承 BaseDO
|
||||||
|
*/
|
||||||
|
public class BusinessHandoverRecordSubDO extends BusinessBaseDO {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ID
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
/**
|
||||||
|
* 样品子样ID
|
||||||
|
*/
|
||||||
|
@TableField("BSN_SB_SMP_ID")
|
||||||
|
private Long businessSubSampleId;
|
||||||
|
/**
|
||||||
|
* 样品流程ID
|
||||||
|
*/
|
||||||
|
@TableField("SMP_FLW_ID")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
/**
|
||||||
|
* 样品流程KEY
|
||||||
|
*/
|
||||||
|
@TableField("SMP_FLW_KY")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
/**
|
||||||
|
* 样品编号
|
||||||
|
*/
|
||||||
|
@TableField("SMP_CD")
|
||||||
|
private String sampleCode;
|
||||||
|
/**
|
||||||
|
* 样品重量
|
||||||
|
*/
|
||||||
|
@TableField("SMP_WGT")
|
||||||
|
private BigDecimal sampleWeight;
|
||||||
|
/**
|
||||||
|
* 操作时间
|
||||||
|
*/
|
||||||
|
@TableField("OPTN_TM")
|
||||||
|
private LocalDateTime operationTime;
|
||||||
|
/**
|
||||||
|
* 操作人
|
||||||
|
*/
|
||||||
|
@TableField("OPTR")
|
||||||
|
private String operator;
|
||||||
|
/**
|
||||||
|
* 操作人ID
|
||||||
|
*/
|
||||||
|
@TableField("OPTR_ID")
|
||||||
|
private Long operatorId;
|
||||||
|
/**
|
||||||
|
* 送样人
|
||||||
|
*/
|
||||||
|
@TableField("SND_SMP_OPTR")
|
||||||
|
private String sendSampleOperator;
|
||||||
|
/**
|
||||||
|
* 收样人
|
||||||
|
*/
|
||||||
|
@TableField("RCV_SMP_OPTR")
|
||||||
|
private String receiveSampleOperator;
|
||||||
|
/**
|
||||||
|
* 所属部门
|
||||||
|
*/
|
||||||
|
@TableField("SYS_DEPT_CD")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
@TableField("RMK")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,65 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.dataobject;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BusinessBaseDO;
|
||||||
|
/**
|
||||||
|
* 委检登记来样品位 DO
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@TableName("t_bsn_smp_asy_rslt")
|
||||||
|
@KeySequence("t_bsn_smp_asy_rslt_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = true)
|
||||||
|
@ToString(callSuper = true)
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
/**
|
||||||
|
* 支持业务基类继承:isBusiness=true 时继承 BusinessBaseDO,否则继承 BaseDO
|
||||||
|
*/
|
||||||
|
public class BusinessSampleAssayResultDO extends BusinessBaseDO {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ID
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
/**
|
||||||
|
* 委托登记样品明细ID
|
||||||
|
*/
|
||||||
|
@TableField("BSN_SMP_ENTT_DTL_ID")
|
||||||
|
private Long businessSampleEntrustDetailId;
|
||||||
|
/**
|
||||||
|
* 样品主样ID
|
||||||
|
*/
|
||||||
|
@TableField("BSN_BSE_SMP_ID")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
/**
|
||||||
|
* 来样品位
|
||||||
|
*/
|
||||||
|
@TableField("DAT")
|
||||||
|
private String data;
|
||||||
|
/**
|
||||||
|
* 所属部门
|
||||||
|
*/
|
||||||
|
@TableField("SYS_DEPT_CD")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
/**
|
||||||
|
* 乐观锁
|
||||||
|
*/
|
||||||
|
@TableField("UPD_CNT")
|
||||||
|
private Integer updateCount;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
@TableField("RMK")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,110 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.dataobject;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BusinessBaseDO;
|
||||||
|
/**
|
||||||
|
* 委检登记样品明细 DO
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@TableName("t_bsn_smp_entt_dtl")
|
||||||
|
@KeySequence("t_bsn_smp_entt_dtl_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = true)
|
||||||
|
@ToString(callSuper = true)
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
/**
|
||||||
|
* 支持业务基类继承:isBusiness=true 时继承 BusinessBaseDO,否则继承 BaseDO
|
||||||
|
*/
|
||||||
|
public class BusinessSampleEntrustDetailDO extends BusinessBaseDO {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ID
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
/**
|
||||||
|
* 检验委托登记ID
|
||||||
|
*/
|
||||||
|
@TableField("BSN_SMP_ENTT_REG_ID")
|
||||||
|
private Long businessSampleEntrustRegistrationId;
|
||||||
|
/**
|
||||||
|
* 主样业务ID
|
||||||
|
*/
|
||||||
|
@TableField("BSN_BSE_SMP_ID")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
/**
|
||||||
|
* 样品大类ID
|
||||||
|
*/
|
||||||
|
@TableField("BSE_SMP_ID")
|
||||||
|
private Long baseSampleId;
|
||||||
|
/**
|
||||||
|
* 样品类型ID,字典表:【T_DIC_BSN】结算样、委检样、生产样等
|
||||||
|
*/
|
||||||
|
@TableField("DIC_BSN_ID")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
/**
|
||||||
|
* 样品名称
|
||||||
|
*/
|
||||||
|
@TableField("SMP_NAME")
|
||||||
|
private String sampleName;
|
||||||
|
/**
|
||||||
|
* 样品编号
|
||||||
|
*/
|
||||||
|
@TableField("SMP_CD")
|
||||||
|
private String sampleCode;
|
||||||
|
/**
|
||||||
|
* 委托样品名称
|
||||||
|
*/
|
||||||
|
@TableField("ENTT_SMP_NAME")
|
||||||
|
private String entrustSampleName;
|
||||||
|
/**
|
||||||
|
* 委托样品编号
|
||||||
|
*/
|
||||||
|
@TableField("ENTT_SMP_CD")
|
||||||
|
private String entrustSampleCode;
|
||||||
|
/**
|
||||||
|
* 排序
|
||||||
|
*/
|
||||||
|
@TableField("SRT")
|
||||||
|
private Integer sort;
|
||||||
|
/**
|
||||||
|
* 检测项目
|
||||||
|
*/
|
||||||
|
@TableField("ASY_PRJ")
|
||||||
|
private String assayProject;
|
||||||
|
/**
|
||||||
|
* 预报结果
|
||||||
|
*/
|
||||||
|
@TableField("FRCST_RSLT")
|
||||||
|
private String forecastResult;
|
||||||
|
/**
|
||||||
|
* 是否称重,1-启用,0-不启用
|
||||||
|
*/
|
||||||
|
@TableField("IS_WG")
|
||||||
|
private Integer isWeighing;
|
||||||
|
/**
|
||||||
|
* 所属部门
|
||||||
|
*/
|
||||||
|
@TableField("SYS_DEPT_CD")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
/**
|
||||||
|
* 乐观锁
|
||||||
|
*/
|
||||||
|
@TableField("UPD_CNT")
|
||||||
|
private Integer updateCount;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
@TableField("RMK")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.dataobject;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BusinessBaseDO;
|
||||||
|
/**
|
||||||
|
* 委检样品检测项目业务 DO
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@TableName("t_bsn_smp_entt_prj")
|
||||||
|
@KeySequence("t_bsn_smp_entt_prj_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = true)
|
||||||
|
@ToString(callSuper = true)
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
/**
|
||||||
|
* 支持业务基类继承:isBusiness=true 时继承 BusinessBaseDO,否则继承 BaseDO
|
||||||
|
*/
|
||||||
|
public class BusinessSampleEntrustProjectDO extends BusinessBaseDO {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ID
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
/**
|
||||||
|
* 样品检验委托明细ID
|
||||||
|
*/
|
||||||
|
@TableField("BSN_SMP_ENTT_DTL_ID")
|
||||||
|
private Long businessSampleEntrustDetailId;
|
||||||
|
/**
|
||||||
|
* 物料检测标准检测项目ID
|
||||||
|
*/
|
||||||
|
@TableField("MTRL_ASY_STD_DTL_ID")
|
||||||
|
private Long materialAssayStandardDetailId;
|
||||||
|
/**
|
||||||
|
* 检测项目ID,字典表:【T_DIC_PRJ】
|
||||||
|
*/
|
||||||
|
@TableField("DIC_PRJ_ID")
|
||||||
|
private Long dictionaryProjectId;
|
||||||
|
/**
|
||||||
|
* 是否启用,1-启用,0-不启用
|
||||||
|
*/
|
||||||
|
@TableField("IS_ENBD")
|
||||||
|
private Integer isEnabled;
|
||||||
|
/**
|
||||||
|
* 所属部门
|
||||||
|
*/
|
||||||
|
@TableField("SYS_DEPT_CD")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
/**
|
||||||
|
* 乐观锁
|
||||||
|
*/
|
||||||
|
@TableField("UPD_CNT")
|
||||||
|
private Integer updateCount;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
@TableField("RMK")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,224 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.dataobject;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BusinessBaseDO;
|
||||||
|
/**
|
||||||
|
* 委检登记业务 DO
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@TableName("t_bsn_smp_entt_reg")
|
||||||
|
@KeySequence("t_bsn_smp_entt_reg_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = true)
|
||||||
|
@ToString(callSuper = true)
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
/**
|
||||||
|
* 支持业务基类继承:isBusiness=true 时继承 BusinessBaseDO,否则继承 BaseDO
|
||||||
|
*/
|
||||||
|
public class BusinessSampleEntrustRegistrationDO extends BusinessBaseDO {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ID
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
/**
|
||||||
|
* 委托ID
|
||||||
|
*/
|
||||||
|
@TableField("ENTT_ID")
|
||||||
|
private Long entrustId;
|
||||||
|
/**
|
||||||
|
* 委托单号
|
||||||
|
*/
|
||||||
|
@TableField("ENTT_NUM")
|
||||||
|
private String entrustNumber;
|
||||||
|
/**
|
||||||
|
* 委托单位/送样单位
|
||||||
|
*/
|
||||||
|
@TableField("ENTT_UNT")
|
||||||
|
private String entrustUnit;
|
||||||
|
/**
|
||||||
|
* 委托来源,西南铜委托、商检委托、内部委托、抽查委托、内审委托、生产委托
|
||||||
|
*/
|
||||||
|
@TableField("CFG_ENTT_SRC_ID")
|
||||||
|
private Long configEntrustSourceId;
|
||||||
|
/**
|
||||||
|
* 样品数量
|
||||||
|
*/
|
||||||
|
@TableField("SMP_QTY")
|
||||||
|
private Integer sampleQuantity;
|
||||||
|
/**
|
||||||
|
* 任务数量
|
||||||
|
*/
|
||||||
|
@TableField("TSK_QTY")
|
||||||
|
private Integer taskQuantity;
|
||||||
|
/**
|
||||||
|
* 已完成任务数量
|
||||||
|
*/
|
||||||
|
@TableField("TSK_FIND_QTY")
|
||||||
|
private Integer taskFinishedQuantity;
|
||||||
|
/**
|
||||||
|
* 余样要求,【字典】【jy_sample_entrust_remaine_requirement】余样返回、放弃
|
||||||
|
*/
|
||||||
|
@TableField("RMNE_SMP_REQM")
|
||||||
|
private String remaineSampleRequirement;
|
||||||
|
/**
|
||||||
|
* 样品状态,【字典】【jy_sample_entrust_status】块状、粉末、颗粒、液体
|
||||||
|
*/
|
||||||
|
@TableField("SMP_STS")
|
||||||
|
private String sampleStatus;
|
||||||
|
/**
|
||||||
|
* 电话
|
||||||
|
*/
|
||||||
|
@TableField("TEL")
|
||||||
|
private String tel;
|
||||||
|
/**
|
||||||
|
* 传真
|
||||||
|
*/
|
||||||
|
@TableField("FAX")
|
||||||
|
private String fax;
|
||||||
|
/**
|
||||||
|
* 通讯地址
|
||||||
|
*/
|
||||||
|
@TableField("ADR")
|
||||||
|
private String address;
|
||||||
|
/**
|
||||||
|
* 邮编
|
||||||
|
*/
|
||||||
|
@TableField("PSTL")
|
||||||
|
private String postal;
|
||||||
|
/**
|
||||||
|
* E-mail
|
||||||
|
*/
|
||||||
|
@TableField("EM")
|
||||||
|
private String email;
|
||||||
|
/**
|
||||||
|
* 委托检测类别,【字典】【jy_sample_entrust_category】一般委托、仲裁委托
|
||||||
|
*/
|
||||||
|
@TableField("ENTT_CTGR")
|
||||||
|
private String entrustCategory;
|
||||||
|
/**
|
||||||
|
* 样品类别(装港/卸港),【字典】【jy_sample_entrust_category】装港样、卸港样
|
||||||
|
*/
|
||||||
|
@TableField("SMP_CTGR")
|
||||||
|
private String sampleCategory;
|
||||||
|
/**
|
||||||
|
* 样品来源,【字典】【jy_sample_entrust_origin】送样、邮寄、现场取样
|
||||||
|
*/
|
||||||
|
@TableField("SMP_ORGN")
|
||||||
|
private String sampleOrigin;
|
||||||
|
/**
|
||||||
|
* 保密要求,【字典】【jy_sample_entrust_secrecy_requirement】要求对样品和文件保密、无保密要求
|
||||||
|
*/
|
||||||
|
@TableField("SCRY_REQR")
|
||||||
|
private String secrecyRequire;
|
||||||
|
/**
|
||||||
|
* 检测方法,【字典】【jy_sample_entrust_assay_method】国标、行标、客户要求、检测方依据样品选择
|
||||||
|
*/
|
||||||
|
@TableField("ASY_MTHD")
|
||||||
|
private String assayMethod;
|
||||||
|
/**
|
||||||
|
* 送样人
|
||||||
|
*/
|
||||||
|
@TableField("SMP_SNDR")
|
||||||
|
private String sampleSender;
|
||||||
|
/**
|
||||||
|
* 送样日期
|
||||||
|
*/
|
||||||
|
@TableField("SMP_SND_DT")
|
||||||
|
private LocalDateTime sampleSendDate;
|
||||||
|
/**
|
||||||
|
* 收样人
|
||||||
|
*/
|
||||||
|
@TableField("SMP_RCVR")
|
||||||
|
private String sampleReceiver;
|
||||||
|
/**
|
||||||
|
* 收样日期
|
||||||
|
*/
|
||||||
|
@TableField("SMP_RCV_DT")
|
||||||
|
private LocalDateTime sampleReceiveDate;
|
||||||
|
/**
|
||||||
|
* 登记状态,register-登记中、submitted-已提交
|
||||||
|
*/
|
||||||
|
@TableField("REG_STS")
|
||||||
|
private String registrationStatus;
|
||||||
|
/**
|
||||||
|
* 数据校验状态,success-数据校验成功、fail-数据校验失败
|
||||||
|
*/
|
||||||
|
@TableField("DAT_CHK_STS")
|
||||||
|
private String dataCheckStatus;
|
||||||
|
/**
|
||||||
|
* 检验状态,unchecked-未检验;checked-已检验
|
||||||
|
*/
|
||||||
|
@TableField("ASY_STS")
|
||||||
|
private String assayStatus;
|
||||||
|
/**
|
||||||
|
* 数据回报状态,unreturned-未回报;returned-已回报
|
||||||
|
*/
|
||||||
|
@TableField("DAT_STS")
|
||||||
|
private String dataStatus;
|
||||||
|
/**
|
||||||
|
* 报告IDs
|
||||||
|
*/
|
||||||
|
@TableField("DOC_MAIN_ID")
|
||||||
|
private String documentMainId;
|
||||||
|
/**
|
||||||
|
* 报告发送方式,【字典】【jy_sample_entrust_send_way】自取、邮寄、电话、传真、E-mail
|
||||||
|
*/
|
||||||
|
@TableField("DOC_SND_WY")
|
||||||
|
private String documentSendWay;
|
||||||
|
/**
|
||||||
|
* 报告发送人
|
||||||
|
*/
|
||||||
|
@TableField("DOC_PUBR")
|
||||||
|
private String documentPublisher;
|
||||||
|
/**
|
||||||
|
* 报告发送日期
|
||||||
|
*/
|
||||||
|
@TableField("DOC_PUBR_DT")
|
||||||
|
private LocalDateTime documentPublisherDate;
|
||||||
|
/**
|
||||||
|
* 报告接收人
|
||||||
|
*/
|
||||||
|
@TableField("DOC_RCVR")
|
||||||
|
private String documentReceiver;
|
||||||
|
/**
|
||||||
|
* 报告接收日期
|
||||||
|
*/
|
||||||
|
@TableField("DOC_RCV_DT")
|
||||||
|
private LocalDateTime documentReceiveDate;
|
||||||
|
/**
|
||||||
|
* 所属部门
|
||||||
|
*/
|
||||||
|
@TableField("SYS_DEPT_CD")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
/**
|
||||||
|
* 乐观锁
|
||||||
|
*/
|
||||||
|
@TableField("UPD_CNT")
|
||||||
|
private Integer updateCount;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
@TableField("RMK")
|
||||||
|
private String remark;
|
||||||
|
/**
|
||||||
|
* 扩展信息
|
||||||
|
*/
|
||||||
|
@TableField("EXT_INF")
|
||||||
|
private String externalInfomation;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,121 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.dataobject;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BusinessBaseDO;
|
||||||
|
/**
|
||||||
|
* 分样业务 DO
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@TableName("t_bsn_sb_prn_smp")
|
||||||
|
@KeySequence("t_bsn_sb_prn_smp_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = true)
|
||||||
|
@ToString(callSuper = true)
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
/**
|
||||||
|
* 支持业务基类继承:isBusiness=true 时继承 BusinessBaseDO,否则继承 BaseDO
|
||||||
|
*/
|
||||||
|
public class BusinessSubParentSampleDO extends BusinessBaseDO {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ID
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
/**
|
||||||
|
* 样品ID
|
||||||
|
*/
|
||||||
|
@TableField("SMP_ID")
|
||||||
|
private Long sampleId;
|
||||||
|
/**
|
||||||
|
* 样品主样ID
|
||||||
|
*/
|
||||||
|
@TableField("BSN_BSE_SMP_ID")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
/**
|
||||||
|
* 分样配置ID
|
||||||
|
*/
|
||||||
|
@TableField("CFG_SB_SMP_PRN_ID")
|
||||||
|
private Long configSubSampleParentId;
|
||||||
|
/**
|
||||||
|
* 分样类型ID,字典表:【T_DIC_BSN】化学样、试金样、仪器样
|
||||||
|
*/
|
||||||
|
@TableField("DIC_BSN_ID")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
/**
|
||||||
|
* 样品编号
|
||||||
|
*/
|
||||||
|
@TableField("SMP_CD")
|
||||||
|
private String sampleCode;
|
||||||
|
/**
|
||||||
|
* 样品名称
|
||||||
|
*/
|
||||||
|
@TableField("SMP_NAME")
|
||||||
|
private String sampleName;
|
||||||
|
/**
|
||||||
|
* 子样样品编号
|
||||||
|
*/
|
||||||
|
@TableField("SB_SMP_CD")
|
||||||
|
private String subSampleCode;
|
||||||
|
/**
|
||||||
|
* 子样归库码
|
||||||
|
*/
|
||||||
|
@TableField("SB_SMP_RTN_CD")
|
||||||
|
private String subSampleReturnCode;
|
||||||
|
/**
|
||||||
|
* 上报人
|
||||||
|
*/
|
||||||
|
@TableField("RPTR")
|
||||||
|
private String reporter;
|
||||||
|
/**
|
||||||
|
* 上报时间
|
||||||
|
*/
|
||||||
|
@TableField("RPT_TM")
|
||||||
|
private LocalDateTime reportTime;
|
||||||
|
/**
|
||||||
|
* 审核流程code
|
||||||
|
*/
|
||||||
|
@TableField("AUD_FLW_CD")
|
||||||
|
private String auditFlowCode;
|
||||||
|
/**
|
||||||
|
* 超差标注
|
||||||
|
*/
|
||||||
|
@TableField("ASMT_STS")
|
||||||
|
private Integer assessmentStatus;
|
||||||
|
/**
|
||||||
|
* 样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废
|
||||||
|
*/
|
||||||
|
@TableField("SMP_STS")
|
||||||
|
private String sampleStatus;
|
||||||
|
/**
|
||||||
|
* 是否启用,1-启用,0-不启用
|
||||||
|
*/
|
||||||
|
@TableField("IS_ENBD")
|
||||||
|
private Integer isEnabled;
|
||||||
|
/**
|
||||||
|
* 所属部门
|
||||||
|
*/
|
||||||
|
@TableField("SYS_DEPT_CD")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
/**
|
||||||
|
* 乐观锁
|
||||||
|
*/
|
||||||
|
@TableField("UPD_CNT")
|
||||||
|
private Integer updateCount;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
@TableField("RMK")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,200 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.dataobject;
|
||||||
|
|
||||||
|
import lombok.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import com.baomidou.mybatisplus.annotation.*;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.dataobject.BusinessBaseDO;
|
||||||
|
/**
|
||||||
|
* 子样业务 DO
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@TableName("t_bsn_sb_smp")
|
||||||
|
@KeySequence("t_bsn_sb_smp_seq") // 用于 Oracle、PostgreSQL、Kingbase、DB2、H2 数据库的主键自增。如果是 MySQL 等数据库,可不写。
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = true)
|
||||||
|
@ToString(callSuper = true)
|
||||||
|
@Builder
|
||||||
|
@NoArgsConstructor
|
||||||
|
@AllArgsConstructor
|
||||||
|
/**
|
||||||
|
* 支持业务基类继承:isBusiness=true 时继承 BusinessBaseDO,否则继承 BaseDO
|
||||||
|
*/
|
||||||
|
public class BusinessSubSampleDO extends BusinessBaseDO {
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* ID
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
private Long id;
|
||||||
|
/**
|
||||||
|
* 样品主样ID
|
||||||
|
*/
|
||||||
|
@TableField("BSN_BSE_SMP_ID")
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
/**
|
||||||
|
* 样品分样ID
|
||||||
|
*/
|
||||||
|
@TableField("BSN_SB_PRN_SMP_ID")
|
||||||
|
private Long businessSubParentSampleId;
|
||||||
|
/**
|
||||||
|
* 子样配置ID
|
||||||
|
*/
|
||||||
|
@TableField("CFG_SB_SMP_ID")
|
||||||
|
private Long configSubSampleId;
|
||||||
|
/**
|
||||||
|
* 子样类型ID,字典表:【T_DIC_BSN】化学分析样、试金分析样、仪器分析样
|
||||||
|
*/
|
||||||
|
@TableField("DIC_BSN_ID")
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
/**
|
||||||
|
* 库位信息ID
|
||||||
|
*/
|
||||||
|
@TableField("CFG_WRH_LOC_INF_ID")
|
||||||
|
private Long configWarehouseLocationInfomationId;
|
||||||
|
/**
|
||||||
|
* 样品ID
|
||||||
|
*/
|
||||||
|
@TableField("SMP_ID")
|
||||||
|
private Long sampleId;
|
||||||
|
/**
|
||||||
|
* 组ID,如果是委托创建的,则组ID和样品分样ID一致
|
||||||
|
*/
|
||||||
|
@TableField("GRP_ID")
|
||||||
|
private String groupId;
|
||||||
|
/**
|
||||||
|
* 样品名称
|
||||||
|
*/
|
||||||
|
@TableField("SMP_NAME")
|
||||||
|
private String sampleName;
|
||||||
|
/**
|
||||||
|
* 样品编号
|
||||||
|
*/
|
||||||
|
@TableField("SMP_CD")
|
||||||
|
private String sampleCode;
|
||||||
|
/**
|
||||||
|
* 分析编号
|
||||||
|
*/
|
||||||
|
@TableField("SMP_ASY_CD")
|
||||||
|
private String sampleAssayCode;
|
||||||
|
/**
|
||||||
|
* 归库编号
|
||||||
|
*/
|
||||||
|
@TableField("SMP_RTN_CD")
|
||||||
|
private String sampleReturnCode;
|
||||||
|
/**
|
||||||
|
* 样品流程ID
|
||||||
|
*/
|
||||||
|
@TableField("SMP_FLW_ID")
|
||||||
|
private Long sampleFlowId;
|
||||||
|
/**
|
||||||
|
* 样品流程KEY
|
||||||
|
*/
|
||||||
|
@TableField("SMP_FLW_KY")
|
||||||
|
private String sampleFlowKey;
|
||||||
|
/**
|
||||||
|
* 下一步样品流程名称
|
||||||
|
*/
|
||||||
|
@TableField("NXT_SMP_FLW")
|
||||||
|
private String nextSampleFlow;
|
||||||
|
/**
|
||||||
|
* 是否已生成归库码
|
||||||
|
*/
|
||||||
|
@TableField("IS_GEN_RTN_CD")
|
||||||
|
private Integer isGenerateReturnCode;
|
||||||
|
/**
|
||||||
|
* 任务指派给分析人
|
||||||
|
*/
|
||||||
|
@TableField("ASY_OPTR")
|
||||||
|
private String assayOperator;
|
||||||
|
/**
|
||||||
|
* 是否已指派
|
||||||
|
*/
|
||||||
|
@TableField("IS_TSKD")
|
||||||
|
private Integer isTasked;
|
||||||
|
/**
|
||||||
|
* 指派时间
|
||||||
|
*/
|
||||||
|
@TableField("TSK_TM")
|
||||||
|
private LocalDateTime taskTime;
|
||||||
|
/**
|
||||||
|
* 是否已上报
|
||||||
|
*/
|
||||||
|
@TableField("IS_RPOD")
|
||||||
|
private Integer isReported;
|
||||||
|
/**
|
||||||
|
* 上报人
|
||||||
|
*/
|
||||||
|
@TableField("RPTR")
|
||||||
|
private String reporter;
|
||||||
|
/**
|
||||||
|
* 上报时间
|
||||||
|
*/
|
||||||
|
@TableField("RPT_TM")
|
||||||
|
private LocalDateTime reportTime;
|
||||||
|
/**
|
||||||
|
* 归库时间
|
||||||
|
*/
|
||||||
|
@TableField("RTN_TM")
|
||||||
|
private LocalDateTime returnTime;
|
||||||
|
/**
|
||||||
|
* 归库状态,【字典】【jy_sample_return_status】待归库、已归库、已调拨、已下架、待销毁、已销毁
|
||||||
|
*/
|
||||||
|
@TableField("RTN_STS")
|
||||||
|
private Integer returnStatus;
|
||||||
|
/**
|
||||||
|
* 打印次数
|
||||||
|
*/
|
||||||
|
@TableField("RTN_CD_PRNT_CNT")
|
||||||
|
private Integer returnCodePrintCount;
|
||||||
|
/**
|
||||||
|
* 末次打印时间
|
||||||
|
*/
|
||||||
|
@TableField("PRNT_LST_TM")
|
||||||
|
private LocalDateTime printLastTime;
|
||||||
|
/**
|
||||||
|
* 样品流程节点时间
|
||||||
|
*/
|
||||||
|
@TableField("SMP_FLW_TM")
|
||||||
|
private LocalDateTime sampleFlowTime;
|
||||||
|
/**
|
||||||
|
* 样品状态,【字典】【jy_sample_status】normal-正常、isolation-隔离、void-作废
|
||||||
|
*/
|
||||||
|
@TableField("SMP_STS")
|
||||||
|
private String sampleStatus;
|
||||||
|
/**
|
||||||
|
* 是否启用,1-启用,0-不启用
|
||||||
|
*/
|
||||||
|
@TableField("IS_ENBD")
|
||||||
|
private Integer isEnabled;
|
||||||
|
/**
|
||||||
|
* 分析元素备注
|
||||||
|
*/
|
||||||
|
@TableField("ANL_RMK")
|
||||||
|
private String analysisRemark;
|
||||||
|
/**
|
||||||
|
* 所属部门
|
||||||
|
*/
|
||||||
|
@TableField("SYS_DEPT_CD")
|
||||||
|
private String systemDepartmentCode;
|
||||||
|
/**
|
||||||
|
* 乐观锁
|
||||||
|
*/
|
||||||
|
@TableField("UPD_CNT")
|
||||||
|
private Integer updateCount;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
@TableField("RMK")
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.mapper;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessBaseSamplePageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessBaseSampleDO;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 主样业务 Mapper
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface BusinessBaseSampleMapper extends BaseMapperX<BusinessBaseSampleDO> {
|
||||||
|
|
||||||
|
default PageResult<BusinessBaseSampleDO> selectPage(BusinessBaseSamplePageReqVO reqVO) {
|
||||||
|
return selectPage(reqVO, new LambdaQueryWrapperX<BusinessBaseSampleDO>()
|
||||||
|
.likeIfPresent(BusinessBaseSampleDO::getSampleName, reqVO.getSampleName())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getSampleCode, reqVO.getSampleCode())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getConfigBaseSampleId, reqVO.getConfigBaseSampleId())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getDictionaryBusinessId, reqVO.getDictionaryBusinessId())
|
||||||
|
.betweenIfPresent(BusinessBaseSampleDO::getSampleTime, reqVO.getSampleTime())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getPrintCount, reqVO.getPrintCount())
|
||||||
|
.betweenIfPresent(BusinessBaseSampleDO::getPrintLastTime, reqVO.getPrintLastTime())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getSampleFlowId, reqVO.getSampleFlowId())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getSampleFlowKey, reqVO.getSampleFlowKey())
|
||||||
|
.betweenIfPresent(BusinessBaseSampleDO::getSampleFlowTime, reqVO.getSampleFlowTime())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getSampleStatus, reqVO.getSampleStatus())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getOperator, reqVO.getOperator())
|
||||||
|
.betweenIfPresent(BusinessBaseSampleDO::getCreateTime, reqVO.getCreateTime())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getUpdateCount, reqVO.getUpdateCount())
|
||||||
|
.eqIfPresent(BusinessBaseSampleDO::getRemark, reqVO.getRemark())
|
||||||
|
.orderByDesc(BusinessBaseSampleDO::getId));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,38 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.mapper;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessHandoverRecordSubPageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessHandoverRecordSubDO;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 子样交接记录业务 Mapper
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface BusinessHandoverRecordSubMapper extends BaseMapperX<BusinessHandoverRecordSubDO> {
|
||||||
|
|
||||||
|
default PageResult<BusinessHandoverRecordSubDO> selectPage(BusinessHandoverRecordSubPageReqVO reqVO) {
|
||||||
|
return selectPage(reqVO, new LambdaQueryWrapperX<BusinessHandoverRecordSubDO>()
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getBusinessSubSampleId, reqVO.getBusinessSubSampleId())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getSampleFlowId, reqVO.getSampleFlowId())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getSampleFlowKey, reqVO.getSampleFlowKey())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getSampleCode, reqVO.getSampleCode())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getSampleWeight, reqVO.getSampleWeight())
|
||||||
|
.betweenIfPresent(BusinessHandoverRecordSubDO::getOperationTime, reqVO.getOperationTime())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getOperator, reqVO.getOperator())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getOperatorId, reqVO.getOperatorId())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getSendSampleOperator, reqVO.getSendSampleOperator())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getReceiveSampleOperator, reqVO.getReceiveSampleOperator())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
|
||||||
|
.betweenIfPresent(BusinessHandoverRecordSubDO::getCreateTime, reqVO.getCreateTime())
|
||||||
|
.eqIfPresent(BusinessHandoverRecordSubDO::getRemark, reqVO.getRemark())
|
||||||
|
.orderByDesc(BusinessHandoverRecordSubDO::getId));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.mapper;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleAssayResultPageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleAssayResultDO;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检登记来样品位 Mapper
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface BusinessSampleAssayResultMapper extends BaseMapperX<BusinessSampleAssayResultDO> {
|
||||||
|
|
||||||
|
default PageResult<BusinessSampleAssayResultDO> selectPage(BusinessSampleAssayResultPageReqVO reqVO) {
|
||||||
|
return selectPage(reqVO, new LambdaQueryWrapperX<BusinessSampleAssayResultDO>()
|
||||||
|
.eqIfPresent(BusinessSampleAssayResultDO::getBusinessSampleEntrustDetailId, reqVO.getBusinessSampleEntrustDetailId())
|
||||||
|
.eqIfPresent(BusinessSampleAssayResultDO::getBusinessBaseSampleId, reqVO.getBusinessBaseSampleId())
|
||||||
|
.eqIfPresent(BusinessSampleAssayResultDO::getData, reqVO.getData())
|
||||||
|
.eqIfPresent(BusinessSampleAssayResultDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
|
||||||
|
.betweenIfPresent(BusinessSampleAssayResultDO::getCreateTime, reqVO.getCreateTime())
|
||||||
|
.eqIfPresent(BusinessSampleAssayResultDO::getUpdateCount, reqVO.getUpdateCount())
|
||||||
|
.eqIfPresent(BusinessSampleAssayResultDO::getRemark, reqVO.getRemark())
|
||||||
|
.orderByDesc(BusinessSampleAssayResultDO::getId));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,41 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.mapper;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustDetailDO;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检登记样品明细 Mapper
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface BusinessSampleEntrustDetailMapper extends BaseMapperX<BusinessSampleEntrustDetailDO> {
|
||||||
|
|
||||||
|
default PageResult<BusinessSampleEntrustDetailDO> selectPage(BusinessSampleEntrustDetailPageReqVO reqVO) {
|
||||||
|
return selectPage(reqVO, new LambdaQueryWrapperX<BusinessSampleEntrustDetailDO>()
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getBusinessSampleEntrustRegistrationId, reqVO.getBusinessSampleEntrustRegistrationId())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getBusinessBaseSampleId, reqVO.getBusinessBaseSampleId())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getBaseSampleId, reqVO.getBaseSampleId())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getDictionaryBusinessId, reqVO.getDictionaryBusinessId())
|
||||||
|
.likeIfPresent(BusinessSampleEntrustDetailDO::getSampleName, reqVO.getSampleName())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getSampleCode, reqVO.getSampleCode())
|
||||||
|
.likeIfPresent(BusinessSampleEntrustDetailDO::getEntrustSampleName, reqVO.getEntrustSampleName())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getEntrustSampleCode, reqVO.getEntrustSampleCode())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getSort, reqVO.getSort())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getAssayProject, reqVO.getAssayProject())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getForecastResult, reqVO.getForecastResult())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getIsWeighing, reqVO.getIsWeighing())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
|
||||||
|
.betweenIfPresent(BusinessSampleEntrustDetailDO::getCreateTime, reqVO.getCreateTime())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getUpdateCount, reqVO.getUpdateCount())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustDetailDO::getRemark, reqVO.getRemark())
|
||||||
|
.orderByDesc(BusinessSampleEntrustDetailDO::getId));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,33 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.mapper;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustProjectPageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustProjectDO;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检样品检测项目业务 Mapper
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface BusinessSampleEntrustProjectMapper extends BaseMapperX<BusinessSampleEntrustProjectDO> {
|
||||||
|
|
||||||
|
default PageResult<BusinessSampleEntrustProjectDO> selectPage(BusinessSampleEntrustProjectPageReqVO reqVO) {
|
||||||
|
return selectPage(reqVO, new LambdaQueryWrapperX<BusinessSampleEntrustProjectDO>()
|
||||||
|
.eqIfPresent(BusinessSampleEntrustProjectDO::getBusinessSampleEntrustDetailId, reqVO.getBusinessSampleEntrustDetailId())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustProjectDO::getMaterialAssayStandardDetailId, reqVO.getMaterialAssayStandardDetailId())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustProjectDO::getDictionaryProjectId, reqVO.getDictionaryProjectId())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustProjectDO::getIsEnabled, reqVO.getIsEnabled())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustProjectDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
|
||||||
|
.betweenIfPresent(BusinessSampleEntrustProjectDO::getCreateTime, reqVO.getCreateTime())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustProjectDO::getUpdateCount, reqVO.getUpdateCount())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustProjectDO::getRemark, reqVO.getRemark())
|
||||||
|
.orderByDesc(BusinessSampleEntrustProjectDO::getId));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,62 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.mapper;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustRegistrationPageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检登记业务 Mapper
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface BusinessSampleEntrustRegistrationMapper extends BaseMapperX<BusinessSampleEntrustRegistrationDO> {
|
||||||
|
|
||||||
|
default PageResult<BusinessSampleEntrustRegistrationDO> selectPage(BusinessSampleEntrustRegistrationPageReqVO reqVO) {
|
||||||
|
return selectPage(reqVO, new LambdaQueryWrapperX<BusinessSampleEntrustRegistrationDO>()
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getEntrustId, reqVO.getEntrustId())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getEntrustNumber, reqVO.getEntrustNumber())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getEntrustUnit, reqVO.getEntrustUnit())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getConfigEntrustSourceId, reqVO.getConfigEntrustSourceId())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getSampleQuantity, reqVO.getSampleQuantity())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getTaskQuantity, reqVO.getTaskQuantity())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getTaskFinishedQuantity, reqVO.getTaskFinishedQuantity())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getRemaineSampleRequirement, reqVO.getRemaineSampleRequirement())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getSampleStatus, reqVO.getSampleStatus())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getTel, reqVO.getTel())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getFax, reqVO.getFax())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getAddress, reqVO.getAddress())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getPostal, reqVO.getPostal())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getEmail, reqVO.getEmail())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getEntrustCategory, reqVO.getEntrustCategory())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getSampleCategory, reqVO.getSampleCategory())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getSampleOrigin, reqVO.getSampleOrigin())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getSecrecyRequire, reqVO.getSecrecyRequire())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getAssayMethod, reqVO.getAssayMethod())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getSampleSender, reqVO.getSampleSender())
|
||||||
|
.betweenIfPresent(BusinessSampleEntrustRegistrationDO::getSampleSendDate, reqVO.getSampleSendDate())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getSampleReceiver, reqVO.getSampleReceiver())
|
||||||
|
.betweenIfPresent(BusinessSampleEntrustRegistrationDO::getSampleReceiveDate, reqVO.getSampleReceiveDate())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getRegistrationStatus, reqVO.getRegistrationStatus())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getDataCheckStatus, reqVO.getDataCheckStatus())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getAssayStatus, reqVO.getAssayStatus())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getDataStatus, reqVO.getDataStatus())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getDocumentMainId, reqVO.getDocumentMainId())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getDocumentSendWay, reqVO.getDocumentSendWay())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getDocumentPublisher, reqVO.getDocumentPublisher())
|
||||||
|
.betweenIfPresent(BusinessSampleEntrustRegistrationDO::getDocumentPublisherDate, reqVO.getDocumentPublisherDate())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getDocumentReceiver, reqVO.getDocumentReceiver())
|
||||||
|
.betweenIfPresent(BusinessSampleEntrustRegistrationDO::getDocumentReceiveDate, reqVO.getDocumentReceiveDate())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
|
||||||
|
.betweenIfPresent(BusinessSampleEntrustRegistrationDO::getCreateTime, reqVO.getCreateTime())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getUpdateCount, reqVO.getUpdateCount())
|
||||||
|
.eqIfPresent(BusinessSampleEntrustRegistrationDO::getRemark, reqVO.getRemark())
|
||||||
|
.orderByDesc(BusinessSampleEntrustRegistrationDO::getId));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,43 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.mapper;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubParentSamplePageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubParentSampleDO;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分样业务 Mapper
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface BusinessSubParentSampleMapper extends BaseMapperX<BusinessSubParentSampleDO> {
|
||||||
|
|
||||||
|
default PageResult<BusinessSubParentSampleDO> selectPage(BusinessSubParentSamplePageReqVO reqVO) {
|
||||||
|
return selectPage(reqVO, new LambdaQueryWrapperX<BusinessSubParentSampleDO>()
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getSampleId, reqVO.getSampleId())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getBusinessBaseSampleId, reqVO.getBusinessBaseSampleId())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getConfigSubSampleParentId, reqVO.getConfigSubSampleParentId())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getDictionaryBusinessId, reqVO.getDictionaryBusinessId())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getSampleCode, reqVO.getSampleCode())
|
||||||
|
.likeIfPresent(BusinessSubParentSampleDO::getSampleName, reqVO.getSampleName())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getSubSampleCode, reqVO.getSubSampleCode())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getSubSampleReturnCode, reqVO.getSubSampleReturnCode())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getReporter, reqVO.getReporter())
|
||||||
|
.betweenIfPresent(BusinessSubParentSampleDO::getReportTime, reqVO.getReportTime())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getAuditFlowCode, reqVO.getAuditFlowCode())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getAssessmentStatus, reqVO.getAssessmentStatus())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getSampleStatus, reqVO.getSampleStatus())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getIsEnabled, reqVO.getIsEnabled())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
|
||||||
|
.betweenIfPresent(BusinessSubParentSampleDO::getCreateTime, reqVO.getCreateTime())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getUpdateCount, reqVO.getUpdateCount())
|
||||||
|
.eqIfPresent(BusinessSubParentSampleDO::getRemark, reqVO.getRemark())
|
||||||
|
.orderByDesc(BusinessSubParentSampleDO::getId));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,58 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.dal.mapper;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSamplePageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubSampleDO;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.mapper.BaseMapperX;
|
||||||
|
import org.apache.ibatis.annotations.Mapper;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 子样业务 Mapper
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Mapper
|
||||||
|
public interface BusinessSubSampleMapper extends BaseMapperX<BusinessSubSampleDO> {
|
||||||
|
|
||||||
|
default PageResult<BusinessSubSampleDO> selectPage(BusinessSubSamplePageReqVO reqVO) {
|
||||||
|
return selectPage(reqVO, new LambdaQueryWrapperX<BusinessSubSampleDO>()
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getBusinessBaseSampleId, reqVO.getBusinessBaseSampleId())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getBusinessSubParentSampleId, reqVO.getBusinessSubParentSampleId())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getConfigSubSampleId, reqVO.getConfigSubSampleId())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getDictionaryBusinessId, reqVO.getDictionaryBusinessId())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getConfigWarehouseLocationInfomationId, reqVO.getConfigWarehouseLocationInfomationId())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getSampleId, reqVO.getSampleId())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getGroupId, reqVO.getGroupId())
|
||||||
|
.likeIfPresent(BusinessSubSampleDO::getSampleName, reqVO.getSampleName())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getSampleCode, reqVO.getSampleCode())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getSampleAssayCode, reqVO.getSampleAssayCode())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getSampleReturnCode, reqVO.getSampleReturnCode())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getSampleFlowId, reqVO.getSampleFlowId())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getSampleFlowKey, reqVO.getSampleFlowKey())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getNextSampleFlow, reqVO.getNextSampleFlow())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getIsGenerateReturnCode, reqVO.getIsGenerateReturnCode())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getAssayOperator, reqVO.getAssayOperator())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getIsTasked, reqVO.getIsTasked())
|
||||||
|
.betweenIfPresent(BusinessSubSampleDO::getTaskTime, reqVO.getTaskTime())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getIsReported, reqVO.getIsReported())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getReporter, reqVO.getReporter())
|
||||||
|
.betweenIfPresent(BusinessSubSampleDO::getReportTime, reqVO.getReportTime())
|
||||||
|
.betweenIfPresent(BusinessSubSampleDO::getReturnTime, reqVO.getReturnTime())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getReturnStatus, reqVO.getReturnStatus())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getReturnCodePrintCount, reqVO.getReturnCodePrintCount())
|
||||||
|
.betweenIfPresent(BusinessSubSampleDO::getPrintLastTime, reqVO.getPrintLastTime())
|
||||||
|
.betweenIfPresent(BusinessSubSampleDO::getSampleFlowTime, reqVO.getSampleFlowTime())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getSampleStatus, reqVO.getSampleStatus())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getIsEnabled, reqVO.getIsEnabled())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getAnalysisRemark, reqVO.getAnalysisRemark())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getSystemDepartmentCode, reqVO.getSystemDepartmentCode())
|
||||||
|
.betweenIfPresent(BusinessSubSampleDO::getCreateTime, reqVO.getCreateTime())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getUpdateCount, reqVO.getUpdateCount())
|
||||||
|
.eqIfPresent(BusinessSubSampleDO::getRemark, reqVO.getRemark())
|
||||||
|
.orderByDesc(BusinessSubSampleDO::getId));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.param;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustDetail</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@Accessors(chain = true)
|
||||||
|
public class SampleEntrustDetail {
|
||||||
|
|
||||||
|
/** ID **/
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 委托登记id **/
|
||||||
|
private Long businessSampleEntrustRegistrationId;
|
||||||
|
|
||||||
|
/** 样品大类id **/
|
||||||
|
private Long baseSampleId;
|
||||||
|
|
||||||
|
/** 主样业务ID **/
|
||||||
|
private Long businessBaseSampleId;
|
||||||
|
|
||||||
|
/** 样品类型ID 字典表:【T_DIC_BSN】结算样、委检样、生产样等 **/
|
||||||
|
private Long dictionaryBusinessId;
|
||||||
|
|
||||||
|
/** 样品名称 **/
|
||||||
|
private String sampleName;
|
||||||
|
|
||||||
|
/** 样品编号 **/
|
||||||
|
private String sampleCode;
|
||||||
|
|
||||||
|
/** 委托样品名称 **/
|
||||||
|
private String entrustSampleName;
|
||||||
|
|
||||||
|
/** 委托样品编号 **/
|
||||||
|
private String entrustSampleCode;
|
||||||
|
|
||||||
|
/** 排序号 **/
|
||||||
|
private Integer sort;
|
||||||
|
|
||||||
|
/** 检测项目 **/
|
||||||
|
private String assayProject;
|
||||||
|
|
||||||
|
/** 预报结果 **/
|
||||||
|
private String forecastResult;
|
||||||
|
|
||||||
|
/** 是否称重 **/
|
||||||
|
private Integer isWeighing;
|
||||||
|
|
||||||
|
/** 备注 **/
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
/** 检测项目 **/
|
||||||
|
private List<SampleEntrustDetailProject> sampleEntrustDetailProjectList;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,36 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.param;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustDetailProject</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@Accessors(chain = true)
|
||||||
|
public class SampleEntrustDetailProject {
|
||||||
|
|
||||||
|
/** ID **/
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 样品检验委托明细ID **/
|
||||||
|
private Long businessSampleEntrustDetailId;
|
||||||
|
|
||||||
|
/** 物料检测标准检测项目ID **/
|
||||||
|
private Long materialAssayStandardDetailId;
|
||||||
|
|
||||||
|
/** 检测项目ID **/
|
||||||
|
private Long dictionaryProjectId;
|
||||||
|
|
||||||
|
/** 是否启用 **/
|
||||||
|
private Integer isEnabled;
|
||||||
|
}
|
||||||
@@ -0,0 +1,61 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.param;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustParam</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@Accessors(chain = true)
|
||||||
|
public class SampleEntrustParam {
|
||||||
|
|
||||||
|
/** 委托登记id **/
|
||||||
|
private Long id;
|
||||||
|
|
||||||
|
/** 委托id **/
|
||||||
|
private Long entrustId;
|
||||||
|
|
||||||
|
/** 委托单号 **/
|
||||||
|
private String entrustNumber;
|
||||||
|
|
||||||
|
/** 委托单位 **/
|
||||||
|
private String entrustUnit;
|
||||||
|
|
||||||
|
/** 委托来源 **/
|
||||||
|
private Long configEntrustSourceId;
|
||||||
|
|
||||||
|
/** 样品数量 **/
|
||||||
|
private Integer sampleQuantity;
|
||||||
|
|
||||||
|
/** 余样要求 **/
|
||||||
|
private String remaineSampleRequirement;
|
||||||
|
|
||||||
|
/** 送样人 **/
|
||||||
|
private String sampleSender;
|
||||||
|
|
||||||
|
/** 送样日期 **/
|
||||||
|
private LocalDateTime sampleSendDate;
|
||||||
|
|
||||||
|
/** 备注 **/
|
||||||
|
private String remark;
|
||||||
|
|
||||||
|
/** 扩展信息 **/
|
||||||
|
private String extInfo;
|
||||||
|
|
||||||
|
private List<SampleEntrustDetail> sampleEntrustDetailList;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,46 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.param;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.Date;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleFlowParam</b>
|
||||||
|
* 样品流转参数
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月6日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月6日
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@Accessors(chain = true)
|
||||||
|
public class SampleFlowParam {
|
||||||
|
|
||||||
|
/** 样品来源 1:主,2:子 **/
|
||||||
|
private Integer sampleSourceType;
|
||||||
|
|
||||||
|
/** 样品当前流程节点 **/
|
||||||
|
private String sampleProcessNo;
|
||||||
|
|
||||||
|
/** 样品id列表 **/
|
||||||
|
private List<Long> sampleIdList;
|
||||||
|
|
||||||
|
/** 指定时间 **/
|
||||||
|
private LocalDateTime specifyDateTime;
|
||||||
|
|
||||||
|
/** 送样人 **/
|
||||||
|
private String sendSampleOper;
|
||||||
|
|
||||||
|
/** 收样人 **/
|
||||||
|
private String receiveSampleOper;
|
||||||
|
}
|
||||||
@@ -0,0 +1,44 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.entrust;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.exception.ServiceException;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleEntrustContext;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.ConfigEntrustSourceDO;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustCheckCmp</b>
|
||||||
|
* 样品委托检查
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleEntrustCheckCmp", name = "样品委托检查")
|
||||||
|
public class SampleEntrustCheckCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
//获取样品委托上下文
|
||||||
|
SampleEntrustContext sampleEntrustContext = this.getContextBean(SampleEntrustContext.class);
|
||||||
|
//获取样品委托单
|
||||||
|
BusinessSampleEntrustRegistrationDO sampleEntrustRegistration = sampleEntrustContext.getSampleEntrustRegistration();
|
||||||
|
if (sampleEntrustRegistration.getConfigEntrustSourceId() == null) {
|
||||||
|
throw new ServiceException(500, "委托来源id不允许为空");
|
||||||
|
}
|
||||||
|
ConfigEntrustSourceDO configEntrustSource = sampleEntrustContext.getConfigEntrustSourceById(sampleEntrustRegistration.getConfigEntrustSourceId());
|
||||||
|
if (configEntrustSource == null) {
|
||||||
|
throw new ServiceException(500, "委托来源id不正确");
|
||||||
|
}
|
||||||
|
sampleEntrustRegistration.setDataCheckStatus("success");
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,127 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.entrust;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.IdWorker;
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
import cn.hutool.core.bean.BeanUtil;
|
||||||
|
import cn.iocoder.yudao.framework.common.exception.ServiceException;
|
||||||
|
import cn.iocoder.yudao.framework.security.core.LoginUser;
|
||||||
|
import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils;
|
||||||
|
import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustProjectDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleEntrustDetail;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleEntrustDetailProject;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleEntrustParam;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleEntrustContext;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.ConfigEntrustSourceDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.MaterialAssayStandardDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.MaterialAssayStandardDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.MaterialAssayStandardMethodDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.mapper.ConfigEntrustSourceMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.mapper.MaterialAssayStandardDetailMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.mapper.MaterialAssayStandardMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.mapper.MaterialAssayStandardMethodMapper;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustContextInitCmp</b>
|
||||||
|
* 样品委托上下文初始化
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleEntrustContextInitCmp", name = "样品委托上下文初始化")
|
||||||
|
public class SampleEntrustContextInitCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private ConfigEntrustSourceMapper configEntrustSourceMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private MaterialAssayStandardMapper materialAssayStandardMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private MaterialAssayStandardDetailMapper materialAssayStandardDetailMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private MaterialAssayStandardMethodMapper materialAssayStandardMethodMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
//租户id
|
||||||
|
Long tenantId = TenantContextHolder.getRequiredTenantId();
|
||||||
|
|
||||||
|
//当前登录用户
|
||||||
|
LoginUser loginUser = SecurityFrameworkUtils.getLoginUser();
|
||||||
|
|
||||||
|
//当前登录用户昵称
|
||||||
|
String nickName = SecurityFrameworkUtils.getLoginUserNickname();
|
||||||
|
|
||||||
|
//获取样品委托参数
|
||||||
|
SampleEntrustParam sampleEntrustParam = this.getRequestData();
|
||||||
|
|
||||||
|
if (sampleEntrustParam == null) {
|
||||||
|
throw new ServiceException(500, "样品委托参数不允许为空");
|
||||||
|
}
|
||||||
|
|
||||||
|
//获取样品委托上下文
|
||||||
|
SampleEntrustContext sampleEntrustContext = this.getContextBean(SampleEntrustContext.class);
|
||||||
|
sampleEntrustContext.setTenantId(tenantId);
|
||||||
|
sampleEntrustContext.setLoginUser(loginUser);
|
||||||
|
sampleEntrustContext.setLoginRealname(nickName);
|
||||||
|
|
||||||
|
//委托来源配置
|
||||||
|
List<ConfigEntrustSourceDO> configEntrustSourceList = configEntrustSourceMapper.selectList();
|
||||||
|
sampleEntrustContext.setConfigEntrustSourceList(configEntrustSourceList);
|
||||||
|
|
||||||
|
//物料检验标准
|
||||||
|
List<MaterialAssayStandardDO> materialAssayStandardList = materialAssayStandardMapper.selectList();
|
||||||
|
sampleEntrustContext.setMaterialAssayStandardList(materialAssayStandardList);
|
||||||
|
|
||||||
|
//物料检验标准项
|
||||||
|
List<MaterialAssayStandardDetailDO> materialAssayStandardDetailList = materialAssayStandardDetailMapper.selectList();
|
||||||
|
sampleEntrustContext.setMaterialAssayStandardDetailList(materialAssayStandardDetailList);
|
||||||
|
|
||||||
|
//物料检验标准方法
|
||||||
|
List<MaterialAssayStandardMethodDO> materialAssayStandardMethodList = materialAssayStandardMethodMapper.selectList();
|
||||||
|
sampleEntrustContext.setMaterialAssayStandardMethodList(materialAssayStandardMethodList);
|
||||||
|
|
||||||
|
//委托登记
|
||||||
|
BusinessSampleEntrustRegistrationDO sampleEntrustRegistration = BeanUtil.copyProperties(sampleEntrustParam, BusinessSampleEntrustRegistrationDO.class);
|
||||||
|
sampleEntrustContext.setSampleEntrustRegistration(sampleEntrustRegistration);
|
||||||
|
|
||||||
|
List<SampleEntrustDetail> detailList = sampleEntrustParam.getSampleEntrustDetailList();
|
||||||
|
|
||||||
|
//委托登记样品明细的检测项目明细
|
||||||
|
List<BusinessSampleEntrustProjectDO> sampleEntrustProjectList = new ArrayList<>();
|
||||||
|
for (SampleEntrustDetail sampleEntrustDetail : detailList) {
|
||||||
|
if (sampleEntrustDetail.getId() == null) {
|
||||||
|
sampleEntrustDetail.setId(IdWorker.getId());
|
||||||
|
}
|
||||||
|
List<SampleEntrustDetailProject> projectList = sampleEntrustDetail.getSampleEntrustDetailProjectList();
|
||||||
|
for (SampleEntrustDetailProject sampleEntrustDetailProject : projectList) {
|
||||||
|
if (sampleEntrustDetailProject.getBusinessSampleEntrustDetailId() == null) {
|
||||||
|
sampleEntrustDetailProject.setBusinessSampleEntrustDetailId(sampleEntrustDetail.getId());
|
||||||
|
}
|
||||||
|
}
|
||||||
|
sampleEntrustProjectList.addAll(BeanUtil.copyToList(projectList, BusinessSampleEntrustProjectDO.class));
|
||||||
|
}
|
||||||
|
sampleEntrustContext.setSampleEntrustProjectList(sampleEntrustProjectList);
|
||||||
|
|
||||||
|
//委托登记样品明细
|
||||||
|
List<BusinessSampleEntrustDetailDO> sampleEntrustDetailList = BeanUtil.copyToList(detailList, BusinessSampleEntrustDetailDO.class);
|
||||||
|
sampleEntrustContext.setSampleEntrustDetailList(sampleEntrustDetailList);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,112 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.entrust;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.toolkit.IdWorker;
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleAssayResultDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustProjectDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleAssayResultMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustDetailMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustProjectMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustRegistrationMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleEntrustContext;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.ConfigEntrustSourceDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.MaterialAssayStandardDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.core.code.SequenceUtil;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustCreateDataCmp</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleEntrustCreateDataCmp", name = "样品委托创建委托数据" )
|
||||||
|
public class SampleEntrustCreateDataCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private SequenceUtil sequenceUtil;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustRegistrationMapper businessSampleEntrustRegistrationMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustDetailMapper businessSampleEntrustDetailMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustProjectMapper businessSampleEntrustProjectMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleAssayResultMapper businessSampleAssayResultMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
//获取样品委托上下文
|
||||||
|
SampleEntrustContext sampleEntrustContext = this.getContextBean(SampleEntrustContext.class);
|
||||||
|
//样品委托
|
||||||
|
BusinessSampleEntrustRegistrationDO sampleEntrustRegistration = sampleEntrustContext.getSampleEntrustRegistration();
|
||||||
|
|
||||||
|
//获取委托来源配置
|
||||||
|
ConfigEntrustSourceDO configEntrustSource = sampleEntrustContext.getConfigEntrustSourceById(sampleEntrustRegistration.getConfigEntrustSourceId());
|
||||||
|
String codeRule = configEntrustSource.getCodeRule();
|
||||||
|
|
||||||
|
//赋值id
|
||||||
|
sampleEntrustRegistration.setId(IdWorker.getId());
|
||||||
|
//设置委托单号
|
||||||
|
sampleEntrustRegistration.setEntrustNumber(sequenceUtil.genCode(codeRule));
|
||||||
|
|
||||||
|
List<BusinessSampleAssayResultDO> sampleAssayResultList = new ArrayList<>();
|
||||||
|
|
||||||
|
|
||||||
|
List<BusinessSampleEntrustDetailDO> sampleEntrustDetailList = sampleEntrustContext.getSampleEntrustDetailList();
|
||||||
|
for (BusinessSampleEntrustDetailDO businessSampleEntrustDetail : sampleEntrustDetailList) {
|
||||||
|
businessSampleEntrustDetail.setBusinessSampleEntrustRegistrationId(sampleEntrustRegistration.getId());
|
||||||
|
|
||||||
|
if (StringUtils.isNotBlank(businessSampleEntrustDetail.getForecastResult())) {
|
||||||
|
BusinessSampleAssayResultDO sampleAssayResult = new BusinessSampleAssayResultDO();
|
||||||
|
sampleAssayResult.setBusinessSampleEntrustDetailId(businessSampleEntrustDetail.getId());
|
||||||
|
sampleAssayResult.setData(businessSampleEntrustDetail.getForecastResult());
|
||||||
|
sampleAssayResultList.add(sampleAssayResult);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
List<BusinessSampleEntrustProjectDO> sampleEntrustProjectList = sampleEntrustContext.getSampleEntrustProjectList();
|
||||||
|
for (BusinessSampleEntrustProjectDO businessSampleEntrustProject : sampleEntrustProjectList) {
|
||||||
|
MaterialAssayStandardDetailDO materialAssayStandardDetail = sampleEntrustContext.getMaterialAssayStandardDetailById(businessSampleEntrustProject.getMaterialAssayStandardDetailId());
|
||||||
|
businessSampleEntrustProject.setDictionaryProjectId(materialAssayStandardDetail.getDictionaryProjectId());
|
||||||
|
}
|
||||||
|
|
||||||
|
//保存样品委托登记
|
||||||
|
businessSampleEntrustRegistrationMapper.insert(sampleEntrustRegistration);
|
||||||
|
|
||||||
|
//保存样品明细
|
||||||
|
if (sampleEntrustDetailList != null && sampleEntrustDetailList.size() > 0) {
|
||||||
|
businessSampleEntrustDetailMapper.insertBatch(sampleEntrustDetailList);
|
||||||
|
}
|
||||||
|
|
||||||
|
//保存检测项目
|
||||||
|
if (sampleEntrustProjectList != null && sampleEntrustProjectList.size() > 0) {
|
||||||
|
businessSampleEntrustProjectMapper.insertBatch(sampleEntrustProjectList);
|
||||||
|
}
|
||||||
|
|
||||||
|
//保存来样元素
|
||||||
|
if (sampleAssayResultList.size() > 0) {
|
||||||
|
businessSampleAssayResultMapper.insertBatch(sampleAssayResultList);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,27 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.entrust;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustGenSampleDataCmp</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleEntrustGenSampleDataCmp", name = "样品委托生成系统样品数据")
|
||||||
|
public class SampleEntrustGenSampleDataCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,34 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.entrust;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeBooleanComponent;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleEntrustContext;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustIsCreateCmp</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月10日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月10日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleEntrustIsCreateCmp", name = "委托登记是否为创建")
|
||||||
|
public class SampleEntrustIsCreateCmp extends NodeBooleanComponent {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean processBoolean() throws Exception {
|
||||||
|
//获取样品委托上下文
|
||||||
|
SampleEntrustContext sampleEntrustContext = this.getContextBean(SampleEntrustContext.class);
|
||||||
|
//样品委托
|
||||||
|
BusinessSampleEntrustRegistrationDO sampleEntrustRegistration = sampleEntrustContext.getSampleEntrustRegistration();
|
||||||
|
//如果委托登记id为空,则为创建
|
||||||
|
return sampleEntrustRegistration.getId() == null;
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,122 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.entrust;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleAssayResultDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustProjectDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleAssayResultMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustDetailMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustProjectMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustRegistrationMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleEntrustContext;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.MaterialAssayStandardDetailDO;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>sampleEntrustUpdateDataCmp</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleEntrustUpdateDataCmp", name = "样品委托更新委托数据" )
|
||||||
|
public class SampleEntrustUpdateDataCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustRegistrationMapper businessSampleEntrustRegistrationMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustDetailMapper businessSampleEntrustDetailMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustProjectMapper businessSampleEntrustProjectMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleAssayResultMapper businessSampleAssayResultMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
//获取样品委托上下文
|
||||||
|
SampleEntrustContext sampleEntrustContext = this.getContextBean(SampleEntrustContext.class);
|
||||||
|
//样品委托
|
||||||
|
BusinessSampleEntrustRegistrationDO sampleEntrustRegistration = sampleEntrustContext.getSampleEntrustRegistration();
|
||||||
|
|
||||||
|
//先删除旧的
|
||||||
|
List<BusinessSampleEntrustDetailDO> sampleEntrustDetailOldList = businessSampleEntrustDetailMapper.selectList(new LambdaQueryWrapperX<BusinessSampleEntrustDetailDO>().eq(BusinessSampleEntrustDetailDO::getBusinessSampleEntrustRegistrationId, sampleEntrustRegistration.getId()));
|
||||||
|
if (sampleEntrustDetailOldList != null && sampleEntrustDetailOldList.size() > 0) {
|
||||||
|
List<Long> sampleEntrustDetailIdList = sampleEntrustDetailOldList.stream().map(m -> m.getId()).collect(Collectors.toList());
|
||||||
|
List<BusinessSampleEntrustProjectDO> sampleEntrustProjectList = businessSampleEntrustProjectMapper.selectList(new LambdaQueryWrapperX<BusinessSampleEntrustProjectDO>().in(BusinessSampleEntrustProjectDO::getBusinessSampleEntrustDetailId, sampleEntrustDetailIdList));
|
||||||
|
if (sampleEntrustProjectList != null && sampleEntrustProjectList.size() > 0) {
|
||||||
|
List<Long> sampleEntrustProjectIdList = sampleEntrustProjectList.stream().map(m -> m.getId()).collect(Collectors.toList());
|
||||||
|
//删除样品对应的检验项目
|
||||||
|
businessSampleEntrustProjectMapper.deleteByIds(sampleEntrustProjectIdList);
|
||||||
|
}
|
||||||
|
List<BusinessSampleAssayResultDO> sampleAssayResultList = businessSampleAssayResultMapper.selectList(new LambdaQueryWrapperX<BusinessSampleAssayResultDO>().in(BusinessSampleAssayResultDO::getBusinessSampleEntrustDetailId, sampleEntrustDetailIdList));
|
||||||
|
if (sampleAssayResultList != null && sampleAssayResultList.size() > 0) {
|
||||||
|
List<Long> sampleAssayResultIdList = sampleAssayResultList.stream().map(m -> m.getId()).collect(Collectors.toList());
|
||||||
|
//删除来样品位
|
||||||
|
businessSampleAssayResultMapper.deleteByIds(sampleAssayResultIdList);
|
||||||
|
}
|
||||||
|
|
||||||
|
//删除委托登记明细
|
||||||
|
businessSampleEntrustDetailMapper.deleteByIds(sampleEntrustDetailIdList);
|
||||||
|
}
|
||||||
|
|
||||||
|
//保存更新新的
|
||||||
|
List<BusinessSampleAssayResultDO> sampleAssayResultList = new ArrayList<>();
|
||||||
|
|
||||||
|
|
||||||
|
List<BusinessSampleEntrustDetailDO> sampleEntrustDetailList = sampleEntrustContext.getSampleEntrustDetailList();
|
||||||
|
for (BusinessSampleEntrustDetailDO businessSampleEntrustDetail : sampleEntrustDetailList) {
|
||||||
|
businessSampleEntrustDetail.setBusinessSampleEntrustRegistrationId(sampleEntrustRegistration.getId());
|
||||||
|
|
||||||
|
if (StringUtils.isNotBlank(businessSampleEntrustDetail.getForecastResult())) {
|
||||||
|
BusinessSampleAssayResultDO sampleAssayResult = new BusinessSampleAssayResultDO();
|
||||||
|
sampleAssayResult.setBusinessSampleEntrustDetailId(businessSampleEntrustDetail.getId());
|
||||||
|
sampleAssayResult.setData(businessSampleEntrustDetail.getForecastResult());
|
||||||
|
sampleAssayResultList.add(sampleAssayResult);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
List<BusinessSampleEntrustProjectDO> sampleEntrustProjectList = sampleEntrustContext.getSampleEntrustProjectList();
|
||||||
|
for (BusinessSampleEntrustProjectDO businessSampleEntrustProject : sampleEntrustProjectList) {
|
||||||
|
MaterialAssayStandardDetailDO materialAssayStandardDetail = sampleEntrustContext.getMaterialAssayStandardDetailById(businessSampleEntrustProject.getMaterialAssayStandardDetailId());
|
||||||
|
businessSampleEntrustProject.setDictionaryProjectId(materialAssayStandardDetail.getDictionaryProjectId());
|
||||||
|
}
|
||||||
|
|
||||||
|
//保存样品委托登记
|
||||||
|
businessSampleEntrustRegistrationMapper.updateById(sampleEntrustRegistration);
|
||||||
|
|
||||||
|
//保存样品明细
|
||||||
|
if (sampleEntrustDetailList != null && sampleEntrustDetailList.size() > 0) {
|
||||||
|
businessSampleEntrustDetailMapper.insertBatch(sampleEntrustDetailList);
|
||||||
|
}
|
||||||
|
|
||||||
|
//保存检测项目
|
||||||
|
if (sampleEntrustProjectList != null && sampleEntrustProjectList.size() > 0) {
|
||||||
|
businessSampleEntrustProjectMapper.insertBatch(sampleEntrustProjectList);
|
||||||
|
}
|
||||||
|
|
||||||
|
//保存来样元素
|
||||||
|
if (sampleAssayResultList.size() > 0) {
|
||||||
|
businessSampleAssayResultMapper.insertBatch(sampleAssayResultList);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,58 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.flow;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessHandoverRecordSubDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubParentSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessHandoverRecordSubMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSubParentSampleMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSubSampleMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleFlowContext;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleDataSaveOrUpdateCmp</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月8日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月8日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleDataSaveOrUpdateCmp", name = "样品相关数据保存或更新")
|
||||||
|
public class SampleDataSaveOrUpdateCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSubParentSampleMapper businessSubParentSampleMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSubSampleMapper businessSubSampleMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessHandoverRecordSubMapper businessHandoverRecordSubMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
SampleFlowContext sampleFlowContext = this.getContextBean(SampleFlowContext.class);
|
||||||
|
List<BusinessSubParentSampleDO> busSubPsampleList = sampleFlowContext.getBusSubPsampleList();
|
||||||
|
if (busSubPsampleList != null && busSubPsampleList.size() > 0) {
|
||||||
|
businessSubParentSampleMapper.updateBatch(busSubPsampleList);
|
||||||
|
}
|
||||||
|
List<BusinessSubSampleDO> busSubCsampleList = sampleFlowContext.getBusSubCsampleList();
|
||||||
|
if (busSubCsampleList != null && busSubCsampleList.size() > 0) {
|
||||||
|
businessSubSampleMapper.updateBatch(busSubCsampleList);
|
||||||
|
}
|
||||||
|
List<BusinessHandoverRecordSubDO> busHandoverRecordSubList = sampleFlowContext.getBusHandoverRecordSubList();
|
||||||
|
if (busHandoverRecordSubList != null && busHandoverRecordSubList.size() > 0) {
|
||||||
|
businessHandoverRecordSubMapper.insertBatch(busHandoverRecordSubList);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,75 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.flow;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.exception.ServiceException;
|
||||||
|
import cn.iocoder.yudao.framework.security.core.LoginUser;
|
||||||
|
import cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils;
|
||||||
|
import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleFlowParam;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleFlowContext;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleFlowContextInitCmp</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月6日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月6日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleFlowContextInitCmp", name = "样品流转上下文初始化")
|
||||||
|
public class SampleFlowContextInitCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
//租户id
|
||||||
|
Long tenantId = TenantContextHolder.getRequiredTenantId();
|
||||||
|
|
||||||
|
//当前登录用户
|
||||||
|
LoginUser loginUser = SecurityFrameworkUtils.getLoginUser();
|
||||||
|
|
||||||
|
//当前登录用户昵称
|
||||||
|
String nickName = SecurityFrameworkUtils.getLoginUserNickname();
|
||||||
|
|
||||||
|
//样品流转请求参数
|
||||||
|
SampleFlowParam sampleFlowParam = this.getRequestData();
|
||||||
|
|
||||||
|
if (StringUtils.isBlank(sampleFlowParam.getSampleProcessNo())) {
|
||||||
|
new ServiceException(500, "样品流程节点sampleProcessNo不允许为空");
|
||||||
|
}
|
||||||
|
|
||||||
|
if (sampleFlowParam.getSampleIdList() == null || sampleFlowParam.getSampleIdList().size() <= 0) {
|
||||||
|
new ServiceException(500, "样品Id列表不允许为空");
|
||||||
|
}
|
||||||
|
|
||||||
|
SampleFlowContext sampleFlowContext = this.getContextBean(SampleFlowContext.class);
|
||||||
|
sampleFlowContext.setTenantId(tenantId);
|
||||||
|
sampleFlowContext.setLoginUser(loginUser);
|
||||||
|
sampleFlowContext.setLoginRealname(nickName);
|
||||||
|
if (sampleFlowParam.getSpecifyDateTime() != null) {
|
||||||
|
sampleFlowContext.setCurrentDateTime(sampleFlowParam.getSpecifyDateTime());
|
||||||
|
}
|
||||||
|
sampleFlowContext.setSampleSourceType(sampleFlowParam.getSampleSourceType());
|
||||||
|
sampleFlowContext.setSampleProcessNo(sampleFlowParam.getSampleProcessNo());
|
||||||
|
sampleFlowContext.setSampleIdList(sampleFlowParam.getSampleIdList());
|
||||||
|
sampleFlowContext.setSendSampleOper(sampleFlowParam.getSendSampleOper());
|
||||||
|
sampleFlowContext.setReceiveSampleOper(sampleFlowParam.getReceiveSampleOper());
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isAccess() {
|
||||||
|
SampleFlowParam sampleFlowParam = this.getRequestData();
|
||||||
|
if (sampleFlowParam == null) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return super.isAccess();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,76 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.flow;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import org.apache.commons.lang3.StringUtils;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.security.core.LoginUser;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessHandoverRecordSubDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleFlowContext;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.service.BusinessHandoverRecordSubService;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleHandRecordSubCmp</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月6日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月6日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleHandoverRecordSubCmp", name = "子样交接记录")
|
||||||
|
public class SampleHandoverRecordSubCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessHandoverRecordSubService businessHandoverRecordSubService;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
SampleFlowContext sampleFlowContext = this.getContextBean(SampleFlowContext.class);
|
||||||
|
LoginUser loginUser = sampleFlowContext.getLoginUser();
|
||||||
|
String loginRealname = sampleFlowContext.getLoginRealname();
|
||||||
|
LocalDateTime currentDateTime = sampleFlowContext.getCurrentDateTime();
|
||||||
|
String sendSampleOper = sampleFlowContext.getSendSampleOper();
|
||||||
|
String receiveSampleOper = sampleFlowContext.getReceiveSampleOper();
|
||||||
|
List<BusinessSubSampleDO> busSubCsampleList = sampleFlowContext.getBusSubCsampleList();
|
||||||
|
|
||||||
|
List<BusinessHandoverRecordSubDO> busHandoverRecordSubList = new ArrayList<>();
|
||||||
|
|
||||||
|
BusinessHandoverRecordSubDO busHandoverRecordSub = null;
|
||||||
|
for (BusinessSubSampleDO businessSubSample : busSubCsampleList) {
|
||||||
|
busHandoverRecordSub = new BusinessHandoverRecordSubDO();
|
||||||
|
busHandoverRecordSub.setBusinessSubSampleId(businessSubSample.getId());
|
||||||
|
busHandoverRecordSub.setSampleCode(businessSubSample.getSampleCode());
|
||||||
|
if (businessSubSample.getIsGenerateReturnCode().intValue() == 1) {
|
||||||
|
busHandoverRecordSub.setSampleCode(businessSubSample.getSampleReturnCode());
|
||||||
|
}
|
||||||
|
busHandoverRecordSub.setSampleFlowKey(businessSubSample.getSampleFlowKey());
|
||||||
|
|
||||||
|
if (StringUtils.isNotBlank(receiveSampleOper)) {
|
||||||
|
busHandoverRecordSub.setReceiveSampleOperator(receiveSampleOper);
|
||||||
|
}
|
||||||
|
if (StringUtils.isNotBlank(sendSampleOper)) {
|
||||||
|
busHandoverRecordSub.setSendSampleOperator(sendSampleOper);
|
||||||
|
}
|
||||||
|
|
||||||
|
busHandoverRecordSub.setOperatorId(loginUser.getId());
|
||||||
|
busHandoverRecordSub.setOperator(loginRealname);
|
||||||
|
busHandoverRecordSub.setOperationTime(currentDateTime);
|
||||||
|
|
||||||
|
busHandoverRecordSubList.add(busHandoverRecordSub);
|
||||||
|
}
|
||||||
|
|
||||||
|
sampleFlowContext.setBusHandoverRecordSubList(busHandoverRecordSubList);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,48 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.flow;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.exception.ServiceException;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSubSampleMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleFlowContext;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleSubCheckCmp</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月6日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月6日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleSubCheckCmp", name = "子样检查")
|
||||||
|
public class SampleSubCheckCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSubSampleMapper businessSubSampleMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
SampleFlowContext sampleFlowContext = this.getContextBean(SampleFlowContext.class);
|
||||||
|
String sampleProcessNo = sampleFlowContext.getSampleProcessNo();
|
||||||
|
List<Long> sampleIdList = sampleFlowContext.getSampleIdList();
|
||||||
|
if (sampleIdList == null || sampleIdList.size() <= 0) {
|
||||||
|
throw new ServiceException(500, "样品ID列表不允许为空");
|
||||||
|
}
|
||||||
|
List<BusinessSubSampleDO> businessSubSampleDOList = businessSubSampleMapper.selectByIds(sampleIdList);
|
||||||
|
|
||||||
|
boolean isSampleFlowKeyFail = businessSubSampleDOList.stream().anyMatch(p -> !p.getSampleFlowKey().equals(sampleProcessNo));
|
||||||
|
if (isSampleFlowKeyFail) {
|
||||||
|
throw new ServiceException(500, "样品列表与当前流程不符");
|
||||||
|
}
|
||||||
|
sampleFlowContext.setBusSubCsampleList(businessSubSampleDOList);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,67 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.sample.flow;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.alibaba.fastjson2.JSON;
|
||||||
|
import com.yomahub.liteflow.annotation.LiteflowComponent;
|
||||||
|
import com.yomahub.liteflow.core.NodeComponent;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleFlowContext;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.ConfigSampleFlowDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.ConfigSubSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.service.ConfigSampleFlowService;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.service.ConfigSubSampleService;
|
||||||
|
import cn.iocoder.yudao.module.qms.core.sampleflow.SampleFlowDefinition;
|
||||||
|
import cn.iocoder.yudao.module.qms.core.sampleflow.SampleFlowNode;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleSubProcessUpdateCmp</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月8日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月8日
|
||||||
|
*/
|
||||||
|
@LiteflowComponent(id = "sampleSubProcessUpdateCmp", name = "子样流程节点更新")
|
||||||
|
public class SampleSubProcessUpdateCmp extends NodeComponent {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private ConfigSubSampleService configSubSampleService;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private ConfigSampleFlowService configSampleFlowService;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void process() throws Exception {
|
||||||
|
SampleFlowContext sampleFlowContext = this.getContextBean(SampleFlowContext.class);
|
||||||
|
String sampleProcessNo = sampleFlowContext.getSampleProcessNo();
|
||||||
|
// LoginUser loginUser = sampleFlowContext.getLoginUser();
|
||||||
|
// String loginRealname = sampleFlowContext.getLoginRealname();
|
||||||
|
LocalDateTime currentDateTime = sampleFlowContext.getCurrentDateTime();
|
||||||
|
List<BusinessSubSampleDO> busSubCsampleList = sampleFlowContext.getBusSubCsampleList();
|
||||||
|
for (BusinessSubSampleDO businessSubSample : busSubCsampleList) {
|
||||||
|
Long configSubSampleId = businessSubSample.getConfigSubSampleId();
|
||||||
|
ConfigSubSampleDO configSubSample = configSubSampleService.getConfigSubSample(configSubSampleId);
|
||||||
|
String sampleFlowKey = configSubSample.getFlowKey();
|
||||||
|
ConfigSampleFlowDO configSampleFlow = configSampleFlowService.getConfigSampleFlowByKey(sampleFlowKey);
|
||||||
|
String configSampleFlowContent = configSampleFlow.getContent();
|
||||||
|
//样品流程定义
|
||||||
|
SampleFlowDefinition sampleFlowDefinition = JSON.parseObject(configSampleFlowContent, SampleFlowDefinition.class);
|
||||||
|
List<SampleFlowNode> flowNodeList = sampleFlowDefinition.getFlowNodeList();
|
||||||
|
SampleFlowNode flowNode = flowNodeList.stream().filter(f -> f.getNodeKey().equals(sampleProcessNo)).findFirst().orElse(null);
|
||||||
|
List<SampleFlowNode> nextFlowNodeList = flowNode.getNextFlowNodeList();
|
||||||
|
SampleFlowNode nextFlowNode = nextFlowNodeList.stream().filter(f -> f.getIsDefault()).findFirst().orElse(null);
|
||||||
|
businessSubSample.setSampleFlowKey(nextFlowNode.getNodeKey());
|
||||||
|
businessSubSample.setSampleFlowTime(currentDateTime);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.slot;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.security.core.LoginUser;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleAssayResultDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustProjectDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.ConfigEntrustSourceDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.MaterialAssayStandardDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.MaterialAssayStandardDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.MaterialAssayStandardMethodDO;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustContext</b>
|
||||||
|
* 样品委托上下文
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月6日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月6日
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@Accessors(chain = true)
|
||||||
|
public class SampleEntrustContext {
|
||||||
|
|
||||||
|
/** 租户id **/
|
||||||
|
private Long tenantId;
|
||||||
|
|
||||||
|
/** 当前时间 **/
|
||||||
|
private LocalDateTime currentDateTime = LocalDateTime.now();
|
||||||
|
|
||||||
|
/** 当前登录用户 **/
|
||||||
|
private LoginUser loginUser;
|
||||||
|
|
||||||
|
/** 当前登录人 **/
|
||||||
|
private String loginRealname;
|
||||||
|
|
||||||
|
/** 委托来源配置列表 **/
|
||||||
|
private List<ConfigEntrustSourceDO> configEntrustSourceList;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 根据id获取委托来源配置
|
||||||
|
* @param id 委托来源配置id
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
public ConfigEntrustSourceDO getConfigEntrustSourceById(Long id) {
|
||||||
|
ConfigEntrustSourceDO configEntrustSource = null;
|
||||||
|
if (this.configEntrustSourceList != null && this.configEntrustSourceList.size() > 0) {
|
||||||
|
configEntrustSource = this.configEntrustSourceList.stream().filter(f -> id.equals(f.getId())).findFirst().orElse(null);
|
||||||
|
}
|
||||||
|
return configEntrustSource;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** 物料检测标准列表 **/
|
||||||
|
private List<MaterialAssayStandardDO> materialAssayStandardList;
|
||||||
|
|
||||||
|
/** 物料检测标准检测项目列表 **/
|
||||||
|
private List<MaterialAssayStandardDetailDO> materialAssayStandardDetailList;
|
||||||
|
|
||||||
|
public MaterialAssayStandardDetailDO getMaterialAssayStandardDetailById(Long id) {
|
||||||
|
MaterialAssayStandardDetailDO materialAssayStandardDetail = null;
|
||||||
|
if (this.materialAssayStandardDetailList != null && this.materialAssayStandardDetailList.size() > 0) {
|
||||||
|
materialAssayStandardDetail = this.materialAssayStandardDetailList.stream().filter(f -> id.equals(f.getId())).findFirst().orElse(null);
|
||||||
|
}
|
||||||
|
return materialAssayStandardDetail;
|
||||||
|
}
|
||||||
|
|
||||||
|
/** 物料检测标准与方法列表 **/
|
||||||
|
private List<MaterialAssayStandardMethodDO> materialAssayStandardMethodList;
|
||||||
|
|
||||||
|
/** 委托登记单 **/
|
||||||
|
private BusinessSampleEntrustRegistrationDO sampleEntrustRegistration;
|
||||||
|
|
||||||
|
/** 委托登记样品明细 **/
|
||||||
|
private List<BusinessSampleEntrustDetailDO> sampleEntrustDetailList;
|
||||||
|
|
||||||
|
/** 委托登记样品检测项目明细 **/
|
||||||
|
private List<BusinessSampleEntrustProjectDO> sampleEntrustProjectList;
|
||||||
|
|
||||||
|
/** 样品委托来样品位 **/
|
||||||
|
private List<BusinessSampleAssayResultDO> sampleAssayResultList;
|
||||||
|
}
|
||||||
@@ -0,0 +1,70 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.liteflow.slot;
|
||||||
|
|
||||||
|
import java.time.LocalDateTime;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.security.core.LoginUser;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessBaseSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessHandoverRecordSubDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubParentSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubSampleDO;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleFlowContext</b>
|
||||||
|
* 样品流转上下文
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月6日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月6日
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
@Accessors(chain = true)
|
||||||
|
public class SampleFlowContext {
|
||||||
|
|
||||||
|
/** 租户id **/
|
||||||
|
private Long tenantId;
|
||||||
|
|
||||||
|
/** 样品来源 1:主,2:子 **/
|
||||||
|
private Integer sampleSourceType;
|
||||||
|
|
||||||
|
/** 样品当前流程节点 **/
|
||||||
|
private String sampleProcessNo;
|
||||||
|
|
||||||
|
/** 样品id列表 **/
|
||||||
|
private List<Long> sampleIdList;
|
||||||
|
|
||||||
|
/** 主样信息 **/
|
||||||
|
private List<BusinessBaseSampleDO> busBaseSampleList;
|
||||||
|
|
||||||
|
/** 分样主样信息 **/
|
||||||
|
private List<BusinessSubParentSampleDO> busSubPsampleList;
|
||||||
|
|
||||||
|
/** 分样子样信息 **/
|
||||||
|
private List<BusinessSubSampleDO> busSubCsampleList;
|
||||||
|
|
||||||
|
/** 交接记录信息 **/
|
||||||
|
private List<BusinessHandoverRecordSubDO> busHandoverRecordSubList;
|
||||||
|
|
||||||
|
/** 当前时间 **/
|
||||||
|
private LocalDateTime currentDateTime = LocalDateTime.now();
|
||||||
|
|
||||||
|
/** 当前登录用户 **/
|
||||||
|
private LoginUser loginUser;
|
||||||
|
|
||||||
|
/** 当前登录人 **/
|
||||||
|
private String loginRealname;
|
||||||
|
|
||||||
|
/** 送样人 **/
|
||||||
|
private String sendSampleOper;
|
||||||
|
|
||||||
|
/** 收样人 **/
|
||||||
|
private String receiveSampleOper;
|
||||||
|
}
|
||||||
@@ -0,0 +1,62 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessBaseSampleDO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 主样业务 Service 接口
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
public interface BusinessBaseSampleService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建主样业务
|
||||||
|
*
|
||||||
|
* @param createReqVO 创建信息
|
||||||
|
* @return 编号
|
||||||
|
*/
|
||||||
|
BusinessBaseSampleRespVO createBusinessBaseSample(@Valid BusinessBaseSampleSaveReqVO createReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新主样业务
|
||||||
|
*
|
||||||
|
* @param updateReqVO 更新信息
|
||||||
|
*/
|
||||||
|
void updateBusinessBaseSample(@Valid BusinessBaseSampleSaveReqVO updateReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除主样业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessBaseSample(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除主样业务
|
||||||
|
*
|
||||||
|
* @param ids 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessBaseSampleListByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得主样业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
* @return 主样业务
|
||||||
|
*/
|
||||||
|
BusinessBaseSampleDO getBusinessBaseSample(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得主样业务分页
|
||||||
|
*
|
||||||
|
* @param pageReqVO 分页查询
|
||||||
|
* @return 主样业务分页
|
||||||
|
*/
|
||||||
|
PageResult<BusinessBaseSampleDO> getBusinessBaseSamplePage(BusinessBaseSamplePageReqVO pageReqVO);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessBaseSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessBaseSampleMapper;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.diffList;
|
||||||
|
import static cn.iocoder.yudao.module.qms.enums.ErrorCodeConstants.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 主样业务 Service 实现类
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@Validated
|
||||||
|
public class BusinessBaseSampleServiceImpl implements BusinessBaseSampleService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessBaseSampleMapper businessBaseSampleMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessBaseSampleRespVO createBusinessBaseSample(BusinessBaseSampleSaveReqVO createReqVO) {
|
||||||
|
// 插入
|
||||||
|
BusinessBaseSampleDO businessBaseSample = BeanUtils.toBean(createReqVO, BusinessBaseSampleDO.class);
|
||||||
|
businessBaseSampleMapper.insert(businessBaseSample);
|
||||||
|
// 返回
|
||||||
|
return BeanUtils.toBean(businessBaseSample, BusinessBaseSampleRespVO.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateBusinessBaseSample(BusinessBaseSampleSaveReqVO updateReqVO) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessBaseSampleExists(updateReqVO.getId());
|
||||||
|
// 更新
|
||||||
|
BusinessBaseSampleDO updateObj = BeanUtils.toBean(updateReqVO, BusinessBaseSampleDO.class);
|
||||||
|
businessBaseSampleMapper.updateById(updateObj);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessBaseSample(Long id) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessBaseSampleExists(id);
|
||||||
|
// 删除
|
||||||
|
businessBaseSampleMapper.deleteById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessBaseSampleListByIds(List<Long> ids) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessBaseSampleExists(ids);
|
||||||
|
// 删除
|
||||||
|
businessBaseSampleMapper.deleteByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessBaseSampleExists(List<Long> ids) {
|
||||||
|
List<BusinessBaseSampleDO> list = businessBaseSampleMapper.selectByIds(ids);
|
||||||
|
if (CollUtil.isEmpty(list) || list.size() != ids.size()) {
|
||||||
|
throw exception(BUSINESS_BASE_SAMPLE_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessBaseSampleExists(Long id) {
|
||||||
|
if (businessBaseSampleMapper.selectById(id) == null) {
|
||||||
|
throw exception(BUSINESS_BASE_SAMPLE_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessBaseSampleDO getBusinessBaseSample(Long id) {
|
||||||
|
return businessBaseSampleMapper.selectById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<BusinessBaseSampleDO> getBusinessBaseSamplePage(BusinessBaseSamplePageReqVO pageReqVO) {
|
||||||
|
return businessBaseSampleMapper.selectPage(pageReqVO);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,62 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessHandoverRecordSubDO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 子样交接记录业务 Service 接口
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
public interface BusinessHandoverRecordSubService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建子样交接记录业务
|
||||||
|
*
|
||||||
|
* @param createReqVO 创建信息
|
||||||
|
* @return 编号
|
||||||
|
*/
|
||||||
|
BusinessHandoverRecordSubRespVO createBusinessHandoverRecordSub(@Valid BusinessHandoverRecordSubSaveReqVO createReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新子样交接记录业务
|
||||||
|
*
|
||||||
|
* @param updateReqVO 更新信息
|
||||||
|
*/
|
||||||
|
void updateBusinessHandoverRecordSub(@Valid BusinessHandoverRecordSubSaveReqVO updateReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除子样交接记录业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessHandoverRecordSub(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除子样交接记录业务
|
||||||
|
*
|
||||||
|
* @param ids 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessHandoverRecordSubListByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得子样交接记录业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
* @return 子样交接记录业务
|
||||||
|
*/
|
||||||
|
BusinessHandoverRecordSubDO getBusinessHandoverRecordSub(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得子样交接记录业务分页
|
||||||
|
*
|
||||||
|
* @param pageReqVO 分页查询
|
||||||
|
* @return 子样交接记录业务分页
|
||||||
|
*/
|
||||||
|
PageResult<BusinessHandoverRecordSubDO> getBusinessHandoverRecordSubPage(BusinessHandoverRecordSubPageReqVO pageReqVO);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessHandoverRecordSubDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessHandoverRecordSubMapper;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.diffList;
|
||||||
|
import static cn.iocoder.yudao.module.qms.enums.ErrorCodeConstants.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 子样交接记录业务 Service 实现类
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@Validated
|
||||||
|
public class BusinessHandoverRecordSubServiceImpl implements BusinessHandoverRecordSubService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessHandoverRecordSubMapper businessHandoverRecordSubMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessHandoverRecordSubRespVO createBusinessHandoverRecordSub(BusinessHandoverRecordSubSaveReqVO createReqVO) {
|
||||||
|
// 插入
|
||||||
|
BusinessHandoverRecordSubDO businessHandoverRecordSub = BeanUtils.toBean(createReqVO, BusinessHandoverRecordSubDO.class);
|
||||||
|
businessHandoverRecordSubMapper.insert(businessHandoverRecordSub);
|
||||||
|
// 返回
|
||||||
|
return BeanUtils.toBean(businessHandoverRecordSub, BusinessHandoverRecordSubRespVO.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateBusinessHandoverRecordSub(BusinessHandoverRecordSubSaveReqVO updateReqVO) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessHandoverRecordSubExists(updateReqVO.getId());
|
||||||
|
// 更新
|
||||||
|
BusinessHandoverRecordSubDO updateObj = BeanUtils.toBean(updateReqVO, BusinessHandoverRecordSubDO.class);
|
||||||
|
businessHandoverRecordSubMapper.updateById(updateObj);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessHandoverRecordSub(Long id) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessHandoverRecordSubExists(id);
|
||||||
|
// 删除
|
||||||
|
businessHandoverRecordSubMapper.deleteById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessHandoverRecordSubListByIds(List<Long> ids) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessHandoverRecordSubExists(ids);
|
||||||
|
// 删除
|
||||||
|
businessHandoverRecordSubMapper.deleteByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessHandoverRecordSubExists(List<Long> ids) {
|
||||||
|
List<BusinessHandoverRecordSubDO> list = businessHandoverRecordSubMapper.selectByIds(ids);
|
||||||
|
if (CollUtil.isEmpty(list) || list.size() != ids.size()) {
|
||||||
|
throw exception(BUSINESS_HANDOVER_RECORD_SUB_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessHandoverRecordSubExists(Long id) {
|
||||||
|
if (businessHandoverRecordSubMapper.selectById(id) == null) {
|
||||||
|
throw exception(BUSINESS_HANDOVER_RECORD_SUB_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessHandoverRecordSubDO getBusinessHandoverRecordSub(Long id) {
|
||||||
|
return businessHandoverRecordSubMapper.selectById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<BusinessHandoverRecordSubDO> getBusinessHandoverRecordSubPage(BusinessHandoverRecordSubPageReqVO pageReqVO) {
|
||||||
|
return businessHandoverRecordSubMapper.selectPage(pageReqVO);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,62 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleAssayResultDO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检登记来样品位 Service 接口
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
public interface BusinessSampleAssayResultService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建委检登记来样品位
|
||||||
|
*
|
||||||
|
* @param createReqVO 创建信息
|
||||||
|
* @return 编号
|
||||||
|
*/
|
||||||
|
BusinessSampleAssayResultRespVO createBusinessSampleAssayResult(@Valid BusinessSampleAssayResultSaveReqVO createReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新委检登记来样品位
|
||||||
|
*
|
||||||
|
* @param updateReqVO 更新信息
|
||||||
|
*/
|
||||||
|
void updateBusinessSampleAssayResult(@Valid BusinessSampleAssayResultSaveReqVO updateReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除委检登记来样品位
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSampleAssayResult(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除委检登记来样品位
|
||||||
|
*
|
||||||
|
* @param ids 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSampleAssayResultListByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得委检登记来样品位
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
* @return 委检登记来样品位
|
||||||
|
*/
|
||||||
|
BusinessSampleAssayResultDO getBusinessSampleAssayResult(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得委检登记来样品位分页
|
||||||
|
*
|
||||||
|
* @param pageReqVO 分页查询
|
||||||
|
* @return 委检登记来样品位分页
|
||||||
|
*/
|
||||||
|
PageResult<BusinessSampleAssayResultDO> getBusinessSampleAssayResultPage(BusinessSampleAssayResultPageReqVO pageReqVO);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleAssayResultDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleAssayResultMapper;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.diffList;
|
||||||
|
import static cn.iocoder.yudao.module.qms.enums.ErrorCodeConstants.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检登记来样品位 Service 实现类
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@Validated
|
||||||
|
public class BusinessSampleAssayResultServiceImpl implements BusinessSampleAssayResultService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleAssayResultMapper businessSampleAssayResultMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSampleAssayResultRespVO createBusinessSampleAssayResult(BusinessSampleAssayResultSaveReqVO createReqVO) {
|
||||||
|
// 插入
|
||||||
|
BusinessSampleAssayResultDO businessSampleAssayResult = BeanUtils.toBean(createReqVO, BusinessSampleAssayResultDO.class);
|
||||||
|
businessSampleAssayResultMapper.insert(businessSampleAssayResult);
|
||||||
|
// 返回
|
||||||
|
return BeanUtils.toBean(businessSampleAssayResult, BusinessSampleAssayResultRespVO.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateBusinessSampleAssayResult(BusinessSampleAssayResultSaveReqVO updateReqVO) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleAssayResultExists(updateReqVO.getId());
|
||||||
|
// 更新
|
||||||
|
BusinessSampleAssayResultDO updateObj = BeanUtils.toBean(updateReqVO, BusinessSampleAssayResultDO.class);
|
||||||
|
businessSampleAssayResultMapper.updateById(updateObj);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSampleAssayResult(Long id) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleAssayResultExists(id);
|
||||||
|
// 删除
|
||||||
|
businessSampleAssayResultMapper.deleteById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSampleAssayResultListByIds(List<Long> ids) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleAssayResultExists(ids);
|
||||||
|
// 删除
|
||||||
|
businessSampleAssayResultMapper.deleteByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSampleAssayResultExists(List<Long> ids) {
|
||||||
|
List<BusinessSampleAssayResultDO> list = businessSampleAssayResultMapper.selectByIds(ids);
|
||||||
|
if (CollUtil.isEmpty(list) || list.size() != ids.size()) {
|
||||||
|
throw exception(BUSINESS_SAMPLE_ASSAY_RESULT_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSampleAssayResultExists(Long id) {
|
||||||
|
if (businessSampleAssayResultMapper.selectById(id) == null) {
|
||||||
|
throw exception(BUSINESS_SAMPLE_ASSAY_RESULT_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSampleAssayResultDO getBusinessSampleAssayResult(Long id) {
|
||||||
|
return businessSampleAssayResultMapper.selectById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<BusinessSampleAssayResultDO> getBusinessSampleAssayResultPage(BusinessSampleAssayResultPageReqVO pageReqVO) {
|
||||||
|
return businessSampleAssayResultMapper.selectPage(pageReqVO);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,64 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustDetailPageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustDetailRespVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustDetailSaveReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustDetailDO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检登记样品明细 Service 接口
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
public interface BusinessSampleEntrustDetailService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建委检登记样品明细
|
||||||
|
*
|
||||||
|
* @param createReqVO 创建信息
|
||||||
|
* @return 编号
|
||||||
|
*/
|
||||||
|
BusinessSampleEntrustDetailRespVO createBusinessSampleEntrustDetail(@Valid BusinessSampleEntrustDetailSaveReqVO createReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新委检登记样品明细
|
||||||
|
*
|
||||||
|
* @param updateReqVO 更新信息
|
||||||
|
*/
|
||||||
|
void updateBusinessSampleEntrustDetail(@Valid BusinessSampleEntrustDetailSaveReqVO updateReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除委检登记样品明细
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSampleEntrustDetail(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除委检登记样品明细
|
||||||
|
*
|
||||||
|
* @param ids 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSampleEntrustDetailListByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得委检登记样品明细
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
* @return 委检登记样品明细
|
||||||
|
*/
|
||||||
|
BusinessSampleEntrustDetailDO getBusinessSampleEntrustDetail(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得委检登记样品明细分页
|
||||||
|
*
|
||||||
|
* @param pageReqVO 分页查询
|
||||||
|
* @return 委检登记样品明细分页
|
||||||
|
*/
|
||||||
|
PageResult<BusinessSampleEntrustDetailDO> getBusinessSampleEntrustDetailPage(BusinessSampleEntrustDetailPageReqVO pageReqVO);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustDetailMapper;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.diffList;
|
||||||
|
import static cn.iocoder.yudao.module.qms.enums.ErrorCodeConstants.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检登记样品明细 Service 实现类
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@Validated
|
||||||
|
public class BusinessSampleEntrustDetailServiceImpl implements BusinessSampleEntrustDetailService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustDetailMapper businessSampleEntrustDetailMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSampleEntrustDetailRespVO createBusinessSampleEntrustDetail(BusinessSampleEntrustDetailSaveReqVO createReqVO) {
|
||||||
|
// 插入
|
||||||
|
BusinessSampleEntrustDetailDO businessSampleEntrustDetail = BeanUtils.toBean(createReqVO, BusinessSampleEntrustDetailDO.class);
|
||||||
|
businessSampleEntrustDetailMapper.insert(businessSampleEntrustDetail);
|
||||||
|
// 返回
|
||||||
|
return BeanUtils.toBean(businessSampleEntrustDetail, BusinessSampleEntrustDetailRespVO.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateBusinessSampleEntrustDetail(BusinessSampleEntrustDetailSaveReqVO updateReqVO) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleEntrustDetailExists(updateReqVO.getId());
|
||||||
|
// 更新
|
||||||
|
BusinessSampleEntrustDetailDO updateObj = BeanUtils.toBean(updateReqVO, BusinessSampleEntrustDetailDO.class);
|
||||||
|
businessSampleEntrustDetailMapper.updateById(updateObj);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSampleEntrustDetail(Long id) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleEntrustDetailExists(id);
|
||||||
|
// 删除
|
||||||
|
businessSampleEntrustDetailMapper.deleteById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSampleEntrustDetailListByIds(List<Long> ids) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleEntrustDetailExists(ids);
|
||||||
|
// 删除
|
||||||
|
businessSampleEntrustDetailMapper.deleteByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSampleEntrustDetailExists(List<Long> ids) {
|
||||||
|
List<BusinessSampleEntrustDetailDO> list = businessSampleEntrustDetailMapper.selectByIds(ids);
|
||||||
|
if (CollUtil.isEmpty(list) || list.size() != ids.size()) {
|
||||||
|
throw exception(BUSINESS_SAMPLE_ENTRUST_DETAIL_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSampleEntrustDetailExists(Long id) {
|
||||||
|
if (businessSampleEntrustDetailMapper.selectById(id) == null) {
|
||||||
|
throw exception(BUSINESS_SAMPLE_ENTRUST_DETAIL_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSampleEntrustDetailDO getBusinessSampleEntrustDetail(Long id) {
|
||||||
|
return businessSampleEntrustDetailMapper.selectById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<BusinessSampleEntrustDetailDO> getBusinessSampleEntrustDetailPage(BusinessSampleEntrustDetailPageReqVO pageReqVO) {
|
||||||
|
return businessSampleEntrustDetailMapper.selectPage(pageReqVO);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,62 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustProjectDO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检样品检测项目业务 Service 接口
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
public interface BusinessSampleEntrustProjectService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建委检样品检测项目业务
|
||||||
|
*
|
||||||
|
* @param createReqVO 创建信息
|
||||||
|
* @return 编号
|
||||||
|
*/
|
||||||
|
BusinessSampleEntrustProjectRespVO createBusinessSampleEntrustProject(@Valid BusinessSampleEntrustProjectSaveReqVO createReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新委检样品检测项目业务
|
||||||
|
*
|
||||||
|
* @param updateReqVO 更新信息
|
||||||
|
*/
|
||||||
|
void updateBusinessSampleEntrustProject(@Valid BusinessSampleEntrustProjectSaveReqVO updateReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除委检样品检测项目业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSampleEntrustProject(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除委检样品检测项目业务
|
||||||
|
*
|
||||||
|
* @param ids 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSampleEntrustProjectListByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得委检样品检测项目业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
* @return 委检样品检测项目业务
|
||||||
|
*/
|
||||||
|
BusinessSampleEntrustProjectDO getBusinessSampleEntrustProject(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得委检样品检测项目业务分页
|
||||||
|
*
|
||||||
|
* @param pageReqVO 分页查询
|
||||||
|
* @return 委检样品检测项目业务分页
|
||||||
|
*/
|
||||||
|
PageResult<BusinessSampleEntrustProjectDO> getBusinessSampleEntrustProjectPage(BusinessSampleEntrustProjectPageReqVO pageReqVO);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustProjectDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustProjectMapper;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.diffList;
|
||||||
|
import static cn.iocoder.yudao.module.qms.enums.ErrorCodeConstants.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检样品检测项目业务 Service 实现类
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@Validated
|
||||||
|
public class BusinessSampleEntrustProjectServiceImpl implements BusinessSampleEntrustProjectService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustProjectMapper businessSampleEntrustProjectMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSampleEntrustProjectRespVO createBusinessSampleEntrustProject(BusinessSampleEntrustProjectSaveReqVO createReqVO) {
|
||||||
|
// 插入
|
||||||
|
BusinessSampleEntrustProjectDO businessSampleEntrustProject = BeanUtils.toBean(createReqVO, BusinessSampleEntrustProjectDO.class);
|
||||||
|
businessSampleEntrustProjectMapper.insert(businessSampleEntrustProject);
|
||||||
|
// 返回
|
||||||
|
return BeanUtils.toBean(businessSampleEntrustProject, BusinessSampleEntrustProjectRespVO.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateBusinessSampleEntrustProject(BusinessSampleEntrustProjectSaveReqVO updateReqVO) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleEntrustProjectExists(updateReqVO.getId());
|
||||||
|
// 更新
|
||||||
|
BusinessSampleEntrustProjectDO updateObj = BeanUtils.toBean(updateReqVO, BusinessSampleEntrustProjectDO.class);
|
||||||
|
businessSampleEntrustProjectMapper.updateById(updateObj);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSampleEntrustProject(Long id) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleEntrustProjectExists(id);
|
||||||
|
// 删除
|
||||||
|
businessSampleEntrustProjectMapper.deleteById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSampleEntrustProjectListByIds(List<Long> ids) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleEntrustProjectExists(ids);
|
||||||
|
// 删除
|
||||||
|
businessSampleEntrustProjectMapper.deleteByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSampleEntrustProjectExists(List<Long> ids) {
|
||||||
|
List<BusinessSampleEntrustProjectDO> list = businessSampleEntrustProjectMapper.selectByIds(ids);
|
||||||
|
if (CollUtil.isEmpty(list) || list.size() != ids.size()) {
|
||||||
|
throw exception(BUSINESS_SAMPLE_ENTRUST_PROJECT_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSampleEntrustProjectExists(Long id) {
|
||||||
|
if (businessSampleEntrustProjectMapper.selectById(id) == null) {
|
||||||
|
throw exception(BUSINESS_SAMPLE_ENTRUST_PROJECT_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSampleEntrustProjectDO getBusinessSampleEntrustProject(Long id) {
|
||||||
|
return businessSampleEntrustProjectMapper.selectById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<BusinessSampleEntrustProjectDO> getBusinessSampleEntrustProjectPage(BusinessSampleEntrustProjectPageReqVO pageReqVO) {
|
||||||
|
return businessSampleEntrustProjectMapper.selectPage(pageReqVO);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,62 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检登记业务 Service 接口
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
public interface BusinessSampleEntrustRegistrationService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建委检登记业务
|
||||||
|
*
|
||||||
|
* @param createReqVO 创建信息
|
||||||
|
* @return 编号
|
||||||
|
*/
|
||||||
|
BusinessSampleEntrustRegistrationRespVO createBusinessSampleEntrustRegistration(@Valid BusinessSampleEntrustRegistrationSaveReqVO createReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新委检登记业务
|
||||||
|
*
|
||||||
|
* @param updateReqVO 更新信息
|
||||||
|
*/
|
||||||
|
void updateBusinessSampleEntrustRegistration(@Valid BusinessSampleEntrustRegistrationSaveReqVO updateReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除委检登记业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSampleEntrustRegistration(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除委检登记业务
|
||||||
|
*
|
||||||
|
* @param ids 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSampleEntrustRegistrationListByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得委检登记业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
* @return 委检登记业务
|
||||||
|
*/
|
||||||
|
BusinessSampleEntrustRegistrationDO getBusinessSampleEntrustRegistration(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得委检登记业务分页
|
||||||
|
*
|
||||||
|
* @param pageReqVO 分页查询
|
||||||
|
* @return 委检登记业务分页
|
||||||
|
*/
|
||||||
|
PageResult<BusinessSampleEntrustRegistrationDO> getBusinessSampleEntrustRegistrationPage(BusinessSampleEntrustRegistrationPageReqVO pageReqVO);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustRegistrationMapper;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.diffList;
|
||||||
|
import static cn.iocoder.yudao.module.qms.enums.ErrorCodeConstants.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 委检登记业务 Service 实现类
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@Validated
|
||||||
|
public class BusinessSampleEntrustRegistrationServiceImpl implements BusinessSampleEntrustRegistrationService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustRegistrationMapper businessSampleEntrustRegistrationMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSampleEntrustRegistrationRespVO createBusinessSampleEntrustRegistration(BusinessSampleEntrustRegistrationSaveReqVO createReqVO) {
|
||||||
|
// 插入
|
||||||
|
BusinessSampleEntrustRegistrationDO businessSampleEntrustRegistration = BeanUtils.toBean(createReqVO, BusinessSampleEntrustRegistrationDO.class);
|
||||||
|
businessSampleEntrustRegistrationMapper.insert(businessSampleEntrustRegistration);
|
||||||
|
// 返回
|
||||||
|
return BeanUtils.toBean(businessSampleEntrustRegistration, BusinessSampleEntrustRegistrationRespVO.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateBusinessSampleEntrustRegistration(BusinessSampleEntrustRegistrationSaveReqVO updateReqVO) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleEntrustRegistrationExists(updateReqVO.getId());
|
||||||
|
// 更新
|
||||||
|
BusinessSampleEntrustRegistrationDO updateObj = BeanUtils.toBean(updateReqVO, BusinessSampleEntrustRegistrationDO.class);
|
||||||
|
businessSampleEntrustRegistrationMapper.updateById(updateObj);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSampleEntrustRegistration(Long id) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleEntrustRegistrationExists(id);
|
||||||
|
// 删除
|
||||||
|
businessSampleEntrustRegistrationMapper.deleteById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSampleEntrustRegistrationListByIds(List<Long> ids) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSampleEntrustRegistrationExists(ids);
|
||||||
|
// 删除
|
||||||
|
businessSampleEntrustRegistrationMapper.deleteByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSampleEntrustRegistrationExists(List<Long> ids) {
|
||||||
|
List<BusinessSampleEntrustRegistrationDO> list = businessSampleEntrustRegistrationMapper.selectByIds(ids);
|
||||||
|
if (CollUtil.isEmpty(list) || list.size() != ids.size()) {
|
||||||
|
throw exception(BUSINESS_SAMPLE_ENTRUST_REGISTRATION_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSampleEntrustRegistrationExists(Long id) {
|
||||||
|
if (businessSampleEntrustRegistrationMapper.selectById(id) == null) {
|
||||||
|
throw exception(BUSINESS_SAMPLE_ENTRUST_REGISTRATION_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSampleEntrustRegistrationDO getBusinessSampleEntrustRegistration(Long id) {
|
||||||
|
return businessSampleEntrustRegistrationMapper.selectById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<BusinessSampleEntrustRegistrationDO> getBusinessSampleEntrustRegistrationPage(BusinessSampleEntrustRegistrationPageReqVO pageReqVO) {
|
||||||
|
return businessSampleEntrustRegistrationMapper.selectPage(pageReqVO);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,62 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubParentSampleDO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分样业务 Service 接口
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
public interface BusinessSubParentSampleService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建分样业务
|
||||||
|
*
|
||||||
|
* @param createReqVO 创建信息
|
||||||
|
* @return 编号
|
||||||
|
*/
|
||||||
|
BusinessSubParentSampleRespVO createBusinessSubParentSample(@Valid BusinessSubParentSampleSaveReqVO createReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新分样业务
|
||||||
|
*
|
||||||
|
* @param updateReqVO 更新信息
|
||||||
|
*/
|
||||||
|
void updateBusinessSubParentSample(@Valid BusinessSubParentSampleSaveReqVO updateReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除分样业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSubParentSample(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除分样业务
|
||||||
|
*
|
||||||
|
* @param ids 编号
|
||||||
|
*/
|
||||||
|
void deleteBusinessSubParentSampleListByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得分样业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
* @return 分样业务
|
||||||
|
*/
|
||||||
|
BusinessSubParentSampleDO getBusinessSubParentSample(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得分样业务分页
|
||||||
|
*
|
||||||
|
* @param pageReqVO 分页查询
|
||||||
|
* @return 分样业务分页
|
||||||
|
*/
|
||||||
|
PageResult<BusinessSubParentSampleDO> getBusinessSubParentSamplePage(BusinessSubParentSamplePageReqVO pageReqVO);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,91 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.*;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubParentSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSubParentSampleMapper;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.diffList;
|
||||||
|
import static cn.iocoder.yudao.module.qms.enums.ErrorCodeConstants.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 分样业务 Service 实现类
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@Validated
|
||||||
|
public class BusinessSubParentSampleServiceImpl implements BusinessSubParentSampleService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSubParentSampleMapper businessSubParentSampleMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSubParentSampleRespVO createBusinessSubParentSample(BusinessSubParentSampleSaveReqVO createReqVO) {
|
||||||
|
// 插入
|
||||||
|
BusinessSubParentSampleDO businessSubParentSample = BeanUtils.toBean(createReqVO, BusinessSubParentSampleDO.class);
|
||||||
|
businessSubParentSampleMapper.insert(businessSubParentSample);
|
||||||
|
// 返回
|
||||||
|
return BeanUtils.toBean(businessSubParentSample, BusinessSubParentSampleRespVO.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateBusinessSubParentSample(BusinessSubParentSampleSaveReqVO updateReqVO) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSubParentSampleExists(updateReqVO.getId());
|
||||||
|
// 更新
|
||||||
|
BusinessSubParentSampleDO updateObj = BeanUtils.toBean(updateReqVO, BusinessSubParentSampleDO.class);
|
||||||
|
businessSubParentSampleMapper.updateById(updateObj);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSubParentSample(Long id) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSubParentSampleExists(id);
|
||||||
|
// 删除
|
||||||
|
businessSubParentSampleMapper.deleteById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteBusinessSubParentSampleListByIds(List<Long> ids) {
|
||||||
|
// 校验存在
|
||||||
|
validateBusinessSubParentSampleExists(ids);
|
||||||
|
// 删除
|
||||||
|
businessSubParentSampleMapper.deleteByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSubParentSampleExists(List<Long> ids) {
|
||||||
|
List<BusinessSubParentSampleDO> list = businessSubParentSampleMapper.selectByIds(ids);
|
||||||
|
if (CollUtil.isEmpty(list) || list.size() != ids.size()) {
|
||||||
|
throw exception(BUSINESS_SUB_PARENT_SAMPLE_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateBusinessSubParentSampleExists(Long id) {
|
||||||
|
if (businessSubParentSampleMapper.selectById(id) == null) {
|
||||||
|
throw exception(BUSINESS_SUB_PARENT_SAMPLE_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSubParentSampleDO getBusinessSubParentSample(Long id) {
|
||||||
|
return businessSubParentSampleMapper.selectById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<BusinessSubParentSampleDO> getBusinessSubParentSamplePage(BusinessSubParentSamplePageReqVO pageReqVO) {
|
||||||
|
return businessSubParentSampleMapper.selectPage(pageReqVO);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,64 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSamplePageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSampleRespVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSampleSaveReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubSampleDO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 子样业务 Service 接口
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
public interface BusinessSubSampleService {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建子样业务
|
||||||
|
*
|
||||||
|
* @param createReqVO 创建信息
|
||||||
|
* @return 编号
|
||||||
|
*/
|
||||||
|
BusinessSubSampleRespVO createinessSubSample(@Valid BusinessSubSampleSaveReqVO createReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 更新子样业务
|
||||||
|
*
|
||||||
|
* @param updateReqVO 更新信息
|
||||||
|
*/
|
||||||
|
void updateinessSubSample(@Valid BusinessSubSampleSaveReqVO updateReqVO);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除子样业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
*/
|
||||||
|
void deleteinessSubSample(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 批量删除子样业务
|
||||||
|
*
|
||||||
|
* @param ids 编号
|
||||||
|
*/
|
||||||
|
void deleteinessSubSampleListByIds(List<Long> ids);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得子样业务
|
||||||
|
*
|
||||||
|
* @param id 编号
|
||||||
|
* @return 子样业务
|
||||||
|
*/
|
||||||
|
BusinessSubSampleDO getinessSubSample(Long id);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获得子样业务分页
|
||||||
|
*
|
||||||
|
* @param pageReqVO 分页查询
|
||||||
|
* @return 子样业务分页
|
||||||
|
*/
|
||||||
|
PageResult<BusinessSubSampleDO> getinessSubSamplePage(BusinessSubSamplePageReqVO pageReqVO);
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,93 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSamplePageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSampleRespVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSubSampleSaveReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSubSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSubSampleMapper;
|
||||||
|
|
||||||
|
import static cn.iocoder.yudao.framework.common.exception.util.ServiceExceptionUtil.exception;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.convertList;
|
||||||
|
import static cn.iocoder.yudao.framework.common.util.collection.CollectionUtils.diffList;
|
||||||
|
import static cn.iocoder.yudao.module.qms.enums.ErrorCodeConstants.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 子样业务 Service 实现类
|
||||||
|
*
|
||||||
|
* @author 后台管理
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@Validated
|
||||||
|
public class BusinessSubSampleServiceImpl implements BusinessSubSampleService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSubSampleMapper businessSubSampleMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSubSampleRespVO createinessSubSample(BusinessSubSampleSaveReqVO createReqVO) {
|
||||||
|
// 插入
|
||||||
|
BusinessSubSampleDO inessSubSample = BeanUtils.toBean(createReqVO, BusinessSubSampleDO.class);
|
||||||
|
businessSubSampleMapper.insert(inessSubSample);
|
||||||
|
// 返回
|
||||||
|
return BeanUtils.toBean(inessSubSample, BusinessSubSampleRespVO.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void updateinessSubSample(BusinessSubSampleSaveReqVO updateReqVO) {
|
||||||
|
// 校验存在
|
||||||
|
validateinessSubSampleExists(updateReqVO.getId());
|
||||||
|
// 更新
|
||||||
|
BusinessSubSampleDO updateObj = BeanUtils.toBean(updateReqVO, BusinessSubSampleDO.class);
|
||||||
|
businessSubSampleMapper.updateById(updateObj);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteinessSubSample(Long id) {
|
||||||
|
// 校验存在
|
||||||
|
validateinessSubSampleExists(id);
|
||||||
|
// 删除
|
||||||
|
businessSubSampleMapper.deleteById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void deleteinessSubSampleListByIds(List<Long> ids) {
|
||||||
|
// 校验存在
|
||||||
|
validateinessSubSampleExists(ids);
|
||||||
|
// 删除
|
||||||
|
businessSubSampleMapper.deleteByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateinessSubSampleExists(List<Long> ids) {
|
||||||
|
List<BusinessSubSampleDO> list = businessSubSampleMapper.selectByIds(ids);
|
||||||
|
if (CollUtil.isEmpty(list) || list.size() != ids.size()) {
|
||||||
|
throw exception(BUSINESS_SUB_SAMPLE_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private void validateinessSubSampleExists(Long id) {
|
||||||
|
if (businessSubSampleMapper.selectById(id) == null) {
|
||||||
|
throw exception(BUSINESS_SUB_SAMPLE_NOT_EXISTS);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSubSampleDO getinessSubSample(Long id) {
|
||||||
|
return businessSubSampleMapper.selectById(id);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public PageResult<BusinessSubSampleDO> getinessSubSamplePage(BusinessSubSamplePageReqVO pageReqVO) {
|
||||||
|
return businessSubSampleMapper.selectPage(pageReqVO);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,37 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.flow.LiteflowResponse;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustRegistrationExtendRespVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustRegistrationSubmitReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleEntrustParam;
|
||||||
|
import jakarta.validation.Valid;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustService</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
public interface SampleEntrustService {
|
||||||
|
|
||||||
|
LiteflowResponse create(@Valid SampleEntrustParam sampleEntrustParam);
|
||||||
|
|
||||||
|
LiteflowResponse update(@Valid SampleEntrustParam sampleEntrustParam);
|
||||||
|
|
||||||
|
BusinessSampleEntrustRegistrationExtendRespVO detail(Long id);
|
||||||
|
|
||||||
|
void delete(Long id);
|
||||||
|
|
||||||
|
void deleteList(List<Long> ids);
|
||||||
|
|
||||||
|
void submit(@Valid BusinessSampleEntrustRegistrationSubmitReqVO req);
|
||||||
|
}
|
||||||
@@ -0,0 +1,187 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import java.util.ArrayList;
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
|
import com.yomahub.liteflow.core.FlowExecutor;
|
||||||
|
import com.yomahub.liteflow.flow.LiteflowResponse;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.exception.ServiceException;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.LambdaQueryWrapperX;
|
||||||
|
import cn.iocoder.yudao.framework.mybatis.core.query.MPJLambdaWrapperX;
|
||||||
|
import cn.iocoder.yudao.framework.tenant.core.context.TenantContextHolder;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustDetailExtendRespVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustProjectExtendRespVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustRegistrationExtendRespVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.controller.vo.BusinessSampleEntrustRegistrationSubmitReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleAssayResultDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustDetailDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustProjectDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.dataobject.BusinessSampleEntrustRegistrationDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleAssayResultMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustDetailMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustProjectMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.dal.mapper.BusinessSampleEntrustRegistrationMapper;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.param.SampleEntrustParam;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.bus.liteflow.slot.SampleEntrustContext;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.dic.dal.dataobject.DictionaryProjectDO;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import jakarta.validation.Valid;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleEntrustServiceImpl</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月10日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月10日
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class SampleEntrustServiceImpl implements SampleEntrustService {
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private FlowExecutor flowExecutor;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustRegistrationMapper businessSampleEntrustRegistrationMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustDetailMapper businessSampleEntrustDetailMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleEntrustProjectMapper businessSampleEntrustProjectMapper;
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BusinessSampleAssayResultMapper businessSampleAssayResultMapper;
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public LiteflowResponse create(@Valid SampleEntrustParam sampleEntrustParam) {
|
||||||
|
Long tenantId = TenantContextHolder.getRequiredTenantId();
|
||||||
|
return flowExecutor.execute2Resp("sampleEntrustChain" + tenantId, sampleEntrustParam, SampleEntrustContext.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public BusinessSampleEntrustRegistrationExtendRespVO detail(Long id) {
|
||||||
|
BusinessSampleEntrustRegistrationDO businessSampleEntrustRegistrationDO = businessSampleEntrustRegistrationMapper.selectById(id);
|
||||||
|
BusinessSampleEntrustRegistrationExtendRespVO businessSampleEntrustRegistrationExtendRespVO = BeanUtils.toBean(businessSampleEntrustRegistrationDO, BusinessSampleEntrustRegistrationExtendRespVO.class);
|
||||||
|
|
||||||
|
List<BusinessSampleEntrustDetailExtendRespVO> sampleEntrustDetailExtendRespVOList = new ArrayList<>();
|
||||||
|
List<BusinessSampleEntrustDetailDO> sampleEntrustDetailList = businessSampleEntrustDetailMapper.selectList(new LambdaQueryWrapperX<BusinessSampleEntrustDetailDO>().eq(BusinessSampleEntrustDetailDO::getBusinessSampleEntrustRegistrationId, id));
|
||||||
|
BusinessSampleEntrustDetailExtendRespVO businessSampleEntrustDetailExtendRespVO = null;
|
||||||
|
for (BusinessSampleEntrustDetailDO businessSampleEntrustDetailDO : sampleEntrustDetailList) {
|
||||||
|
businessSampleEntrustDetailExtendRespVO = BeanUtils.toBean(businessSampleEntrustDetailDO, BusinessSampleEntrustDetailExtendRespVO.class);
|
||||||
|
|
||||||
|
List<BusinessSampleEntrustProjectExtendRespVO> businessSampleEntrustProjectExtendRespVOList = businessSampleEntrustProjectMapper.selectJoinList(BusinessSampleEntrustProjectExtendRespVO.class, new MPJLambdaWrapperX<BusinessSampleEntrustProjectDO>()
|
||||||
|
.selectAll(BusinessSampleEntrustProjectDO.class)
|
||||||
|
.selectAs(DictionaryProjectDO::getCode, BusinessSampleEntrustProjectExtendRespVO::getProjectCode)
|
||||||
|
.selectAs(DictionaryProjectDO::getName, BusinessSampleEntrustProjectExtendRespVO::getProjectName)
|
||||||
|
.selectAs(DictionaryProjectDO::getSimpleName, BusinessSampleEntrustProjectExtendRespVO::getProjectSimpleName)
|
||||||
|
.selectAs(DictionaryProjectDO::getShowName, BusinessSampleEntrustProjectExtendRespVO::getProjectShowName)
|
||||||
|
.leftJoin(DictionaryProjectDO.class, DictionaryProjectDO::getId, BusinessSampleEntrustProjectDO::getDictionaryProjectId)
|
||||||
|
.eq(BusinessSampleEntrustProjectDO::getBusinessSampleEntrustDetailId, businessSampleEntrustDetailDO.getId()));
|
||||||
|
|
||||||
|
// List<BusinessSampleEntrustProjectDO> sampleEntrustProjectList = businessSampleEntrustProjectMapper.selectList(new LambdaQueryWrapperX<BusinessSampleEntrustProjectDO>().eq(BusinessSampleEntrustProjectDO::getBusinessSampleEntrustDetailId, businessSampleEntrustDetailDO.getId()));
|
||||||
|
// List<BusinessSampleEntrustProjectExtendRespVO> businessSampleEntrustProjectExtendRespVOList = BeanUtils.toBean(sampleEntrustProjectList, BusinessSampleEntrustProjectExtendRespVO.class);
|
||||||
|
|
||||||
|
businessSampleEntrustDetailExtendRespVO.setSampleEntrustDetailProjectList(businessSampleEntrustProjectExtendRespVOList);
|
||||||
|
|
||||||
|
sampleEntrustDetailExtendRespVOList.add(businessSampleEntrustDetailExtendRespVO);
|
||||||
|
}
|
||||||
|
businessSampleEntrustRegistrationExtendRespVO.setSampleEntrustDetailList(sampleEntrustDetailExtendRespVOList);
|
||||||
|
|
||||||
|
return businessSampleEntrustRegistrationExtendRespVO;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public LiteflowResponse update(@Valid SampleEntrustParam sampleEntrustParam) {
|
||||||
|
Long tenantId = TenantContextHolder.getRequiredTenantId();
|
||||||
|
return flowExecutor.execute2Resp("sampleEntrustChain" + tenantId, sampleEntrustParam, SampleEntrustContext.class);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void delete(Long id) {
|
||||||
|
if (id == null) {
|
||||||
|
throw new ServiceException(500, "委托登记id不允许为空");
|
||||||
|
}
|
||||||
|
if (businessSampleEntrustRegistrationMapper.selectById(id) == null) {
|
||||||
|
throw new ServiceException(500, "委托登记业务不存在");
|
||||||
|
}
|
||||||
|
|
||||||
|
List<BusinessSampleEntrustDetailDO> sampleEntrustDetailList = businessSampleEntrustDetailMapper.selectList(new LambdaQueryWrapperX<BusinessSampleEntrustDetailDO>().eq(BusinessSampleEntrustDetailDO::getBusinessSampleEntrustRegistrationId, id));
|
||||||
|
if (sampleEntrustDetailList != null && sampleEntrustDetailList.size() > 0) {
|
||||||
|
List<Long> sampleEntrustDetailIdList = sampleEntrustDetailList.stream().map(m -> m.getId()).collect(Collectors.toList());
|
||||||
|
List<BusinessSampleEntrustProjectDO> sampleEntrustProjectList = businessSampleEntrustProjectMapper.selectList(new LambdaQueryWrapperX<BusinessSampleEntrustProjectDO>().in(BusinessSampleEntrustProjectDO::getBusinessSampleEntrustDetailId, sampleEntrustDetailIdList));
|
||||||
|
if (sampleEntrustProjectList != null && sampleEntrustProjectList.size() > 0) {
|
||||||
|
List<Long> sampleEntrustProjectIdList = sampleEntrustProjectList.stream().map(m -> m.getId()).collect(Collectors.toList());
|
||||||
|
//删除样品对应的检验项目
|
||||||
|
businessSampleEntrustProjectMapper.deleteByIds(sampleEntrustProjectIdList);
|
||||||
|
}
|
||||||
|
List<BusinessSampleAssayResultDO> sampleAssayResultList = businessSampleAssayResultMapper.selectList(new LambdaQueryWrapperX<BusinessSampleAssayResultDO>().in(BusinessSampleAssayResultDO::getBusinessSampleEntrustDetailId, sampleEntrustDetailIdList));
|
||||||
|
if (sampleAssayResultList != null && sampleAssayResultList.size() > 0) {
|
||||||
|
List<Long> sampleAssayResultIdList = sampleAssayResultList.stream().map(m -> m.getId()).collect(Collectors.toList());
|
||||||
|
//删除来样品位
|
||||||
|
businessSampleAssayResultMapper.deleteByIds(sampleAssayResultIdList);
|
||||||
|
}
|
||||||
|
|
||||||
|
//删除委托登记明细
|
||||||
|
businessSampleEntrustDetailMapper.deleteByIds(sampleEntrustDetailIdList);
|
||||||
|
}
|
||||||
|
//删除委托登记
|
||||||
|
businessSampleEntrustRegistrationMapper.deleteById(id);
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void deleteList(List<Long> ids) {
|
||||||
|
if (ids == null || ids.size() <= 0) {
|
||||||
|
throw new ServiceException(500, "委托登记id列表不允许为空");
|
||||||
|
}
|
||||||
|
List<BusinessSampleEntrustRegistrationDO> sampleEntrustRegistrationList = businessSampleEntrustRegistrationMapper.selectByIds(ids);
|
||||||
|
if (sampleEntrustRegistrationList == null || sampleEntrustRegistrationList.size() != ids.size()) {
|
||||||
|
throw new ServiceException(500, "委托登记业务不存在");
|
||||||
|
}
|
||||||
|
|
||||||
|
List<BusinessSampleEntrustDetailDO> sampleEntrustDetailList = businessSampleEntrustDetailMapper.selectList(new LambdaQueryWrapperX<BusinessSampleEntrustDetailDO>().in(BusinessSampleEntrustDetailDO::getBusinessSampleEntrustRegistrationId, ids));
|
||||||
|
if (sampleEntrustDetailList != null && sampleEntrustDetailList.size() > 0) {
|
||||||
|
List<Long> sampleEntrustDetailIdList = sampleEntrustDetailList.stream().map(m -> m.getId()).collect(Collectors.toList());
|
||||||
|
List<BusinessSampleEntrustProjectDO> sampleEntrustProjectList = businessSampleEntrustProjectMapper.selectList(new LambdaQueryWrapperX<BusinessSampleEntrustProjectDO>().in(BusinessSampleEntrustProjectDO::getBusinessSampleEntrustDetailId, sampleEntrustDetailIdList));
|
||||||
|
if (sampleEntrustProjectList != null && sampleEntrustProjectList.size() > 0) {
|
||||||
|
List<Long> sampleEntrustProjectIdList = sampleEntrustProjectList.stream().map(m -> m.getId()).collect(Collectors.toList());
|
||||||
|
//删除样品对应的检验项目
|
||||||
|
businessSampleEntrustProjectMapper.deleteByIds(sampleEntrustProjectIdList);
|
||||||
|
}
|
||||||
|
List<BusinessSampleAssayResultDO> sampleAssayResultList = businessSampleAssayResultMapper.selectList(new LambdaQueryWrapperX<BusinessSampleAssayResultDO>().in(BusinessSampleAssayResultDO::getBusinessSampleEntrustDetailId, sampleEntrustDetailIdList));
|
||||||
|
if (sampleAssayResultList != null && sampleAssayResultList.size() > 0) {
|
||||||
|
List<Long> sampleAssayResultIdList = sampleAssayResultList.stream().map(m -> m.getId()).collect(Collectors.toList());
|
||||||
|
//删除来样品位
|
||||||
|
businessSampleAssayResultMapper.deleteByIds(sampleAssayResultIdList);
|
||||||
|
}
|
||||||
|
|
||||||
|
//删除委托登记明细
|
||||||
|
businessSampleEntrustDetailMapper.deleteByIds(sampleEntrustDetailIdList);
|
||||||
|
}
|
||||||
|
//删除委托登记
|
||||||
|
businessSampleEntrustRegistrationMapper.deleteByIds(ids);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
public void submit(@Valid BusinessSampleEntrustRegistrationSubmitReqVO req) {
|
||||||
|
// TODO Auto-generated method stub
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleFlowService</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
public interface SampleFlowService {
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.bus.service;
|
||||||
|
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* <b>SampleFlowServiceImpl</b>
|
||||||
|
* <p>
|
||||||
|
* 更新历史:
|
||||||
|
* <pre> 版本 更新时间 更新者 更新内容<hr/>
|
||||||
|
* V1.0 2025年9月9日 wxr Add</pre>
|
||||||
|
* <b>Copyright (C) 云南志者竟成科技有限公司</b>
|
||||||
|
* </p>
|
||||||
|
* @author 王兴荣<wxr@wangxingrong.com>
|
||||||
|
* @version V1.0
|
||||||
|
* @since 2025年9月9日
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class SampleFlowServiceImpl implements SampleFlowService {
|
||||||
|
|
||||||
|
}
|
||||||
@@ -0,0 +1,116 @@
|
|||||||
|
package cn.iocoder.yudao.module.qms.business.config.controller.admin;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.controller.vo.BaseSamplePageReqVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.controller.vo.BaseSampleRespVO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.controller.vo.BaseSampleSaveReqVO;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
import jakarta.annotation.Resource;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.security.access.prepost.PreAuthorize;
|
||||||
|
import cn.iocoder.yudao.framework.business.interceptor.BusinessControllerMarker;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import io.swagger.v3.oas.annotations.Parameter;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
|
||||||
|
import jakarta.validation.*;
|
||||||
|
import jakarta.servlet.http.*;
|
||||||
|
import java.util.*;
|
||||||
|
import java.io.IOException;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.vo.BatchDeleteReqVO;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageParam;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.PageResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.pojo.CommonResult;
|
||||||
|
import cn.iocoder.yudao.framework.common.util.object.BeanUtils;
|
||||||
|
import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.excel.core.util.ExcelUtils;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.framework.apilog.core.annotation.ApiAccessLog;
|
||||||
|
import static cn.iocoder.yudao.framework.apilog.core.enums.OperateTypeEnum.*;
|
||||||
|
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.dal.dataobject.BaseSampleDO;
|
||||||
|
import cn.iocoder.yudao.module.qms.business.config.service.BaseSampleService;
|
||||||
|
|
||||||
|
@Tag(name = "管理后台 - 样品大类管理")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/qms/base-sample")
|
||||||
|
@Validated
|
||||||
|
public class BaseSampleController implements BusinessControllerMarker {
|
||||||
|
|
||||||
|
|
||||||
|
@Resource
|
||||||
|
private BaseSampleService baseSampleService;
|
||||||
|
|
||||||
|
@PostMapping("/create")
|
||||||
|
@Operation(summary = "创建样品大类管理")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:base-sample:create')")
|
||||||
|
public CommonResult<BaseSampleRespVO> createBaseSample(@Valid @RequestBody BaseSampleSaveReqVO createReqVO) {
|
||||||
|
return success(baseSampleService.createBaseSample(createReqVO));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PutMapping("/update")
|
||||||
|
@Operation(summary = "更新样品大类管理")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:base-sample:update')")
|
||||||
|
public CommonResult<Boolean> updateBaseSample(@Valid @RequestBody BaseSampleSaveReqVO updateReqVO) {
|
||||||
|
baseSampleService.updateBaseSample(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete")
|
||||||
|
@Operation(summary = "删除样品大类管理")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:base-sample:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBaseSample(@RequestParam("id") Long id) {
|
||||||
|
baseSampleService.deleteBaseSample(id);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@DeleteMapping("/delete-list")
|
||||||
|
@Parameter(name = "ids", description = "编号", required = true)
|
||||||
|
@Operation(summary = "批量删除样品大类管理")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:base-sample:delete')")
|
||||||
|
public CommonResult<Boolean> deleteBaseSampleList(@RequestBody BatchDeleteReqVO req) {
|
||||||
|
baseSampleService.deleteBaseSampleListByIds(req.getIds());
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/get")
|
||||||
|
@Operation(summary = "获得样品大类管理")
|
||||||
|
@Parameter(name = "id", description = "编号", required = true, example = "1024")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:base-sample:query')")
|
||||||
|
public CommonResult<BaseSampleRespVO> getBaseSample(@RequestParam("id") Long id) {
|
||||||
|
BaseSampleDO baseSample = baseSampleService.getBaseSample(id);
|
||||||
|
return success(BeanUtils.toBean(baseSample, BaseSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/getBaseSampleListWithAssayStandardCount")
|
||||||
|
@Operation(summary = "获得样品大类选项-含检测标准数")
|
||||||
|
public CommonResult<List<BaseSampleRespVO>> getBaseSampleListWithAssayStandardCount() {
|
||||||
|
List<BaseSampleDO> pageResult = baseSampleService.getBaseSampleListWithAssayStandardCount();
|
||||||
|
return success(BeanUtils.toBean(pageResult, BaseSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/page")
|
||||||
|
@Operation(summary = "获得样品大类管理分页")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:base-sample:query')")
|
||||||
|
public CommonResult<PageResult<BaseSampleRespVO>> getBaseSamplePage(@Valid BaseSamplePageReqVO pageReqVO) {
|
||||||
|
PageResult<BaseSampleDO> pageResult = baseSampleService.getBaseSamplePage(pageReqVO);
|
||||||
|
return success(BeanUtils.toBean(pageResult, BaseSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/export-excel")
|
||||||
|
@Operation(summary = "导出样品大类管理 Excel")
|
||||||
|
@PreAuthorize("@ss.hasPermission('qms:base-sample:export')")
|
||||||
|
@ApiAccessLog(operateType = EXPORT)
|
||||||
|
public void exportBaseSampleExcel(@Valid BaseSamplePageReqVO pageReqVO,
|
||||||
|
HttpServletResponse response) throws IOException {
|
||||||
|
pageReqVO.setPageSize(PageParam.PAGE_SIZE_NONE);
|
||||||
|
List<BaseSampleDO> list = baseSampleService.getBaseSamplePage(pageReqVO).getList();
|
||||||
|
// 导出 Excel
|
||||||
|
ExcelUtils.write(response, "样品大类管理.xls", "数据", BaseSampleRespVO.class,
|
||||||
|
BeanUtils.toBean(list, BaseSampleRespVO.class));
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user