diff --git a/pom.xml b/pom.xml
index dcd041c..0400b2a 100644
--- a/pom.xml
+++ b/pom.xml
@@ -50,7 +50,9 @@
org.projectlombok
lombok
- true
+ 1.18.34
+
+ provided
org.springframework.boot
@@ -79,6 +81,8 @@
com.mysql
mysql-connector-j
+ ${mysql.version}
+ runtime
@@ -131,34 +135,34 @@
-
- org.apache.maven.plugins
- maven-compiler-plugin
-
-
-
- org.springframework.boot
- spring-boot-configuration-processor
-
-
- org.projectlombok
- lombok
-
-
-
-
-
- org.springframework.boot
- spring-boot-maven-plugin
-
-
-
- org.projectlombok
- lombok
-
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/main/java/com/dc/dc_project/DcProjectApplication.java b/src/main/java/com/dc/dc_project/DcProjectApplication.java
index d257b00..e3f9e8f 100644
--- a/src/main/java/com/dc/dc_project/DcProjectApplication.java
+++ b/src/main/java/com/dc/dc_project/DcProjectApplication.java
@@ -1,9 +1,13 @@
package com.dc.dc_project;
+import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
+import org.springframework.context.annotation.ComponentScan;
@SpringBootApplication
+@MapperScan("com.dc.dc_project.mapper")
+@ComponentScan(basePackages = {"com.dc.dc_project.service"})
public class DcProjectApplication {
public static void main(String[] args) {
diff --git a/src/main/java/com/dc/dc_project/config/StpInterfaceImpl.java b/src/main/java/com/dc/dc_project/config/StpInterfaceImpl.java
index 06f93bc..5eb8738 100644
--- a/src/main/java/com/dc/dc_project/config/StpInterfaceImpl.java
+++ b/src/main/java/com/dc/dc_project/config/StpInterfaceImpl.java
@@ -1,35 +1,36 @@
package com.dc.dc_project.config;
import cn.dev33.satoken.stp.StpInterface;
-import com.plm.common.model.pojo.RoleDesc;
-import com.plm.common.service.RoleDescService;
-import com.plm.common.service.UserDataService;
-import com.plm.common.vo.RolePermissionInfoVo;
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
+import com.dc.dc_project.model.pojo.Role;
+import com.dc.dc_project.model.pojo.UserRole;
+import com.dc.dc_project.service.RoleService;
+import com.dc.dc_project.service.UserRoleService;
import lombok.RequiredArgsConstructor;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;
-
-import java.util.ArrayList;
import java.util.List;
/**
* 权限加载接口实现类
*/
@Component
-@RequiredArgsConstructor(onConstructor_ = {@Autowired})
+//@RequiredArgsConstructor(onConstructor_ = {@Autowired})
public class StpInterfaceImpl implements StpInterface {
- private final UserDataService userDataService;
+ @Autowired
+ private UserRoleService userRoleService;
- private final RoleDescService descService;
+ @Autowired
+ private RoleService roleService;
/**
* 返回一个账号所拥有的权限码集合
*/
@Override
public List getPermissionList(Object loginId, String loginType) {
- Long roleIdByUserId = userDataService.getRoleIdByUserId(Long.valueOf(loginId.toString()));
- RolePermissionInfoVo data = descService.getUserRoleAndPermission(roleIdByUserId).getData();
- return data.getCodes();
+ LambdaQueryWrapper lambdaQueryWrapper = new LambdaQueryWrapper().eq(UserRole::getUserId, Long.valueOf(loginId.toString()));
+ List roleIds = userRoleService.list(lambdaQueryWrapper).stream().map(UserRole::getRoleId).toList();
+ return roleService.list(new LambdaQueryWrapper().in(Role::getId, roleIds)).stream().map(Role::getCode).toList();
}
/**
@@ -37,13 +38,9 @@ public class StpInterfaceImpl implements StpInterface {
*/
@Override
public List getRoleList(Object loginId, String loginType) {
- Long roleIdByUserId = userDataService.getRoleIdByUserId(Long.valueOf(loginId.toString()));
- RoleDesc data = descService.getById(roleIdByUserId);
- List roles = new ArrayList<>();
- if (data != null) {
- roles.add(data.getCode());
- }
- return roles;
+ LambdaQueryWrapper lambdaQueryWrapper = new LambdaQueryWrapper().eq(UserRole::getUserId, Long.valueOf(loginId.toString()));
+ List roleIds = userRoleService.list(lambdaQueryWrapper).stream().map(UserRole::getRoleId).toList();
+ return roleService.list(new LambdaQueryWrapper().in(Role::getId, roleIds)).stream().map(Role::getCode).toList();
}
}
diff --git a/src/main/java/com/dc/dc_project/mapper/LaboratoryMapper.java b/src/main/java/com/dc/dc_project/mapper/LaboratoryMapper.java
new file mode 100644
index 0000000..85bcb18
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/mapper/LaboratoryMapper.java
@@ -0,0 +1,18 @@
+package com.dc.dc_project.mapper;
+
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
+import com.dc.dc_project.model.pojo.Laboratory;
+
+/**
+* @author ADMIN
+* @description 针对表【sys_laboratory(试验室信息表)】的数据库操作Mapper
+* @createDate 2025-11-12 10:49:22
+* @Entity generator.pojo.Laboratory
+*/
+public interface LaboratoryMapper extends BaseMapper {
+
+}
+
+
+
+
diff --git a/src/main/java/com/dc/dc_project/model/Base.java b/src/main/java/com/dc/dc_project/model/Base.java
new file mode 100644
index 0000000..f153f50
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/Base.java
@@ -0,0 +1,4 @@
+package com.dc.dc_project.model;
+
+public class Base {
+}
diff --git a/src/main/java/com/dc/dc_project/model/pojo/Equipment.java b/src/main/java/com/dc/dc_project/model/pojo/Equipment.java
new file mode 100644
index 0000000..c481141
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/Equipment.java
@@ -0,0 +1,259 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+import lombok.Getter;
+import lombok.Setter;
+
+import java.math.BigDecimal;
+import java.time.LocalDate;
+import java.time.LocalDateTime;
+
+/**
+ * 设备台账表
+ * @TableName sys_equipment
+ */
+@TableName(value ="sys_equipment")
+@Data
+public class Equipment {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 所属组织ID(试验室)
+ */
+ @TableField(value = "org_id")
+ private Long orgId;
+
+ /**
+ * 设备名称
+ */
+ @TableField(value = "name")
+ private String name;
+
+ /**
+ * 设备型号
+ */
+ @TableField(value = "model")
+ private String model;
+
+ /**
+ * 生产厂家
+ */
+ @TableField(value = "manufacturer")
+ private String manufacturer;
+
+ /**
+ * 出厂编号
+ */
+ @TableField(value = "serial_no")
+ private String serialNo;
+
+ /**
+ * 购置日期
+ */
+ @TableField(value = "purchase_date")
+ private LocalDate purchaseDate;
+
+ /**
+ * 单价
+ */
+ @TableField(value = "price")
+ private BigDecimal price;
+
+ /**
+ * 量程范围
+ */
+ @TableField(value = "range_value")
+ private String rangeValue;
+
+ /**
+ * 精度等级
+ */
+ @TableField(value = "accuracy")
+ private String accuracy;
+
+ /**
+ * 设备状态(1=在用,2=停用,3=报废)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 检校单位
+ */
+ @TableField(value = "calibration_org")
+ private String calibrationOrg;
+
+ /**
+ * 最近检校日期
+ */
+ @TableField(value = "calibration_date")
+ private LocalDate calibrationDate;
+
+ /**
+ * 检校有效期
+ */
+ @TableField(value = "valid_until")
+ private LocalDate validUntil;
+
+ /**
+ * 有效期提醒天数(到期前X天提醒)
+ */
+ @TableField(value = "remind_days")
+ private Integer remindDays;
+
+ /**
+ * 存放位置
+ */
+ @TableField(value = "location")
+ private String location;
+
+ /**
+ * 责任人(user_id)
+ */
+ @TableField(value = "responsible_user")
+ private Long responsibleUser;
+
+ /**
+ * 备注说明
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 创建人ID
+ */
+ @TableField(value = "created_by")
+ private Long createdBy;
+
+ /**
+ * 更新人ID
+ */
+ @TableField(value = "updated_by")
+ private Long updatedBy;
+
+ /**
+ * 逻辑删除(0=正常,1=删除)
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ Equipment other = (Equipment) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getOrgId() == null ? other.getOrgId() == null : this.getOrgId().equals(other.getOrgId()))
+ && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
+ && (this.getModel() == null ? other.getModel() == null : this.getModel().equals(other.getModel()))
+ && (this.getManufacturer() == null ? other.getManufacturer() == null : this.getManufacturer().equals(other.getManufacturer()))
+ && (this.getSerialNo() == null ? other.getSerialNo() == null : this.getSerialNo().equals(other.getSerialNo()))
+ && (this.getPurchaseDate() == null ? other.getPurchaseDate() == null : this.getPurchaseDate().equals(other.getPurchaseDate()))
+ && (this.getPrice() == null ? other.getPrice() == null : this.getPrice().equals(other.getPrice()))
+ && (this.getRangeValue() == null ? other.getRangeValue() == null : this.getRangeValue().equals(other.getRangeValue()))
+ && (this.getAccuracy() == null ? other.getAccuracy() == null : this.getAccuracy().equals(other.getAccuracy()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getCalibrationOrg() == null ? other.getCalibrationOrg() == null : this.getCalibrationOrg().equals(other.getCalibrationOrg()))
+ && (this.getCalibrationDate() == null ? other.getCalibrationDate() == null : this.getCalibrationDate().equals(other.getCalibrationDate()))
+ && (this.getValidUntil() == null ? other.getValidUntil() == null : this.getValidUntil().equals(other.getValidUntil()))
+ && (this.getRemindDays() == null ? other.getRemindDays() == null : this.getRemindDays().equals(other.getRemindDays()))
+ && (this.getLocation() == null ? other.getLocation() == null : this.getLocation().equals(other.getLocation()))
+ && (this.getResponsibleUser() == null ? other.getResponsibleUser() == null : this.getResponsibleUser().equals(other.getResponsibleUser()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()))
+ && (this.getUpdatedBy() == null ? other.getUpdatedBy() == null : this.getUpdatedBy().equals(other.getUpdatedBy()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getOrgId() == null) ? 0 : getOrgId().hashCode());
+ result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
+ result = prime * result + ((getModel() == null) ? 0 : getModel().hashCode());
+ result = prime * result + ((getManufacturer() == null) ? 0 : getManufacturer().hashCode());
+ result = prime * result + ((getSerialNo() == null) ? 0 : getSerialNo().hashCode());
+ result = prime * result + ((getPurchaseDate() == null) ? 0 : getPurchaseDate().hashCode());
+ result = prime * result + ((getPrice() == null) ? 0 : getPrice().hashCode());
+ result = prime * result + ((getRangeValue() == null) ? 0 : getRangeValue().hashCode());
+ result = prime * result + ((getAccuracy() == null) ? 0 : getAccuracy().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getCalibrationOrg() == null) ? 0 : getCalibrationOrg().hashCode());
+ result = prime * result + ((getCalibrationDate() == null) ? 0 : getCalibrationDate().hashCode());
+ result = prime * result + ((getValidUntil() == null) ? 0 : getValidUntil().hashCode());
+ result = prime * result + ((getRemindDays() == null) ? 0 : getRemindDays().hashCode());
+ result = prime * result + ((getLocation() == null) ? 0 : getLocation().hashCode());
+ result = prime * result + ((getResponsibleUser() == null) ? 0 : getResponsibleUser().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ result = prime * result + ((getUpdatedBy() == null) ? 0 : getUpdatedBy().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", orgId=").append(orgId);
+ sb.append(", name=").append(name);
+ sb.append(", model=").append(model);
+ sb.append(", manufacturer=").append(manufacturer);
+ sb.append(", serialNo=").append(serialNo);
+ sb.append(", purchaseDate=").append(purchaseDate);
+ sb.append(", price=").append(price);
+ sb.append(", rangeValue=").append(rangeValue);
+ sb.append(", accuracy=").append(accuracy);
+ sb.append(", status=").append(status);
+ sb.append(", calibrationOrg=").append(calibrationOrg);
+ sb.append(", calibrationDate=").append(calibrationDate);
+ sb.append(", validUntil=").append(validUntil);
+ sb.append(", remindDays=").append(remindDays);
+ sb.append(", location=").append(location);
+ sb.append(", responsibleUser=").append(responsibleUser);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append(", updatedBy=").append(updatedBy);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/File.java b/src/main/java/com/dc/dc_project/model/pojo/File.java
new file mode 100644
index 0000000..b184f7a
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/File.java
@@ -0,0 +1,201 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 通用文件信息表(文件存储记录)
+ * @TableName sys_file
+ */
+@TableName(value ="sys_file")
+@Data
+public class File {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 关联表名(如 lab_equipment / lab_report)
+ */
+ @TableField(value = "ref_table")
+ private String refTable;
+
+ /**
+ * 关联记录ID
+ */
+ @TableField(value = "ref_id")
+ private Long refId;
+
+ /**
+ * 文件原始名称
+ */
+ @TableField(value = "file_name")
+ private String fileName;
+
+ /**
+ * 文件扩展名(如 pdf, jpg, docx)
+ */
+ @TableField(value = "file_ext")
+ private String fileExt;
+
+ /**
+ * 文件类型(0=未知, 1=图片, 2=文档, 3=报告, 4=证书, 5=其他)
+ */
+ @TableField(value = "file_type")
+ private Integer fileType;
+
+ /**
+ * 文件大小(字节)
+ */
+ @TableField(value = "file_size")
+ private Long fileSize;
+
+ /**
+ * 文件存储路径
+ */
+ @TableField(value = "file_url")
+ private String fileUrl;
+
+ /**
+ * 存储类型(1=本地, 2=MinIO, 3=OSS, 4=其他)
+ */
+ @TableField(value = "storage_type")
+ private Integer storageType;
+
+ /**
+ * 文件哈希值(用于去重校验)
+ */
+ @TableField(value = "hash_code")
+ private String hashCode;
+
+ /**
+ * 上传人ID
+ */
+ @TableField(value = "uploader_id")
+ private Long uploaderId;
+
+ /**
+ * 上传人姓名(冗余存储)
+ */
+ @TableField(value = "uploader_name")
+ private String uploaderName;
+
+ /**
+ * 上传时间
+ */
+ @TableField(value = "upload_time")
+ private LocalDateTime uploadTime;
+
+ /**
+ * 备注()
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 逻辑删除(0=正常,1=删除)
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ File other = (File) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getRefTable() == null ? other.getRefTable() == null : this.getRefTable().equals(other.getRefTable()))
+ && (this.getRefId() == null ? other.getRefId() == null : this.getRefId().equals(other.getRefId()))
+ && (this.getFileName() == null ? other.getFileName() == null : this.getFileName().equals(other.getFileName()))
+ && (this.getFileExt() == null ? other.getFileExt() == null : this.getFileExt().equals(other.getFileExt()))
+ && (this.getFileType() == null ? other.getFileType() == null : this.getFileType().equals(other.getFileType()))
+ && (this.getFileSize() == null ? other.getFileSize() == null : this.getFileSize().equals(other.getFileSize()))
+ && (this.getFileUrl() == null ? other.getFileUrl() == null : this.getFileUrl().equals(other.getFileUrl()))
+ && (this.getStorageType() == null ? other.getStorageType() == null : this.getStorageType().equals(other.getStorageType()))
+ && (this.getHashCode() == null ? other.getHashCode() == null : this.getHashCode().equals(other.getHashCode()))
+ && (this.getUploaderId() == null ? other.getUploaderId() == null : this.getUploaderId().equals(other.getUploaderId()))
+ && (this.getUploaderName() == null ? other.getUploaderName() == null : this.getUploaderName().equals(other.getUploaderName()))
+ && (this.getUploadTime() == null ? other.getUploadTime() == null : this.getUploadTime().equals(other.getUploadTime()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getRefTable() == null) ? 0 : getRefTable().hashCode());
+ result = prime * result + ((getRefId() == null) ? 0 : getRefId().hashCode());
+ result = prime * result + ((getFileName() == null) ? 0 : getFileName().hashCode());
+ result = prime * result + ((getFileExt() == null) ? 0 : getFileExt().hashCode());
+ result = prime * result + ((getFileType() == null) ? 0 : getFileType().hashCode());
+ result = prime * result + ((getFileSize() == null) ? 0 : getFileSize().hashCode());
+ result = prime * result + ((getFileUrl() == null) ? 0 : getFileUrl().hashCode());
+ result = prime * result + ((getStorageType() == null) ? 0 : getStorageType().hashCode());
+ result = prime * result + ((getHashCode() == null) ? 0 : getHashCode().hashCode());
+ result = prime * result + ((getUploaderId() == null) ? 0 : getUploaderId().hashCode());
+ result = prime * result + ((getUploaderName() == null) ? 0 : getUploaderName().hashCode());
+ result = prime * result + ((getUploadTime() == null) ? 0 : getUploadTime().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", refTable=").append(refTable);
+ sb.append(", refId=").append(refId);
+ sb.append(", fileName=").append(fileName);
+ sb.append(", fileExt=").append(fileExt);
+ sb.append(", fileType=").append(fileType);
+ sb.append(", fileSize=").append(fileSize);
+ sb.append(", fileUrl=").append(fileUrl);
+ sb.append(", storageType=").append(storageType);
+ sb.append(", hashCode=").append(hashCode);
+ sb.append(", uploaderId=").append(uploaderId);
+ sb.append(", uploaderName=").append(uploaderName);
+ sb.append(", uploadTime=").append(uploadTime);
+ sb.append(", remark=").append(remark);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/Org.java b/src/main/java/com/dc/dc_project/model/pojo/Org.java
new file mode 100644
index 0000000..d41237a
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/Org.java
@@ -0,0 +1,138 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 组织架构表(公司/项目部/试验室)
+ * @TableName sys_org
+ */
+@TableName(value ="sys_org")
+@Data
+public class Org {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 上级组织ID
+ */
+ @TableField(value = "parent_id")
+ private Long parentId;
+
+ /**
+ * 组织名称
+ */
+ @TableField(value = "name")
+ private String name;
+
+ /**
+ * 组织类型(1=公司,2=项目部,3=试验室)
+ */
+ @TableField(value = "type")
+ private Integer type;
+
+ /**
+ * 组织编码
+ */
+ @TableField(value = "code")
+ private String code;
+
+ /**
+ * 排序号
+ */
+ @TableField(value = "sort_order")
+ private Integer sortOrder;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除标志(0=正常,1=删除)
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ Org other = (Org) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getParentId() == null ? other.getParentId() == null : this.getParentId().equals(other.getParentId()))
+ && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
+ && (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()))
+ && (this.getCode() == null ? other.getCode() == null : this.getCode().equals(other.getCode()))
+ && (this.getSortOrder() == null ? other.getSortOrder() == null : this.getSortOrder().equals(other.getSortOrder()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getParentId() == null) ? 0 : getParentId().hashCode());
+ result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
+ result = prime * result + ((getType() == null) ? 0 : getType().hashCode());
+ result = prime * result + ((getCode() == null) ? 0 : getCode().hashCode());
+ result = prime * result + ((getSortOrder() == null) ? 0 : getSortOrder().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", parentId=").append(parentId);
+ sb.append(", name=").append(name);
+ sb.append(", type=").append(type);
+ sb.append(", code=").append(code);
+ sb.append(", sortOrder=").append(sortOrder);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/Permission.java b/src/main/java/com/dc/dc_project/model/pojo/Permission.java
new file mode 100644
index 0000000..b432bca
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/Permission.java
@@ -0,0 +1,174 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 系统权限表(菜单/接口控制)
+ * @TableName sys_permission
+ */
+@TableName(value ="sys_permission")
+@Data
+public class Permission {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 上级权限ID(形成权限树)
+ */
+ @TableField(value = "parent_id")
+ private Long parentId;
+
+ /**
+ * 权限名称
+ */
+ @TableField(value = "name")
+ private String name;
+
+ /**
+ * 权限编码(如 system:user:view)
+ */
+ @TableField(value = "code")
+ private String code;
+
+ /**
+ * 权限类型(1=目录,2=菜单,3=按钮/接口)
+ */
+ @TableField(value = "type")
+ private Integer type;
+
+ /**
+ * 前端路径或接口地址
+ */
+ @TableField(value = "path")
+ private String path;
+
+ /**
+ * HTTP方法(GET/POST/PUT/DELETE)
+ */
+ @TableField(value = "method")
+ private String method;
+
+ /**
+ * 图标(菜单类)
+ */
+ @TableField(value = "icon")
+ private String icon;
+
+ /**
+ * 排序号
+ */
+ @TableField(value = "sort_order")
+ private Integer sortOrder;
+
+ /**
+ * 状态(0=停用,1=启用)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除标志
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ Permission other = (Permission) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getParentId() == null ? other.getParentId() == null : this.getParentId().equals(other.getParentId()))
+ && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
+ && (this.getCode() == null ? other.getCode() == null : this.getCode().equals(other.getCode()))
+ && (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()))
+ && (this.getPath() == null ? other.getPath() == null : this.getPath().equals(other.getPath()))
+ && (this.getMethod() == null ? other.getMethod() == null : this.getMethod().equals(other.getMethod()))
+ && (this.getIcon() == null ? other.getIcon() == null : this.getIcon().equals(other.getIcon()))
+ && (this.getSortOrder() == null ? other.getSortOrder() == null : this.getSortOrder().equals(other.getSortOrder()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getParentId() == null) ? 0 : getParentId().hashCode());
+ result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
+ result = prime * result + ((getCode() == null) ? 0 : getCode().hashCode());
+ result = prime * result + ((getType() == null) ? 0 : getType().hashCode());
+ result = prime * result + ((getPath() == null) ? 0 : getPath().hashCode());
+ result = prime * result + ((getMethod() == null) ? 0 : getMethod().hashCode());
+ result = prime * result + ((getIcon() == null) ? 0 : getIcon().hashCode());
+ result = prime * result + ((getSortOrder() == null) ? 0 : getSortOrder().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", parentId=").append(parentId);
+ sb.append(", name=").append(name);
+ sb.append(", code=").append(code);
+ sb.append(", type=").append(type);
+ sb.append(", path=").append(path);
+ sb.append(", method=").append(method);
+ sb.append(", icon=").append(icon);
+ sb.append(", sortOrder=").append(sortOrder);
+ sb.append(", status=").append(status);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/Personnel.java b/src/main/java/com/dc/dc_project/model/pojo/Personnel.java
new file mode 100644
index 0000000..40d3c72
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/Personnel.java
@@ -0,0 +1,174 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 人员台账表
+ * @TableName sys_personnel
+ */
+@TableName(value ="sys_personnel")
+@Data
+public class Personnel {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 所属组织(公司/项目/试验室)ID
+ */
+ @TableField(value = "org_id")
+ private Long orgId;
+
+ /**
+ * 关联系统用户ID(可为空)
+ */
+ @TableField(value = "user_id")
+ private Long userId;
+
+ /**
+ * 姓名
+ */
+ @TableField(value = "name")
+ private String name;
+
+ /**
+ * 职务/岗位(如 检测员、试验室主任)
+ */
+ @TableField(value = "position")
+ private String position;
+
+ /**
+ * 联系电话
+ */
+ @TableField(value = "contact_phone")
+ private String contactPhone;
+
+ /**
+ * 邮箱
+ */
+ @TableField(value = "email")
+ private String email;
+
+ /**
+ * 主要负责(自由文本,如 混凝土试验、材料检测)
+ */
+ @TableField(value = "main_responsibility")
+ private String mainResponsibility;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 状态(1=在岗,0=离岗)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 创建人ID
+ */
+ @TableField(value = "created_by")
+ private Long createdBy;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ Personnel other = (Personnel) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getOrgId() == null ? other.getOrgId() == null : this.getOrgId().equals(other.getOrgId()))
+ && (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
+ && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
+ && (this.getPosition() == null ? other.getPosition() == null : this.getPosition().equals(other.getPosition()))
+ && (this.getContactPhone() == null ? other.getContactPhone() == null : this.getContactPhone().equals(other.getContactPhone()))
+ && (this.getEmail() == null ? other.getEmail() == null : this.getEmail().equals(other.getEmail()))
+ && (this.getMainResponsibility() == null ? other.getMainResponsibility() == null : this.getMainResponsibility().equals(other.getMainResponsibility()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getOrgId() == null) ? 0 : getOrgId().hashCode());
+ result = prime * result + ((getUserId() == null) ? 0 : getUserId().hashCode());
+ result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
+ result = prime * result + ((getPosition() == null) ? 0 : getPosition().hashCode());
+ result = prime * result + ((getContactPhone() == null) ? 0 : getContactPhone().hashCode());
+ result = prime * result + ((getEmail() == null) ? 0 : getEmail().hashCode());
+ result = prime * result + ((getMainResponsibility() == null) ? 0 : getMainResponsibility().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", orgId=").append(orgId);
+ sb.append(", userId=").append(userId);
+ sb.append(", name=").append(name);
+ sb.append(", position=").append(position);
+ sb.append(", contactPhone=").append(contactPhone);
+ sb.append(", email=").append(email);
+ sb.append(", mainResponsibility=").append(mainResponsibility);
+ sb.append(", remark=").append(remark);
+ sb.append(", status=").append(status);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/Record.java b/src/main/java/com/dc/dc_project/model/pojo/Record.java
new file mode 100644
index 0000000..e221352
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/Record.java
@@ -0,0 +1,157 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.math.BigDecimal;
+import java.time.LocalDateTime;
+
+/**
+ * 检测记录表(实际检测过程)
+ * @TableName sys_record
+ */
+@TableName(value ="sys_record")
+@Data
+public class Record {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 样品ID(lab_record_sample.id)
+ */
+ @TableField(value = "sample_id")
+ private Long sampleId;
+
+ /**
+ * 检测人ID
+ */
+ @TableField(value = "operator_id")
+ private Long operatorId;
+
+ /**
+ * 检测日期
+ */
+ @TableField(value = "record_date")
+ private LocalDateTime recordDate;
+
+ /**
+ * 使用设备ID
+ */
+ @TableField(value = "equipment_id")
+ private Long equipmentId;
+
+ /**
+ * 检测温度
+ */
+ @TableField(value = "temperature")
+ private BigDecimal temperature;
+
+ /**
+ * 检测湿度
+ */
+ @TableField(value = "humidity")
+ private BigDecimal humidity;
+
+ /**
+ * 状态(0=录入中,1=待审核,2=已审核)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建人ID
+ */
+ @TableField(value = "created_by")
+ private Long createdBy;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ Record other = (Record) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getSampleId() == null ? other.getSampleId() == null : this.getSampleId().equals(other.getSampleId()))
+ && (this.getOperatorId() == null ? other.getOperatorId() == null : this.getOperatorId().equals(other.getOperatorId()))
+ && (this.getRecordDate() == null ? other.getRecordDate() == null : this.getRecordDate().equals(other.getRecordDate()))
+ && (this.getEquipmentId() == null ? other.getEquipmentId() == null : this.getEquipmentId().equals(other.getEquipmentId()))
+ && (this.getTemperature() == null ? other.getTemperature() == null : this.getTemperature().equals(other.getTemperature()))
+ && (this.getHumidity() == null ? other.getHumidity() == null : this.getHumidity().equals(other.getHumidity()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getSampleId() == null) ? 0 : getSampleId().hashCode());
+ result = prime * result + ((getOperatorId() == null) ? 0 : getOperatorId().hashCode());
+ result = prime * result + ((getRecordDate() == null) ? 0 : getRecordDate().hashCode());
+ result = prime * result + ((getEquipmentId() == null) ? 0 : getEquipmentId().hashCode());
+ result = prime * result + ((getTemperature() == null) ? 0 : getTemperature().hashCode());
+ result = prime * result + ((getHumidity() == null) ? 0 : getHumidity().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", sampleId=").append(sampleId);
+ sb.append(", operatorId=").append(operatorId);
+ sb.append(", recordDate=").append(recordDate);
+ sb.append(", equipmentId=").append(equipmentId);
+ sb.append(", temperature=").append(temperature);
+ sb.append(", humidity=").append(humidity);
+ sb.append(", status=").append(status);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/RecordEntrust.java b/src/main/java/com/dc/dc_project/model/pojo/RecordEntrust.java
new file mode 100644
index 0000000..ddac6cf
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/RecordEntrust.java
@@ -0,0 +1,219 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 检测委托单
+ * @TableName sys_record_entrust
+ */
+@TableName(value ="sys_record_entrust")
+@Data
+public class RecordEntrust {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 委托编号
+ */
+ @TableField(value = "entrust_no")
+ private String entrustNo;
+
+ /**
+ * 委托单位(项目/试验室)ID
+ */
+ @TableField(value = "org_id")
+ private Long orgId;
+
+ /**
+ * 委托单位名称
+ */
+ @TableField(value = "client_name")
+ private String clientName;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "entrust_date")
+ private LocalDateTime entrustDate;
+
+ /**
+ * 联系人
+ */
+ @TableField(value = "contact_name")
+ private String contactName;
+
+ /**
+ * 联系电话
+ */
+ @TableField(value = "contact_phone")
+ private String contactPhone;
+
+ /**
+ * 样品名称
+ */
+ @TableField(value = "sample_name")
+ private String sampleName;
+
+ /**
+ * 样品编号
+ */
+ @TableField(value = "sample_code")
+ private String sampleCode;
+
+ /**
+ * 样品类型(混凝土/钢筋/砂石等)
+ */
+ @TableField(value = "sample_type")
+ private String sampleType;
+
+ /**
+ * 样品接收日期
+ */
+ @TableField(value = "receive_date")
+ private LocalDateTime receiveDate;
+
+ /**
+ * 检测类型(1=自检,2=送检,3=外委)
+ */
+ @TableField(value = "test_type")
+ private Integer testType;
+
+ /**
+ * 状态(0=待检测,1=检测中,2=已报告,3=已归档)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 备注说明
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建人ID
+ */
+ @TableField(value = "created_by")
+ private Long createdBy;
+
+ /**
+ * 更新人ID
+ */
+ @TableField(value = "updated_by")
+ private Long updatedBy;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ RecordEntrust other = (RecordEntrust) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getEntrustNo() == null ? other.getEntrustNo() == null : this.getEntrustNo().equals(other.getEntrustNo()))
+ && (this.getOrgId() == null ? other.getOrgId() == null : this.getOrgId().equals(other.getOrgId()))
+ && (this.getClientName() == null ? other.getClientName() == null : this.getClientName().equals(other.getClientName()))
+ && (this.getEntrustDate() == null ? other.getEntrustDate() == null : this.getEntrustDate().equals(other.getEntrustDate()))
+ && (this.getContactName() == null ? other.getContactName() == null : this.getContactName().equals(other.getContactName()))
+ && (this.getContactPhone() == null ? other.getContactPhone() == null : this.getContactPhone().equals(other.getContactPhone()))
+ && (this.getSampleName() == null ? other.getSampleName() == null : this.getSampleName().equals(other.getSampleName()))
+ && (this.getSampleCode() == null ? other.getSampleCode() == null : this.getSampleCode().equals(other.getSampleCode()))
+ && (this.getSampleType() == null ? other.getSampleType() == null : this.getSampleType().equals(other.getSampleType()))
+ && (this.getReceiveDate() == null ? other.getReceiveDate() == null : this.getReceiveDate().equals(other.getReceiveDate()))
+ && (this.getTestType() == null ? other.getTestType() == null : this.getTestType().equals(other.getTestType()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()))
+ && (this.getUpdatedBy() == null ? other.getUpdatedBy() == null : this.getUpdatedBy().equals(other.getUpdatedBy()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getEntrustNo() == null) ? 0 : getEntrustNo().hashCode());
+ result = prime * result + ((getOrgId() == null) ? 0 : getOrgId().hashCode());
+ result = prime * result + ((getClientName() == null) ? 0 : getClientName().hashCode());
+ result = prime * result + ((getEntrustDate() == null) ? 0 : getEntrustDate().hashCode());
+ result = prime * result + ((getContactName() == null) ? 0 : getContactName().hashCode());
+ result = prime * result + ((getContactPhone() == null) ? 0 : getContactPhone().hashCode());
+ result = prime * result + ((getSampleName() == null) ? 0 : getSampleName().hashCode());
+ result = prime * result + ((getSampleCode() == null) ? 0 : getSampleCode().hashCode());
+ result = prime * result + ((getSampleType() == null) ? 0 : getSampleType().hashCode());
+ result = prime * result + ((getReceiveDate() == null) ? 0 : getReceiveDate().hashCode());
+ result = prime * result + ((getTestType() == null) ? 0 : getTestType().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ result = prime * result + ((getUpdatedBy() == null) ? 0 : getUpdatedBy().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", entrustNo=").append(entrustNo);
+ sb.append(", orgId=").append(orgId);
+ sb.append(", clientName=").append(clientName);
+ sb.append(", entrustDate=").append(entrustDate);
+ sb.append(", contactName=").append(contactName);
+ sb.append(", contactPhone=").append(contactPhone);
+ sb.append(", sampleName=").append(sampleName);
+ sb.append(", sampleCode=").append(sampleCode);
+ sb.append(", sampleType=").append(sampleType);
+ sb.append(", receiveDate=").append(receiveDate);
+ sb.append(", testType=").append(testType);
+ sb.append(", status=").append(status);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append(", updatedBy=").append(updatedBy);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/RecordEntrustItem.java b/src/main/java/com/dc/dc_project/model/pojo/RecordEntrustItem.java
new file mode 100644
index 0000000..fb07237
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/RecordEntrustItem.java
@@ -0,0 +1,127 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+/**
+ * 委托单检测项目明细表
+ * @TableName sys_record_entrust_item
+ */
+@TableName(value ="sys_record_entrust_item")
+@Data
+public class RecordEntrustItem {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 委托单ID
+ */
+ @TableField(value = "entrust_id")
+ private Long entrustId;
+
+ /**
+ * 检测依据标准ID
+ */
+ @TableField(value = "standard_id")
+ private Long standardId;
+
+ /**
+ * 检测参数ID(lab_standard_param)
+ */
+ @TableField(value = "param_id")
+ private Long paramId;
+
+ /**
+ * 检测项目名称(如 抗压强度)
+ */
+ @TableField(value = "item_name")
+ private String itemName;
+
+ /**
+ * 样品数量
+ */
+ @TableField(value = "sample_count")
+ private Integer sampleCount;
+
+ /**
+ * 检测方法描述
+ */
+ @TableField(value = "test_method")
+ private String testMethod;
+
+ /**
+ * 状态(0=待检测,1=检测中,2=已完成,3=报告生成)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ RecordEntrustItem other = (RecordEntrustItem) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getEntrustId() == null ? other.getEntrustId() == null : this.getEntrustId().equals(other.getEntrustId()))
+ && (this.getStandardId() == null ? other.getStandardId() == null : this.getStandardId().equals(other.getStandardId()))
+ && (this.getParamId() == null ? other.getParamId() == null : this.getParamId().equals(other.getParamId()))
+ && (this.getItemName() == null ? other.getItemName() == null : this.getItemName().equals(other.getItemName()))
+ && (this.getSampleCount() == null ? other.getSampleCount() == null : this.getSampleCount().equals(other.getSampleCount()))
+ && (this.getTestMethod() == null ? other.getTestMethod() == null : this.getTestMethod().equals(other.getTestMethod()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getEntrustId() == null) ? 0 : getEntrustId().hashCode());
+ result = prime * result + ((getStandardId() == null) ? 0 : getStandardId().hashCode());
+ result = prime * result + ((getParamId() == null) ? 0 : getParamId().hashCode());
+ result = prime * result + ((getItemName() == null) ? 0 : getItemName().hashCode());
+ result = prime * result + ((getSampleCount() == null) ? 0 : getSampleCount().hashCode());
+ result = prime * result + ((getTestMethod() == null) ? 0 : getTestMethod().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", entrustId=").append(entrustId);
+ sb.append(", standardId=").append(standardId);
+ sb.append(", paramId=").append(paramId);
+ sb.append(", itemName=").append(itemName);
+ sb.append(", sampleCount=").append(sampleCount);
+ sb.append(", testMethod=").append(testMethod);
+ sb.append(", status=").append(status);
+ sb.append(", remark=").append(remark);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/RecordLedger.java b/src/main/java/com/dc/dc_project/model/pojo/RecordLedger.java
new file mode 100644
index 0000000..d00b125
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/RecordLedger.java
@@ -0,0 +1,211 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDate;
+import java.time.LocalDateTime;
+
+/**
+ * 检测成果台账表
+ * @TableName sys_record_ledger
+ */
+@TableName(value ="sys_record_ledger")
+@Data
+public class RecordLedger {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 报告ID
+ */
+ @TableField(value = "report_id")
+ private Long reportId;
+
+ /**
+ * 所属组织(项目/试验室)ID
+ */
+ @TableField(value = "org_id")
+ private Long orgId;
+
+ /**
+ * 台账编号
+ */
+ @TableField(value = "ledger_no")
+ private String ledgerNo;
+
+ /**
+ * 报告编号
+ */
+ @TableField(value = "report_no")
+ private String reportNo;
+
+ /**
+ * 样品名称
+ */
+ @TableField(value = "sample_name")
+ private String sampleName;
+
+ /**
+ * 样品类型
+ */
+ @TableField(value = "sample_type")
+ private String sampleType;
+
+ /**
+ * 检测项目
+ */
+ @TableField(value = "test_item")
+ private String testItem;
+
+ /**
+ * 检测标准编号
+ */
+ @TableField(value = "test_standard")
+ private String testStandard;
+
+ /**
+ * 委托单位
+ */
+ @TableField(value = "entrust_unit")
+ private String entrustUnit;
+
+ /**
+ * 报告日期
+ */
+ @TableField(value = "report_date")
+ private LocalDate reportDate;
+
+ /**
+ * 检测日期
+ */
+ @TableField(value = "test_date")
+ private LocalDate testDate;
+
+ /**
+ * 主要检测结果(简要)
+ */
+ @TableField(value = "result_summary")
+ private String resultSummary;
+
+ /**
+ * 综合结论(1=合格,0=不合格)
+ */
+ @TableField(value = "result_flag")
+ private Integer resultFlag;
+
+ /**
+ * 是否已导出台账(0=否,1=是)
+ */
+ @TableField(value = "export_flag")
+ private Integer exportFlag;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ RecordLedger other = (RecordLedger) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getReportId() == null ? other.getReportId() == null : this.getReportId().equals(other.getReportId()))
+ && (this.getOrgId() == null ? other.getOrgId() == null : this.getOrgId().equals(other.getOrgId()))
+ && (this.getLedgerNo() == null ? other.getLedgerNo() == null : this.getLedgerNo().equals(other.getLedgerNo()))
+ && (this.getReportNo() == null ? other.getReportNo() == null : this.getReportNo().equals(other.getReportNo()))
+ && (this.getSampleName() == null ? other.getSampleName() == null : this.getSampleName().equals(other.getSampleName()))
+ && (this.getSampleType() == null ? other.getSampleType() == null : this.getSampleType().equals(other.getSampleType()))
+ && (this.getTestItem() == null ? other.getTestItem() == null : this.getTestItem().equals(other.getTestItem()))
+ && (this.getTestStandard() == null ? other.getTestStandard() == null : this.getTestStandard().equals(other.getTestStandard()))
+ && (this.getEntrustUnit() == null ? other.getEntrustUnit() == null : this.getEntrustUnit().equals(other.getEntrustUnit()))
+ && (this.getReportDate() == null ? other.getReportDate() == null : this.getReportDate().equals(other.getReportDate()))
+ && (this.getTestDate() == null ? other.getTestDate() == null : this.getTestDate().equals(other.getTestDate()))
+ && (this.getResultSummary() == null ? other.getResultSummary() == null : this.getResultSummary().equals(other.getResultSummary()))
+ && (this.getResultFlag() == null ? other.getResultFlag() == null : this.getResultFlag().equals(other.getResultFlag()))
+ && (this.getExportFlag() == null ? other.getExportFlag() == null : this.getExportFlag().equals(other.getExportFlag()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getReportId() == null) ? 0 : getReportId().hashCode());
+ result = prime * result + ((getOrgId() == null) ? 0 : getOrgId().hashCode());
+ result = prime * result + ((getLedgerNo() == null) ? 0 : getLedgerNo().hashCode());
+ result = prime * result + ((getReportNo() == null) ? 0 : getReportNo().hashCode());
+ result = prime * result + ((getSampleName() == null) ? 0 : getSampleName().hashCode());
+ result = prime * result + ((getSampleType() == null) ? 0 : getSampleType().hashCode());
+ result = prime * result + ((getTestItem() == null) ? 0 : getTestItem().hashCode());
+ result = prime * result + ((getTestStandard() == null) ? 0 : getTestStandard().hashCode());
+ result = prime * result + ((getEntrustUnit() == null) ? 0 : getEntrustUnit().hashCode());
+ result = prime * result + ((getReportDate() == null) ? 0 : getReportDate().hashCode());
+ result = prime * result + ((getTestDate() == null) ? 0 : getTestDate().hashCode());
+ result = prime * result + ((getResultSummary() == null) ? 0 : getResultSummary().hashCode());
+ result = prime * result + ((getResultFlag() == null) ? 0 : getResultFlag().hashCode());
+ result = prime * result + ((getExportFlag() == null) ? 0 : getExportFlag().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", reportId=").append(reportId);
+ sb.append(", orgId=").append(orgId);
+ sb.append(", ledgerNo=").append(ledgerNo);
+ sb.append(", reportNo=").append(reportNo);
+ sb.append(", sampleName=").append(sampleName);
+ sb.append(", sampleType=").append(sampleType);
+ sb.append(", testItem=").append(testItem);
+ sb.append(", testStandard=").append(testStandard);
+ sb.append(", entrustUnit=").append(entrustUnit);
+ sb.append(", reportDate=").append(reportDate);
+ sb.append(", testDate=").append(testDate);
+ sb.append(", resultSummary=").append(resultSummary);
+ sb.append(", resultFlag=").append(resultFlag);
+ sb.append(", exportFlag=").append(exportFlag);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/RecordReport.java b/src/main/java/com/dc/dc_project/model/pojo/RecordReport.java
new file mode 100644
index 0000000..917d998
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/RecordReport.java
@@ -0,0 +1,157 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDate;
+import java.time.LocalDateTime;
+
+/**
+ * 检测报告表
+ * @TableName sys_record_report
+ */
+@TableName(value ="sys_record_report")
+@Data
+public class RecordReport {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 报告编号
+ */
+ @TableField(value = "report_no")
+ private String reportNo;
+
+ /**
+ * 委托单ID
+ */
+ @TableField(value = "entrust_id")
+ private Long entrustId;
+
+ /**
+ * 报告签发日期
+ */
+ @TableField(value = "issue_date")
+ private LocalDate issueDate;
+
+ /**
+ * 审核人ID
+ */
+ @TableField(value = "reviewer_id")
+ private Long reviewerId;
+
+ /**
+ * 批准人ID
+ */
+ @TableField(value = "approver_id")
+ private Long approverId;
+
+ /**
+ * 状态(0=草稿,1=待审核,2=已签发,3=已归档)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 综合结论(合格/不合格)
+ */
+ @TableField(value = "conclusion")
+ private String conclusion;
+
+ /**
+ * 报告PDF路径
+ */
+ @TableField(value = "file_url")
+ private String fileUrl;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ RecordReport other = (RecordReport) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getReportNo() == null ? other.getReportNo() == null : this.getReportNo().equals(other.getReportNo()))
+ && (this.getEntrustId() == null ? other.getEntrustId() == null : this.getEntrustId().equals(other.getEntrustId()))
+ && (this.getIssueDate() == null ? other.getIssueDate() == null : this.getIssueDate().equals(other.getIssueDate()))
+ && (this.getReviewerId() == null ? other.getReviewerId() == null : this.getReviewerId().equals(other.getReviewerId()))
+ && (this.getApproverId() == null ? other.getApproverId() == null : this.getApproverId().equals(other.getApproverId()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getConclusion() == null ? other.getConclusion() == null : this.getConclusion().equals(other.getConclusion()))
+ && (this.getFileUrl() == null ? other.getFileUrl() == null : this.getFileUrl().equals(other.getFileUrl()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getReportNo() == null) ? 0 : getReportNo().hashCode());
+ result = prime * result + ((getEntrustId() == null) ? 0 : getEntrustId().hashCode());
+ result = prime * result + ((getIssueDate() == null) ? 0 : getIssueDate().hashCode());
+ result = prime * result + ((getReviewerId() == null) ? 0 : getReviewerId().hashCode());
+ result = prime * result + ((getApproverId() == null) ? 0 : getApproverId().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getConclusion() == null) ? 0 : getConclusion().hashCode());
+ result = prime * result + ((getFileUrl() == null) ? 0 : getFileUrl().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", reportNo=").append(reportNo);
+ sb.append(", entrustId=").append(entrustId);
+ sb.append(", issueDate=").append(issueDate);
+ sb.append(", reviewerId=").append(reviewerId);
+ sb.append(", approverId=").append(approverId);
+ sb.append(", status=").append(status);
+ sb.append(", conclusion=").append(conclusion);
+ sb.append(", fileUrl=").append(fileUrl);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/RecordResult.java b/src/main/java/com/dc/dc_project/model/pojo/RecordResult.java
new file mode 100644
index 0000000..affb5bc
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/RecordResult.java
@@ -0,0 +1,166 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.math.BigDecimal;
+import java.time.LocalDateTime;
+
+/**
+ * 检测结果表(支持参数层级结构)
+ * @TableName sys_record_result
+ */
+@TableName(value ="sys_record_result")
+@Data
+public class RecordResult {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 检测记录ID
+ */
+ @TableField(value = "record_id")
+ private Long recordId;
+
+ /**
+ * 参数ID(lab_standard_param.id)
+ */
+ @TableField(value = "param_id")
+ private Long paramId;
+
+ /**
+ * 父结果ID(层级关系)
+ */
+ @TableField(value = "parent_result_id")
+ private Long parentResultId;
+
+ /**
+ * 参数名称
+ */
+ @TableField(value = "param_name")
+ private String paramName;
+
+ /**
+ * 单位
+ */
+ @TableField(value = "unit")
+ private String unit;
+
+ /**
+ * 实测值
+ */
+ @TableField(value = "measured_value")
+ private BigDecimal measuredValue;
+
+ /**
+ * 判定类型(1=≥min,2=≤max,3=区间)
+ */
+ @TableField(value = "judge_type")
+ private Integer judgeType;
+
+ /**
+ * 标准下限
+ */
+ @TableField(value = "min_value")
+ private BigDecimal minValue;
+
+ /**
+ * 标准上限
+ */
+ @TableField(value = "max_value")
+ private BigDecimal maxValue;
+
+ /**
+ * 判定结果(1=合格,0=不合格)
+ */
+ @TableField(value = "result_flag")
+ private Integer resultFlag;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ RecordResult other = (RecordResult) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getRecordId() == null ? other.getRecordId() == null : this.getRecordId().equals(other.getRecordId()))
+ && (this.getParamId() == null ? other.getParamId() == null : this.getParamId().equals(other.getParamId()))
+ && (this.getParentResultId() == null ? other.getParentResultId() == null : this.getParentResultId().equals(other.getParentResultId()))
+ && (this.getParamName() == null ? other.getParamName() == null : this.getParamName().equals(other.getParamName()))
+ && (this.getUnit() == null ? other.getUnit() == null : this.getUnit().equals(other.getUnit()))
+ && (this.getMeasuredValue() == null ? other.getMeasuredValue() == null : this.getMeasuredValue().equals(other.getMeasuredValue()))
+ && (this.getJudgeType() == null ? other.getJudgeType() == null : this.getJudgeType().equals(other.getJudgeType()))
+ && (this.getMinValue() == null ? other.getMinValue() == null : this.getMinValue().equals(other.getMinValue()))
+ && (this.getMaxValue() == null ? other.getMaxValue() == null : this.getMaxValue().equals(other.getMaxValue()))
+ && (this.getResultFlag() == null ? other.getResultFlag() == null : this.getResultFlag().equals(other.getResultFlag()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getRecordId() == null) ? 0 : getRecordId().hashCode());
+ result = prime * result + ((getParamId() == null) ? 0 : getParamId().hashCode());
+ result = prime * result + ((getParentResultId() == null) ? 0 : getParentResultId().hashCode());
+ result = prime * result + ((getParamName() == null) ? 0 : getParamName().hashCode());
+ result = prime * result + ((getUnit() == null) ? 0 : getUnit().hashCode());
+ result = prime * result + ((getMeasuredValue() == null) ? 0 : getMeasuredValue().hashCode());
+ result = prime * result + ((getJudgeType() == null) ? 0 : getJudgeType().hashCode());
+ result = prime * result + ((getMinValue() == null) ? 0 : getMinValue().hashCode());
+ result = prime * result + ((getMaxValue() == null) ? 0 : getMaxValue().hashCode());
+ result = prime * result + ((getResultFlag() == null) ? 0 : getResultFlag().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", recordId=").append(recordId);
+ sb.append(", paramId=").append(paramId);
+ sb.append(", parentResultId=").append(parentResultId);
+ sb.append(", paramName=").append(paramName);
+ sb.append(", unit=").append(unit);
+ sb.append(", measuredValue=").append(measuredValue);
+ sb.append(", judgeType=").append(judgeType);
+ sb.append(", minValue=").append(minValue);
+ sb.append(", maxValue=").append(maxValue);
+ sb.append(", resultFlag=").append(resultFlag);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/RecordSample.java b/src/main/java/com/dc/dc_project/model/pojo/RecordSample.java
new file mode 100644
index 0000000..3235564
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/RecordSample.java
@@ -0,0 +1,211 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDate;
+import java.time.LocalDateTime;
+
+/**
+ * 检测样品信息表
+ * @TableName sys_record_sample
+ */
+@TableName(value ="sys_record_sample")
+@Data
+public class RecordSample {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 所属委托单ID
+ */
+ @TableField(value = "entrust_id")
+ private Long entrustId;
+
+ /**
+ * 样品编号(系统生成或手动录入)
+ */
+ @TableField(value = "sample_code")
+ private String sampleCode;
+
+ /**
+ * 样品名称(如 混凝土试块)
+ */
+ @TableField(value = "sample_name")
+ private String sampleName;
+
+ /**
+ * 样品类型(如 混凝土/砂/钢筋)
+ */
+ @TableField(value = "sample_type")
+ private String sampleType;
+
+ /**
+ * 取样日期
+ */
+ @TableField(value = "sampling_date")
+ private LocalDate samplingDate;
+
+ /**
+ * 取样点(如 墩身承台、梁板区等)
+ */
+ @TableField(value = "sampling_point")
+ private String samplingPoint;
+
+ /**
+ * 取样部位(如 主梁下缘)
+ */
+ @TableField(value = "sampling_position")
+ private String samplingPosition;
+
+ /**
+ * 代表数量(试件组数等)
+ */
+ @TableField(value = "representative_count")
+ private Integer representativeCount;
+
+ /**
+ * 样品状态或描述(如 外观、湿度)
+ */
+ @TableField(value = "condition_desc")
+ private String conditionDesc;
+
+ /**
+ * 样品存放位置
+ */
+ @TableField(value = "storage_location")
+ private String storageLocation;
+
+ /**
+ * 状态(0=待检测,1=检测中,2=检测完成)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建人ID
+ */
+ @TableField(value = "created_by")
+ private Long createdBy;
+
+ /**
+ * 更新人ID
+ */
+ @TableField(value = "updated_by")
+ private Long updatedBy;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除标志
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ RecordSample other = (RecordSample) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getEntrustId() == null ? other.getEntrustId() == null : this.getEntrustId().equals(other.getEntrustId()))
+ && (this.getSampleCode() == null ? other.getSampleCode() == null : this.getSampleCode().equals(other.getSampleCode()))
+ && (this.getSampleName() == null ? other.getSampleName() == null : this.getSampleName().equals(other.getSampleName()))
+ && (this.getSampleType() == null ? other.getSampleType() == null : this.getSampleType().equals(other.getSampleType()))
+ && (this.getSamplingDate() == null ? other.getSamplingDate() == null : this.getSamplingDate().equals(other.getSamplingDate()))
+ && (this.getSamplingPoint() == null ? other.getSamplingPoint() == null : this.getSamplingPoint().equals(other.getSamplingPoint()))
+ && (this.getSamplingPosition() == null ? other.getSamplingPosition() == null : this.getSamplingPosition().equals(other.getSamplingPosition()))
+ && (this.getRepresentativeCount() == null ? other.getRepresentativeCount() == null : this.getRepresentativeCount().equals(other.getRepresentativeCount()))
+ && (this.getConditionDesc() == null ? other.getConditionDesc() == null : this.getConditionDesc().equals(other.getConditionDesc()))
+ && (this.getStorageLocation() == null ? other.getStorageLocation() == null : this.getStorageLocation().equals(other.getStorageLocation()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()))
+ && (this.getUpdatedBy() == null ? other.getUpdatedBy() == null : this.getUpdatedBy().equals(other.getUpdatedBy()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getEntrustId() == null) ? 0 : getEntrustId().hashCode());
+ result = prime * result + ((getSampleCode() == null) ? 0 : getSampleCode().hashCode());
+ result = prime * result + ((getSampleName() == null) ? 0 : getSampleName().hashCode());
+ result = prime * result + ((getSampleType() == null) ? 0 : getSampleType().hashCode());
+ result = prime * result + ((getSamplingDate() == null) ? 0 : getSamplingDate().hashCode());
+ result = prime * result + ((getSamplingPoint() == null) ? 0 : getSamplingPoint().hashCode());
+ result = prime * result + ((getSamplingPosition() == null) ? 0 : getSamplingPosition().hashCode());
+ result = prime * result + ((getRepresentativeCount() == null) ? 0 : getRepresentativeCount().hashCode());
+ result = prime * result + ((getConditionDesc() == null) ? 0 : getConditionDesc().hashCode());
+ result = prime * result + ((getStorageLocation() == null) ? 0 : getStorageLocation().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ result = prime * result + ((getUpdatedBy() == null) ? 0 : getUpdatedBy().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", entrustId=").append(entrustId);
+ sb.append(", sampleCode=").append(sampleCode);
+ sb.append(", sampleName=").append(sampleName);
+ sb.append(", sampleType=").append(sampleType);
+ sb.append(", samplingDate=").append(samplingDate);
+ sb.append(", samplingPoint=").append(samplingPoint);
+ sb.append(", samplingPosition=").append(samplingPosition);
+ sb.append(", representativeCount=").append(representativeCount);
+ sb.append(", conditionDesc=").append(conditionDesc);
+ sb.append(", storageLocation=").append(storageLocation);
+ sb.append(", status=").append(status);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append(", updatedBy=").append(updatedBy);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/Role.java b/src/main/java/com/dc/dc_project/model/pojo/Role.java
new file mode 100644
index 0000000..3997a83
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/Role.java
@@ -0,0 +1,129 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 系统角色表
+ * @TableName sys_role
+ */
+@TableName(value ="sys_role")
+@Data
+public class Role {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 角色名称
+ */
+ @TableField(value = "name")
+ private String name;
+
+ /**
+ * 角色编码(英文标识)
+ */
+ @TableField(value = "code")
+ private String code;
+
+ /**
+ * 角色层级(1=公司级,2=项目部级,3=试验室级)
+ */
+ @TableField(value = "level")
+ private Integer level;
+
+ /**
+ * 角色状态(0=停用,1=启用)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 角色描述
+ */
+ @TableField(value = "description")
+ private String description;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除标志
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ Role other = (Role) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
+ && (this.getCode() == null ? other.getCode() == null : this.getCode().equals(other.getCode()))
+ && (this.getLevel() == null ? other.getLevel() == null : this.getLevel().equals(other.getLevel()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getDescription() == null ? other.getDescription() == null : this.getDescription().equals(other.getDescription()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
+ result = prime * result + ((getCode() == null) ? 0 : getCode().hashCode());
+ result = prime * result + ((getLevel() == null) ? 0 : getLevel().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getDescription() == null) ? 0 : getDescription().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", name=").append(name);
+ sb.append(", code=").append(code);
+ sb.append(", level=").append(level);
+ sb.append(", status=").append(status);
+ sb.append(", description=").append(description);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/RoleOrg.java b/src/main/java/com/dc/dc_project/model/pojo/RoleOrg.java
new file mode 100644
index 0000000..7a9fc22
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/RoleOrg.java
@@ -0,0 +1,93 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 角色-组织关系表
+ * @TableName sys_role_org
+ */
+@TableName(value ="sys_role_org")
+@Data
+public class RoleOrg {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 角色ID
+ */
+ @TableField(value = "role_id")
+ private Long roleId;
+
+ /**
+ * 组织ID(作用范围)
+ */
+ @TableField(value = "org_id")
+ private Long orgId;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 创建人
+ */
+ @TableField(value = "created_by")
+ private String createdBy;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ RoleOrg other = (RoleOrg) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getRoleId() == null ? other.getRoleId() == null : this.getRoleId().equals(other.getRoleId()))
+ && (this.getOrgId() == null ? other.getOrgId() == null : this.getOrgId().equals(other.getOrgId()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getRoleId() == null) ? 0 : getRoleId().hashCode());
+ result = prime * result + ((getOrgId() == null) ? 0 : getOrgId().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", roleId=").append(roleId);
+ sb.append(", orgId=").append(orgId);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/RolePermission.java b/src/main/java/com/dc/dc_project/model/pojo/RolePermission.java
new file mode 100644
index 0000000..bdc4b2d
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/RolePermission.java
@@ -0,0 +1,93 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 角色-权限关系表
+ * @TableName sys_role_permission
+ */
+@TableName(value ="sys_role_permission")
+@Data
+public class RolePermission {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 角色ID
+ */
+ @TableField(value = "role_id")
+ private Long roleId;
+
+ /**
+ * 权限ID
+ */
+ @TableField(value = "permission_id")
+ private Long permissionId;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 创建人
+ */
+ @TableField(value = "created_by")
+ private String createdBy;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ RolePermission other = (RolePermission) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getRoleId() == null ? other.getRoleId() == null : this.getRoleId().equals(other.getRoleId()))
+ && (this.getPermissionId() == null ? other.getPermissionId() == null : this.getPermissionId().equals(other.getPermissionId()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getRoleId() == null) ? 0 : getRoleId().hashCode());
+ result = prime * result + ((getPermissionId() == null) ? 0 : getPermissionId().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", roleId=").append(roleId);
+ sb.append(", permissionId=").append(permissionId);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/Standard.java b/src/main/java/com/dc/dc_project/model/pojo/Standard.java
new file mode 100644
index 0000000..7211fe6
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/Standard.java
@@ -0,0 +1,228 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 检测标准主表
+ * @TableName sys_standard
+ */
+@TableName(value ="sys_standard")
+@Data
+public class Standard {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 所属分类ID(lab_standard_category.id)
+ */
+ @TableField(value = "category_id")
+ private Long categoryId;
+
+ /**
+ * 标准编号(如 GB/T 50082-2009)
+ */
+ @TableField(value = "code")
+ private String code;
+
+ /**
+ * 标准名称
+ */
+ @TableField(value = "name")
+ private String name;
+
+ /**
+ * 发布日期
+ */
+ @TableField(value = "publish_date")
+ private LocalDateTime publishDate;
+
+ /**
+ * 实施日期
+ */
+ @TableField(value = "effective_date")
+ private LocalDateTime effectiveDate;
+
+ /**
+ * 废止日期(如已失效)
+ */
+ @TableField(value = "abolish_date")
+ private LocalDateTime abolishDate;
+
+ /**
+ * 来源类型(1=内部标准,2=外委标准,3=外部导入)
+ */
+ @TableField(value = "source_type")
+ private Integer sourceType;
+
+ /**
+ * 状态(0=废止,1=有效,2=即将废止)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 版本号或年号(如 2019版)
+ */
+ @TableField(value = "version_no")
+ private String versionNo;
+
+ /**
+ * 外部链接(如工标网地址)
+ */
+ @TableField(value = "url")
+ private String url;
+
+ /**
+ * 是否有附件文件(sys_file中记录)
+ */
+ @TableField(value = "has_file")
+ private Integer hasFile;
+
+ /**
+ * 更新周期(月),用于提醒
+ */
+ @TableField(value = "update_cycle")
+ private Integer updateCycle;
+
+ /**
+ * 下次查新日期
+ */
+ @TableField(value = "next_check_date")
+ private LocalDateTime nextCheckDate;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建人ID
+ */
+ @TableField(value = "created_by")
+ private Long createdBy;
+
+ /**
+ * 更新人ID
+ */
+ @TableField(value = "updated_by")
+ private Long updatedBy;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ Standard other = (Standard) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getCategoryId() == null ? other.getCategoryId() == null : this.getCategoryId().equals(other.getCategoryId()))
+ && (this.getCode() == null ? other.getCode() == null : this.getCode().equals(other.getCode()))
+ && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
+ && (this.getPublishDate() == null ? other.getPublishDate() == null : this.getPublishDate().equals(other.getPublishDate()))
+ && (this.getEffectiveDate() == null ? other.getEffectiveDate() == null : this.getEffectiveDate().equals(other.getEffectiveDate()))
+ && (this.getAbolishDate() == null ? other.getAbolishDate() == null : this.getAbolishDate().equals(other.getAbolishDate()))
+ && (this.getSourceType() == null ? other.getSourceType() == null : this.getSourceType().equals(other.getSourceType()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getVersionNo() == null ? other.getVersionNo() == null : this.getVersionNo().equals(other.getVersionNo()))
+ && (this.getUrl() == null ? other.getUrl() == null : this.getUrl().equals(other.getUrl()))
+ && (this.getHasFile() == null ? other.getHasFile() == null : this.getHasFile().equals(other.getHasFile()))
+ && (this.getUpdateCycle() == null ? other.getUpdateCycle() == null : this.getUpdateCycle().equals(other.getUpdateCycle()))
+ && (this.getNextCheckDate() == null ? other.getNextCheckDate() == null : this.getNextCheckDate().equals(other.getNextCheckDate()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()))
+ && (this.getUpdatedBy() == null ? other.getUpdatedBy() == null : this.getUpdatedBy().equals(other.getUpdatedBy()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getCategoryId() == null) ? 0 : getCategoryId().hashCode());
+ result = prime * result + ((getCode() == null) ? 0 : getCode().hashCode());
+ result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
+ result = prime * result + ((getPublishDate() == null) ? 0 : getPublishDate().hashCode());
+ result = prime * result + ((getEffectiveDate() == null) ? 0 : getEffectiveDate().hashCode());
+ result = prime * result + ((getAbolishDate() == null) ? 0 : getAbolishDate().hashCode());
+ result = prime * result + ((getSourceType() == null) ? 0 : getSourceType().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getVersionNo() == null) ? 0 : getVersionNo().hashCode());
+ result = prime * result + ((getUrl() == null) ? 0 : getUrl().hashCode());
+ result = prime * result + ((getHasFile() == null) ? 0 : getHasFile().hashCode());
+ result = prime * result + ((getUpdateCycle() == null) ? 0 : getUpdateCycle().hashCode());
+ result = prime * result + ((getNextCheckDate() == null) ? 0 : getNextCheckDate().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ result = prime * result + ((getUpdatedBy() == null) ? 0 : getUpdatedBy().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", categoryId=").append(categoryId);
+ sb.append(", code=").append(code);
+ sb.append(", name=").append(name);
+ sb.append(", publishDate=").append(publishDate);
+ sb.append(", effectiveDate=").append(effectiveDate);
+ sb.append(", abolishDate=").append(abolishDate);
+ sb.append(", sourceType=").append(sourceType);
+ sb.append(", status=").append(status);
+ sb.append(", versionNo=").append(versionNo);
+ sb.append(", url=").append(url);
+ sb.append(", hasFile=").append(hasFile);
+ sb.append(", updateCycle=").append(updateCycle);
+ sb.append(", nextCheckDate=").append(nextCheckDate);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append(", updatedBy=").append(updatedBy);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/StandardCategory.java b/src/main/java/com/dc/dc_project/model/pojo/StandardCategory.java
new file mode 100644
index 0000000..65d2734
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/StandardCategory.java
@@ -0,0 +1,129 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 标准分类表(行业/专业领域)
+ * @TableName sys_standard_category
+ */
+@TableName(value ="sys_standard_category")
+@Data
+public class StandardCategory {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 上级分类ID
+ */
+ @TableField(value = "parent_id")
+ private Long parentId;
+
+ /**
+ * 分类名称(如水利、电力、公路等)
+ */
+ @TableField(value = "name")
+ private String name;
+
+ /**
+ * 分类编码(可用于同步外部标准库)
+ */
+ @TableField(value = "code")
+ private String code;
+
+ /**
+ * 排序号
+ */
+ @TableField(value = "sort_order")
+ private Integer sortOrder;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ StandardCategory other = (StandardCategory) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getParentId() == null ? other.getParentId() == null : this.getParentId().equals(other.getParentId()))
+ && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
+ && (this.getCode() == null ? other.getCode() == null : this.getCode().equals(other.getCode()))
+ && (this.getSortOrder() == null ? other.getSortOrder() == null : this.getSortOrder().equals(other.getSortOrder()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getParentId() == null) ? 0 : getParentId().hashCode());
+ result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
+ result = prime * result + ((getCode() == null) ? 0 : getCode().hashCode());
+ result = prime * result + ((getSortOrder() == null) ? 0 : getSortOrder().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", parentId=").append(parentId);
+ sb.append(", name=").append(name);
+ sb.append(", code=").append(code);
+ sb.append(", sortOrder=").append(sortOrder);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/StandardParam.java b/src/main/java/com/dc/dc_project/model/pojo/StandardParam.java
new file mode 100644
index 0000000..e6f67e0
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/StandardParam.java
@@ -0,0 +1,229 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.math.BigDecimal;
+import java.time.LocalDateTime;
+
+/**
+ * 标准参数表(检测项目与合格判定规则)
+ * @TableName sys_standard_param
+ */
+@TableName(value ="sys_standard_param")
+@Data
+public class StandardParam {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 所属标准ID(lab_standard.id)
+ */
+ @TableField(value = "standard_id")
+ private Long standardId;
+
+ /**
+ * 参数编码(系统内部编码,可选)
+ */
+ @TableField(value = "param_code")
+ private String paramCode;
+
+ /**
+ * 检测参数名称(如 抗压强度)
+ */
+ @TableField(value = "param_name")
+ private String paramName;
+
+ /**
+ * 参数别名(可用于报告显示)
+ */
+ @TableField(value = "param_alias")
+ private String paramAlias;
+
+ /**
+ * 参数单位(如 MPa, %, g/cm³)
+ */
+ @TableField(value = "unit")
+ private String unit;
+
+ /**
+ * 下限值(如 ≥3)
+ */
+ @TableField(value = "min_value")
+ private BigDecimal minValue;
+
+ /**
+ * 上限值(如 ≤10)
+ */
+ @TableField(value = "max_value")
+ private BigDecimal maxValue;
+
+ /**
+ * 判定类型(1=≥min, 2=≤max, 3=范围[min,max], 4=等于, 5=不等于)
+ */
+ @TableField(value = "judge_type")
+ private Integer judgeType;
+
+ /**
+ * 参考值或设计值(可选)
+ */
+ @TableField(value = "default_value")
+ private BigDecimal defaultValue;
+
+ /**
+ * 结果保留小数位数
+ */
+ @TableField(value = "precision_scale")
+ private Integer precisionScale;
+
+ /**
+ * 检测方法描述(如 28天抗压试验)
+ */
+ @TableField(value = "method_desc")
+ private String methodDesc;
+
+ /**
+ * 判定规则文字说明(如 “≥30MPa 为合格”)
+ */
+ @TableField(value = "judge_rule")
+ private String judgeRule;
+
+ /**
+ * 分组编号(用于区分不同材料、项目组)
+ */
+ @TableField(value = "group_code")
+ private String groupCode;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建人ID
+ */
+ @TableField(value = "created_by")
+ private Long createdBy;
+
+ /**
+ * 更新人ID
+ */
+ @TableField(value = "updated_by")
+ private Long updatedBy;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除(0=正常,1=删除)
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ StandardParam other = (StandardParam) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getStandardId() == null ? other.getStandardId() == null : this.getStandardId().equals(other.getStandardId()))
+ && (this.getParamCode() == null ? other.getParamCode() == null : this.getParamCode().equals(other.getParamCode()))
+ && (this.getParamName() == null ? other.getParamName() == null : this.getParamName().equals(other.getParamName()))
+ && (this.getParamAlias() == null ? other.getParamAlias() == null : this.getParamAlias().equals(other.getParamAlias()))
+ && (this.getUnit() == null ? other.getUnit() == null : this.getUnit().equals(other.getUnit()))
+ && (this.getMinValue() == null ? other.getMinValue() == null : this.getMinValue().equals(other.getMinValue()))
+ && (this.getMaxValue() == null ? other.getMaxValue() == null : this.getMaxValue().equals(other.getMaxValue()))
+ && (this.getJudgeType() == null ? other.getJudgeType() == null : this.getJudgeType().equals(other.getJudgeType()))
+ && (this.getDefaultValue() == null ? other.getDefaultValue() == null : this.getDefaultValue().equals(other.getDefaultValue()))
+ && (this.getPrecisionScale() == null ? other.getPrecisionScale() == null : this.getPrecisionScale().equals(other.getPrecisionScale()))
+ && (this.getMethodDesc() == null ? other.getMethodDesc() == null : this.getMethodDesc().equals(other.getMethodDesc()))
+ && (this.getJudgeRule() == null ? other.getJudgeRule() == null : this.getJudgeRule().equals(other.getJudgeRule()))
+ && (this.getGroupCode() == null ? other.getGroupCode() == null : this.getGroupCode().equals(other.getGroupCode()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()))
+ && (this.getUpdatedBy() == null ? other.getUpdatedBy() == null : this.getUpdatedBy().equals(other.getUpdatedBy()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getStandardId() == null) ? 0 : getStandardId().hashCode());
+ result = prime * result + ((getParamCode() == null) ? 0 : getParamCode().hashCode());
+ result = prime * result + ((getParamName() == null) ? 0 : getParamName().hashCode());
+ result = prime * result + ((getParamAlias() == null) ? 0 : getParamAlias().hashCode());
+ result = prime * result + ((getUnit() == null) ? 0 : getUnit().hashCode());
+ result = prime * result + ((getMinValue() == null) ? 0 : getMinValue().hashCode());
+ result = prime * result + ((getMaxValue() == null) ? 0 : getMaxValue().hashCode());
+ result = prime * result + ((getJudgeType() == null) ? 0 : getJudgeType().hashCode());
+ result = prime * result + ((getDefaultValue() == null) ? 0 : getDefaultValue().hashCode());
+ result = prime * result + ((getPrecisionScale() == null) ? 0 : getPrecisionScale().hashCode());
+ result = prime * result + ((getMethodDesc() == null) ? 0 : getMethodDesc().hashCode());
+ result = prime * result + ((getJudgeRule() == null) ? 0 : getJudgeRule().hashCode());
+ result = prime * result + ((getGroupCode() == null) ? 0 : getGroupCode().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ result = prime * result + ((getUpdatedBy() == null) ? 0 : getUpdatedBy().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", standardId=").append(standardId);
+ sb.append(", paramCode=").append(paramCode);
+ sb.append(", paramName=").append(paramName);
+ sb.append(", paramAlias=").append(paramAlias);
+ sb.append(", unit=").append(unit);
+ sb.append(", minValue=").append(minValue);
+ sb.append(", maxValue=").append(maxValue);
+ sb.append(", judgeType=").append(judgeType);
+ sb.append(", defaultValue=").append(defaultValue);
+ sb.append(", precisionScale=").append(precisionScale);
+ sb.append(", methodDesc=").append(methodDesc);
+ sb.append(", judgeRule=").append(judgeRule);
+ sb.append(", groupCode=").append(groupCode);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append(", updatedBy=").append(updatedBy);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/User.java b/src/main/java/com/dc/dc_project/model/pojo/User.java
new file mode 100644
index 0000000..7e987f7
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/User.java
@@ -0,0 +1,174 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 系统用户表
+ * @TableName sys_user
+ */
+@TableName(value ="sys_user")
+@Data
+public class User {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 登录用户名
+ */
+ @TableField(value = "username")
+ private String username;
+
+ /**
+ * 登录密码(加密存储)
+ */
+ @TableField(value = "password")
+ private String password;
+
+ /**
+ * 真实姓名
+ */
+ @TableField(value = "real_name")
+ private String realName;
+
+ /**
+ * 性别(0=未知,1=男,2=女)
+ */
+ @TableField(value = "gender")
+ private Integer gender;
+
+ /**
+ * 联系电话
+ */
+ @TableField(value = "phone")
+ private String phone;
+
+ /**
+ * 邮箱地址
+ */
+ @TableField(value = "email")
+ private String email;
+
+ /**
+ * 所属组织ID
+ */
+ @TableField(value = "org_id")
+ private Long orgId;
+
+ /**
+ * 账户状态(0=停用,1=启用)
+ */
+ @TableField(value = "status")
+ private Integer status;
+
+ /**
+ * 最后登录时间
+ */
+ @TableField(value = "last_login_time")
+ private LocalDateTime lastLoginTime;
+
+ /**
+ * 备注
+ */
+ @TableField(value = "remark")
+ private String remark;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 更新时间
+ */
+ @TableField(value = "updated_at")
+ private LocalDateTime updatedAt;
+
+ /**
+ * 逻辑删除标志(0=正常,1=删除)
+ */
+ @TableField(value = "is_deleted")
+ private Integer isDeleted;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ User other = (User) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getUsername() == null ? other.getUsername() == null : this.getUsername().equals(other.getUsername()))
+ && (this.getPassword() == null ? other.getPassword() == null : this.getPassword().equals(other.getPassword()))
+ && (this.getRealName() == null ? other.getRealName() == null : this.getRealName().equals(other.getRealName()))
+ && (this.getGender() == null ? other.getGender() == null : this.getGender().equals(other.getGender()))
+ && (this.getPhone() == null ? other.getPhone() == null : this.getPhone().equals(other.getPhone()))
+ && (this.getEmail() == null ? other.getEmail() == null : this.getEmail().equals(other.getEmail()))
+ && (this.getOrgId() == null ? other.getOrgId() == null : this.getOrgId().equals(other.getOrgId()))
+ && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
+ && (this.getLastLoginTime() == null ? other.getLastLoginTime() == null : this.getLastLoginTime().equals(other.getLastLoginTime()))
+ && (this.getRemark() == null ? other.getRemark() == null : this.getRemark().equals(other.getRemark()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getUpdatedAt() == null ? other.getUpdatedAt() == null : this.getUpdatedAt().equals(other.getUpdatedAt()))
+ && (this.getIsDeleted() == null ? other.getIsDeleted() == null : this.getIsDeleted().equals(other.getIsDeleted()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getUsername() == null) ? 0 : getUsername().hashCode());
+ result = prime * result + ((getPassword() == null) ? 0 : getPassword().hashCode());
+ result = prime * result + ((getRealName() == null) ? 0 : getRealName().hashCode());
+ result = prime * result + ((getGender() == null) ? 0 : getGender().hashCode());
+ result = prime * result + ((getPhone() == null) ? 0 : getPhone().hashCode());
+ result = prime * result + ((getEmail() == null) ? 0 : getEmail().hashCode());
+ result = prime * result + ((getOrgId() == null) ? 0 : getOrgId().hashCode());
+ result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
+ result = prime * result + ((getLastLoginTime() == null) ? 0 : getLastLoginTime().hashCode());
+ result = prime * result + ((getRemark() == null) ? 0 : getRemark().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getUpdatedAt() == null) ? 0 : getUpdatedAt().hashCode());
+ result = prime * result + ((getIsDeleted() == null) ? 0 : getIsDeleted().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", username=").append(username);
+ sb.append(", password=").append(password);
+ sb.append(", realName=").append(realName);
+ sb.append(", gender=").append(gender);
+ sb.append(", phone=").append(phone);
+ sb.append(", email=").append(email);
+ sb.append(", orgId=").append(orgId);
+ sb.append(", status=").append(status);
+ sb.append(", lastLoginTime=").append(lastLoginTime);
+ sb.append(", remark=").append(remark);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", updatedAt=").append(updatedAt);
+ sb.append(", isDeleted=").append(isDeleted);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/java/com/dc/dc_project/model/pojo/UserRole.java b/src/main/java/com/dc/dc_project/model/pojo/UserRole.java
new file mode 100644
index 0000000..d79a23a
--- /dev/null
+++ b/src/main/java/com/dc/dc_project/model/pojo/UserRole.java
@@ -0,0 +1,93 @@
+package com.dc.dc_project.model.pojo;
+
+import com.baomidou.mybatisplus.annotation.IdType;
+import com.baomidou.mybatisplus.annotation.TableField;
+import com.baomidou.mybatisplus.annotation.TableId;
+import com.baomidou.mybatisplus.annotation.TableName;
+import lombok.Data;
+
+import java.time.LocalDateTime;
+
+/**
+ * 用户-角色关系表
+ * @TableName sys_user_role
+ */
+@TableName(value ="sys_user_role")
+@Data
+public class UserRole {
+ /**
+ * 主键ID
+ */
+ @TableId(value = "id", type = IdType.AUTO)
+ private Long id;
+
+ /**
+ * 用户ID
+ */
+ @TableField(value = "user_id")
+ private Long userId;
+
+ /**
+ * 角色ID
+ */
+ @TableField(value = "role_id")
+ private Long roleId;
+
+ /**
+ * 创建时间
+ */
+ @TableField(value = "created_at")
+ private LocalDateTime createdAt;
+
+ /**
+ * 创建人
+ */
+ @TableField(value = "created_by")
+ private String createdBy;
+
+ @Override
+ public boolean equals(Object that) {
+ if (this == that) {
+ return true;
+ }
+ if (that == null) {
+ return false;
+ }
+ if (getClass() != that.getClass()) {
+ return false;
+ }
+ UserRole other = (UserRole) that;
+ return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
+ && (this.getUserId() == null ? other.getUserId() == null : this.getUserId().equals(other.getUserId()))
+ && (this.getRoleId() == null ? other.getRoleId() == null : this.getRoleId().equals(other.getRoleId()))
+ && (this.getCreatedAt() == null ? other.getCreatedAt() == null : this.getCreatedAt().equals(other.getCreatedAt()))
+ && (this.getCreatedBy() == null ? other.getCreatedBy() == null : this.getCreatedBy().equals(other.getCreatedBy()));
+ }
+
+ @Override
+ public int hashCode() {
+ final int prime = 31;
+ int result = 1;
+ result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
+ result = prime * result + ((getUserId() == null) ? 0 : getUserId().hashCode());
+ result = prime * result + ((getRoleId() == null) ? 0 : getRoleId().hashCode());
+ result = prime * result + ((getCreatedAt() == null) ? 0 : getCreatedAt().hashCode());
+ result = prime * result + ((getCreatedBy() == null) ? 0 : getCreatedBy().hashCode());
+ return result;
+ }
+
+ @Override
+ public String toString() {
+ StringBuilder sb = new StringBuilder();
+ sb.append(getClass().getSimpleName());
+ sb.append(" [");
+ sb.append("Hash = ").append(hashCode());
+ sb.append(", id=").append(id);
+ sb.append(", userId=").append(userId);
+ sb.append(", roleId=").append(roleId);
+ sb.append(", createdAt=").append(createdAt);
+ sb.append(", createdBy=").append(createdBy);
+ sb.append("]");
+ return sb.toString();
+ }
+}
\ No newline at end of file
diff --git a/src/main/resources/application.properties b/src/main/resources/application.properties
deleted file mode 100644
index 76da76d..0000000
--- a/src/main/resources/application.properties
+++ /dev/null
@@ -1 +0,0 @@
-spring.application.name=dc_project
diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml
index 1d6463e..c10abcf 100644
--- a/src/main/resources/application.yml
+++ b/src/main/resources/application.yml
@@ -16,20 +16,22 @@ spring:
datasource:
type: com.alibaba.druid.pool.DruidDataSource
driver-class-name: com.mysql.cj.jdbc.Driver
- url: jdbc:mysql://www.yuxindazhineng.com:3306/dc_lab_system?serverTimeZone=CST
+ url: jdbc:mysql://www.yuxindazhineng.com:3306/dc_lab_system?serverTimeZone=CST&allowPublicKeyRetrieval=true&allowMultiQueries=true
username: dc_admin
password: DC_yxd_admin@01
mybatis-plus:
- mapper-locations: classpath:/mappers/*.xml
+ mapper-locations: classpath:/mapper/*.xml
configuration:
default-enum-type-handler: com.baomidou.mybatisplus.core.handlers.MybatisEnumTypeHandler
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
map-underscore-to-camel-case: true
log-prefix: 'dc-'
- type-aliases-package: com.plm.common.vo
global-config:
enable-sql-runner: true
banner: false
+ db-config:
+ # 数据库配置
+ id-type: auto
sa-token:
token-name: token
token-style: random-128