Compare commits
87 Commits
d74f0cd354
...
prod
Author | SHA1 | Date | |
---|---|---|---|
a8d8a76fd2 | |||
a661d4f24c | |||
118b1820cf | |||
f44904a5f1 | |||
8326c3110f | |||
fa5dc0e7ac | |||
6bce3c3dea | |||
33de0ea8eb | |||
0233c59e32 | |||
b9bad1c006 | |||
1cc9186022 | |||
01678fda6a | |||
e706540fe3 | |||
55090acb64 | |||
9173e02471 | |||
7a9a648d9a | |||
92d5fefc26 | |||
5199f104b9 | |||
a716991576 | |||
bb7fa6f71e | |||
1a7ba72978 | |||
e4d1be276b | |||
f3d0db70f8 | |||
ee88d9ea09 | |||
604d1b6da2 | |||
3aa5c53149 | |||
55b96c059e | |||
84204a59a3 | |||
a6c915ce04 | |||
4ad8c2e20c | |||
5e86cb9b7d | |||
ad1ca2d429 | |||
baea1dc7ab | |||
71f18458d6 | |||
86f0f21f86 | |||
0eeab2aadf | |||
ede1b40039 | |||
7b9e3a52f0 | |||
054ecd92a1 | |||
3463845b13 | |||
0a0477977f | |||
fcf810ed7a | |||
ce68cca915 | |||
89e88a957f | |||
c159cda767 | |||
0b3652ff70 | |||
9cc4ce105e | |||
9212fb31a7 | |||
7a7a40b13e | |||
7657697d34 | |||
e7bbe2f1ca | |||
177fcd5f05 | |||
f030b825aa | |||
efb32a5367 | |||
1ed47f0ff3 | |||
7a72c1a4a2 | |||
a8f5c86ce9 | |||
18ad351010 | |||
0b1233339c | |||
d45b3cccb8 | |||
c6efc08650 | |||
e79c6b1ed3 | |||
dd6aafde0a | |||
d3bc55ea18 | |||
14abcc646b | |||
c2933c68a7 | |||
eaac167036 | |||
b9e9d6e855 | |||
d08bdea8ec | |||
6aed3167b3 | |||
71a9cfafa4 | |||
e89c99d2ca | |||
fe7a195362 | |||
ccfe6b8f3e | |||
aade077977 | |||
3dc6d94d60 | |||
67fa422218 | |||
888af08666 | |||
e623855b21 | |||
7b9176dff5 | |||
81f4284b9c | |||
d51c0402ff | |||
de2012140e | |||
c93565ad9c | |||
019af8a7ae | |||
67ff23e048 | |||
0f9e37b1a8 |
@ -6,6 +6,8 @@ import org.springframework.boot.context.metrics.buffering.BufferingApplicationSt
|
||||
import org.springframework.context.annotation.EnableAspectJAutoProxy;
|
||||
import org.springframework.scheduling.annotation.EnableAsync;
|
||||
import org.springframework.scheduling.annotation.EnableScheduling;
|
||||
import org.springframework.web.servlet.config.annotation.ResourceHandlerRegistry;
|
||||
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;
|
||||
|
||||
/**
|
||||
* 启动程序
|
||||
@ -16,7 +18,7 @@ import org.springframework.scheduling.annotation.EnableScheduling;
|
||||
@EnableAsync
|
||||
@EnableAspectJAutoProxy(proxyTargetClass = true, exposeProxy = true)
|
||||
@EnableScheduling
|
||||
public class DromaraApplication {
|
||||
public class DromaraApplication implements WebMvcConfigurer {
|
||||
|
||||
public static void main(String[] args) {
|
||||
SpringApplication application = new SpringApplication(DromaraApplication.class);
|
||||
@ -25,4 +27,10 @@ public class DromaraApplication {
|
||||
System.out.println("(♥◠‿◠)ノ゙ RuoYi-Vue-Plus启动成功 ლ(´ڡ`ლ)゙");
|
||||
}
|
||||
|
||||
@Override
|
||||
public void addResourceHandlers(ResourceHandlerRegistry registry) {
|
||||
registry.addResourceHandler("doc.html").addResourceLocations("classpath:/META-INF/resources/");
|
||||
registry.addResourceHandler("/webjars/**").addResourceLocations("classpath:/META-INF/resources/webjars/");
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -80,7 +80,7 @@ public class AuthController {
|
||||
* @param body 登录信息
|
||||
* @return 结果
|
||||
*/
|
||||
@ApiEncrypt
|
||||
// @ApiEncrypt
|
||||
@PostMapping("/login")
|
||||
public R<LoginVo> login(@RequestBody String body) {
|
||||
LoginBody loginBody = JsonUtils.parseObject(body, LoginBody.class);
|
||||
@ -183,7 +183,7 @@ public class AuthController {
|
||||
/**
|
||||
* 用户注册
|
||||
*/
|
||||
@ApiEncrypt
|
||||
// @ApiEncrypt
|
||||
@PostMapping("/register")
|
||||
public R<Void> register(@Validated @RequestBody RegisterBody user) {
|
||||
if (!configService.selectRegisterEnabled(user.getTenantId())) {
|
||||
|
@ -188,7 +188,7 @@ public class SysLoginService {
|
||||
/**
|
||||
* 登录校验
|
||||
*/
|
||||
public void checkLogin(LoginType loginType, String tenantId, String username, Supplier<Boolean> supplier) {
|
||||
public void checkLogin(LoginType loginType, String tenantId, String username, Supplier<Boolean> supplier) {
|
||||
String errorKey = CacheConstants.PWD_ERR_CNT_KEY + username;
|
||||
String loginFail = Constants.LOGIN_FAIL;
|
||||
|
||||
|
@ -46,7 +46,12 @@ public class SysRegisterService {
|
||||
String password = registerBody.getPassword();
|
||||
// 校验用户类型是否存在
|
||||
String userType = UserType.getUserType(registerBody.getUserType()).getUserType();
|
||||
|
||||
// 校验密码是否符合要求
|
||||
String pattern = "^(?!.*\\s)(?!^[a-zA-Z]+$)(?!^[0-9]+$)(?!^[^a-zA-Z0-9]+$)(?!^[a-zA-Z0-9]+$).{8,18}$";
|
||||
boolean isValid = password.matches(pattern);
|
||||
if (!isValid) {
|
||||
throw new UserException("注册失败,密码需满足8–18位,包含大小写字母、数字、特殊字符中的至少三种组合");
|
||||
}
|
||||
boolean captchaEnabled = captchaProperties.getEnable();
|
||||
// 验证码开关
|
||||
if (captchaEnabled) {
|
||||
|
@ -2,7 +2,7 @@
|
||||
spring.boot.admin.client:
|
||||
# 增加客户端开关
|
||||
enabled: false
|
||||
url: http://localhost:9090/admin
|
||||
url: http://192.168.110.119:9090/admin
|
||||
instance:
|
||||
service-host-type: IP
|
||||
metadata:
|
||||
@ -19,7 +19,7 @@ snail-job:
|
||||
# SnailJob 接入验证令牌 详见 script/sql/ry_job.sql `sj_group_config` 表
|
||||
token: "SJ_cKqBTPzCsWA3VyuCfFoccmuIEGXjr5KT"
|
||||
server:
|
||||
host: 127.0.0.1
|
||||
host: 192.168.110.119
|
||||
port: 17888
|
||||
# 命名空间UUID 详见 script/sql/ry_job.sql `sj_namespace`表`unique_id`字段
|
||||
namespace: ${spring.profiles.active}
|
||||
@ -52,14 +52,14 @@ spring:
|
||||
url: jdbc:mysql://192.168.110.2:13386/xinnengyuandev?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8
|
||||
username: xinnengyuandev
|
||||
password: StRWCZdZirysNSs2
|
||||
# # 从库数据源
|
||||
# slave:
|
||||
# lazy: true
|
||||
# type: ${spring.datasource.type}
|
||||
# driverClassName: com.mysql.cj.jdbc.Driver
|
||||
# url: jdbc:mysql://localhost:3306/ry-vue?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true
|
||||
# username:
|
||||
# password:
|
||||
# 从库数据源
|
||||
# slave:
|
||||
# lazy: true
|
||||
# type: ${spring.datasource.type}
|
||||
# driverClassName: com.mysql.cj.jdbc.Driver
|
||||
# url: jdbc:mysql://192.168.110.2:13386/zmkgdev?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true
|
||||
# username: zmkgdev
|
||||
# password: JhYxREf25AXdy3h8
|
||||
# oracle:
|
||||
# type: ${spring.datasource.type}
|
||||
# driverClassName: oracle.jdbc.OracleDriver
|
||||
@ -286,3 +286,5 @@ sparta:
|
||||
# 身份证加密密钥(32 位)
|
||||
id-card:
|
||||
encrypt-key: 7ae260d150a14027d2238a1cf80a48ef
|
||||
recognizer:
|
||||
url: http://192.168.110.5:50070
|
||||
|
289
xinnengyuan/ruoyi-admin/src/main/resources/application-local.yml
Normal file
289
xinnengyuan/ruoyi-admin/src/main/resources/application-local.yml
Normal file
@ -0,0 +1,289 @@
|
||||
--- # 临时文件存储位置 避免临时文件被系统清理报错
|
||||
spring.servlet.multipart.location: /ruoyi/server/temp
|
||||
|
||||
--- # 监控中心配置
|
||||
spring.boot.admin.client:
|
||||
# 增加客户端开关
|
||||
enabled: false
|
||||
url: http://localhost:9090/admin
|
||||
instance:
|
||||
service-host-type: IP
|
||||
metadata:
|
||||
username: ${spring.boot.admin.client.username}
|
||||
userpassword: ${spring.boot.admin.client.password}
|
||||
username: @monitor.username@
|
||||
password: @monitor.password@
|
||||
|
||||
--- # snail-job 配置
|
||||
snail-job:
|
||||
enabled: false
|
||||
# 需要在 SnailJob 后台组管理创建对应名称的组,然后创建任务的时候选择对应的组,才能正确分派任务
|
||||
group: "ruoyi_group"
|
||||
# SnailJob 接入验证令牌 详见 script/sql/ry_job.sql `sj_group_config`表
|
||||
token: "SJ_cKqBTPzCsWA3VyuCfFoccmuIEGXjr5KT"
|
||||
server:
|
||||
host: 127.0.0.1
|
||||
port: 17888
|
||||
# 命名空间UUID 详见 script/sql/ry_job.sql `sj_namespace`表`unique_id`字段
|
||||
namespace: ${spring.profiles.active}
|
||||
# 随主应用端口漂移
|
||||
port: 2${server.port}
|
||||
# 客户端ip指定
|
||||
host:
|
||||
# RPC类型: netty, grpc
|
||||
rpc-type: grpc
|
||||
|
||||
--- # 数据源配置
|
||||
spring:
|
||||
datasource:
|
||||
type: com.zaxxer.hikari.HikariDataSource
|
||||
# 动态数据源文档 https://www.kancloud.cn/tracy5546/dynamic-datasource/content
|
||||
dynamic:
|
||||
# 性能分析插件(有性能损耗 不建议生产环境使用)
|
||||
p6spy: false
|
||||
# 设置默认的数据源或者数据源组,默认值即为 master
|
||||
primary: master
|
||||
# 严格模式 匹配不到数据源则报错
|
||||
strict: true
|
||||
datasource:
|
||||
# 主库数据源
|
||||
master:
|
||||
type: ${spring.datasource.type}
|
||||
driverClassName: com.mysql.cj.jdbc.Driver
|
||||
# jdbc 所有参数配置参考 https://lionli.blog.csdn.net/article/details/122018562
|
||||
# rewriteBatchedStatements=true 批处理优化 大幅提升批量插入更新删除性能(对数据库有性能损耗 使用批量操作应考虑性能问题)
|
||||
url: jdbc:mysql://192.168.110.2:13386/xinnengyuanlocal?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true
|
||||
username: xinnengyuanlocal
|
||||
password: 5Rff6TrihXZAAT5M
|
||||
# # 从库数据源
|
||||
# slave:
|
||||
# lazy: true
|
||||
# type: ${spring.datasource.type}
|
||||
# driverClassName: com.mysql.cj.jdbc.Driver
|
||||
# url: jdbc:mysql://localhost:3306/ry-vue?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8&autoReconnect=true&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true&nullCatalogMeansCurrent=true
|
||||
# username:
|
||||
# password:
|
||||
# oracle:
|
||||
# type: ${spring.datasource.type}
|
||||
# driverClassName: oracle.jdbc.OracleDriver
|
||||
# url: jdbc:oracle:thin:@//localhost:1521/XE
|
||||
# username: ROOT
|
||||
# password: root
|
||||
# postgres:
|
||||
# type: ${spring.datasource.type}
|
||||
# driverClassName: org.postgresql.Driver
|
||||
# url: jdbc:postgresql://localhost:5432/postgres?useUnicode=true&characterEncoding=utf8&useSSL=true&autoReconnect=true&reWriteBatchedInserts=true
|
||||
# username: root
|
||||
# password: root
|
||||
# sqlserver:
|
||||
# type: ${spring.datasource.type}
|
||||
# driverClassName: com.microsoft.sqlserver.jdbc.SQLServerDriver
|
||||
# url: jdbc:sqlserver://localhost:1433;DatabaseName=tempdb;SelectMethod=cursor;encrypt=false;rewriteBatchedStatements=true
|
||||
# username: SA
|
||||
# password: root
|
||||
hikari:
|
||||
# 最大连接池数量
|
||||
maxPoolSize: 20
|
||||
# 最小空闲线程数量
|
||||
minIdle: 10
|
||||
# 配置获取连接等待超时的时间
|
||||
connectionTimeout: 30000
|
||||
# 校验超时时间
|
||||
validationTimeout: 5000
|
||||
# 空闲连接存活最大时间,默认10分钟
|
||||
idleTimeout: 600000
|
||||
# 此属性控制池中连接的最长生命周期,值0表示无限生命周期,默认30分钟
|
||||
maxLifetime: 1800000
|
||||
# 多久检查一次连接的活性
|
||||
keepaliveTime: 30000
|
||||
|
||||
--- # redis 单机配置(单机与集群只能开启一个另一个需要注释掉)
|
||||
spring.data:
|
||||
redis:
|
||||
# 地址
|
||||
host: 192.168.110.2
|
||||
# 端口,默认为6379
|
||||
port: 9287
|
||||
# 数据库索引
|
||||
database: 6
|
||||
# redis 密码必须配置
|
||||
password: syar23rdsaagdrsa
|
||||
# 连接超时时间
|
||||
timeout: 10s
|
||||
# 是否开启ssl
|
||||
ssl.enabled: false
|
||||
|
||||
# redisson 配置
|
||||
redisson:
|
||||
# redis key前缀
|
||||
keyPrefix:
|
||||
# 线程池数量
|
||||
threads: 16
|
||||
# Netty线程池数量
|
||||
nettyThreads: 32
|
||||
# 单节点配置
|
||||
singleServerConfig:
|
||||
# 客户端名称
|
||||
clientName: ${ruoyi.name}
|
||||
# 最小空闲连接数
|
||||
connectionMinimumIdleSize: 32
|
||||
# 连接池大小
|
||||
connectionPoolSize: 64
|
||||
# 连接空闲超时,单位:毫秒
|
||||
idleConnectionTimeout: 10000
|
||||
# 命令等待超时,单位:毫秒
|
||||
timeout: 3000
|
||||
# 发布和订阅连接池大小
|
||||
subscriptionConnectionPoolSize: 50
|
||||
|
||||
--- # mail 邮件发送
|
||||
mail:
|
||||
enabled: false
|
||||
host: smtp.163.com
|
||||
port: 465
|
||||
# 是否需要用户名密码验证
|
||||
auth: true
|
||||
# 发送方,遵循RFC-822标准
|
||||
from: xxx@163.com
|
||||
# 用户名(注意:如果使用foxmail邮箱,此处user为qq号)
|
||||
user: xxx@163.com
|
||||
# 密码(注意,某些邮箱需要为SMTP服务单独设置密码,详情查看相关帮助)
|
||||
pass: xxxxxxxxxx
|
||||
# 使用 STARTTLS安全连接,STARTTLS是对纯文本通信协议的扩展。
|
||||
starttlsEnable: true
|
||||
# 使用SSL安全连接
|
||||
sslEnable: true
|
||||
# SMTP超时时长,单位毫秒,缺省值不超时
|
||||
timeout: 0
|
||||
# Socket连接超时值,单位毫秒,缺省值不超时
|
||||
connectionTimeout: 0
|
||||
|
||||
--- # sms 短信 支持 阿里云 腾讯云 云片 等等各式各样的短信服务商
|
||||
# https://sms4j.com/doc3/ 差异配置文档地址 支持单厂商多配置,可以配置多个同时使用
|
||||
sms:
|
||||
# 配置源类型用于标定配置来源(interface,yaml)
|
||||
config-type: yaml
|
||||
# 用于标定yml中的配置是否开启短信拦截,接口配置不受此限制
|
||||
restricted: true
|
||||
# 短信拦截限制单手机号每分钟最大发送,只对开启了拦截的配置有效
|
||||
minute-max: 1
|
||||
# 短信拦截限制单手机号每日最大发送量,只对开启了拦截的配置有效
|
||||
account-max: 30
|
||||
# 以下配置来自于 org.dromara.sms4j.provider.config.BaseConfig类中
|
||||
blends:
|
||||
# 唯一ID 用于发送短信寻找具体配置 随便定义别用中文即可
|
||||
# 可以同时存在两个相同厂商 例如: ali1 ali2 两个不同的阿里短信账号 也可用于区分租户
|
||||
config1:
|
||||
# 框架定义的厂商名称标识,标定此配置是哪个厂商,详细请看厂商标识介绍部分
|
||||
supplier: alibaba
|
||||
# 有些称为accessKey有些称之为apiKey,也有称为sdkKey或者appId。
|
||||
access-key-id: 您的accessKey
|
||||
# 称为accessSecret有些称之为apiSecret
|
||||
access-key-secret: 您的accessKeySecret
|
||||
signature: 您的短信签名
|
||||
sdk-app-id: 您的sdkAppId
|
||||
config2:
|
||||
# 厂商标识,标定此配置是哪个厂商,详细请看厂商标识介绍部分
|
||||
supplier: tencent
|
||||
access-key-id: 您的accessKey
|
||||
access-key-secret: 您的accessKeySecret
|
||||
signature: 您的短信签名
|
||||
sdk-app-id: 您的sdkAppId
|
||||
|
||||
--- # 三方授权
|
||||
justauth:
|
||||
# 前端外网访问地址
|
||||
address: http://localhost:80
|
||||
type:
|
||||
maxkey:
|
||||
# maxkey 服务器地址
|
||||
# 注意 如下均配置均不需要修改 maxkey 已经内置好了数据
|
||||
server-url: http://sso.maxkey.top
|
||||
client-id: 876892492581044224
|
||||
client-secret: x1Y5MTMwNzIwMjMxNTM4NDc3Mzche8
|
||||
redirect-uri: ${justauth.address}/social-callback?source=maxkey
|
||||
topiam:
|
||||
# topiam 服务器地址
|
||||
server-url: http://127.0.0.1:1989/api/v1/authorize/y0q************spq***********8ol
|
||||
client-id: 449c4*********937************759
|
||||
client-secret: ac7***********1e0************28d
|
||||
redirect-uri: ${justauth.address}/social-callback?source=topiam
|
||||
scopes: [ openid, email, phone, profile ]
|
||||
qq:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=qq
|
||||
union-id: false
|
||||
weibo:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=weibo
|
||||
gitee:
|
||||
client-id: 91436b7940090d09c72c7daf85b959cfd5f215d67eea73acbf61b6b590751a98
|
||||
client-secret: 02c6fcfd70342980cd8dd2f2c06c1a350645d76c754d7a264c4e125f9ba915ac
|
||||
redirect-uri: ${justauth.address}/social-callback?source=gitee
|
||||
dingtalk:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=dingtalk
|
||||
baidu:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=baidu
|
||||
csdn:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=csdn
|
||||
coding:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=coding
|
||||
coding-group-name: xx
|
||||
oschina:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=oschina
|
||||
alipay_wallet:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=alipay_wallet
|
||||
alipay-public-key: MIIB**************DAQAB
|
||||
wechat_open:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=wechat_open
|
||||
wechat_mp:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=wechat_mp
|
||||
wechat_enterprise:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=wechat_enterprise
|
||||
agent-id: 1000002
|
||||
gitlab:
|
||||
client-id: 10**********6
|
||||
client-secret: 1f7d08**********5b7**********29e
|
||||
redirect-uri: ${justauth.address}/social-callback?source=gitlab
|
||||
# 和风天气 https://dev.qweather.com/
|
||||
weather:
|
||||
key-id: T65EAABUXC
|
||||
project-id: 2JTHPUQ5YY
|
||||
private-key: MC4CAQAwBQYDK2VwBCIEIMAglX7IsxYiTeM+FXXnvCUsIggajeP4s8gAllewm6BN
|
||||
api-host: n35rk53njv.re.qweatherapi.com
|
||||
# dxf转 geojson 执行文件名
|
||||
dxf2GeoJson:
|
||||
file-name: main
|
||||
ys7:
|
||||
app-key: 3acf9f1a43dc4209841e0893003db0a2
|
||||
app-secret: 4bbf3e9394f55d3af6e3af27b2d3db36
|
||||
# 斯巴达算法
|
||||
sparta:
|
||||
url: http://119.3.204.120:8040
|
||||
client-id: test
|
||||
client-secret: 115fcb08fa6742a1b086d9bb80a6ad59
|
||||
# 身份证加密密钥(32 位)
|
||||
id-card:
|
||||
encrypt-key: 7ae260d150a14027d2238a1cf80a48ef
|
||||
recognizer:
|
||||
url: http://192.168.110.5:50070
|
@ -285,3 +285,5 @@ sparta:
|
||||
# 身份证加密密钥(32 位)
|
||||
id-card:
|
||||
encrypt-key: 7ae260d150a14027d2238a1cf80a48ef
|
||||
recognizer:
|
||||
url: http://192.168.110.5:50070
|
||||
|
@ -8,7 +8,7 @@ ruoyi:
|
||||
copyrightYear: 2024
|
||||
|
||||
captcha:
|
||||
enable: true
|
||||
enable: false
|
||||
# 页面 <参数设置> 可开启关闭 验证码校验
|
||||
# 验证码类型 math 数组计算 char 字符验证
|
||||
type: MATH
|
||||
@ -119,11 +119,12 @@ security:
|
||||
- /error
|
||||
- /*/api-docs
|
||||
- /*/api-docs/**
|
||||
- /warm-flow-ui/config
|
||||
- /warm-flow-ui/**
|
||||
- /warm-flow/**
|
||||
- /other/ys7Device/webhook
|
||||
# todo 仅测试
|
||||
- /facility/matrix/**
|
||||
- /*/knowledgeDocument/changxie/callback/**
|
||||
- /**/changxie/callback/**
|
||||
|
||||
# 多租户配置
|
||||
tenant:
|
||||
@ -147,11 +148,11 @@ mybatis-plus:
|
||||
# 自定义配置 是否全局开启逻辑删除 关闭后 所有逻辑删除功能将失效
|
||||
enableLogicDelete: true
|
||||
# 多包名使用 例如 org.dromara.**.mapper,org.xxx.**.mapper
|
||||
mapperPackage: org.dromara.**.mapper
|
||||
mapperPackage: org.dromara.**.mapper,org.dromara.app.**.mapper
|
||||
# 对应的 XML 文件位置
|
||||
mapperLocations: classpath*:mapper/**/*Mapper.xml
|
||||
mapperLocations: classpath*:mapper/**/*Mapper.xml,classpath*:mapper/app/**/*Mapper.xml
|
||||
# 实体扫描,多个package用逗号或者分号分隔
|
||||
typeAliasesPackage: org.dromara.**.domain
|
||||
typeAliasesPackage: org.dromara.**.domain,org.dromara.app.**.domain
|
||||
global-config:
|
||||
dbConfig:
|
||||
# 主键类型
|
||||
@ -185,15 +186,20 @@ api-decrypt:
|
||||
# 请求解密私钥 非对称算法的公私钥 如:SM2,RSA 使用者请自行更换
|
||||
# 对应前端加密公钥 MFwwDQYJKoZIhvcNAQEBBQADSwAwSAJBAKoR8mX0rGKLqzcWmOzbfj64K8ZIgOdHnzkXSOVOZbFu/TJhZ7rFAN+eaGkl3C4buccQd/EjEsj9ir7ijT7h96MCAwEAAQ==
|
||||
privateKey: MIIBVAIBADANBgkqhkiG9w0BAQEFAASCAT4wggE6AgEAAkEAqhHyZfSsYourNxaY7Nt+PrgrxkiA50efORdI5U5lsW79MmFnusUA355oaSXcLhu5xxB38SMSyP2KvuKNPuH3owIDAQABAkAfoiLyL+Z4lf4Myxk6xUDgLaWGximj20CUf+5BKKnlrK+Ed8gAkM0HqoTt2UZwA5E2MzS4EI2gjfQhz5X28uqxAiEA3wNFxfrCZlSZHb0gn2zDpWowcSxQAgiCstxGUoOqlW8CIQDDOerGKH5OmCJ4Z21v+F25WaHYPxCFMvwxpcw99EcvDQIgIdhDTIqD2jfYjPTY8Jj3EDGPbH2HHuffvflECt3Ek60CIQCFRlCkHpi7hthhYhovyloRYsM+IS9h/0BzlEAuO0ktMQIgSPT3aFAgJYwKpqRYKlLDVcflZFCKY7u3UP8iWi1Qw0Y=
|
||||
# cory 放行部分接口
|
||||
excluded-paths:
|
||||
- /doc.html # 放行Swagger文档
|
||||
- /swagger-ui/** # 放行Swagger文档
|
||||
- /v3/api-docs/** # 放行OpenAPI文档
|
||||
- /actuator/** # 放行监控接口
|
||||
- /other/ys7Device/webhook # 放行萤石云设备回调接口
|
||||
- /auth/register # 放行注册接口
|
||||
|
||||
springdoc:
|
||||
api-docs:
|
||||
# 是否开启接口文档
|
||||
enabled: true
|
||||
swagger-ui:
|
||||
path: /swagger-ui.html # 明确Swagger UI路径
|
||||
# 持久化认证数据
|
||||
persistAuthorization: false
|
||||
path: /v3/api-docs
|
||||
info:
|
||||
# 标题
|
||||
title: '标题:${ruoyi.name}多租户管理系统_接口文档'
|
||||
@ -243,9 +249,23 @@ springdoc:
|
||||
packages-to-scan: org.dromara.workflow
|
||||
- group: 14.罗成模块
|
||||
packages-to-scan: org.dromara.cory
|
||||
- group: 15.无人机模块
|
||||
packages-to-scan: org.dromara.drone
|
||||
- group: 20.代码生成模块
|
||||
packages-to-scan: org.dromara.generator
|
||||
|
||||
- group: 16.app模块
|
||||
packages-to-scan: org.dromara.app
|
||||
- group: 17.材料设备模块
|
||||
packages-to-scan: org.dromara.cailiaoshebei
|
||||
- group: 18.产值模块
|
||||
packages-to-scan: org.dromara.out
|
||||
- group: 19.消息模块
|
||||
packages-to-scan: org.dromara.message
|
||||
# knife4j的增强配置,不需要增强可以不配
|
||||
knife4j:
|
||||
enable: true
|
||||
setting:
|
||||
language: zh_cn
|
||||
|
||||
# 防止XSS攻击
|
||||
xss:
|
||||
@ -315,3 +335,10 @@ warm-flow:
|
||||
- 255,205,23
|
||||
## 已办理
|
||||
- 157,255,0
|
||||
|
||||
|
||||
--- # 百度云配置
|
||||
baidu:
|
||||
client:
|
||||
id: zSB7KdLgY7a1tIEx3eTy65TE
|
||||
secret: 5nabjclW5BWGV8UwEueDgBDmOveRVkmD
|
||||
|
BIN
xinnengyuan/ruoyi-admin/src/main/resources/favicon.ico
Normal file
BIN
xinnengyuan/ruoyi-admin/src/main/resources/favicon.ico
Normal file
Binary file not shown.
After Width: | Height: | Size: 7.9 KiB |
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -11,7 +11,7 @@ import java.util.Arrays;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author lcj
|
||||
* @author lilemy
|
||||
* @date 2025/4/23 10:15
|
||||
*/
|
||||
@SpringBootTest
|
||||
|
@ -9,6 +9,7 @@ import org.dromara.facility.service.IFacMatrixService;
|
||||
import org.dromara.facility.service.IFacPhotovoltaicPanelPartsService;
|
||||
import org.dromara.progress.service.IPgsProgressCategoryService;
|
||||
import org.dromara.project.service.IBusProjectService;
|
||||
import org.dromara.system.service.ISysDeptService;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
|
||||
@ -16,7 +17,7 @@ import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author lcj
|
||||
* @author lilemy
|
||||
* @date 2025/5/30 9:48
|
||||
*/
|
||||
@Slf4j
|
||||
@ -38,6 +39,9 @@ public class DemoTest {
|
||||
@Resource
|
||||
private IDesTechnicalStandardService desTechnicalStandardService;
|
||||
|
||||
@Resource
|
||||
private ISysDeptService deptService;
|
||||
|
||||
@Test
|
||||
void test() {
|
||||
Boolean result = photovoltaicPanelPartsService
|
||||
@ -79,4 +83,10 @@ public class DemoTest {
|
||||
.list();
|
||||
Boolean result = progressCategoryService.insertByTemplate(1906557369562726402L, matrixList, null);
|
||||
}
|
||||
|
||||
@Test
|
||||
void testDeptProject() {
|
||||
deptService.selectProjectIdById(100L);
|
||||
deptService.selectProjectIdById(1937478258803171329L);
|
||||
}
|
||||
}
|
||||
|
@ -0,0 +1,39 @@
|
||||
package org.dromara.test;
|
||||
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.dromara.common.utils.PdfBoxQrCodeGenerator;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author lilemy
|
||||
* @date 2025/7/7 10:13
|
||||
*/
|
||||
@Slf4j
|
||||
@SpringBootTest
|
||||
public class PDFTest {
|
||||
|
||||
@Test
|
||||
void test() {
|
||||
String srcPdf = "http://58.17.134.85:9000/xinnengyuan-dev/2025/07/07/146cb913cb4841eb9944463b762cba53.pdf"; // 原始PDF
|
||||
String destPdf = "output.pdf"; // 输出PDF
|
||||
Map<String, Object> params = new HashMap<>();
|
||||
params.put("版本:", "1.0");
|
||||
params.put("文件名:", "绝对哦啊手机号丢啊");
|
||||
params.put("文件类型:", "蓝图");
|
||||
String qrText = "fdas:1.0 das:asd sad:dsa";
|
||||
String qrPath = "qrcode.png";
|
||||
|
||||
byte[] bytes = PdfBoxQrCodeGenerator.generateQRCodeBytes(qrText, 200, 200);
|
||||
try {
|
||||
PdfBoxQrCodeGenerator.addQRCodeToPDF(srcPdf, destPdf, bytes, 1, 1510, 900); // 页码从1开始,坐标单位是 pt(约1/72英寸)
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
System.out.println("二维码添加成功!");
|
||||
}
|
||||
}
|
@ -0,0 +1,29 @@
|
||||
package org.dromara.test;
|
||||
|
||||
import jakarta.annotation.Resource;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.dromara.manager.recognizermanager.RecognizerManager;
|
||||
import org.dromara.manager.recognizermanager.enums.RecognizerTypeEnum;
|
||||
import org.dromara.manager.recognizermanager.vo.RecognizeVo;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author lilemy
|
||||
* @date 2025/7/21 11:35
|
||||
*/
|
||||
@Slf4j
|
||||
@SpringBootTest
|
||||
public class RecognizerTest {
|
||||
|
||||
@Resource
|
||||
private RecognizerManager recognizerManager;
|
||||
|
||||
@Test
|
||||
void test() {
|
||||
RecognizeVo recognize = recognizerManager.recognize("http://xny.yj-3d.com:7363/file/tif/20250625160218orthophoto.png", List.of(RecognizerTypeEnum.PHO));
|
||||
log.info("recognize: {}", recognize);
|
||||
}
|
||||
}
|
@ -1,591 +0,0 @@
|
||||
package org.dromara.test;
|
||||
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import jakarta.annotation.Resource;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.dromara.manager.spartamanager.SpartaManager;
|
||||
import org.dromara.manager.spartamanager.enums.SpartaRecTypeEnum;
|
||||
import org.dromara.manager.spartamanager.vo.ImageStreamResult;
|
||||
import org.dromara.manager.spartamanager.vo.SpartaRecognizeVo;
|
||||
import org.dromara.manager.spartamanager.vo.SpartaTargetVo;
|
||||
import org.dromara.other.domain.dto.ys7deviceimg.OthYs7DeviceImgCreateByCapture;
|
||||
import org.dromara.other.service.IOthYs7DeviceImgService;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
|
||||
import javax.imageio.ImageIO;
|
||||
import java.awt.*;
|
||||
import java.awt.image.BufferedImage;
|
||||
import java.io.File;
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.OutputStream;
|
||||
import java.net.URI;
|
||||
import java.net.URISyntaxException;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author lcj
|
||||
* @date 2025/6/20 19:40
|
||||
*/
|
||||
@Slf4j
|
||||
@SpringBootTest
|
||||
public class SpartaTest {
|
||||
|
||||
@Resource
|
||||
private SpartaManager spartaManager;
|
||||
|
||||
@Resource
|
||||
private IOthYs7DeviceImgService othYs7DeviceImgService;
|
||||
|
||||
@Test
|
||||
public void test() {
|
||||
String token = spartaManager.getToken();
|
||||
log.info("token: {}", token);
|
||||
}
|
||||
|
||||
@Test
|
||||
public void test2() throws URISyntaxException, IOException {
|
||||
String url = "http://58.17.134.85:9000/xinnengyuan-dev/ys7/device/img/sxt_1750583731809_227.jpg";
|
||||
// List<SpartaRecTypeEnum> hat = List.of(SpartaRecTypeEnum.HAT, SpartaRecTypeEnum.HEAD);
|
||||
// SpartaRecognizeVo recognize = spartaManager.recognize(
|
||||
// url,
|
||||
// hat,
|
||||
// null,
|
||||
// null,
|
||||
// null
|
||||
// );
|
||||
// log.info("识别结果: {}", recognize);
|
||||
SpartaRecognizeVo vo = new SpartaRecognizeVo();
|
||||
vo.setHasTarget(1);
|
||||
vo.setOriginalImgSize(List.of(2560, 1440));
|
||||
|
||||
SpartaTargetVo targets = new SpartaTargetVo();
|
||||
targets.setType("hat");
|
||||
targets.setSize(List.of(59, 78));
|
||||
targets.setLeftTopPoint(List.of(880, 597));
|
||||
targets.setScore(0.41687846183776855);
|
||||
|
||||
vo.setTargets(List.of(targets));
|
||||
// 1. 读取图片
|
||||
URI uri = new URI(url);
|
||||
BufferedImage image = ImageIO.read(uri.toURL());
|
||||
// 2. 创建画布
|
||||
Graphics2D g = image.createGraphics();
|
||||
g.setColor(Color.RED);
|
||||
g.setStroke(new BasicStroke(5));
|
||||
g.setFont(new Font("SansSerif", Font.BOLD, 18));
|
||||
// 3. 遍历目标并画框
|
||||
for (SpartaTargetVo target : vo.getTargets()) {
|
||||
List<Integer> size = target.getSize(); // 宽高
|
||||
List<Integer> leftTop = target.getLeftTopPoint(); // x y
|
||||
|
||||
int x = leftTop.get(0);
|
||||
int y = leftTop.get(1);
|
||||
int width = size.get(0);
|
||||
int height = size.get(1);
|
||||
|
||||
// 画矩形框
|
||||
g.drawRect(x, y, width, height);
|
||||
|
||||
// 写文字(类型 + 置信度)
|
||||
String label = SpartaRecTypeEnum.fromValue(target.getType()).getText() + " (" + String.format("%.2f", target.getScore()) + ")";
|
||||
g.drawString(label, x, y - 5);
|
||||
}
|
||||
|
||||
g.dispose();
|
||||
|
||||
// 4. 保存标记后的图片
|
||||
File outFile = new File("marked_output.jpg");
|
||||
ImageIO.write(image, "jpg", outFile);
|
||||
|
||||
System.out.println("标记完成,保存路径: " + "marked_output.jpg");
|
||||
}
|
||||
|
||||
@Test
|
||||
public void test3() {
|
||||
String url = "http://58.17.134.85:9000/xinnengyuan-dev/ys7/device/img/sxt_1750583731809_227.jpg";
|
||||
OthYs7DeviceImgCreateByCapture img = new OthYs7DeviceImgCreateByCapture();
|
||||
img.setCreateTime(new Date());
|
||||
img.setUrl(url);
|
||||
img.setDeviceName("摄像头1");
|
||||
img.setDeviceSerial("sxt_1750583731809_227");
|
||||
log.info("识别结果: {}", img);
|
||||
othYs7DeviceImgService.saveCapturePic(List.of(img));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void test4() throws IOException, URISyntaxException {
|
||||
String url = "http://xny.yj-3d.com:7363/file/tif/20250625160218orthophoto.png";
|
||||
String targetStr = "[\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 344,\n" +
|
||||
" 149\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3787,\n" +
|
||||
" 3241\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9511\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 334,\n" +
|
||||
" 147\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4276,\n" +
|
||||
" 3590\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9498\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 330,\n" +
|
||||
" 149\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3459,\n" +
|
||||
" 3183\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9496\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 353,\n" +
|
||||
" 148\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4226,\n" +
|
||||
" 3714\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9495\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 339,\n" +
|
||||
" 132\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4276,\n" +
|
||||
" 2678\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9486\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 340,\n" +
|
||||
" 145\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4565,\n" +
|
||||
" 2982\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9486\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 335,\n" +
|
||||
" 142\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3695,\n" +
|
||||
" 3360\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9475\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 336,\n" +
|
||||
" 145\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4446,\n" +
|
||||
" 3357\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9473\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 338,\n" +
|
||||
" 140\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4248,\n" +
|
||||
" 2803\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9466\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 343,\n" +
|
||||
" 155\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4565,\n" +
|
||||
" 3769\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9464\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 346,\n" +
|
||||
" 148\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4233,\n" +
|
||||
" 2925\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9462\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 327,\n" +
|
||||
" 159\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4000,\n" +
|
||||
" 2484\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.946\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 336,\n" +
|
||||
" 145\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4906,\n" +
|
||||
" 2908\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9457\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 339,\n" +
|
||||
" 150\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3618,\n" +
|
||||
" 3477\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9456\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 318,\n" +
|
||||
" 147\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 5241,\n" +
|
||||
" 3883\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9448\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 328,\n" +
|
||||
" 147\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4934,\n" +
|
||||
" 3702\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.943\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 312,\n" +
|
||||
" 142\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3633,\n" +
|
||||
" 2557\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9428\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 340,\n" +
|
||||
" 137\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4576,\n" +
|
||||
" 2856\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9406\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 335,\n" +
|
||||
" 138\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4316,\n" +
|
||||
" 2548\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9398\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 345,\n" +
|
||||
" 146\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4890,\n" +
|
||||
" 3829\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9378\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 332,\n" +
|
||||
" 153\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4126,\n" +
|
||||
" 3304\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9371\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 325,\n" +
|
||||
" 137\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3581,\n" +
|
||||
" 2944\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9318\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 320,\n" +
|
||||
" 145\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3879,\n" +
|
||||
" 3123\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9304\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 343,\n" +
|
||||
" 143\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4601,\n" +
|
||||
" 3645\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9258\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 335,\n" +
|
||||
" 142\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4673,\n" +
|
||||
" 3528\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9255\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 312,\n" +
|
||||
" 144\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4800,\n" +
|
||||
" 3411\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.923\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 337,\n" +
|
||||
" 139\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4016,\n" +
|
||||
" 3412\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9225\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 340,\n" +
|
||||
" 141\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4605,\n" +
|
||||
" 2729\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9191\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 298,\n" +
|
||||
" 325\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3249,\n" +
|
||||
" 2576\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9185\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 338,\n" +
|
||||
" 156\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4537,\n" +
|
||||
" 2451\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9118\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 334,\n" +
|
||||
" 143\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4933,\n" +
|
||||
" 2783\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9114\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 339,\n" +
|
||||
" 141\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4464,\n" +
|
||||
" 2308\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9107\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 343,\n" +
|
||||
" 143\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3890,\n" +
|
||||
" 3000\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.9064\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 313,\n" +
|
||||
" 139\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3593,\n" +
|
||||
" 2810\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.902\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 259,\n" +
|
||||
" 131\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 4000,\n" +
|
||||
" 2755\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.8869\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 345,\n" +
|
||||
" 149\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3901,\n" +
|
||||
" 2864\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.8841\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 345,\n" +
|
||||
" 150\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 3945,\n" +
|
||||
" 2610\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.8632\n" +
|
||||
" },\n" +
|
||||
" {\n" +
|
||||
" \"type\": \"pho\",\n" +
|
||||
" \"size\": [\n" +
|
||||
" 199,\n" +
|
||||
" 110\n" +
|
||||
" ],\n" +
|
||||
" \"leftTopPoint\": [\n" +
|
||||
" 5166,\n" +
|
||||
" 3661\n" +
|
||||
" ],\n" +
|
||||
" \"score\": 0.8225\n" +
|
||||
" }\n" +
|
||||
" ]";
|
||||
List<SpartaTargetVo> list = JSONUtil.toList(targetStr, SpartaTargetVo.class);
|
||||
log.info("list:{}", list);
|
||||
ImageStreamResult imageStreamResult = spartaManager.drawImageToStream(url, list);
|
||||
log.info("imageStreamResult:{}", imageStreamResult);
|
||||
try (OutputStream outputStream = new FileOutputStream("D:/images/save.png")) {
|
||||
byte[] buffer = new byte[4096];
|
||||
int bytesRead;
|
||||
while ((bytesRead = imageStreamResult.getInputStream().read(buffer)) != -1) {
|
||||
outputStream.write(buffer, 0, bytesRead);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,58 @@
|
||||
package org.dromara.test;
|
||||
|
||||
import jakarta.annotation.Resource;
|
||||
import org.dromara.safety.domain.dto.violationrecord.HseViolationRecordCreateDto;
|
||||
import org.dromara.safety.service.IHseViolationRecordService;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author lilemy
|
||||
* @date 2025/7/22 15:36
|
||||
*/
|
||||
@SpringBootTest
|
||||
public class ViolationRecordTest {
|
||||
|
||||
@Resource
|
||||
private IHseViolationRecordService violationRecordService;
|
||||
|
||||
@Test
|
||||
void test() {
|
||||
List<HseViolationRecordCreateDto> list = new ArrayList<>();
|
||||
HseViolationRecordCreateDto dto1 = new HseViolationRecordCreateDto();
|
||||
dto1.setProjectId(1897160897167638529L);
|
||||
dto1.setRecognizeId(1937451365735419905L);
|
||||
dto1.setViolationType("3");
|
||||
dto1.setViolationTime(new Date());
|
||||
list.add(dto1);
|
||||
HseViolationRecordCreateDto dto2 = new HseViolationRecordCreateDto();
|
||||
dto2.setProjectId(1897160897167638529L);
|
||||
dto2.setRecognizeId(1937451365735419906L);
|
||||
dto2.setViolationType("1,2,3");
|
||||
dto2.setViolationTime(new Date());
|
||||
list.add(dto2);
|
||||
HseViolationRecordCreateDto dto3 = new HseViolationRecordCreateDto();
|
||||
dto3.setProjectId(1897160897167638529L);
|
||||
dto3.setRecognizeId(1937451365735419907L);
|
||||
dto3.setViolationType("2,7,8");
|
||||
dto3.setViolationTime(new Date());
|
||||
list.add(dto3);
|
||||
HseViolationRecordCreateDto dto4 = new HseViolationRecordCreateDto();
|
||||
dto4.setProjectId(1897160897167638529L);
|
||||
dto4.setRecognizeId(1937451365735419908L);
|
||||
dto4.setViolationType("5,8");
|
||||
dto4.setViolationTime(new Date());
|
||||
list.add(dto4);
|
||||
HseViolationRecordCreateDto dto5 = new HseViolationRecordCreateDto();
|
||||
dto5.setProjectId(1897160897167638529L);
|
||||
dto5.setRecognizeId(1937451365735419909L);
|
||||
dto5.setViolationType("3,9");
|
||||
dto5.setViolationTime(new Date());
|
||||
list.add(dto5);
|
||||
violationRecordService.insertByMonitor(list);
|
||||
}
|
||||
}
|
@ -2,16 +2,25 @@ package org.dromara.test;
|
||||
|
||||
import jakarta.annotation.Resource;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.dromara.formalities.domain.bo.AddBusFormalitiesAreConsolidatedBo;
|
||||
import org.dromara.formalities.domain.bo.BusFormalitiesAreConsolidatedBo;
|
||||
import org.dromara.formalities.domain.bo.BusListOfFormalitiesBo;
|
||||
import org.dromara.formalities.domain.vo.BusListOfFormalitiesVo;
|
||||
import org.dromara.formalities.service.IBusFormalitiesAreConsolidatedService;
|
||||
import org.dromara.formalities.service.IBusListOfFormalitiesService;
|
||||
import org.dromara.manager.ys7manager.Ys7Manager;
|
||||
import org.dromara.manager.ys7manager.Ys7RequestUtils;
|
||||
import org.dromara.manager.ys7manager.vo.Ys7QueryDeviceResponseVo;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @author lcj
|
||||
* @author lilemy
|
||||
* @date 2025/6/12 17:06
|
||||
*/
|
||||
@Slf4j
|
||||
@ -34,4 +43,56 @@ public class Ys7Test {
|
||||
System.out.println(pic);
|
||||
}
|
||||
|
||||
@Resource
|
||||
private IBusListOfFormalitiesService busListOfFormalitiesService;
|
||||
|
||||
@Test
|
||||
public void test111(){
|
||||
BusListOfFormalitiesBo busListOfFormalitiesBo = new BusListOfFormalitiesBo();
|
||||
// busListOfFormalitiesBo.setName("test1");
|
||||
// busListOfFormalitiesBo.setPid(1955976169241026561L);
|
||||
// busListOfFormalitiesService.insertByBo(busListOfFormalitiesBo);
|
||||
// List<BusListOfFormalitiesVo> tree = busListOfFormalitiesService.getTree(busListOfFormalitiesBo);
|
||||
// System.out.println(tree);
|
||||
Boolean b = busListOfFormalitiesService.deleteWithValidByIds(1955976169241026561L, true);
|
||||
System.out.println(b);
|
||||
|
||||
}
|
||||
|
||||
@Resource
|
||||
private IBusFormalitiesAreConsolidatedService formalitiesAreConsolidatedService;
|
||||
|
||||
@Test
|
||||
public void test222(){
|
||||
BusFormalitiesAreConsolidatedBo busFormalitiesAreConsolidatedBo = new BusFormalitiesAreConsolidatedBo();
|
||||
// List<AddBusFormalitiesAreConsolidatedBo> addBusFormalitiesAreConsolidatedBos = new ArrayList<>();
|
||||
// AddBusFormalitiesAreConsolidatedBo bo1 = new AddBusFormalitiesAreConsolidatedBo();
|
||||
// bo1.setFormalitiesId(1955977461032103939L);
|
||||
// AddBusFormalitiesAreConsolidatedBo bo2 = new AddBusFormalitiesAreConsolidatedBo();
|
||||
// bo2.setFormalitiesId(1955977461032103940L);
|
||||
// bo2.setFormalitiesPid(1955977461032103939L);
|
||||
// AddBusFormalitiesAreConsolidatedBo bo3 = new AddBusFormalitiesAreConsolidatedBo();
|
||||
// bo3.setFormalitiesId(1955977461032103941L);
|
||||
// bo3.setFormalitiesPid(1955977461032103939L);
|
||||
// AddBusFormalitiesAreConsolidatedBo bo4 = new AddBusFormalitiesAreConsolidatedBo();
|
||||
// bo4.setFormalitiesId(1955977461032103942L);
|
||||
// bo4.setFormalitiesPid(1955977461032103939L);
|
||||
// addBusFormalitiesAreConsolidatedBos.add(bo1);
|
||||
// addBusFormalitiesAreConsolidatedBos.add(bo2);
|
||||
// addBusFormalitiesAreConsolidatedBos.add(bo3);
|
||||
// addBusFormalitiesAreConsolidatedBos.add(bo4);
|
||||
// busFormalitiesAreConsolidatedBo.setAddBusFormalitiesAreConsolidatedBos(addBusFormalitiesAreConsolidatedBos);
|
||||
// busFormalitiesAreConsolidatedBo.setProjectId(1555L);
|
||||
// Boolean b = formalitiesAreConsolidatedService.insertByBo(busFormalitiesAreConsolidatedBo);
|
||||
// System.out.println(b);
|
||||
// busFormalitiesAreConsolidatedBo.setId(1956013379818409985L);
|
||||
// busFormalitiesAreConsolidatedBo.setHead("舟山");
|
||||
// busFormalitiesAreConsolidatedBo.setPlanTheStartTime(new Date());
|
||||
// busFormalitiesAreConsolidatedBo.setRemark("asdasd");
|
||||
// busFormalitiesAreConsolidatedBo.setStatus(0);
|
||||
// MultipartFile[] files = {};
|
||||
// Boolean b = formalitiesAreConsolidatedService.updateByBo(busFormalitiesAreConsolidatedBo, files);
|
||||
// System.out.println(b);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -3,7 +3,7 @@ package org.dromara.common.core.constant;
|
||||
import java.util.regex.Pattern;
|
||||
|
||||
/**
|
||||
* @author lcj
|
||||
* @author lilemy
|
||||
* @date 2025/4/7 17:12
|
||||
*/
|
||||
public interface DateConstant {
|
||||
|
@ -3,7 +3,7 @@ package org.dromara.common.core.domain.vo;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @author lcj
|
||||
* @author lilemy
|
||||
* @date 2025/3/19 11:40
|
||||
*/
|
||||
@Data
|
||||
|
@ -24,37 +24,37 @@ public enum BusinessStatusEnum {
|
||||
/**
|
||||
* 已撤销
|
||||
*/
|
||||
CANCEL("cancel", "已撤销"),
|
||||
CANCEL("cancel", "已撤销",6),
|
||||
|
||||
/**
|
||||
* 草稿
|
||||
*/
|
||||
DRAFT("draft", "草稿"),
|
||||
DRAFT("draft", "草稿",3),
|
||||
|
||||
/**
|
||||
* 待审核
|
||||
*/
|
||||
WAITING("waiting", "待审核"),
|
||||
WAITING("waiting", "待审核",2),
|
||||
|
||||
/**
|
||||
* 已完成
|
||||
*/
|
||||
FINISH("finish", "已完成"),
|
||||
FINISH("finish", "已完成",1),
|
||||
|
||||
/**
|
||||
* 已作废
|
||||
*/
|
||||
INVALID("invalid", "已作废"),
|
||||
INVALID("invalid", "已作废",7),
|
||||
|
||||
/**
|
||||
* 已退回
|
||||
*/
|
||||
BACK("back", "已退回"),
|
||||
BACK("back", "已退回",4),
|
||||
|
||||
/**
|
||||
* 已终止
|
||||
*/
|
||||
TERMINATION("termination", "已终止");
|
||||
TERMINATION("termination", "已终止",5);
|
||||
|
||||
/**
|
||||
* 状态
|
||||
@ -66,6 +66,11 @@ public enum BusinessStatusEnum {
|
||||
*/
|
||||
private final String desc;
|
||||
|
||||
/**
|
||||
* 排序字段
|
||||
*/
|
||||
private final int order;
|
||||
|
||||
private static final Map<String, BusinessStatusEnum> STATUS_MAP = Arrays.stream(BusinessStatusEnum.values())
|
||||
.collect(Collectors.toConcurrentMap(BusinessStatusEnum::getStatus, Function.identity()));
|
||||
|
||||
|
@ -9,6 +9,7 @@ import java.text.ParseException;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.time.*;
|
||||
import java.time.format.DateTimeFormatter;
|
||||
import java.time.format.DateTimeParseException;
|
||||
import java.util.Date;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
@ -148,6 +149,28 @@ public class DateUtils extends org.apache.commons.lang3.time.DateUtils {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 将指定格式的日期时间字符串转换为 LocalDate 对象
|
||||
*
|
||||
* @param format 要解析的日期时间格式,例如"YYYY-MM-DD HH:MM:SS"
|
||||
* @param ts 要解析的日期时间字符串
|
||||
* @return 解析后的 Date 对象
|
||||
* @throws RuntimeException 如果解析过程中发生异常
|
||||
*/
|
||||
public static LocalDate parseLocalDateTime(final FormatsType format, final String ts) {
|
||||
try {
|
||||
DateTimeFormatter formatter = DateTimeFormatter.ofPattern(format.getTimeFormat());
|
||||
// 如果是年月格式,则默认设置为该月第一天
|
||||
if (format.getTimeFormat().equals("yyyy-MM") || format.getTimeFormat().equals("yyyy/MM") || format.getTimeFormat().equals("yyyy.MM")) {
|
||||
YearMonth yearMonth = YearMonth.parse(ts, formatter);
|
||||
return yearMonth.atDay(1);
|
||||
}
|
||||
return LocalDate.parse(ts, formatter);
|
||||
} catch (Exception e) {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 将对象转换为日期对象
|
||||
*
|
||||
@ -254,6 +277,16 @@ public class DateUtils extends org.apache.commons.lang3.time.DateUtils {
|
||||
return Date.from(zdt.toInstant());
|
||||
}
|
||||
|
||||
/**
|
||||
* 将 Date 对象转换为 LocalDate 对象
|
||||
*
|
||||
* @param temporalAccessor 要转换的 Date 对象
|
||||
* @return 转换后的 LocalDate 对象
|
||||
*/
|
||||
public static LocalDate toLocalDate(Date temporalAccessor) {
|
||||
return temporalAccessor.toInstant().atZone(ZoneId.systemDefault()).toLocalDate();
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验日期范围
|
||||
*
|
||||
@ -309,4 +342,22 @@ public class DateUtils extends org.apache.commons.lang3.time.DateUtils {
|
||||
return Date.from(combinedInstant);
|
||||
}
|
||||
|
||||
/**
|
||||
* 校验日期范围
|
||||
*
|
||||
* @param startStr 开始日期字符串,格式为 "yyyy-MM-dd"
|
||||
* @param endStr 结束日期字符串,格式为 "yyyy-MM-dd"
|
||||
* @return true 表示日期范围有效,false 表示日期范围无效
|
||||
*/
|
||||
public static boolean isValidDateRange(String startStr, String endStr) {
|
||||
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd");
|
||||
try {
|
||||
LocalDate startDate = LocalDate.parse(startStr, formatter);
|
||||
LocalDate endDate = LocalDate.parse(endStr, formatter);
|
||||
return !startDate.isAfter(endDate); // start <= end
|
||||
} catch (DateTimeParseException e) {
|
||||
return false; // 格式非法
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -339,4 +339,16 @@ public class StringUtils extends org.apache.commons.lang3.StringUtils {
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* 判断字符串是否全为数字
|
||||
*
|
||||
* @param str 字符串
|
||||
* @return 是否为数字
|
||||
*/
|
||||
public static boolean isAllDigits(String str) {
|
||||
if (str == null) return false;
|
||||
String noSpaces = str.replaceAll(" ", "");
|
||||
return noSpaces.matches("\\d+");
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -26,6 +26,11 @@
|
||||
<artifactId>springdoc-openapi-starter-webmvc-api</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.springdoc</groupId>
|
||||
<artifactId>springdoc-openapi-starter-webmvc-ui</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.github.therapi</groupId>
|
||||
<artifactId>therapi-runtime-javadoc</artifactId>
|
||||
@ -36,6 +41,12 @@
|
||||
<artifactId>jackson-module-kotlin</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>com.github.xiaoymin</groupId>
|
||||
<artifactId>knife4j-openapi3-jakarta-spring-boot-starter</artifactId>
|
||||
<version>4.4.0</version>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
</project>
|
||||
|
@ -8,6 +8,7 @@ import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
||||
import org.springframework.boot.context.properties.EnableConfigurationProperties;
|
||||
import org.springframework.boot.web.servlet.FilterRegistrationBean;
|
||||
import org.springframework.context.annotation.Bean;
|
||||
import org.springframework.util.PathMatcher;
|
||||
|
||||
/**
|
||||
* api 解密自动配置
|
||||
@ -20,10 +21,10 @@ import org.springframework.context.annotation.Bean;
|
||||
public class ApiDecryptAutoConfiguration {
|
||||
|
||||
@Bean
|
||||
public FilterRegistrationBean<CryptoFilter> cryptoFilterRegistration(ApiDecryptProperties properties) {
|
||||
public FilterRegistrationBean<CryptoFilter> cryptoFilterRegistration(ApiDecryptProperties properties, PathMatcher pathMatcher) {
|
||||
FilterRegistrationBean<CryptoFilter> registration = new FilterRegistrationBean<>();
|
||||
registration.setDispatcherTypes(DispatcherType.REQUEST);
|
||||
registration.setFilter(new CryptoFilter(properties));
|
||||
registration.setFilter(new CryptoFilter(properties,pathMatcher));
|
||||
registration.addUrlPatterns("/*");
|
||||
registration.setName("cryptoFilter");
|
||||
registration.setOrder(FilterRegistrationBean.HIGHEST_PRECEDENCE);
|
||||
|
@ -11,12 +11,14 @@ import org.dromara.common.core.utils.StringUtils;
|
||||
import org.dromara.common.encrypt.annotation.ApiEncrypt;
|
||||
import org.dromara.common.encrypt.properties.ApiDecryptProperties;
|
||||
import org.springframework.http.HttpMethod;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
import org.springframework.util.PathMatcher;
|
||||
import org.springframework.web.method.HandlerMethod;
|
||||
import org.springframework.web.servlet.HandlerExceptionResolver;
|
||||
import org.springframework.web.servlet.HandlerExecutionChain;
|
||||
import org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerMapping;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
@ -26,18 +28,35 @@ import java.io.IOException;
|
||||
*/
|
||||
public class CryptoFilter implements Filter {
|
||||
private final ApiDecryptProperties properties;
|
||||
private final PathMatcher pathMatcher;
|
||||
|
||||
public CryptoFilter(ApiDecryptProperties properties) {
|
||||
public CryptoFilter(ApiDecryptProperties properties, PathMatcher pathMatcher) {
|
||||
this.properties = properties;
|
||||
this.pathMatcher = pathMatcher;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void doFilter(ServletRequest request, ServletResponse response, FilterChain chain) throws IOException, ServletException {
|
||||
HttpServletRequest servletRequest = (HttpServletRequest) request;
|
||||
HttpServletResponse servletResponse = (HttpServletResponse) response;
|
||||
|
||||
// 获取加密注解
|
||||
ApiEncrypt apiEncrypt = this.getApiEncryptAnnotation(servletRequest);
|
||||
boolean responseFlag = apiEncrypt != null && apiEncrypt.response();
|
||||
//ApiEncrypt apiEncrypt = this.getApiEncryptAnnotation(servletRequest);
|
||||
//boolean responseFlag = apiEncrypt != null && apiEncrypt.response();
|
||||
|
||||
//直接全局加密
|
||||
boolean responseFlag = false;
|
||||
|
||||
// 检查请求是否被排除
|
||||
if (isExcludedPath(servletRequest.getRequestURI())) {
|
||||
chain.doFilter(request, response);
|
||||
return;
|
||||
}
|
||||
if ("OPTIONS".equalsIgnoreCase(servletRequest.getMethod())) {
|
||||
chain.doFilter(request, response);
|
||||
return;
|
||||
}
|
||||
|
||||
ServletRequest requestWrapper = null;
|
||||
ServletResponse responseWrapper = null;
|
||||
EncryptResponseBodyWrapper responseBodyWrapper = null;
|
||||
@ -49,16 +68,18 @@ public class CryptoFilter implements Filter {
|
||||
if (StringUtils.isNotBlank(headerValue)) {
|
||||
// 请求解密
|
||||
requestWrapper = new DecryptRequestBodyWrapper(servletRequest, properties.getPrivateKey(), properties.getHeaderFlag());
|
||||
} else {
|
||||
// 是否有注解,有就报错,没有放行
|
||||
if (ObjectUtil.isNotNull(apiEncrypt)) {
|
||||
HandlerExceptionResolver exceptionResolver = SpringUtils.getBean("handlerExceptionResolver", HandlerExceptionResolver.class);
|
||||
exceptionResolver.resolveException(
|
||||
servletRequest, servletResponse, null,
|
||||
new ServiceException("没有访问权限,请联系管理员授权", HttpStatus.FORBIDDEN));
|
||||
return;
|
||||
}
|
||||
}
|
||||
// else {
|
||||
//// // 是否有注解,有就报错,没有放行
|
||||
//// if (ObjectUtil.isNotNull(apiEncrypt)) {
|
||||
//// HandlerExceptionResolver exceptionResolver = SpringUtils.getBean("handlerExceptionResolver", HandlerExceptionResolver.class);
|
||||
//// exceptionResolver.resolveException(
|
||||
//// servletRequest, servletResponse, null,
|
||||
//// new ServiceException("没有访问权限,请联系管理员授权", HttpStatus.FORBIDDEN));
|
||||
//// return;
|
||||
//// }
|
||||
// throw new ServiceException("无权访问接口", HttpStatus.BAD_METHOD);
|
||||
// }
|
||||
}
|
||||
|
||||
// 判断是否响应加密
|
||||
@ -81,6 +102,25 @@ public class CryptoFilter implements Filter {
|
||||
}
|
||||
}
|
||||
|
||||
private boolean isExcludedPath(String requestUri) {
|
||||
// 从配置中获取放行的URL列表
|
||||
List<String> excludedPaths = properties.getExcludedPaths();
|
||||
|
||||
if (CollectionUtils.isEmpty(excludedPaths)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
// 检查请求URI是否匹配任何一个放行路径
|
||||
for (String excludedPath : excludedPaths) {
|
||||
// 支持简单的Ant风格路径匹配(如 /api/public/**)
|
||||
if (pathMatcher.match(excludedPath, requestUri)) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取 ApiEncrypt 注解
|
||||
*/
|
||||
|
@ -3,6 +3,9 @@ package org.dromara.common.encrypt.properties;
|
||||
import lombok.Data;
|
||||
import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* api解密属性配置类
|
||||
* @author wdhcr
|
||||
@ -31,4 +34,10 @@ public class ApiDecryptProperties {
|
||||
*/
|
||||
private String privateKey;
|
||||
|
||||
/**
|
||||
* cory
|
||||
* 需要放行的接口路径列表(支持Ant风格路径匹配)
|
||||
*/
|
||||
private List<String> excludedPaths = new ArrayList<>();
|
||||
|
||||
}
|
||||
|
@ -0,0 +1,226 @@
|
||||
package org.dromara.common.excel.coryUtils;
|
||||
|
||||
import org.apache.poi.hssf.usermodel.HSSFSheet;
|
||||
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
|
||||
import org.apache.poi.ss.usermodel.Cell;
|
||||
import org.apache.poi.ss.usermodel.Row;
|
||||
import org.apache.poi.xssf.usermodel.XSSFSheet;
|
||||
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* 工程量清单解析
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/8/11 16:29
|
||||
* @Version 1.0
|
||||
*/
|
||||
public class BillOfQuantitiesUtils {
|
||||
// 中文数字正则表达式,用于检测顶层节点
|
||||
private static final String CHINESE_NUMBERS_REGEX = "[一二三四五六七八九十]+";
|
||||
// 标记是否已找到中文数字开头的行
|
||||
private static boolean foundChineseStart = false;
|
||||
|
||||
public static void main(String[] args) {
|
||||
try {
|
||||
// 文件路径,请根据实际情况修改
|
||||
FileInputStream file = new FileInputStream(new File(
|
||||
"E:\\cory\\app\\xwechat_files\\wxid_8q1mhp57yu6p22_50ad\\msg\\file\\2025-08\\设计管理模块说明\\8、工程量清单表.xls"));
|
||||
|
||||
HSSFWorkbook workbook = new HSSFWorkbook(file);
|
||||
|
||||
for (int sheetIndex = 0; sheetIndex < workbook.getNumberOfSheets(); sheetIndex++) {
|
||||
HSSFSheet sheet = workbook.getSheetAt(sheetIndex);
|
||||
System.out.println("===== 工作表: " + sheet.getSheetName() + " =====");
|
||||
|
||||
// 重置标记,处理新工作表时重新开始检测
|
||||
foundChineseStart = false;
|
||||
List<List<String>> data = new ArrayList<>();
|
||||
|
||||
boolean isFirstRow = true;
|
||||
for (Row row : sheet) {
|
||||
// 跳过表头行
|
||||
if (isFirstRow) {
|
||||
isFirstRow = false;
|
||||
continue;
|
||||
}
|
||||
|
||||
List<String> rowData = new ArrayList<>();
|
||||
// 读取A到E列(索引0到4)
|
||||
for (int cellIndex = 0; cellIndex < 5; cellIndex++) {
|
||||
Cell cell = row.getCell(cellIndex, Row.MissingCellPolicy.CREATE_NULL_AS_BLANK);
|
||||
rowData.add(getCellValue(cell));
|
||||
}
|
||||
|
||||
// 检查是否找到中文数字开头的行
|
||||
String aColumnValue = rowData.get(0).trim();
|
||||
if (aColumnValue.matches(CHINESE_NUMBERS_REGEX)) {
|
||||
foundChineseStart = true;
|
||||
}
|
||||
|
||||
// 只有找到中文数字开头的行之后,才开始收集数据
|
||||
if (foundChineseStart) {
|
||||
data.add(rowData);
|
||||
}
|
||||
}
|
||||
|
||||
if (!data.isEmpty()) {
|
||||
// 构建树形结构
|
||||
TreeNode root = new TreeNode(new ArrayList<>());
|
||||
Map<String, TreeNode> nodeMap = new HashMap<>();
|
||||
nodeMap.put("", root);
|
||||
List<String> nonEmptyKeys = new ArrayList<>(); // 记录非空A列值的顺序
|
||||
|
||||
for (List<String> row : data) {
|
||||
String key = row.get(0).trim();
|
||||
TreeNode node = new TreeNode(row);
|
||||
|
||||
if (!key.isEmpty()) {
|
||||
String parentKey = getParentKey(key);
|
||||
TreeNode parent = nodeMap.get(parentKey);
|
||||
|
||||
if (parent == null) {
|
||||
parent = new TreeNode(new ArrayList<>());
|
||||
nodeMap.put(parentKey, parent);
|
||||
TreeNode grandParent = nodeMap.get(getParentKey(parentKey));
|
||||
if (grandParent != null) {
|
||||
grandParent.addChild(parent);
|
||||
} else {
|
||||
// 如果没有更高级别的父节点,就挂到根节点
|
||||
root.addChild(parent);
|
||||
}
|
||||
}
|
||||
|
||||
parent.addChild(node);
|
||||
nodeMap.put(key, node);
|
||||
nonEmptyKeys.add(key);
|
||||
} else {
|
||||
// A列为空,挂到上一个非空节点下
|
||||
if (!nonEmptyKeys.isEmpty()) {
|
||||
String lastKey = nonEmptyKeys.get(nonEmptyKeys.size() - 1);
|
||||
TreeNode parent = nodeMap.get(lastKey);
|
||||
if (parent != null) {
|
||||
parent.addChild(node);
|
||||
}
|
||||
} else {
|
||||
root.addChild(node);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 打印树形结构
|
||||
printTree(root, 0);
|
||||
} else {
|
||||
System.out.println("该工作表中未找到以中文数字(一、二、三...)开头的数据行");
|
||||
}
|
||||
}
|
||||
|
||||
workbook.close();
|
||||
file.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取单元格的值,处理不同数据类型
|
||||
*/
|
||||
private static String getCellValue(Cell cell) {
|
||||
if (cell == null) {
|
||||
return "";
|
||||
}
|
||||
|
||||
switch (cell.getCellType()) {
|
||||
case STRING:
|
||||
return cell.getStringCellValue().trim();
|
||||
case NUMERIC:
|
||||
// 处理数字,移除不必要的.0后缀
|
||||
String numericValue = String.valueOf(cell.getNumericCellValue());
|
||||
if (numericValue.endsWith(".0")) {
|
||||
return numericValue.substring(0, numericValue.length() - 2);
|
||||
}
|
||||
return numericValue;
|
||||
case BOOLEAN:
|
||||
return String.valueOf(cell.getBooleanCellValue());
|
||||
default:
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据A列的值确定父节点的键
|
||||
*/
|
||||
private static String getParentKey(String key) {
|
||||
// 中文数字(一、二、三...)的父节点是根节点
|
||||
if (key.matches(CHINESE_NUMBERS_REGEX)) {
|
||||
return "";
|
||||
}
|
||||
|
||||
// 数字格式(1、1.1、1.2.1等)的父节点是上一级
|
||||
if (key.matches("\\d+(\\.\\d+)*")) {
|
||||
int lastDotIndex = key.lastIndexOf('.');
|
||||
if (lastDotIndex > 0) {
|
||||
return key.substring(0, lastDotIndex);
|
||||
} else {
|
||||
// 一级数字(如1、2)的父节点是根节点或最近的中文数字节点
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
// 其他格式默认父节点是根节点
|
||||
return "";
|
||||
}
|
||||
|
||||
/**
|
||||
* 以可视化方式打印树形结构
|
||||
*/
|
||||
private static void printTree(TreeNode node, int depth) {
|
||||
// 跳过空的中间节点
|
||||
if (node.data.isEmpty() && node.children.size() == 1) {
|
||||
printTree(node.children.get(0), depth);
|
||||
return;
|
||||
}
|
||||
|
||||
if (!node.data.isEmpty()) {
|
||||
// 打印层级连接线
|
||||
for (int i = 0; i < depth; i++) {
|
||||
// 最后一级节点用└──,其他用├──
|
||||
if (i == depth - 1) {
|
||||
System.out.print("└── ");
|
||||
} else {
|
||||
System.out.print("│ ");
|
||||
}
|
||||
}
|
||||
// 打印数据,突出显示A列的值
|
||||
System.out.println("[" + node.data.get(0) + "] " + node.data.subList(1, node.data.size()));
|
||||
}
|
||||
|
||||
// 递归打印子节点
|
||||
for (TreeNode child : node.children) {
|
||||
printTree(child, depth + 1);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 树形节点类
|
||||
*/
|
||||
static class TreeNode {
|
||||
List<String> data;
|
||||
List<TreeNode> children;
|
||||
|
||||
TreeNode(List<String> data) {
|
||||
this.data = data;
|
||||
this.children = new ArrayList<>();
|
||||
}
|
||||
|
||||
void addChild(TreeNode child) {
|
||||
this.children.add(child);
|
||||
}
|
||||
}
|
||||
}
|
@ -0,0 +1,484 @@
|
||||
package org.dromara.common.excel.coryUtils;
|
||||
|
||||
import org.apache.poi.hssf.usermodel.HSSFSheet;
|
||||
import org.apache.poi.hssf.usermodel.HSSFWorkbook;
|
||||
import org.apache.poi.ss.usermodel.Cell;
|
||||
import org.apache.poi.ss.usermodel.Row;
|
||||
import org.apache.poi.xssf.usermodel.XSSFSheet;
|
||||
import org.apache.poi.xssf.usermodel.XSSFWorkbook;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/8/11 16:44
|
||||
* @Version 1.0
|
||||
*/
|
||||
public class ExcelReader {
|
||||
// 中文数字正则表达式,用于检测顶层节点
|
||||
public static final String CHINESE_NUMBERS_REGEX = "[一二三四五六七八九十]+";
|
||||
|
||||
public static void main(String[] args) {
|
||||
try {
|
||||
// 1. 读取Excel中所有sheet的完整数据
|
||||
String filePath = "E:\\cory\\app\\xwechat_files\\wxid_8q1mhp57yu6p22_50ad\\msg\\file\\2025-08\\设计管理模块说明\\8、工程量清单表.xls";
|
||||
ExcelData excelData = readExcelData(filePath);
|
||||
// ExcelData excelData = ExcelReader.readExcelFromMultipartFile(file);
|
||||
|
||||
// 2. 处理每个sheet的数据并打印树形结构
|
||||
for (SheetData sheetData : excelData.getSheetDataList()) {
|
||||
System.out.println("===== 工作表: " + sheetData.getSheetName() + " =====");
|
||||
|
||||
if (sheetData.getData().isEmpty()) {
|
||||
System.out.println("该工作表中未找到以中文数字(一、二、三...)开头的数据行");
|
||||
continue;
|
||||
}
|
||||
|
||||
// 构建树形结构
|
||||
TreeNode root = buildTree(sheetData.getData());
|
||||
|
||||
// 打印树形结构
|
||||
printTree(root, 0);
|
||||
}
|
||||
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 从MultipartFile读取Excel数据
|
||||
*/
|
||||
public static ExcelData readExcelFromMultipartFile(MultipartFile file) throws IOException {
|
||||
if (file.isEmpty()) {
|
||||
throw new IllegalArgumentException("上传的文件为空");
|
||||
}
|
||||
|
||||
ExcelData excelData = new ExcelData();
|
||||
List<SheetData> sheetDataList = new ArrayList<>();
|
||||
|
||||
// 获取文件名判断文件类型
|
||||
String fileName = file.getOriginalFilename();
|
||||
if (fileName == null || (!fileName.toLowerCase().endsWith(".xls") && !fileName.toLowerCase().endsWith(".xlsx"))) {
|
||||
throw new IllegalArgumentException("不支持的文件类型,仅支持xls和xlsx格式");
|
||||
}
|
||||
|
||||
boolean isXlsx = fileName.toLowerCase().endsWith(".xlsx");
|
||||
|
||||
// 从MultipartFile获取输入流
|
||||
try (InputStream stream = file.getInputStream();
|
||||
org.apache.poi.ss.usermodel.Workbook workbook = isXlsx ?
|
||||
new XSSFWorkbook(stream) : new HSSFWorkbook(stream)) {
|
||||
|
||||
for (int sheetIndex = 0; sheetIndex < workbook.getNumberOfSheets(); sheetIndex++) {
|
||||
org.apache.poi.ss.usermodel.Sheet sheet = workbook.getSheetAt(sheetIndex);
|
||||
SheetData sheetData = new SheetData();
|
||||
sheetData.setSheetName(sheet.getSheetName());
|
||||
|
||||
processSheetData(sheet, sheetData);
|
||||
sheetDataList.add(sheetData);
|
||||
}
|
||||
}
|
||||
|
||||
excelData.setSheetDataList(sheetDataList);
|
||||
return excelData;
|
||||
}
|
||||
|
||||
/**
|
||||
* 文件路径来读取
|
||||
* 读取Excel文件的完整数据并封装为实体
|
||||
*/
|
||||
public static ExcelData readExcelData(String filePath) throws IOException {
|
||||
ExcelData excelData = new ExcelData();
|
||||
List<SheetData> sheetDataList = new ArrayList<>();
|
||||
|
||||
FileInputStream file = new FileInputStream(new File(filePath));
|
||||
boolean isXlsx = filePath.toLowerCase().endsWith(".xlsx");
|
||||
|
||||
// 根据文件后缀选择对应的Workbook实现
|
||||
try (org.apache.poi.ss.usermodel.Workbook workbook = isXlsx ?
|
||||
new XSSFWorkbook(file) : new HSSFWorkbook(file)) {
|
||||
|
||||
for (int sheetIndex = 0; sheetIndex < workbook.getNumberOfSheets(); sheetIndex++) {
|
||||
org.apache.poi.ss.usermodel.Sheet sheet = workbook.getSheetAt(sheetIndex);
|
||||
SheetData sheetData = new SheetData();
|
||||
sheetData.setSheetName(sheet.getSheetName());
|
||||
|
||||
// 处理单个sheet的数据
|
||||
processSheetData(sheet, sheetData);
|
||||
|
||||
sheetDataList.add(sheetData);
|
||||
}
|
||||
} finally {
|
||||
file.close();
|
||||
}
|
||||
|
||||
excelData.setSheetDataList(sheetDataList);
|
||||
return excelData;
|
||||
}
|
||||
|
||||
/**
|
||||
* 处理单个工作表的数据
|
||||
*/
|
||||
private static void processSheetData(org.apache.poi.ss.usermodel.Sheet sheet, SheetData sheetData) {
|
||||
boolean foundChineseStart = false;
|
||||
List<List<String>> data = new ArrayList<>();
|
||||
boolean isFirstRow = true;
|
||||
|
||||
for (Row row : sheet) {
|
||||
// 跳过表头行
|
||||
if (isFirstRow) {
|
||||
isFirstRow = false;
|
||||
continue;
|
||||
}
|
||||
|
||||
List<String> rowData = new ArrayList<>();
|
||||
// 读取A到E列(索引0到4)
|
||||
for (int cellIndex = 0; cellIndex < 5; cellIndex++) {
|
||||
Cell cell = row.getCell(cellIndex, Row.MissingCellPolicy.CREATE_NULL_AS_BLANK);
|
||||
rowData.add(getCellValue(cell));
|
||||
}
|
||||
|
||||
// 检查是否找到中文数字开头的行
|
||||
String aColumnValue = rowData.get(0).trim();
|
||||
if (aColumnValue.matches(CHINESE_NUMBERS_REGEX)) {
|
||||
foundChineseStart = true;
|
||||
}
|
||||
|
||||
// 只有找到中文数字开头的行之后,才开始收集数据
|
||||
if (foundChineseStart) {
|
||||
data.add(rowData);
|
||||
}
|
||||
}
|
||||
|
||||
sheetData.setData(data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据数据构建树形结构
|
||||
*/
|
||||
public static TreeNode buildTree(List<List<String>> data) {
|
||||
TreeNode root = new TreeNode(new ArrayList<>());
|
||||
Map<String, TreeNode> nodeMap = new HashMap<>();
|
||||
nodeMap.put("", root);
|
||||
List<String> nonEmptyKeys = new ArrayList<>(); // 记录非空A列值的顺序
|
||||
Map<String, String> lastChineseNumberMap = new HashMap<>(); // 记录各级别最近的中文数字节点
|
||||
|
||||
// 初始化根级中文数字节点
|
||||
lastChineseNumberMap.put("", "");
|
||||
|
||||
for (List<String> row : data) {
|
||||
String key = row.get(0).trim();
|
||||
TreeNode node = new TreeNode(row);
|
||||
|
||||
if (!key.isEmpty()) {
|
||||
String parentKey = getParentKey(key, lastChineseNumberMap, nonEmptyKeys);
|
||||
|
||||
// 更新最近的中文数字节点记录
|
||||
if (key.matches(CHINESE_NUMBERS_REGEX)) {
|
||||
String currentLevelParentKey = getParentKey(key, lastChineseNumberMap, nonEmptyKeys);
|
||||
lastChineseNumberMap.put(key, key);
|
||||
lastChineseNumberMap.put(parentKey + ".children", key);
|
||||
}
|
||||
|
||||
TreeNode parent = nodeMap.get(parentKey);
|
||||
|
||||
if (parent == null) {
|
||||
parent = new TreeNode(new ArrayList<>());
|
||||
nodeMap.put(parentKey, parent);
|
||||
TreeNode grandParent = nodeMap.get(getParentKey(parentKey, lastChineseNumberMap, nonEmptyKeys));
|
||||
if (grandParent != null) {
|
||||
parent.setParent(grandParent);
|
||||
grandParent.addChild(parent);
|
||||
} else {
|
||||
// 如果没有更高级别的父节点,就挂到根节点
|
||||
parent.setParent(root);
|
||||
root.addChild(parent);
|
||||
}
|
||||
}
|
||||
|
||||
node.setParent(parent);
|
||||
parent.addChild(node);
|
||||
nodeMap.put(key, node);
|
||||
nonEmptyKeys.add(key);
|
||||
} else {
|
||||
// A列为空,挂到上一个非空节点下
|
||||
if (!nonEmptyKeys.isEmpty()) {
|
||||
String lastKey = nonEmptyKeys.get(nonEmptyKeys.size() - 1);
|
||||
TreeNode parent = nodeMap.get(lastKey);
|
||||
if (parent != null) {
|
||||
node.setParent(parent);
|
||||
parent.addChild(node);
|
||||
}
|
||||
} else {
|
||||
node.setParent(root);
|
||||
root.addChild(node);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return root;
|
||||
}
|
||||
// public static TreeNode buildTree(List<List<String>> data) {
|
||||
// TreeNode root = new TreeNode(new ArrayList<>());
|
||||
// Map<String, TreeNode> nodeMap = new HashMap<>();
|
||||
// nodeMap.put("", root);
|
||||
// List<String> nonEmptyKeys = new ArrayList<>(); // 记录非空A列值的顺序
|
||||
//
|
||||
// for (List<String> row : data) {
|
||||
// String key = row.get(0).trim();
|
||||
// TreeNode node = new TreeNode(row);
|
||||
//
|
||||
// if (!key.isEmpty()) {
|
||||
// String parentKey = getParentKey(key);
|
||||
// TreeNode parent = nodeMap.get(parentKey);
|
||||
//
|
||||
// if (parent == null) {
|
||||
// parent = new TreeNode(new ArrayList<>());
|
||||
// nodeMap.put(parentKey, parent);
|
||||
// TreeNode grandParent = nodeMap.get(getParentKey(parentKey));
|
||||
// if (grandParent != null) {
|
||||
// grandParent.addChild(parent);
|
||||
// } else {
|
||||
// // 如果没有更高级别的父节点,就挂到根节点
|
||||
// root.addChild(parent);
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// parent.addChild(node);
|
||||
// nodeMap.put(key, node);
|
||||
// nonEmptyKeys.add(key);
|
||||
// } else {
|
||||
// // A列为空,挂到上一个非空节点下
|
||||
// if (!nonEmptyKeys.isEmpty()) {
|
||||
// String lastKey = nonEmptyKeys.get(nonEmptyKeys.size() - 1);
|
||||
// TreeNode parent = nodeMap.get(lastKey);
|
||||
// if (parent != null) {
|
||||
// parent.addChild(node);
|
||||
// }
|
||||
// } else {
|
||||
// root.addChild(node);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// return root;
|
||||
// }
|
||||
|
||||
/**
|
||||
* 以可视化方式打印树形结构
|
||||
*/
|
||||
public static void printTree(TreeNode node, int depth) {
|
||||
// 跳过空的中间节点
|
||||
if (node.data.isEmpty() && node.children.size() == 1) {
|
||||
printTree(node.children.get(0), depth);
|
||||
return;
|
||||
}
|
||||
|
||||
if (!node.data.isEmpty()) {
|
||||
// 打印层级连接线
|
||||
for (int i = 0; i < depth; i++) {
|
||||
// 最后一级节点用└──,其他用├──
|
||||
if (i == depth - 1) {
|
||||
System.out.print("└── ");
|
||||
} else {
|
||||
System.out.print("│ ");
|
||||
}
|
||||
}
|
||||
// 打印数据,突出显示A列的值
|
||||
System.out.println("[" + node.data.get(0) + "] " + node.data.subList(1, node.data.size()));
|
||||
}
|
||||
|
||||
// 递归打印子节点
|
||||
for (TreeNode child : node.children) {
|
||||
printTree(child, depth + 1);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取单元格的值,处理不同数据类型
|
||||
*/
|
||||
private static String getCellValue(Cell cell) {
|
||||
if (cell == null) {
|
||||
return "";
|
||||
}
|
||||
|
||||
switch (cell.getCellType()) {
|
||||
case STRING:
|
||||
return cell.getStringCellValue().trim();
|
||||
case NUMERIC:
|
||||
// 处理数字,移除不必要的.0后缀
|
||||
String numericValue = String.valueOf(cell.getNumericCellValue());
|
||||
if (numericValue.endsWith(".0")) {
|
||||
return numericValue.substring(0, numericValue.length() - 2);
|
||||
}
|
||||
return numericValue;
|
||||
case BOOLEAN:
|
||||
return String.valueOf(cell.getBooleanCellValue());
|
||||
default:
|
||||
return "";
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据A列的值确定父节点的键
|
||||
*/
|
||||
private static String getParentKey(String key, Map<String, String> lastChineseNumberMap, List<String> nonEmptyKeys) {
|
||||
// 中文数字(一、二、三...)的父节点是根节点
|
||||
if (key.matches(CHINESE_NUMBERS_REGEX)) {
|
||||
return "";
|
||||
}
|
||||
|
||||
// 数字格式(1、1.1、1.2.1等)的父节点是上一级
|
||||
if (key.matches("\\d+(\\.\\d+)*")) {
|
||||
int lastDotIndex = key.lastIndexOf('.');
|
||||
if (lastDotIndex > 0) {
|
||||
return key.substring(0, lastDotIndex);
|
||||
} else {
|
||||
// 一级数字(如1、2)的父节点是最近的中文数字节点
|
||||
if (!nonEmptyKeys.isEmpty()) {
|
||||
// 查找最近的中文数字节点作为父节点
|
||||
for (int i = nonEmptyKeys.size() - 1; i >= 0; i--) {
|
||||
String prevKey = nonEmptyKeys.get(i);
|
||||
if (prevKey.matches(CHINESE_NUMBERS_REGEX)) {
|
||||
return prevKey;
|
||||
}
|
||||
}
|
||||
}
|
||||
// 如果没有找到中文数字节点,使用根节点
|
||||
return lastChineseNumberMap.getOrDefault("", "");
|
||||
}
|
||||
}
|
||||
|
||||
// 其他格式默认父节点是根节点
|
||||
return "";
|
||||
}
|
||||
// private static String getParentKey(String key) {
|
||||
// // 中文数字(一、二、三...)的父节点是根节点
|
||||
// if (key.matches(CHINESE_NUMBERS_REGEX)) {
|
||||
// return "";
|
||||
// }
|
||||
//
|
||||
// // 数字格式(1、1.1、1.2.1等)的父节点是上一级
|
||||
// if (key.matches("\\d+(\\.\\d+)*")) {
|
||||
// int lastDotIndex = key.lastIndexOf('.');
|
||||
// if (lastDotIndex > 0) {
|
||||
// return key.substring(0, lastDotIndex);
|
||||
// } else {
|
||||
// // 一级数字(如1、2)的父节点是根节点或最近的中文数字节点
|
||||
// return "";
|
||||
// }
|
||||
// }
|
||||
//
|
||||
// // 其他格式默认父节点是根节点
|
||||
// return "";
|
||||
// }
|
||||
|
||||
/**
|
||||
* Excel数据实体类,包含所有工作表数据
|
||||
*/
|
||||
public static class ExcelData {
|
||||
private List<SheetData> sheetDataList;
|
||||
|
||||
public List<SheetData> getSheetDataList() {
|
||||
return sheetDataList;
|
||||
}
|
||||
|
||||
public void setSheetDataList(List<SheetData> sheetDataList) {
|
||||
this.sheetDataList = sheetDataList;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 工作表数据实体类,包含单个工作表的名称和数据
|
||||
*/
|
||||
public static class SheetData {
|
||||
private String sheetName;
|
||||
private List<List<String>> data;
|
||||
|
||||
public String getSheetName() {
|
||||
return sheetName;
|
||||
}
|
||||
|
||||
public void setSheetName(String sheetName) {
|
||||
this.sheetName = sheetName;
|
||||
}
|
||||
|
||||
public List<List<String>> getData() {
|
||||
return data;
|
||||
}
|
||||
|
||||
public void setData(List<List<String>> data) {
|
||||
this.data = data;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 树形节点类
|
||||
*/
|
||||
/**
|
||||
* 树形节点类,增加了父节点引用
|
||||
*/
|
||||
public static class TreeNode {
|
||||
List<String> data;
|
||||
List<TreeNode> children;
|
||||
TreeNode parent; // 新增:父节点引用
|
||||
|
||||
public TreeNode(List<String> data) {
|
||||
this.data = data;
|
||||
this.children = new ArrayList<>();
|
||||
this.parent = null;
|
||||
}
|
||||
|
||||
public void addChild(TreeNode child) {
|
||||
this.children.add(child);
|
||||
}
|
||||
|
||||
public List<String> getData() {
|
||||
return data;
|
||||
}
|
||||
|
||||
public List<TreeNode> getChildren() {
|
||||
return children;
|
||||
}
|
||||
|
||||
public TreeNode getParent() {
|
||||
return parent;
|
||||
}
|
||||
|
||||
public void setParent(TreeNode parent) {
|
||||
this.parent = parent;
|
||||
}
|
||||
}
|
||||
// public static class TreeNode {
|
||||
// List<String> data;
|
||||
// List<TreeNode> children;
|
||||
//
|
||||
// public TreeNode(List<String> data) {
|
||||
// this.data = data;
|
||||
// this.children = new ArrayList<>();
|
||||
// }
|
||||
//
|
||||
// public void addChild(TreeNode child) {
|
||||
// this.children.add(child);
|
||||
// }
|
||||
//
|
||||
// public List<String> getData() {
|
||||
// return data;
|
||||
// }
|
||||
//
|
||||
// public List<TreeNode> getChildren() {
|
||||
// return children;
|
||||
// }
|
||||
// }
|
||||
|
||||
}
|
@ -0,0 +1,23 @@
|
||||
package org.dromara.common.excel.coryUtils;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/8/11 16:44
|
||||
* @Version 1.0
|
||||
*/
|
||||
public class TreeNode {
|
||||
List<String> data;
|
||||
List<TreeNode> children;
|
||||
|
||||
TreeNode(List<String> data) {
|
||||
this.data = data;
|
||||
this.children = new ArrayList<>();
|
||||
}
|
||||
|
||||
void addChild(TreeNode child) {
|
||||
this.children.add(child);
|
||||
}
|
||||
}
|
@ -26,6 +26,11 @@
|
||||
<artifactId>ruoyi-common-satoken</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-doc</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- dynamic-datasource 多数据源-->
|
||||
<dependency>
|
||||
<groupId>com.baomidou</groupId>
|
||||
|
@ -33,8 +33,8 @@ public class BaseEntity implements Serializable {
|
||||
/**
|
||||
* 创建部门
|
||||
*/
|
||||
/* @TableField(fill = FieldFill.INSERT)
|
||||
private Long createDept;*/
|
||||
@TableField(fill = FieldFill.INSERT)
|
||||
private Long createDept;
|
||||
|
||||
/**
|
||||
* 创建者
|
||||
|
@ -44,7 +44,7 @@ public class InjectionMetaObjectHandler implements MetaObjectHandler {
|
||||
// 填充创建人、更新人和创建部门信息
|
||||
baseEntity.setCreateBy(userId);
|
||||
baseEntity.setUpdateBy(userId);
|
||||
// baseEntity.setCreateDept(ObjectUtils.notNull(baseEntity.getCreateDept(), loginUser.getDeptId()));
|
||||
baseEntity.setCreateDept(ObjectUtils.notNull(baseEntity.getCreateDept(), loginUser.getDeptId()));
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
@ -1,5 +1,6 @@
|
||||
package org.dromara.common.mybatis.handler;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Hidden;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.dromara.common.core.domain.R;
|
||||
@ -15,6 +16,7 @@ import org.springframework.web.bind.annotation.RestControllerAdvice;
|
||||
* @author Lion Li
|
||||
*/
|
||||
@Slf4j
|
||||
@Hidden
|
||||
@RestControllerAdvice
|
||||
public class MybatisExceptionHandler {
|
||||
|
||||
|
@ -22,6 +22,11 @@
|
||||
<artifactId>ruoyi-common-core</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-doc</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!--redisson-->
|
||||
<dependency>
|
||||
<groupId>org.redisson</groupId>
|
||||
|
@ -2,6 +2,7 @@ package org.dromara.common.redis.handler;
|
||||
|
||||
import cn.hutool.http.HttpStatus;
|
||||
import com.baomidou.lock.exception.LockFailureException;
|
||||
import io.swagger.v3.oas.annotations.Hidden;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.dromara.common.core.domain.R;
|
||||
@ -14,6 +15,7 @@ import org.springframework.web.bind.annotation.RestControllerAdvice;
|
||||
* @author AprilWind
|
||||
*/
|
||||
@Slf4j
|
||||
@Hidden
|
||||
@RestControllerAdvice
|
||||
public class RedisExceptionHandler {
|
||||
|
||||
|
@ -77,6 +77,7 @@ public class RedisUtils {
|
||||
public static <T> void publish(String channelKey, T msg, Consumer<T> consumer) {
|
||||
RTopic topic = CLIENT.getTopic(channelKey);
|
||||
topic.publish(msg);
|
||||
System.out.println("发布通道消息---------"+msg.toString());
|
||||
consumer.accept(msg);
|
||||
}
|
||||
|
||||
|
@ -24,6 +24,11 @@
|
||||
<artifactId>ruoyi-common-redis</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-doc</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- Sa-Token 权限认证, 在线文档:http://sa-token.dev33.cn/ -->
|
||||
<dependency>
|
||||
<groupId>cn.dev33</groupId>
|
||||
|
@ -4,6 +4,7 @@ import cn.dev33.satoken.exception.NotLoginException;
|
||||
import cn.dev33.satoken.exception.NotPermissionException;
|
||||
import cn.dev33.satoken.exception.NotRoleException;
|
||||
import cn.hutool.http.HttpStatus;
|
||||
import io.swagger.v3.oas.annotations.Hidden;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.dromara.common.core.domain.R;
|
||||
@ -16,6 +17,7 @@ import org.springframework.web.bind.annotation.RestControllerAdvice;
|
||||
* @author Lion Li
|
||||
*/
|
||||
@Slf4j
|
||||
@Hidden
|
||||
@RestControllerAdvice
|
||||
public class SaTokenExceptionHandler {
|
||||
|
||||
|
@ -28,6 +28,11 @@
|
||||
<artifactId>ruoyi-common-redis</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-doc</artifactId>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
</project>
|
||||
|
@ -1,6 +1,7 @@
|
||||
package org.dromara.common.sms.handler;
|
||||
|
||||
import cn.hutool.http.HttpStatus;
|
||||
import io.swagger.v3.oas.annotations.Hidden;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.dromara.common.core.domain.R;
|
||||
@ -14,6 +15,7 @@ import org.springframework.web.bind.annotation.RestControllerAdvice;
|
||||
* @author AprilWind
|
||||
*/
|
||||
@Slf4j
|
||||
@Hidden
|
||||
@RestControllerAdvice
|
||||
public class SmsExceptionHandler {
|
||||
|
||||
|
@ -134,6 +134,8 @@ public class SseEmitterManager {
|
||||
SseMessageDto broadcastMessage = new SseMessageDto();
|
||||
broadcastMessage.setMessage(sseMessageDto.getMessage());
|
||||
broadcastMessage.setUserIds(sseMessageDto.getUserIds());
|
||||
broadcastMessage.setRoute(sseMessageDto.getRoute());
|
||||
broadcastMessage.setDetailId(sseMessageDto.getDetailId());
|
||||
RedisUtils.publish(SSE_TOPIC, broadcastMessage, consumer -> {
|
||||
log.info("SSE发送主题订阅消息topic:{} session keys:{} message:{}",
|
||||
SSE_TOPIC, sseMessageDto.getUserIds(), sseMessageDto.getMessage());
|
||||
|
@ -26,4 +26,15 @@ public class SseMessageDto implements Serializable {
|
||||
* 需要发送的消息
|
||||
*/
|
||||
private String message;
|
||||
|
||||
/**
|
||||
* 路由
|
||||
*/
|
||||
private String route;
|
||||
|
||||
/**
|
||||
* 详情
|
||||
*/
|
||||
private String detailId;
|
||||
|
||||
}
|
||||
|
@ -7,6 +7,9 @@ import org.dromara.common.core.utils.SpringUtils;
|
||||
import org.dromara.common.sse.core.SseEmitterManager;
|
||||
import org.dromara.common.sse.dto.SseMessageDto;
|
||||
|
||||
import java.lang.reflect.Array;
|
||||
import java.util.Arrays;
|
||||
|
||||
/**
|
||||
* SSE工具类
|
||||
*
|
||||
|
@ -26,6 +26,11 @@
|
||||
<artifactId>ruoyi-common-redis</artifactId>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-common-doc</artifactId>
|
||||
</dependency>
|
||||
|
||||
<!-- SpringBoot Web容器 -->
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
|
@ -3,6 +3,7 @@ package org.dromara.common.web.handler;
|
||||
import cn.hutool.core.text.AntPathMatcher;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import cn.hutool.http.HttpStatus;
|
||||
import io.swagger.v3.oas.annotations.Hidden;
|
||||
import jakarta.servlet.ServletException;
|
||||
import jakarta.servlet.http.HttpServletRequest;
|
||||
import jakarta.validation.ConstraintViolation;
|
||||
@ -34,6 +35,7 @@ import java.io.IOException;
|
||||
* @author Lion Li
|
||||
*/
|
||||
@Slf4j
|
||||
@Hidden
|
||||
@RestControllerAdvice
|
||||
public class GlobalExceptionHandler {
|
||||
|
||||
|
@ -38,7 +38,7 @@ spring.boot.admin.client:
|
||||
# 增加客户端开关
|
||||
enabled: true
|
||||
# 设置 Spring Boot Admin Server 地址
|
||||
url: http://localhost:9090/admin
|
||||
url: http://192.168.110.119:9090/admin
|
||||
instance:
|
||||
service-host-type: IP
|
||||
metadata:
|
||||
|
@ -2,9 +2,9 @@ spring:
|
||||
datasource:
|
||||
type: com.zaxxer.hikari.HikariDataSource
|
||||
driver-class-name: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://localhost:3306/ry-vue?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true
|
||||
username: root
|
||||
password: root
|
||||
url: jdbc:mysql://192.168.110.2:13386/xinnengyuandev?useUnicode=true&characterEncoding=UTF-8&serverTimezone=Asia/Shanghai&allowPublicKeyRetrieval=true
|
||||
username: xinnengyuandev
|
||||
password: StRWCZdZirysNSs2
|
||||
hikari:
|
||||
connection-timeout: 30000
|
||||
validation-timeout: 5000
|
||||
@ -43,7 +43,7 @@ snail-job:
|
||||
spring.boot.admin.client:
|
||||
# 增加客户端开关
|
||||
enabled: true
|
||||
url: http://localhost:9090/admin
|
||||
url: http://192.168.110.119:9090/admin
|
||||
instance:
|
||||
service-host-type: IP
|
||||
metadata:
|
||||
|
@ -2,11 +2,13 @@ package ${packageName}.service;
|
||||
|
||||
import ${packageName}.domain.vo.${ClassName}Vo;
|
||||
import ${packageName}.domain.bo.${ClassName}Bo;
|
||||
import ${packageName}.domain.${ClassName};
|
||||
#if($table.crud)
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
#end
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
@ -16,7 +18,7 @@ import java.util.List;
|
||||
* @author ${author}
|
||||
* @date ${datetime}
|
||||
*/
|
||||
public interface I${ClassName}Service {
|
||||
public interface I${ClassName}Service extends IService<${ClassName}>{
|
||||
|
||||
/**
|
||||
* 查询${functionName}
|
||||
|
@ -29,7 +29,7 @@ import java.util.Collection;
|
||||
*/
|
||||
@RequiredArgsConstructor
|
||||
@Service
|
||||
public class ${ClassName}ServiceImpl implements I${ClassName}Service {
|
||||
public class ${ClassName}ServiceImpl extends ServiceImpl<${ClassName}Mapper, ${ClassName}> implements I${ClassName}Service {
|
||||
|
||||
private final ${ClassName}Mapper baseMapper;
|
||||
|
||||
@ -97,7 +97,7 @@ public class ${ClassName}ServiceImpl implements I${ClassName}Service {
|
||||
#end
|
||||
#set($AttrName=$column.javaField.substring(0,1).toUpperCase() + ${column.javaField.substring(1)})
|
||||
#if($column.isPk==1)
|
||||
lqw.orderByAsc(${ClassName}::get$AttrName);
|
||||
lqw.orderByDesc(${ClassName}::get$AttrName);
|
||||
#end
|
||||
#end
|
||||
return lqw;
|
||||
|
@ -16,10 +16,13 @@
|
||||
</description>
|
||||
|
||||
|
||||
|
||||
|
||||
<dependencies>
|
||||
|
||||
<!-- JSON解析(FastJSON) -->
|
||||
<dependency>
|
||||
<groupId>com.alibaba</groupId>
|
||||
<artifactId>fastjson</artifactId>
|
||||
<version>2.0.32</version>
|
||||
</dependency>
|
||||
<!-- word转pdf转图片 -->
|
||||
<!-- docx4j 核心 -->
|
||||
<dependency>
|
||||
@ -62,12 +65,38 @@
|
||||
<version>2.0.29</version>
|
||||
</dependency>
|
||||
|
||||
<!-- word 模版导出 poi-tl 模板引擎 -->
|
||||
<dependency>
|
||||
<groupId>com.deepoove</groupId>
|
||||
<artifactId>poi-tl</artifactId>
|
||||
<version>1.12.2</version> <!-- 建议使用最新版本 -->
|
||||
</dependency>
|
||||
|
||||
<!-- 在pdf上生成二维码 -->
|
||||
<!-- 支持中文字体 -->
|
||||
<dependency>
|
||||
<groupId>com.itextpdf</groupId>
|
||||
<artifactId>itext-asian</artifactId>
|
||||
<version>5.2.0</version>
|
||||
</dependency>
|
||||
<!-- iText -->
|
||||
<dependency>
|
||||
<groupId>com.itextpdf</groupId>
|
||||
<artifactId>itextpdf</artifactId>
|
||||
<version>5.5.13.3</version>
|
||||
</dependency>
|
||||
<!-- ZXing -->
|
||||
<dependency>
|
||||
<groupId>com.google.zxing</groupId>
|
||||
<artifactId>core</artifactId>
|
||||
<version>3.5.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.google.zxing</groupId>
|
||||
<artifactId>javase</artifactId>
|
||||
<version>3.5.2</version>
|
||||
</dependency>
|
||||
|
||||
<!-- 通用工具-->
|
||||
<dependency>
|
||||
<groupId>org.dromara</groupId>
|
||||
@ -165,6 +194,28 @@
|
||||
<groupId>org.dromara</groupId>
|
||||
<artifactId>ruoyi-workflow</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.google.code.gson</groupId>
|
||||
<artifactId>gson</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.scala-lang</groupId>
|
||||
<artifactId>scala-library</artifactId>
|
||||
<version>2.13.9</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>net.java.dev.jna</groupId>
|
||||
<artifactId>jna-platform</artifactId>
|
||||
<version>5.15.0</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.xmlbeans</groupId>
|
||||
<artifactId>xmlbeans</artifactId>
|
||||
<version>5.3.0</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
|
||||
</dependencies>
|
||||
|
||||
|
@ -0,0 +1,251 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.dromara.cailiaoshebei.domain.BusCailiaoshebeiPici;
|
||||
import org.dromara.cailiaoshebei.domain.bo.*;
|
||||
import org.dromara.cailiaoshebei.domain.vo.*;
|
||||
import org.dromara.cailiaoshebei.service.IBusCailiaoshebeiPiciService;
|
||||
import org.dromara.common.utils.BatchNumberGenerator;
|
||||
import org.dromara.design.domain.bo.ObtainTheListReq;
|
||||
import org.dromara.design.domain.vo.ObtainTheListRes;
|
||||
import org.dromara.design.service.IBusBillofquantitiesVersionsService;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.cailiaoshebei.service.IBusCailiaoshebeiService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 物资-材料设备
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-07-31
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/cailiaoshebei")
|
||||
public class BusCailiaoshebeiController extends BaseController {
|
||||
|
||||
private final IBusCailiaoshebeiService busCailiaoshebeiService;
|
||||
private final IBusCailiaoshebeiPiciService busCailiaoshebeiPiciService;
|
||||
|
||||
|
||||
//===============================设计===============================
|
||||
|
||||
/**
|
||||
* 设计-新增批次号
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:pcAdd")
|
||||
@Log(title = "设计-新增批次号", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping("/pcAdd")
|
||||
public R<Void> pcAdd(@Validated(AddGroup.class) @RequestBody BusCailiaoshebeiPiciAddReq bo) {
|
||||
BusCailiaoshebeiPici busCailiaoshebeiPici = new BusCailiaoshebeiPici().
|
||||
setProjectId(bo.getProjectId()).
|
||||
setBatchType("1").
|
||||
setBatchNumber(BatchNumberGenerator.generateBatchNumber("PC-"));
|
||||
return toAjax(busCailiaoshebeiPiciService.save(busCailiaoshebeiPici));
|
||||
}
|
||||
|
||||
/**
|
||||
* 设计-批次号列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:pcList")
|
||||
@GetMapping("/pcList")
|
||||
public TableDataInfo<BusCailiaoshebeiPiciVo> pcList(BusCailiaoshebeiPiciPcListReq bo, PageQuery pageQuery) {
|
||||
BusCailiaoshebeiPiciBo busCailiaoshebeiPiciBo = BeanUtil.copyProperties(bo, BusCailiaoshebeiPiciBo.class);
|
||||
// busCailiaoshebeiPiciBo.setCxsj("1"); //作为查询数据-设计
|
||||
busCailiaoshebeiPiciBo.setBatchType("1");
|
||||
return busCailiaoshebeiPiciService.queryPageList(busCailiaoshebeiPiciBo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 设计-批次号详细信息
|
||||
*
|
||||
* @param batchNumber 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:spQuery")
|
||||
@GetMapping("/spQuery/{batchNumber}")
|
||||
public R<BusCailiaoshebeiPici> spQuery(@NotNull(message = "主键不能为空") @PathVariable String batchNumber) {
|
||||
return R.ok(busCailiaoshebeiPiciService.queryByBatchNumber(batchNumber));
|
||||
}
|
||||
|
||||
/**
|
||||
* 设计-删除批次号
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:pcDelete")
|
||||
@Log(title = "设计-删除批次号", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/pcDelete/{ids}")
|
||||
public R<Void> pcDelete(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busCailiaoshebeiPiciService.deleteWithValidByIds(List.of(ids), true, "1"));
|
||||
}
|
||||
|
||||
/**
|
||||
* 设计-新增材料设备
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:add")
|
||||
@Log(title = "设计-新增材料设备", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusCailiaoshebeiAddReq req) {
|
||||
return toAjax(busCailiaoshebeiService.insertByBo(req));
|
||||
}
|
||||
|
||||
/**
|
||||
* 设计-材料设备列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusCailiaoshebeiVo> list(BusCailiaoshebeiListReq bo, PageQuery pageQuery) {
|
||||
BusCailiaoshebeiBo busCailiaoshebeiBo = BeanUtil.copyProperties(bo, BusCailiaoshebeiBo.class);
|
||||
return busCailiaoshebeiService.queryPageList(busCailiaoshebeiBo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 设计-材料设备详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusCailiaoshebeiVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busCailiaoshebeiService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 设计-修改物资-材料设备
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:edit")
|
||||
@Log(title = "物资-材料设备-设计部", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusCailiaoshebeiEditReq bo) {
|
||||
return toAjax(busCailiaoshebeiService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 设计-删除物资-材料设备
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:remove")
|
||||
@Log(title = "设计-删除物资-材料设备", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/remove/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busCailiaoshebeiService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
// /**
|
||||
// * 导出物资-材料设备列表
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:cailiaoshebei:export")
|
||||
// @Log(title = "物资-材料设备", businessType = BusinessType.EXPORT)
|
||||
// @PostMapping("/export")
|
||||
// public void export(BusCailiaoshebeiBo bo, HttpServletResponse response) {
|
||||
// List<BusCailiaoshebeiVo> list = busCailiaoshebeiService.queryList(bo);
|
||||
// ExcelUtil.exportExcel(list, "物资-材料设备", BusCailiaoshebeiVo.class, response);
|
||||
// }
|
||||
|
||||
//===============================计划===============================
|
||||
|
||||
/**
|
||||
* 计划-批次号列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:pcPlanList")
|
||||
@GetMapping("/pcPlanList")
|
||||
public TableDataInfo<BusCailiaoshebeiPiciVo> pcPlanList(BusCailiaoshebeiPiciPcListReq bo, PageQuery pageQuery) {
|
||||
BusCailiaoshebeiPiciBo busCailiaoshebeiPiciBo = BeanUtil.copyProperties(bo, BusCailiaoshebeiPiciBo.class);
|
||||
busCailiaoshebeiPiciBo.setCxsj("1"); //设计完成,才能展示计划
|
||||
busCailiaoshebeiPiciBo.setBatchType("1");
|
||||
return busCailiaoshebeiPiciService.queryPageList(busCailiaoshebeiPiciBo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 计划-批次号详细信息
|
||||
*
|
||||
* @param batchNumber 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:spQueryPlan")
|
||||
@GetMapping("/spQueryPlan/{batchNumber}")
|
||||
public R<BusCailiaoshebeiPici> spQueryPlan(@NotNull(message = "主键不能为空") @PathVariable String batchNumber) {
|
||||
return R.ok(busCailiaoshebeiPiciService.queryByBatchNumber(batchNumber));
|
||||
}
|
||||
|
||||
/**
|
||||
* 计划-材料设备清单列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:listPlan")
|
||||
@GetMapping("/listPlan")
|
||||
public TableDataInfo<BusCailiaoshebeiListPlanRes> listPlan(BusCailiaoshebeiBo bo, PageQuery pageQuery) {
|
||||
return busCailiaoshebeiService.queryPageListPlan(bo, pageQuery);
|
||||
}
|
||||
|
||||
// /**
|
||||
// * 计划-删除批次号
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:cailiaoshebei:deletePlan")
|
||||
// @Log(title = "计划-删除批次号", businessType = BusinessType.DELETE)
|
||||
// @DeleteMapping("/deletePlan/{ids}")
|
||||
// public R<Void> deletePlan(@NotEmpty(message = "主键不能为空")
|
||||
// @PathVariable Long[] ids) {
|
||||
// return toAjax(busCailiaoshebeiPiciService.deleteWithValidByIds(List.of(ids), true, "2"));
|
||||
// }
|
||||
|
||||
|
||||
/**
|
||||
* 计划-获取物资清单详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:getInfoPlanSon")
|
||||
@GetMapping("getInfoPlanSon/{id}")
|
||||
public R<BusSuppliespriceAddPlanSonRes> getInfoPlanSon(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busCailiaoshebeiService.getInfoPlanSon(id));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 计划-修改物资清单详细信息`
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebei:editPlan")
|
||||
@Log(title = "物资-材料设备-计划部", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping("/editPlanSon")
|
||||
public R<Void> editPlan(@Validated(EditGroup.class) @RequestBody BusCailiaoshebeiEditPlanReq bo) {
|
||||
return toAjax(busCailiaoshebeiService.updateByPlanBo(bo));
|
||||
}
|
||||
|
||||
//===============================物资-工程量清单===============================
|
||||
|
||||
private final IBusBillofquantitiesVersionsService busBillofquantitiesVersionsService;
|
||||
|
||||
/**
|
||||
* 获取工程量清单
|
||||
*/
|
||||
@SaCheckPermission("design:cailiaoshebei:obtainTheList")
|
||||
@GetMapping("/obtainTheList")
|
||||
public R<List<ObtainTheListRes>> obtainTheList(ObtainTheListReq bo, PageQuery pageQuery) {
|
||||
return R.ok(busBillofquantitiesVersionsService.obtainTheList(bo));
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,105 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusCailiaoshebeiPiciVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusCailiaoshebeiPiciBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusCailiaoshebeiPiciService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-批次号
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-07-31
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/cailiaoshebeiPici")
|
||||
public class BusCailiaoshebeiPiciController extends BaseController {
|
||||
|
||||
private final IBusCailiaoshebeiPiciService busCailiaoshebeiPiciService;
|
||||
|
||||
/**
|
||||
* 查询物资-批次号列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebeiPici:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusCailiaoshebeiPiciVo> list(BusCailiaoshebeiPiciBo bo, PageQuery pageQuery) {
|
||||
return busCailiaoshebeiPiciService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资-批次号列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebeiPici:export")
|
||||
@Log(title = "物资-批次号", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusCailiaoshebeiPiciBo bo, HttpServletResponse response) {
|
||||
List<BusCailiaoshebeiPiciVo> list = busCailiaoshebeiPiciService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资-批次号", BusCailiaoshebeiPiciVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-批次号详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebeiPici:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusCailiaoshebeiPiciVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busCailiaoshebeiPiciService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-批次号
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebeiPici:add")
|
||||
@Log(title = "物资-批次号", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusCailiaoshebeiPiciBo bo) {
|
||||
return toAjax(busCailiaoshebeiPiciService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物资-批次号
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebeiPici:edit")
|
||||
@Log(title = "物资-批次号", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusCailiaoshebeiPiciBo bo) {
|
||||
return toAjax(busCailiaoshebeiPiciService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资-批次号
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:cailiaoshebeiPici:remove")
|
||||
@Log(title = "物资-批次号", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busCailiaoshebeiPiciService.deleteWithValidByIds(List.of(ids), true, "0"));
|
||||
}
|
||||
}
|
@ -0,0 +1,131 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.dromara.cailiaoshebei.domain.dto.BusLtnDto;
|
||||
import org.dromara.common.utils.logistics.LogisticsInquiryDemo;
|
||||
import org.dromara.common.utils.logistics.LogisticsInquiryUtil;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusLtnVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusLtnBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusLtnService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-物流单号
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-14
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/ltn")
|
||||
public class BusLtnController extends BaseController {
|
||||
|
||||
private final IBusLtnService busLtnService;
|
||||
|
||||
/**
|
||||
* 查询物资-物流单号列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:ltn:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusLtnVo> list(BusLtnBo bo, PageQuery pageQuery) {
|
||||
return busLtnService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资-物流单号列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:ltn:export")
|
||||
@Log(title = "物资-物流单号", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusLtnBo bo, HttpServletResponse response) {
|
||||
List<BusLtnVo> list = busLtnService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资-物流单号", BusLtnVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-物流单号详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:ltn:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusLtnVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busLtnService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-物流单号
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:ltn:add")
|
||||
@Log(title = "物资-物流单号", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusLtnBo bo) {
|
||||
return toAjax(busLtnService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物资-物流单号
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:ltn:edit")
|
||||
@Log(title = "物资-物流单号", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusLtnBo bo) {
|
||||
return toAjax(busLtnService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资-物流单号
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:ltn:remove")
|
||||
@Log(title = "物资-物流单号", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busLtnService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增物资-物流单号
|
||||
*/
|
||||
@Log(title = "物资-物流单号", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping("/link")
|
||||
public R<Void> linkAdd(@RequestBody BusLtnDto dto) {
|
||||
return toAjax(busLtnService.linkAdd(dto));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物流信息
|
||||
*
|
||||
* @param ltn 物流单号
|
||||
*/
|
||||
@GetMapping("/logistics/{ltn}")
|
||||
public R<LogisticsInquiryDemo> getInfo(@NotNull(message = "物流单号不能为空")
|
||||
@PathVariable String ltn) {
|
||||
return R.ok(LogisticsInquiryUtil.aLiLogisticsInquiry(ltn));
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,186 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.dromara.cailiaoshebei.domain.BusCailiaoshebeiPici;
|
||||
import org.dromara.cailiaoshebei.domain.bo.*;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusCailiaoshebeiPiciVo;
|
||||
import org.dromara.cailiaoshebei.domain.vo.MasterDataListRes;
|
||||
import org.dromara.cailiaoshebei.service.IBusCailiaoshebeiPiciService;
|
||||
import org.dromara.cailiaoshebei.service.IBusCailiaoshebeiService;
|
||||
import org.dromara.common.utils.BatchNumberGenerator;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusMaterialbatchdemandplanVo;
|
||||
import org.dromara.cailiaoshebei.service.IBusMaterialbatchdemandplanService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-批次需求计划
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-02
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/materialbatchdemandplan")
|
||||
public class BusMaterialbatchdemandplanController extends BaseController {
|
||||
|
||||
private final IBusMaterialbatchdemandplanService busMaterialbatchdemandplanService;
|
||||
private final IBusCailiaoshebeiPiciService busCailiaoshebeiPiciService;
|
||||
private final IBusCailiaoshebeiService busCailiaoshebeiService;
|
||||
|
||||
/**
|
||||
* 需求-新增批次号
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialbatchdemandplan:pcAdd")
|
||||
@Log(title = "需求-新增批次号", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping("/pcAdd")
|
||||
public R<Void> pcAdd(@Validated(AddGroup.class) @RequestBody BusCailiaoshebeiPiciAddReq bo) {
|
||||
BusCailiaoshebeiPici busCailiaoshebeiPici = new BusCailiaoshebeiPici().
|
||||
setProjectId(bo.getProjectId()).
|
||||
setBatchType("2").
|
||||
setBatchNumber(BatchNumberGenerator.generateBatchNumber("PC-"));
|
||||
return toAjax( busCailiaoshebeiPiciService.save(busCailiaoshebeiPici));
|
||||
}
|
||||
|
||||
/**
|
||||
* 批次号列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialbatchdemandplan:pcList")
|
||||
@GetMapping("/pcList")
|
||||
public TableDataInfo<BusCailiaoshebeiPiciVo> pcList(BusCailiaoshebeiPiciPcListReq bo, PageQuery pageQuery) {
|
||||
BusCailiaoshebeiPiciBo busCailiaoshebeiPiciBo = BeanUtil.copyProperties(bo, BusCailiaoshebeiPiciBo.class);
|
||||
// busCailiaoshebeiPiciBo.setCxsj("2"); //计划完成,才能展示需求
|
||||
busCailiaoshebeiPiciBo.setBatchType("2");
|
||||
return busCailiaoshebeiPiciService.queryPageList(busCailiaoshebeiPiciBo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 需求-批次号详细信息
|
||||
*
|
||||
* @param batchNumber 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialbatchdemandplan:spQuery")
|
||||
@GetMapping("/spQuery/{batchNumber}")
|
||||
public R<BusCailiaoshebeiPici> spQuery(@NotNull(message = "主键不能为空") @PathVariable String batchNumber) {
|
||||
return R.ok(busCailiaoshebeiPiciService.queryByBatchNumber(batchNumber));
|
||||
}
|
||||
|
||||
/**
|
||||
* 需求-删除物资批次号
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialbatchdemandplan:pcDelete")
|
||||
@Log(title = "需求-删除批次号", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busCailiaoshebeiPiciService.deleteWithValidByIds(List.of(ids), true, "3"));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取到所有的物资信息
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialbatchdemandplan:masterDataList")
|
||||
@Log(title = "获取到所有的物资信息", businessType = BusinessType.INSERT)
|
||||
@GetMapping("/masterDataList")
|
||||
public TableDataInfo<MasterDataListRes> masterDataList(MasterDataListReq bo, PageQuery pageQuery) {
|
||||
return busCailiaoshebeiService.masterDataList(bo, pageQuery);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 批量新增物资批次需求计划
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialbatchdemandplan:addBatch")
|
||||
@Log(title = "批量新增物资批次需求计划", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> addBatch(@Validated(AddGroup.class) @RequestBody BusMaterialbatchdemandplanAddReq bo) {
|
||||
return toAjax(busMaterialbatchdemandplanService.add(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询物资-批次需求计划列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialbatchdemandplan:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusMaterialbatchdemandplanVo> list(BusMaterialbatchdemandplanBo bo, PageQuery pageQuery) {
|
||||
return busMaterialbatchdemandplanService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
//
|
||||
// /**
|
||||
// * 导出物资-批次需求计划列表
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialbatchdemandplan:export")
|
||||
// @Log(title = "物资-批次需求计划", businessType = BusinessType.EXPORT)
|
||||
// @PostMapping("/export")
|
||||
// public void export(BusMaterialbatchdemandplanBo bo, HttpServletResponse response) {
|
||||
// List<BusMaterialbatchdemandplanVo> list = busMaterialbatchdemandplanService.queryList(bo);
|
||||
// ExcelUtil.exportExcel(list, "物资-批次需求计划", BusMaterialbatchdemandplanVo.class, response);
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 获取物资-批次需求计划详细信息
|
||||
// *
|
||||
// * @param id 主键
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialbatchdemandplan:query")
|
||||
// @GetMapping("/{id}")
|
||||
// public R<BusMaterialbatchdemandplanVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
// @PathVariable Long id) {
|
||||
// return R.ok(busMaterialbatchdemandplanService.queryById(id));
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 新增物资-批次需求计划
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialbatchdemandplan:add")
|
||||
// @Log(title = "物资-批次需求计划", businessType = BusinessType.INSERT)
|
||||
// @RepeatSubmit()
|
||||
// @PostMapping()
|
||||
// public R<Void> add(@Validated(AddGroup.class) @RequestBody BusMaterialbatchdemandplanBo bo) {
|
||||
// return toAjax(busMaterialbatchdemandplanService.insertByBo(bo));
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 修改物资-批次需求计划
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialbatchdemandplan:edit")
|
||||
// @Log(title = "物资-批次需求计划", businessType = BusinessType.UPDATE)
|
||||
// @RepeatSubmit()
|
||||
// @PutMapping()
|
||||
// public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusMaterialbatchdemandplanBo bo) {
|
||||
// return toAjax(busMaterialbatchdemandplanService.updateByBo(bo));
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 删除物资-批次需求计划
|
||||
// *
|
||||
// * @param ids 主键串
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialbatchdemandplan:remove")
|
||||
// @Log(title = "物资-批次需求计划", businessType = BusinessType.DELETE)
|
||||
// @DeleteMapping("/{ids}")
|
||||
// public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
// @PathVariable Long[] ids) {
|
||||
// return toAjax(busMaterialbatchdemandplanService.deleteWithValidByIds(List.of(ids), true));
|
||||
// }
|
||||
|
||||
}
|
@ -0,0 +1,259 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.dromara.cailiaoshebei.domain.BusCailiaoshebeiPici;
|
||||
import org.dromara.cailiaoshebei.domain.BusMaterialbatchdemandplan;
|
||||
import org.dromara.cailiaoshebei.domain.BusMaterialsorder;
|
||||
import org.dromara.cailiaoshebei.domain.bo.*;
|
||||
import org.dromara.cailiaoshebei.domain.dto.ModifyTheOrderFormGYSTwoDto;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusCailiaoshebeiPiciVo;
|
||||
import org.dromara.cailiaoshebei.service.IBusCailiaoshebeiPiciService;
|
||||
import org.dromara.common.core.exception.ServiceException;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusMaterialsorderVo;
|
||||
import org.dromara.cailiaoshebei.service.IBusMaterialsorderService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
/**
|
||||
* 物资-设备订货
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-02
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/materialsorder")
|
||||
public class BusMaterialsorderController extends BaseController {
|
||||
|
||||
private final IBusMaterialsorderService busMaterialsorderService;
|
||||
private final IBusCailiaoshebeiPiciService busCailiaoshebeiPiciService;
|
||||
|
||||
//================================订货================================
|
||||
|
||||
// /**
|
||||
// * 测试
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialsorder:cs")
|
||||
// @Log(title = "测试", businessType = BusinessType.UPDATE)
|
||||
// @RepeatSubmit()
|
||||
// @PutMapping("/cs")
|
||||
// public R<Void> cs(@Validated(EditGroup.class) @RequestBody MaterialsorderPcPlanEditReq req) {
|
||||
// busMaterialsorderService.extractDataNewAddition(req.getCbatchNumber(),req.getCprojectId() );
|
||||
// return toAjax(true);
|
||||
// }
|
||||
|
||||
|
||||
/**
|
||||
* 订货-批次号列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialsorder:pcPlanList")
|
||||
@GetMapping("/pcPlanList")
|
||||
public TableDataInfo<BusCailiaoshebeiPiciVo> pcPlanList(BusCailiaoshebeiPiciPcListReq bo, PageQuery pageQuery) {
|
||||
BusCailiaoshebeiPiciBo busCailiaoshebeiPiciBo = BeanUtil.copyProperties(bo, BusCailiaoshebeiPiciBo.class);
|
||||
busCailiaoshebeiPiciBo.setBatchType("3");
|
||||
return busCailiaoshebeiPiciService.queryPageList(busCailiaoshebeiPiciBo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 订货-批次号详细信息
|
||||
*
|
||||
* @param batchNumber 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialsorder:spQuery")
|
||||
@GetMapping("/spQuery/{batchNumber}")
|
||||
public R<BusCailiaoshebeiPici> spQuery(@NotNull(message = "主键不能为空") @PathVariable String batchNumber) {
|
||||
return R.ok(busCailiaoshebeiPiciService.queryByBatchNumber(batchNumber));
|
||||
}
|
||||
|
||||
/**
|
||||
* 订货-修改订货信息
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialsorder:modifyTheOrderForm")
|
||||
@Log(title = "订货-修改订货信息", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping("/modifyTheOrderForm")
|
||||
public R<Void> modifyTheOrderForm(@Validated(EditGroup.class) @RequestBody MaterialsorderPcPlanEditReq req) {
|
||||
return toAjax(busMaterialsorderService.modifyTheOrderForm(req));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 订货-查询物资设备订货列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialsorder:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusMaterialsorderVo> list(BusMaterialsorderListReq req, PageQuery pageQuery) {
|
||||
BusMaterialsorderBo bo = BeanUtil.copyProperties(req, BusMaterialsorderBo.class);
|
||||
return busMaterialsorderService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 订货-修改订货信息(供货商修改版)
|
||||
*/
|
||||
// @SaCheckPermission("cailiaoshebei:materialsorder:modifyTheOrderFormGYS")
|
||||
// @Log(title = "订货-修改订货信息(供货商修改版)", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping("/modifyTheOrderFormGYS")
|
||||
public R<Void> modifyTheOrderFormGYS(@Validated(EditGroup.class) @RequestBody ModifyTheOrderFormGYSReq req) {
|
||||
List<BusMaterialsorder> upEntity = BeanUtil.copyToList(req.getList(), BusMaterialsorder.class);
|
||||
if (upEntity.isEmpty()){
|
||||
throw new ServiceException("请选择要修改的行");
|
||||
}
|
||||
//如果批次号状态不为草稿,那么不允许修改
|
||||
for (BusMaterialsorder busMaterialsorder : upEntity) {
|
||||
busMaterialsorder.setBatchNumber(req.getBatchNumber());
|
||||
BusCailiaoshebeiPici busCailiaoshebeiPici = busCailiaoshebeiPiciService.queryByBatchNumber(busMaterialsorder.getBatchNumber());
|
||||
if (!"draft".equals(busCailiaoshebeiPici.getApprovalOrder())){
|
||||
throw new ServiceException("批次号状态不为草稿,不允许修改");
|
||||
}
|
||||
}
|
||||
return toAjax(busMaterialsorderService.updateBatchById(upEntity));
|
||||
}
|
||||
|
||||
/**
|
||||
* 订货-查询物资设备订货列表(供货商修改版)
|
||||
*/
|
||||
// @SaCheckPermission("cailiaoshebei:materialsorder:listGYS")
|
||||
@GetMapping("/listGYS")
|
||||
public TableDataInfo<BusMaterialsorderVo> listGYS(BusMaterialsorderListReq req, PageQuery pageQuery) {
|
||||
BusMaterialsorderBo bo = BeanUtil.copyProperties(req, BusMaterialsorderBo.class);
|
||||
return busMaterialsorderService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 订货-批次号列表(供货商修改版)
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialsorder:pcPlanListGHS")
|
||||
@GetMapping("/pcPlanListGHS")
|
||||
public TableDataInfo<BusCailiaoshebeiPiciVo> pcPlanListGHS(BusCailiaoshebeiPiciPcListReq bo, PageQuery pageQuery) {
|
||||
BusCailiaoshebeiPiciBo busCailiaoshebeiPiciBo = BeanUtil.copyProperties(bo, BusCailiaoshebeiPiciBo.class);
|
||||
return busCailiaoshebeiPiciService.queryPageList(busCailiaoshebeiPiciBo, pageQuery);
|
||||
}
|
||||
|
||||
|
||||
|
||||
//================================物资设备批次需求计划执行跟踪================================
|
||||
|
||||
/**
|
||||
* 跟踪-批次号列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialsorder:trackPcPlanList")
|
||||
@GetMapping("/trackPcPlanList")
|
||||
public TableDataInfo<BusCailiaoshebeiPiciVo> trackPcPlanList(BusCailiaoshebeiPiciPcListReq bo, PageQuery pageQuery) {
|
||||
BusCailiaoshebeiPiciBo busCailiaoshebeiPiciBo = BeanUtil.copyProperties(bo, BusCailiaoshebeiPiciBo.class);
|
||||
busCailiaoshebeiPiciBo.setBatchType("3");
|
||||
busCailiaoshebeiPiciBo.setCxsj("4");
|
||||
return busCailiaoshebeiPiciService.queryPageList(busCailiaoshebeiPiciBo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 跟踪-计划执行跟踪列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialsorder:planExecutionTrackingList")
|
||||
@GetMapping("/planExecutionTrackingList")
|
||||
public TableDataInfo<BusMaterialsorderVo> planExecutionTrackingList(PlanExecutionTrackingListReq req, PageQuery pageQuery) {
|
||||
BusMaterialsorderBo bo = BeanUtil.copyProperties(req, BusMaterialsorderBo.class);
|
||||
return busMaterialsorderService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 跟踪-变更物资设备执行状态
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:materialsorder:changeTheStatusOfTheMaterials")
|
||||
@Log(title = "跟踪-变更物资设备执行状态", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PostMapping("/changeTheStatusOfTheMaterials")
|
||||
public R<Void> changeTheStatusOfTheMaterials(ChangeTheStatusOfTheMaterialsReq bo,@RequestParam(value = "file", required = false) MultipartFile file) {
|
||||
System.out.println("!!!!!!!!!!!!!!!!!!!!");
|
||||
BusMaterialsorderBo busMaterialsorderBo = BeanUtil.copyProperties(bo, BusMaterialsorderBo.class);
|
||||
return toAjax(busMaterialsorderService.updateByBo(busMaterialsorderBo,file));
|
||||
}
|
||||
|
||||
|
||||
|
||||
// /**
|
||||
// * 查询物资-设备订货列表
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialsorder:list")
|
||||
// @GetMapping("/list")
|
||||
// public TableDataInfo<BusMaterialsorderVo> list(BusMaterialsorderBo bo, PageQuery pageQuery) {
|
||||
// return busMaterialsorderService.queryPageList(bo, pageQuery);
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 导出物资-设备订货列表
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialsorder:export")
|
||||
// @Log(title = "物资-设备订货", businessType = BusinessType.EXPORT)
|
||||
// @PostMapping("/export")
|
||||
// public void export(BusMaterialsorderBo bo, HttpServletResponse response) {
|
||||
// List<BusMaterialsorderVo> list = busMaterialsorderService.queryList(bo);
|
||||
// ExcelUtil.exportExcel(list, "物资-设备订货", BusMaterialsorderVo.class, response);
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 获取物资-设备订货详细信息
|
||||
// *
|
||||
// * @param id 主键
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialsorder:query")
|
||||
// @GetMapping("/{id}")
|
||||
// public R<BusMaterialsorderVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
// @PathVariable Long id) {
|
||||
// return R.ok(busMaterialsorderService.queryById(id));
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 新增物资-设备订货
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialsorder:add")
|
||||
// @Log(title = "物资-设备订货", businessType = BusinessType.INSERT)
|
||||
// @RepeatSubmit()
|
||||
// @PostMapping()
|
||||
// public R<Void> add(@Validated(AddGroup.class) @RequestBody BusMaterialsorderBo bo) {
|
||||
// return toAjax(busMaterialsorderService.insertByBo(bo));
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 修改物资-设备订货
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialsorder:edit")
|
||||
// @Log(title = "物资-设备订货", businessType = BusinessType.UPDATE)
|
||||
// @RepeatSubmit()
|
||||
// @PutMapping()
|
||||
// public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusMaterialsorderBo bo) {
|
||||
// return toAjax(busMaterialsorderService.updateByBo(bo));
|
||||
// }
|
||||
//
|
||||
// /**
|
||||
// * 删除物资-设备订货
|
||||
// *
|
||||
// * @param ids 主键串
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:materialsorder:remove")
|
||||
// @Log(title = "物资-设备订货", businessType = BusinessType.DELETE)
|
||||
// @DeleteMapping("/{ids}")
|
||||
// public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
// @PathVariable Long[] ids) {
|
||||
// return toAjax(busMaterialsorderService.deleteWithValidByIds(List.of(ids), true));
|
||||
// }
|
||||
|
||||
}
|
@ -0,0 +1,132 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.dromara.cailiaoshebei.domain.dto.BusMrpDto;
|
||||
import org.dromara.cailiaoshebei.domain.dto.BusMrpExportDto;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusMrpVo;
|
||||
import org.dromara.design.domain.dto.desCollect.DesCollectBatchDto;
|
||||
import org.dromara.design.domain.vo.DesCollectVo;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusMrpBaseVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusMrpBaseBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusMrpBaseService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-批次需求计划基础信息
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/mrpBase")
|
||||
public class BusMrpBaseController extends BaseController {
|
||||
|
||||
private final IBusMrpBaseService busMrpBaseService;
|
||||
|
||||
/**
|
||||
* 查询物资-批次需求计划基础信息列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:mrpBase:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusMrpBaseVo> list(BusMrpBaseBo bo, PageQuery pageQuery) {
|
||||
return busMrpBaseService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资-批次需求计划基础信息列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:mrpBase:export")
|
||||
@Log(title = "物资-批次需求计划基础信息", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusMrpBaseBo bo, HttpServletResponse response) {
|
||||
List<BusMrpBaseVo> list = busMrpBaseService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资-批次需求计划基础信息", BusMrpBaseVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-批次需求计划基础信息详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:mrpBase:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusMrpVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busMrpBaseService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-批次需求计划基础信息
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:mrpBase:add")
|
||||
@Log(title = "物资-批次需求计划基础信息", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusMrpBaseBo bo) {
|
||||
return toAjax(busMrpBaseService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物资-批次需求计划基础信息
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:mrpBase:edit")
|
||||
@Log(title = "物资-批次需求计划基础信息", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusMrpBaseBo bo) {
|
||||
return toAjax(busMrpBaseService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资-批次需求计划基础信息
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:mrpBase:remove")
|
||||
@Log(title = "物资-批次需求计划基础信息", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busMrpBaseService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量新增或修改
|
||||
*/
|
||||
@RepeatSubmit()
|
||||
@PostMapping("/batch")
|
||||
public R<Void> batchAddOrUpdate(@RequestBody BusMrpDto dto) {
|
||||
return toAjax(busMrpBaseService.batchAddOrUpdate(dto));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 导入物资需求批次计划
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:mrpBase:add")
|
||||
@Log(title = "物资-批次需求计划基础信息", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping("/import")
|
||||
public R<Void> importData(BusMrpExportDto dto) {
|
||||
return toAjax(busMrpBaseService.importData(dto));
|
||||
}
|
||||
|
||||
}
|
@ -0,0 +1,105 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusPhysicalsupplyVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusPhysicalsupplyBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusPhysicalsupplyService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-使用情况
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-14
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/physicalsupply")
|
||||
public class BusPhysicalsupplyController extends BaseController {
|
||||
|
||||
private final IBusPhysicalsupplyService busPhysicalsupplyService;
|
||||
|
||||
/**
|
||||
* 查询物资-使用情况列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupply:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusPhysicalsupplyVo> list(BusPhysicalsupplyBo bo, PageQuery pageQuery) {
|
||||
return busPhysicalsupplyService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资-使用情况列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupply:export")
|
||||
@Log(title = "物资-使用情况", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusPhysicalsupplyBo bo, HttpServletResponse response) {
|
||||
List<BusPhysicalsupplyVo> list = busPhysicalsupplyService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资-使用情况", BusPhysicalsupplyVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-使用情况详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupply:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusPhysicalsupplyVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busPhysicalsupplyService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-使用情况
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupply:add")
|
||||
@Log(title = "物资-使用情况", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusPhysicalsupplyBo bo) {
|
||||
return toAjax(busPhysicalsupplyService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物资-使用情况
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupply:edit")
|
||||
@Log(title = "物资-使用情况", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusPhysicalsupplyBo bo) {
|
||||
return toAjax(busPhysicalsupplyService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资-使用情况
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupply:remove")
|
||||
@Log(title = "物资-使用情况", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busPhysicalsupplyService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@ -0,0 +1,105 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusPhysicalsupplySonVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusPhysicalsupplySonBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusPhysicalsupplySonService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-使用情况子数据
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-14
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/physicalsupplySon")
|
||||
public class BusPhysicalsupplySonController extends BaseController {
|
||||
|
||||
private final IBusPhysicalsupplySonService busPhysicalsupplySonService;
|
||||
|
||||
/**
|
||||
* 查询物资-使用情况子数据列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupplySon:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusPhysicalsupplySonVo> list(BusPhysicalsupplySonBo bo, PageQuery pageQuery) {
|
||||
return busPhysicalsupplySonService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资-使用情况子数据列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupplySon:export")
|
||||
@Log(title = "物资-使用情况子数据", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusPhysicalsupplySonBo bo, HttpServletResponse response) {
|
||||
List<BusPhysicalsupplySonVo> list = busPhysicalsupplySonService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资-使用情况子数据", BusPhysicalsupplySonVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-使用情况子数据详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupplySon:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusPhysicalsupplySonVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busPhysicalsupplySonService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-使用情况子数据
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupplySon:add")
|
||||
@Log(title = "物资-使用情况子数据", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusPhysicalsupplySonBo bo) {
|
||||
return toAjax(busPhysicalsupplySonService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物资-使用情况子数据
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupplySon:edit")
|
||||
@Log(title = "物资-使用情况子数据", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusPhysicalsupplySonBo bo) {
|
||||
return toAjax(busPhysicalsupplySonService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资-使用情况子数据
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:physicalsupplySon:remove")
|
||||
@Log(title = "物资-使用情况子数据", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busPhysicalsupplySonService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@ -0,0 +1,105 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusPlanDocAssociationVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusPlanDocAssociationBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusPlanDocAssociationService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-批次需求计划与采购单关联
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/planDocAssociation")
|
||||
public class BusPlanDocAssociationController extends BaseController {
|
||||
|
||||
private final IBusPlanDocAssociationService busPlanDocAssociationService;
|
||||
|
||||
/**
|
||||
* 查询物资-批次需求计划与采购单关联列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:planDocAssociation:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusPlanDocAssociationVo> list(BusPlanDocAssociationBo bo, PageQuery pageQuery) {
|
||||
return busPlanDocAssociationService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资-批次需求计划与采购单关联列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:planDocAssociation:export")
|
||||
@Log(title = "物资-批次需求计划与采购单关联", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusPlanDocAssociationBo bo, HttpServletResponse response) {
|
||||
List<BusPlanDocAssociationVo> list = busPlanDocAssociationService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资-批次需求计划与采购单关联", BusPlanDocAssociationVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-批次需求计划与采购单关联详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:planDocAssociation:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusPlanDocAssociationVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busPlanDocAssociationService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-批次需求计划与采购单关联
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:planDocAssociation:add")
|
||||
@Log(title = "物资-批次需求计划与采购单关联", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusPlanDocAssociationBo bo) {
|
||||
return toAjax(busPlanDocAssociationService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物资-批次需求计划与采购单关联
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:planDocAssociation:edit")
|
||||
@Log(title = "物资-批次需求计划与采购单关联", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusPlanDocAssociationBo bo) {
|
||||
return toAjax(busPlanDocAssociationService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资-批次需求计划与采购单关联
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:planDocAssociation:remove")
|
||||
@Log(title = "物资-批次需求计划与采购单关联", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busPlanDocAssociationService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@ -0,0 +1,146 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.NotEmpty;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.dromara.cailiaoshebei.domain.BusPlanDocAssociation;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusMaterialbatchdemandplanBo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusPurchaseDocBo;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusMaterialbatchdemandplanVo;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusPurchaseDocVo;
|
||||
import org.dromara.cailiaoshebei.service.IBusMaterialbatchdemandplanService;
|
||||
import org.dromara.cailiaoshebei.service.IBusPlanDocAssociationService;
|
||||
import org.dromara.cailiaoshebei.service.IBusPurchaseDocService;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 物资-采购联系单
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/purchaseDoc")
|
||||
public class BusPurchaseDocController extends BaseController {
|
||||
|
||||
private final IBusPurchaseDocService busPurchaseDocService;
|
||||
|
||||
private final IBusMaterialbatchdemandplanService materialbatchdemandplanService;
|
||||
|
||||
private final IBusPlanDocAssociationService planDocAssociationService;
|
||||
|
||||
/**
|
||||
* 查询物资-采购联系单列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseDoc:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusPurchaseDocVo> list(BusPurchaseDocBo bo, PageQuery pageQuery) {
|
||||
return busPurchaseDocService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资-采购联系单列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseDoc:export")
|
||||
@Log(title = "物资-采购联系单", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusPurchaseDocBo bo, HttpServletResponse response) {
|
||||
List<BusPurchaseDocVo> list = busPurchaseDocService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资-采购联系单", BusPurchaseDocVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据主键导出物资-采购联系单
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseDoc:downloadWord")
|
||||
@Log(title = "物资-采购联系单", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export/word")
|
||||
public void exportWordById(@NotNull(message = "主键不能为空") Long id,
|
||||
HttpServletResponse response) {
|
||||
busPurchaseDocService.exportWordById(id, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-采购联系单详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseDoc:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusPurchaseDocVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busPurchaseDocService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-采购联系单
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseDoc:add")
|
||||
@Log(title = "物资-采购联系单", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusPurchaseDocBo bo) {
|
||||
return toAjax(busPurchaseDocService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物资-采购联系单
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseDoc:edit")
|
||||
@Log(title = "物资-采购联系单", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusPurchaseDocBo bo) {
|
||||
return toAjax(busPurchaseDocService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资-采购联系单
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseDoc:remove")
|
||||
@Log(title = "物资-采购联系单", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busPurchaseDocService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 查询采购单关联的计划
|
||||
*/
|
||||
@GetMapping("/planList/{id}")
|
||||
public R<List<BusMaterialbatchdemandplanVo>> list(@NotNull(message = "主键不能为空")
|
||||
@PathVariable("id") Long id) {
|
||||
List<BusPlanDocAssociation> list = planDocAssociationService.list(Wrappers.lambdaQuery(BusPlanDocAssociation.class)
|
||||
.eq(BusPlanDocAssociation::getDocId, id));
|
||||
List<Long> list1 = list.stream().map(BusPlanDocAssociation::getPlanId).toList();
|
||||
if (list1.isEmpty()) {
|
||||
return R.ok(new ArrayList<>());
|
||||
}
|
||||
BusMaterialbatchdemandplanBo bo = new BusMaterialbatchdemandplanBo();
|
||||
bo.setIds(list1);
|
||||
return R.ok(materialbatchdemandplanService.queryList(bo));
|
||||
}
|
||||
}
|
@ -0,0 +1,130 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusPurchaseUserVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusPurchaseUserBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusPurchaseUserService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资采购人员
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/purchaseUser")
|
||||
public class BusPurchaseUserController extends BaseController {
|
||||
|
||||
private final IBusPurchaseUserService busPurchaseUserService;
|
||||
|
||||
/**
|
||||
* 查询物资采购人员列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseUser:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusPurchaseUserVo> list(BusPurchaseUserBo bo, PageQuery pageQuery) {
|
||||
return busPurchaseUserService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资采购人员列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseUser:export")
|
||||
@Log(title = "物资采购人员", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusPurchaseUserBo bo, HttpServletResponse response) {
|
||||
List<BusPurchaseUserVo> list = busPurchaseUserService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资采购人员", BusPurchaseUserVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资采购人员详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseUser:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusPurchaseUserVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busPurchaseUserService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资采购人员
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseUser:add")
|
||||
@Log(title = "物资采购人员", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusPurchaseUserBo bo) {
|
||||
return toAjax(busPurchaseUserService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物资采购人员
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseUser:edit")
|
||||
@Log(title = "物资采购人员", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusPurchaseUserBo bo) {
|
||||
return toAjax(busPurchaseUserService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资采购人员
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseUser:remove")
|
||||
@Log(title = "物资采购人员", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busPurchaseUserService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增或修改物资采购人员
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseUser:add")
|
||||
@Log(title = "物资采购人员", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping("/addOrUpdate")
|
||||
public R<Void> addOrUpdate(@Validated(AddGroup.class) @RequestBody BusPurchaseUserBo bo) {
|
||||
return toAjax(busPurchaseUserService.addOrUpdate(bo));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 根据项目获取物资采购人员详细信息
|
||||
*
|
||||
* @param projectId 项目id
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:purchaseUser:query")
|
||||
@GetMapping("/byProject/{projectId}")
|
||||
public R<BusPurchaseUserVo> getInfoByProject(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long projectId) {
|
||||
return R.ok(busPurchaseUserService.getInfoByProject(projectId));
|
||||
}
|
||||
}
|
@ -0,0 +1,106 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusRepertoryVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusRepertoryBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusRepertoryService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-库存详情
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-04
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/repertory")
|
||||
public class BusRepertoryController extends BaseController {
|
||||
|
||||
private final IBusRepertoryService busRepertoryService;
|
||||
|
||||
/**
|
||||
* 查询物资-库存详情列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:repertory:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusRepertoryVo> list(BusRepertoryBo bo, PageQuery pageQuery) {
|
||||
return busRepertoryService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-库存详情详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:repertory:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusRepertoryVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busRepertoryService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-库存详情
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:repertory:add")
|
||||
@Log(title = "物资-库存详情", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusRepertoryBo bo) {
|
||||
return toAjax(busRepertoryService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资-库存详情
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:repertory:remove")
|
||||
@Log(title = "物资-库存详情", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busRepertoryService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
|
||||
// /**
|
||||
// * 导出物资-库存详情列表
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:repertory:export")
|
||||
// @Log(title = "物资-库存详情", businessType = BusinessType.EXPORT)
|
||||
// @PostMapping("/export")
|
||||
// public void export(BusRepertoryBo bo, HttpServletResponse response) {
|
||||
// List<BusRepertoryVo> list = busRepertoryService.queryList(bo);
|
||||
// ExcelUtil.exportExcel(list, "物资-库存详情", BusRepertoryVo.class, response);
|
||||
// }
|
||||
|
||||
|
||||
// /**
|
||||
// * 修改物资-库存详情
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:repertory:edit")
|
||||
// @Log(title = "物资-库存详情", businessType = BusinessType.UPDATE)
|
||||
// @RepeatSubmit()
|
||||
// @PutMapping()
|
||||
// public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusRepertoryBo bo) {
|
||||
// return toAjax(busRepertoryService.updateByBo(bo));
|
||||
// }
|
||||
}
|
@ -0,0 +1,108 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.dromara.cailiaoshebei.domain.bo.RepertoryDetailsListReq;
|
||||
import org.dromara.cailiaoshebei.domain.vo.RepertoryDetailsListRes;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusRepertoryDetailsVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusRepertoryDetailsBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusRepertoryDetailsService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-库存
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-04
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/repertoryDetails")
|
||||
public class BusRepertoryDetailsController extends BaseController {
|
||||
|
||||
private final IBusRepertoryDetailsService busRepertoryDetailsService;
|
||||
|
||||
/**
|
||||
* 查询物资-库存列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:repertoryDetails:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<RepertoryDetailsListRes> list(RepertoryDetailsListReq bo, PageQuery pageQuery) {
|
||||
return busRepertoryDetailsService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-库存详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:repertoryDetails:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusRepertoryDetailsVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busRepertoryDetailsService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-库存
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:repertoryDetails:add")
|
||||
@Log(title = "物资-库存", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusRepertoryDetailsBo bo) {
|
||||
return toAjax(busRepertoryDetailsService.insertByBo(bo));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 删除物资-库存
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:repertoryDetails:remove")
|
||||
@Log(title = "物资-库存", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busRepertoryDetailsService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
|
||||
// /**
|
||||
// * 导出物资-库存列表
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:repertoryDetails:export")
|
||||
// @Log(title = "物资-库存", businessType = BusinessType.EXPORT)
|
||||
// @PostMapping("/export")
|
||||
// public void export(BusRepertoryDetailsBo bo, HttpServletResponse response) {
|
||||
// List<BusRepertoryDetailsVo> list = busRepertoryDetailsService.queryList(bo);
|
||||
// ExcelUtil.exportExcel(list, "物资-库存", BusRepertoryDetailsVo.class, response);
|
||||
// }
|
||||
|
||||
// /**
|
||||
// * 修改物资-库存
|
||||
// */
|
||||
// @SaCheckPermission("cailiaoshebei:repertoryDetails:edit")
|
||||
// @Log(title = "物资-库存", businessType = BusinessType.UPDATE)
|
||||
// @RepeatSubmit()
|
||||
// @PutMapping()
|
||||
// public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusRepertoryDetailsBo bo) {
|
||||
// return toAjax(busRepertoryDetailsService.updateByBo(bo));
|
||||
// }
|
||||
}
|
@ -0,0 +1,105 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusSuppliespriceVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusSuppliespriceBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusSuppliespriceService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-物资清单
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-07-31
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/cailiaoshebei/suppliesprice")
|
||||
public class BusSuppliespriceController extends BaseController {
|
||||
|
||||
private final IBusSuppliespriceService busSuppliespriceService;
|
||||
|
||||
/**
|
||||
* 查询物资-物资清单列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:suppliesprice:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusSuppliespriceVo> list(BusSuppliespriceBo bo, PageQuery pageQuery) {
|
||||
return busSuppliespriceService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资-物资清单列表
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:suppliesprice:export")
|
||||
@Log(title = "物资-物资清单", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusSuppliespriceBo bo, HttpServletResponse response) {
|
||||
List<BusSuppliespriceVo> list = busSuppliespriceService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资-物资清单", BusSuppliespriceVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-物资清单详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:suppliesprice:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusSuppliespriceVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busSuppliespriceService.queryById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增物资-物资清单
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:suppliesprice:add")
|
||||
@Log(title = "物资-物资清单", businessType = BusinessType.INSERT)
|
||||
@RepeatSubmit()
|
||||
@PostMapping()
|
||||
public R<Void> add(@Validated(AddGroup.class) @RequestBody BusSuppliespriceBo bo) {
|
||||
return toAjax(busSuppliespriceService.insertByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改物资-物资清单
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:suppliesprice:edit")
|
||||
@Log(title = "物资-物资清单", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusSuppliespriceBo bo) {
|
||||
return toAjax(busSuppliespriceService.updateByBo(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除物资-物资清单
|
||||
*
|
||||
* @param ids 主键串
|
||||
*/
|
||||
@SaCheckPermission("cailiaoshebei:suppliesprice:remove")
|
||||
@Log(title = "物资-物资清单", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
@PathVariable Long[] ids) {
|
||||
return toAjax(busSuppliespriceService.deleteWithValidByIds(List.of(ids), true));
|
||||
}
|
||||
}
|
@ -0,0 +1,131 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import cn.hutool.core.bean.BeanUtil;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import jakarta.servlet.http.HttpServletResponse;
|
||||
import jakarta.validation.constraints.*;
|
||||
import cn.dev33.satoken.annotation.SaCheckPermission;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusTotalsupplyplanAuditBo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.MasterDataReq;
|
||||
import org.dromara.cailiaoshebei.domain.bo.TotalsupplyplanQueryListReq;
|
||||
import org.dromara.cailiaoshebei.domain.dto.MasterDataReqDto;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusTotalsupplyplanAuditVo;
|
||||
import org.dromara.cailiaoshebei.service.IBusTotalsupplyplanAuditService;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.dromara.common.idempotent.annotation.RepeatSubmit;
|
||||
import org.dromara.common.log.annotation.Log;
|
||||
import org.dromara.common.web.core.BaseController;
|
||||
import org.dromara.common.mybatis.core.page.PageQuery;
|
||||
import org.dromara.common.core.domain.R;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.log.enums.BusinessType;
|
||||
import org.dromara.common.excel.utils.ExcelUtil;
|
||||
import org.dromara.cailiaoshebei.domain.vo.BusTotalsupplyplanVo;
|
||||
import org.dromara.cailiaoshebei.domain.bo.BusTotalsupplyplanBo;
|
||||
import org.dromara.cailiaoshebei.service.IBusTotalsupplyplanService;
|
||||
import org.dromara.common.mybatis.core.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 物资-总供应计划
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Validated
|
||||
@RequiredArgsConstructor
|
||||
@RestController
|
||||
@RequestMapping("/design/totalsupplyplan")
|
||||
public class BusTotalsupplyplanController extends BaseController {
|
||||
|
||||
private final IBusTotalsupplyplanService busTotalsupplyplanService;
|
||||
private final IBusTotalsupplyplanAuditService busTotalsupplyplanAuditService;
|
||||
|
||||
/**
|
||||
* 获取主数据列表
|
||||
*/
|
||||
@SaCheckPermission("design:totalsupplyplan:queryList")
|
||||
@GetMapping("/queryList")
|
||||
public R<List<BusTotalsupplyplanAuditVo>> queryList(TotalsupplyplanQueryListReq bo) {
|
||||
BusTotalsupplyplanAuditBo busTotalsupplyplanAuditBo = BeanUtil.copyProperties(bo, BusTotalsupplyplanAuditBo.class);
|
||||
return R.ok(busTotalsupplyplanAuditService.queryList(busTotalsupplyplanAuditBo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据主数据获取到详情
|
||||
*/
|
||||
@SaCheckPermission("design:totalsupplyplan:masterData")
|
||||
@GetMapping("/masterData")
|
||||
public R<MasterDataReqDto> masterData(MasterDataReq bo) {
|
||||
return R.ok(busTotalsupplyplanService.masterData(bo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询物资-总供应计划列表
|
||||
*/
|
||||
@SaCheckPermission("design:totalsupplyplan:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo<BusTotalsupplyplanVo> list(BusTotalsupplyplanBo bo, PageQuery pageQuery) {
|
||||
return busTotalsupplyplanService.queryPageList(bo, pageQuery);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出物资-总供应计划列表
|
||||
*/
|
||||
@SaCheckPermission("design:totalsupplyplan:export")
|
||||
@Log(title = "物资-总供应计划", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(BusTotalsupplyplanBo bo, HttpServletResponse response) {
|
||||
List<BusTotalsupplyplanVo> list = busTotalsupplyplanService.queryList(bo);
|
||||
ExcelUtil.exportExcel(list, "物资-总供应计划", BusTotalsupplyplanVo.class, response);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取物资-总供应计划详细信息
|
||||
*
|
||||
* @param id 主键
|
||||
*/
|
||||
@SaCheckPermission("design:totalsupplyplan:query")
|
||||
@GetMapping("/{id}")
|
||||
public R<BusTotalsupplyplanVo> getInfo(@NotNull(message = "主键不能为空")
|
||||
@PathVariable Long id) {
|
||||
return R.ok(busTotalsupplyplanService.queryById(id));
|
||||
}
|
||||
|
||||
// /**
|
||||
// * 新增物资-总供应计划
|
||||
// */
|
||||
// @SaCheckPermission("design:totalsupplyplan:add")
|
||||
// @Log(title = "物资-总供应计划", businessType = BusinessType.INSERT)
|
||||
// @RepeatSubmit()
|
||||
// @PostMapping()
|
||||
// public R<Void> add(@Validated(AddGroup.class) @RequestBody BusTotalsupplyplanBo bo) {
|
||||
// return toAjax(busTotalsupplyplanService.insertByBo(bo));
|
||||
// }
|
||||
|
||||
/**
|
||||
* 修改物资-总供应计划
|
||||
*/
|
||||
@SaCheckPermission("design:totalsupplyplan:edit")
|
||||
@Log(title = "物资-总供应计划", businessType = BusinessType.UPDATE)
|
||||
@RepeatSubmit()
|
||||
@PutMapping()
|
||||
public R<Void> edit(@Validated(EditGroup.class) @RequestBody BusTotalsupplyplanBo bo) {
|
||||
return toAjax(busTotalsupplyplanService.updateByBo(bo));
|
||||
}
|
||||
|
||||
// /**
|
||||
// * 删除物资-总供应计划
|
||||
// *
|
||||
// * @param ids 主键串
|
||||
// */
|
||||
// @SaCheckPermission("design:totalsupplyplan:remove")
|
||||
// @Log(title = "物资-总供应计划", businessType = BusinessType.DELETE)
|
||||
// @DeleteMapping("/{ids}")
|
||||
// public R<Void> remove(@NotEmpty(message = "主键不能为空")
|
||||
// @PathVariable Long[] ids) {
|
||||
// return toAjax(busTotalsupplyplanService.deleteWithValidByIds(List.of(ids), true));
|
||||
// }
|
||||
}
|
@ -0,0 +1,14 @@
|
||||
package org.dromara.cailiaoshebei.controller;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/8/8 11:15
|
||||
* @Version 1.0
|
||||
*/
|
||||
public class constant {
|
||||
public static final String MaterialDesign = "materialDesign"; //设计
|
||||
public static final String MaterialsPlans = "materialsPlans"; //计划
|
||||
public static final String BatchRequirements = "batchRequirements"; //需求
|
||||
public static final String EquipmentOrdering = "equipmentOrdering"; //订货
|
||||
public static final String PURCHASE_DOC_TEMPLATE_PATH = "template/物资采购联系单模版.docx"; // 采购联系单文件路径
|
||||
}
|
@ -0,0 +1,109 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-材料设备对象 bus_cailiaoshebei
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-07-31
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_cailiaoshebei")
|
||||
public class BusCailiaoshebei extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 供货商ID
|
||||
*/
|
||||
private String supplierId;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 供货商
|
||||
*/
|
||||
private String supplier;
|
||||
|
||||
/**
|
||||
* 设备材料名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 供货来源(字典)
|
||||
*/
|
||||
private String supply;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 特征描述
|
||||
*/
|
||||
private String signalment;
|
||||
|
||||
/**
|
||||
* 物料编码
|
||||
*/
|
||||
private String materialCode;
|
||||
|
||||
/**
|
||||
* 计划到场时间
|
||||
*/
|
||||
private LocalDate arrivalTime;
|
||||
|
||||
/**
|
||||
* 计划完成时间
|
||||
*/
|
||||
private LocalDate finishTime;
|
||||
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 计划数量
|
||||
*/
|
||||
private Long plan;
|
||||
|
||||
/**
|
||||
* 实际数量
|
||||
*/
|
||||
private Long realQuantity;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
}
|
@ -0,0 +1,103 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.experimental.Accessors;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 物资-批次号对象 bus_cailiaoshebei_pici
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-07-31
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_cailiaoshebei_pici")
|
||||
@Accessors(chain = true)
|
||||
public class BusCailiaoshebeiPici extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 批次需求
|
||||
*/
|
||||
private String batchType;
|
||||
|
||||
/**
|
||||
* 审批设计
|
||||
*/
|
||||
private String approvalDesign;
|
||||
|
||||
/**
|
||||
* 审批计划
|
||||
*/
|
||||
private String approvalPlan;
|
||||
|
||||
/**
|
||||
* 审批项目
|
||||
*/
|
||||
private String approvalProject;
|
||||
|
||||
/**
|
||||
* 审批订货
|
||||
*/
|
||||
private String approvalOrder;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 订货-采购人
|
||||
*/
|
||||
private String purchasingAgent;
|
||||
/**
|
||||
* 订货-采购时间
|
||||
*/
|
||||
private Date purchasingPeriod;
|
||||
/**
|
||||
* 订货-合同号
|
||||
*/
|
||||
private String contractNumber;
|
||||
/**
|
||||
* 订货-备注
|
||||
*/
|
||||
private String dhRemark;
|
||||
/**
|
||||
* 订货-供应商
|
||||
*/
|
||||
private String dhSupplier;
|
||||
/**
|
||||
* 订货-状态
|
||||
*/
|
||||
private String dhSucceed;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,57 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 物资-物流单号对象 bus_ltn
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-14
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_ltn")
|
||||
public class BusLtn extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 采购联系单id
|
||||
*/
|
||||
private Long docId;
|
||||
|
||||
/**
|
||||
* 计划id
|
||||
*/
|
||||
private Long planId;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
private BigDecimal num;
|
||||
|
||||
/**
|
||||
* 物流单号
|
||||
*/
|
||||
private String ltn;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,108 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-批次需求计划对象 bus_materialbatchdemandplan
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-02
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_materialbatchdemandplan")
|
||||
public class BusMaterialbatchdemandplan extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 材料设备ID
|
||||
*/
|
||||
private Long cailiaoshebeiId;
|
||||
|
||||
/**
|
||||
* 物资清单ID
|
||||
*/
|
||||
private Long suppliespriceId;
|
||||
|
||||
/**
|
||||
* 基础信息ID
|
||||
*/
|
||||
private Long mrpBaseId;
|
||||
|
||||
/**
|
||||
* 物料编码
|
||||
*/
|
||||
private String materialCode;
|
||||
|
||||
/**
|
||||
* 设备材料名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 供货公司
|
||||
*/
|
||||
private String supplierCompany;
|
||||
|
||||
/**
|
||||
* 预估供应周期
|
||||
*/
|
||||
private Long estimatedCycle;
|
||||
|
||||
/**
|
||||
* 需求数量
|
||||
*/
|
||||
private Long demandQuantity;
|
||||
|
||||
/**
|
||||
* 计划到场时间
|
||||
*/
|
||||
private Date arrivalTime;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 质量标准
|
||||
*/
|
||||
private String qs;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,155 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-设备订货对象 bus_materialsorder
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-02
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_materialsorder")
|
||||
public class BusMaterialsorder extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 材料设备ID
|
||||
*/
|
||||
private Long cailiaoshebeiId;
|
||||
|
||||
/**
|
||||
* 物资清单ID
|
||||
*/
|
||||
private Long suppliespriceId;
|
||||
|
||||
/**
|
||||
* 物料编码
|
||||
*/
|
||||
private String materialCode;
|
||||
|
||||
/**
|
||||
* 设备材料名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 需求数量
|
||||
*/
|
||||
private Long demandQuantity;
|
||||
|
||||
/**
|
||||
* 计划到场时间
|
||||
*/
|
||||
private LocalDate arrivalTime;
|
||||
|
||||
/**
|
||||
* 订货数量
|
||||
*/
|
||||
private int orderQuantity;
|
||||
|
||||
/**
|
||||
* 预计到货时间
|
||||
*/
|
||||
private LocalDate expectedArrival;
|
||||
|
||||
/**
|
||||
* 预计生产完成时间
|
||||
*/
|
||||
private LocalDate productionTime;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 验收数量
|
||||
*/
|
||||
private Integer acceptanceQuantity;
|
||||
|
||||
/**
|
||||
* 实际到货时间
|
||||
*/
|
||||
private LocalDate actualArrival;
|
||||
|
||||
/**
|
||||
* 需求提交时间
|
||||
*/
|
||||
private LocalDate requiredTime;
|
||||
|
||||
/**
|
||||
* 订货时间
|
||||
*/
|
||||
private LocalDate orderTime;
|
||||
|
||||
/**
|
||||
* 验收时间
|
||||
*/
|
||||
private LocalDate receptionTime;
|
||||
|
||||
/**
|
||||
* 物资执行状态(字典)
|
||||
*/
|
||||
private String materialStatus;
|
||||
|
||||
/**
|
||||
* 物资预期类型(字典)
|
||||
*/
|
||||
private String overdueType;
|
||||
|
||||
/**
|
||||
* 逾期原因
|
||||
*/
|
||||
private String cause;
|
||||
|
||||
/**
|
||||
* 签收单据
|
||||
*/
|
||||
private String signatureForm;
|
||||
|
||||
/**
|
||||
* 退货单据
|
||||
*/
|
||||
private String returnedSalesReport;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,57 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.time.LocalDate;
|
||||
|
||||
/**
|
||||
* 物资-批次需求计划基础信息对象 bus_mrp_base
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_mrp_base")
|
||||
public class BusMrpBase extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 计划编号
|
||||
*/
|
||||
private String planCode;
|
||||
|
||||
/**
|
||||
* 物资类别
|
||||
*/
|
||||
private String matCat;
|
||||
|
||||
/**
|
||||
* 编制日期
|
||||
*/
|
||||
private LocalDate preparedDate;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
private String status;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,98 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-使用情况对象 bus_physicalsupply
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-14
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_physicalsupply")
|
||||
public class BusPhysicalsupply extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 材料名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 规格
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 供应商
|
||||
*/
|
||||
private String supplier;
|
||||
|
||||
/**
|
||||
* 合同签订时间
|
||||
*/
|
||||
private Date contractSigning;
|
||||
|
||||
/**
|
||||
* 供货要求
|
||||
*/
|
||||
private String supplyRequirements;
|
||||
|
||||
/**
|
||||
* 生产周期
|
||||
*/
|
||||
private Long productionPhase;
|
||||
|
||||
/**
|
||||
* 运算周期
|
||||
*/
|
||||
private Long executionCycle;
|
||||
|
||||
/**
|
||||
* 安装量
|
||||
*/
|
||||
private String installationQuantity;
|
||||
|
||||
/**
|
||||
* 安装比列
|
||||
*/
|
||||
private String installationRatio;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 采购提交
|
||||
*/
|
||||
private String purchaseSubmission;
|
||||
|
||||
/**
|
||||
* 材料提交
|
||||
*/
|
||||
private String submissionMaterials;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,168 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-使用情况子数据对象 bus_physicalsupply_son
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-14
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_physicalsupply_son")
|
||||
public class BusPhysicalsupplySon extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 使用情况ID
|
||||
*/
|
||||
private Long physicalsupplyId;
|
||||
|
||||
/**
|
||||
* 到货要求
|
||||
*/
|
||||
private String deliveryRequirements;
|
||||
|
||||
/**
|
||||
* 转换为合同
|
||||
*/
|
||||
private String transition;
|
||||
|
||||
/**
|
||||
* 批次
|
||||
*/
|
||||
private String batch;
|
||||
|
||||
/**
|
||||
* 联系单下达时间
|
||||
*/
|
||||
private Date issuanceTime;
|
||||
|
||||
/**
|
||||
* 要求到货时间
|
||||
*/
|
||||
private Date requireDelivery;
|
||||
|
||||
/**
|
||||
* 要求到货数量
|
||||
*/
|
||||
private String requiredQuantity;
|
||||
|
||||
/**
|
||||
* 采购备注
|
||||
*/
|
||||
private String cgRemark;
|
||||
|
||||
/**
|
||||
* 计划到货时间
|
||||
*/
|
||||
private Date scheduledDelivery;
|
||||
|
||||
/**
|
||||
* 计划到货数量
|
||||
*/
|
||||
private String plannedQuantity;
|
||||
|
||||
/**
|
||||
* 差异量
|
||||
*/
|
||||
private String differenceQuantity;
|
||||
|
||||
/**
|
||||
* 供应商备注
|
||||
*/
|
||||
private String gysRemark;
|
||||
|
||||
/**
|
||||
* 实际到货时间
|
||||
*/
|
||||
private Date actualDelivery;
|
||||
|
||||
/**
|
||||
* 验收移交时间
|
||||
*/
|
||||
private Date acceptanceCheck;
|
||||
|
||||
/**
|
||||
* 交接方式
|
||||
*/
|
||||
private String associate;
|
||||
|
||||
/**
|
||||
* 实际到货验收数量
|
||||
*/
|
||||
private String actualAcceptance;
|
||||
|
||||
/**
|
||||
* 到货差异量
|
||||
*/
|
||||
private String dhDifferenceQuantity;
|
||||
|
||||
/**
|
||||
* 逾期状态
|
||||
*/
|
||||
private String expectedState;
|
||||
|
||||
/**
|
||||
* 到货备注
|
||||
*/
|
||||
private String dhRemark;
|
||||
|
||||
/**
|
||||
* 货物金额
|
||||
*/
|
||||
private String cargoAmount;
|
||||
|
||||
/**
|
||||
* 结算金额
|
||||
*/
|
||||
private String settlementAmount;
|
||||
|
||||
/**
|
||||
* 预付款
|
||||
*/
|
||||
private String advance;
|
||||
|
||||
/**
|
||||
* 投料款
|
||||
*/
|
||||
private String feed;
|
||||
|
||||
/**
|
||||
* 到货验收款
|
||||
*/
|
||||
private String acceptancePayment;
|
||||
|
||||
/**
|
||||
* 质保金
|
||||
*/
|
||||
private String qualityGuarantee;
|
||||
|
||||
/**
|
||||
* 调试款
|
||||
*/
|
||||
private String debugging;
|
||||
|
||||
/**
|
||||
* 结算备注
|
||||
*/
|
||||
private String jsRemark;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-批次需求计划与采购单关联对象 bus_plan_doc_association
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_plan_doc_association")
|
||||
public class BusPlanDocAssociation extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 计划id
|
||||
*/
|
||||
private Long planId;
|
||||
|
||||
/**
|
||||
* 采购联系单id
|
||||
*/
|
||||
private Long docId;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,135 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.time.LocalDate;
|
||||
|
||||
/**
|
||||
* 物资-采购联系单对象 bus_purchase_doc
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_purchase_doc")
|
||||
public class BusPurchaseDoc extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 1-采购单,2-补货单
|
||||
*/
|
||||
private String docType;
|
||||
|
||||
/**
|
||||
* 采购单编号
|
||||
*/
|
||||
private String docCode;
|
||||
|
||||
/**
|
||||
* 供应商id
|
||||
*/
|
||||
private Long supplierId;
|
||||
|
||||
/**
|
||||
* 供应商
|
||||
*/
|
||||
private String supplier;
|
||||
|
||||
/**
|
||||
* 事由
|
||||
*/
|
||||
private String reason;
|
||||
|
||||
/**
|
||||
* 设备统称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 到货日期
|
||||
*/
|
||||
private LocalDate arrivalDate;
|
||||
|
||||
/**
|
||||
* 设计负责人联系方式
|
||||
*/
|
||||
private String designDirectorTel;
|
||||
|
||||
/**
|
||||
* 现场技术负责人联系方式
|
||||
*/
|
||||
private String technicalDirectorTel;
|
||||
|
||||
/**
|
||||
* 收货地址
|
||||
*/
|
||||
private String receivingAddress;
|
||||
|
||||
/**
|
||||
* 联系人
|
||||
*/
|
||||
private String contacts;
|
||||
|
||||
/**
|
||||
* 项目负责人
|
||||
*/
|
||||
private String projectDirector;
|
||||
|
||||
/**
|
||||
* 采购经办人
|
||||
*/
|
||||
private String purchasingAgent;
|
||||
|
||||
/**
|
||||
* 日期
|
||||
*/
|
||||
private LocalDate preparedDate;
|
||||
|
||||
/**
|
||||
* 反馈文件地址
|
||||
*/
|
||||
private String feedbackUrl;
|
||||
|
||||
/**
|
||||
* 签收单位
|
||||
*/
|
||||
private String signingUnit;
|
||||
|
||||
/**
|
||||
* 签收人
|
||||
*/
|
||||
private String signingPerson;
|
||||
|
||||
/**
|
||||
* 签收日期
|
||||
*/
|
||||
private LocalDate signingDate;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
private String status;
|
||||
|
||||
/**
|
||||
* 计划基础ID
|
||||
*/
|
||||
private Long mrpBaseId;
|
||||
}
|
@ -0,0 +1,46 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资采购人员对象 bus_purchase_user
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_purchase_user")
|
||||
public class BusPurchaseUser extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目id
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 采购人员id
|
||||
*/
|
||||
private Long userId;
|
||||
|
||||
/**
|
||||
* 采购人员姓名
|
||||
*/
|
||||
private String userName;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,51 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-库存详情对象 bus_repertory
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-04
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_repertory")
|
||||
public class BusRepertory extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 设备材料名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,86 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-库存对象 bus_repertory_details
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-04
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_repertory_details")
|
||||
public class BusRepertoryDetails extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 库存ID
|
||||
*/
|
||||
private Long repertoryId;
|
||||
|
||||
/**
|
||||
* 数据来源ID
|
||||
*/
|
||||
private Long materialsorderId;
|
||||
|
||||
/**
|
||||
* 物料编码
|
||||
*/
|
||||
private String materialCode;
|
||||
|
||||
/**
|
||||
* 原始数量
|
||||
*/
|
||||
private int originalQuantity;
|
||||
|
||||
/**
|
||||
* 变更原因
|
||||
*/
|
||||
private String changeReasons;
|
||||
|
||||
/**
|
||||
* 变更数量
|
||||
*/
|
||||
private int changeQuantity;
|
||||
|
||||
/**
|
||||
* 最终数量
|
||||
*/
|
||||
private int finalNumber;
|
||||
|
||||
/**
|
||||
* 操作状态(字典)
|
||||
*/
|
||||
private String operationStatus;
|
||||
|
||||
/**
|
||||
* 操作人
|
||||
*/
|
||||
private String operationName;
|
||||
|
||||
/**
|
||||
* 操作人联系电话
|
||||
*/
|
||||
private String operationPhone;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,67 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 物资-物资清单对象 bus_suppliesprice
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-07-31
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_suppliesprice")
|
||||
public class BusSuppliesprice extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 材料设备ID
|
||||
*/
|
||||
private Long cailiaoshebeiId;
|
||||
|
||||
/**
|
||||
* 单价
|
||||
*/
|
||||
private BigDecimal unitPrice;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
private int num;
|
||||
|
||||
/**
|
||||
* 合同号
|
||||
*/
|
||||
private String contractNum;
|
||||
|
||||
/**
|
||||
* 预估供应周期
|
||||
*/
|
||||
private Long estimatedCycle;
|
||||
|
||||
/**
|
||||
* 供货公司
|
||||
*/
|
||||
private String supplierCompany;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,119 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.Date;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-总供应计划对象 bus_totalsupplyplan
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_totalsupplyplan")
|
||||
public class BusTotalsupplyplan extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目Id
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 编制日期
|
||||
*/
|
||||
private LocalDate compileDate;
|
||||
|
||||
/**
|
||||
* 计划编号
|
||||
*/
|
||||
private String planNumber;
|
||||
|
||||
/**
|
||||
* 编号
|
||||
*/
|
||||
private String num;
|
||||
|
||||
/**
|
||||
* 名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 规格
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 材质
|
||||
*/
|
||||
private String texture;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
private Long quantity;
|
||||
|
||||
/**
|
||||
* 品牌
|
||||
*/
|
||||
private String brand;
|
||||
|
||||
/**
|
||||
* 质量标准
|
||||
*/
|
||||
private String qualityStandard;
|
||||
|
||||
/**
|
||||
* 预计使用日期
|
||||
*/
|
||||
private Date dateService;
|
||||
|
||||
/**
|
||||
* 交货地点
|
||||
*/
|
||||
private String deliveryPoints;
|
||||
|
||||
/**
|
||||
* 使用部位
|
||||
*/
|
||||
private String partUsed;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
private String status;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,51 @@
|
||||
package org.dromara.cailiaoshebei.domain;
|
||||
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import com.baomidou.mybatisplus.annotation.*;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serial;
|
||||
|
||||
/**
|
||||
* 物资-总供应计划审核对象 bus_totalsupplyplan_audit
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@TableName("bus_totalsupplyplan_audit")
|
||||
public class BusTotalsupplyplanAudit extends BaseEntity {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@TableId(value = "id")
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目Id
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
private String status;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,114 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import jakarta.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
import org.dromara.cailiaoshebei.domain.BusCailiaoshebei;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/7/31 10:04
|
||||
* @Version 1.0
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusCailiaoshebei.class, reverseConvertGenerate = false)
|
||||
@Accessors(chain = true)
|
||||
public class BusCailiaoshebeiAddReq extends BaseEntity {
|
||||
/**
|
||||
* 主键ID (编辑时必填)
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
@NotNull(message = "项目ID不能为空", groups = { AddGroup.class })
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 批次ID (必填)
|
||||
*/
|
||||
@NotBlank(message = "批次号不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 128, message = "批次ID长度不能超过128个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 供货商ID (必填,多个逗号分隔)
|
||||
*/
|
||||
@NotNull(message = "供货商ID不能为空", groups = { AddGroup.class })
|
||||
private String supplierId;
|
||||
|
||||
/**
|
||||
* 供货商 (必填,多个逗号分隔)
|
||||
*/
|
||||
@NotBlank(message = "供货商不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 64, message = "供货商名称长度不能超过64个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String supplier;
|
||||
|
||||
/**
|
||||
* 设备材料名称 (必填)
|
||||
*/
|
||||
@NotBlank(message = "设备材料名称不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 64, message = "设备材料名称长度不能超过64个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@NotBlank(message = "规格型号不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 128, message = "规格型号长度不能超过128个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 特征描述
|
||||
*/
|
||||
@NotBlank(message = "特征描述不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 128, message = "特征描述长度不能超过128个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String signalment;
|
||||
|
||||
/**
|
||||
* 计量单位 (必填)
|
||||
*/
|
||||
@NotBlank(message = "计量单位不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 10, message = "计量单位长度不能超过10个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 计划数量 (必填)
|
||||
*/
|
||||
@NotNull(message = "计划数量不能为空", groups = { AddGroup.class })
|
||||
private Long plan;
|
||||
|
||||
/**
|
||||
* 供货来源(字典) (必填)
|
||||
*/
|
||||
@NotBlank(message = "供货来源不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 1, message = "供货来源只能是1个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String supply;
|
||||
/**
|
||||
* 物料编码 (必填)
|
||||
*/
|
||||
// @NotBlank(message = "物料编码不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 128, message = "物料编码长度不能超过255个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String materialCode;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String remark;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,110 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import org.dromara.cailiaoshebei.domain.BusCailiaoshebei;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
/**
|
||||
* 物资-材料设备业务对象 bus_cailiaoshebei
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-07-31
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusCailiaoshebei.class, reverseConvertGenerate = false)
|
||||
public class BusCailiaoshebeiBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
@NotNull(message = "项目ID不能为空")
|
||||
private Long projectId;
|
||||
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
@NotBlank(message = "批次号不能为空")
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 供货商ID
|
||||
*/
|
||||
private Long supplierId;
|
||||
|
||||
/**
|
||||
* 供货商
|
||||
*/
|
||||
private String supplier;
|
||||
|
||||
/**
|
||||
* 设备材料名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 供货来源(字典)
|
||||
*/
|
||||
private String supply;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 特征描述
|
||||
*/
|
||||
private String signalment;
|
||||
|
||||
/**
|
||||
* 物料编码
|
||||
*/
|
||||
private String materialCode;
|
||||
|
||||
/**
|
||||
* 计划到场时间
|
||||
*/
|
||||
private Date arrivalTime;
|
||||
|
||||
/**
|
||||
* 计划完成时间
|
||||
*/
|
||||
private Date finishTime;
|
||||
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 计划数量
|
||||
*/
|
||||
private Long plan;
|
||||
|
||||
/**
|
||||
* 实际数量
|
||||
*/
|
||||
private Long realQuantity;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,56 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import jakarta.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
import org.dromara.cailiaoshebei.domain.BusCailiaoshebei;
|
||||
import org.dromara.cailiaoshebei.domain.dto.BusCailiaoshebeiEditPlanDto;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/7/31 10:04
|
||||
* @Version 1.0
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusCailiaoshebei.class, reverseConvertGenerate = false)
|
||||
@Accessors(chain = true)
|
||||
public class BusCailiaoshebeiEditPlanReq extends BaseEntity {
|
||||
/**
|
||||
* 主键ID (编辑时必填)
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 计划到场时间
|
||||
*/
|
||||
@NotNull(message = "计划到场时间", groups = { EditGroup.class })
|
||||
private LocalDate arrivalTime;
|
||||
|
||||
/**
|
||||
* 计划完成时间
|
||||
*/
|
||||
@NotNull(message = "计划完成时间", groups = { EditGroup.class })
|
||||
private LocalDate finishTime;
|
||||
|
||||
/**
|
||||
* 物资清单列表
|
||||
*/
|
||||
@Size(min = 1, message = "物资清单列表不能为空", groups = { EditGroup.class })
|
||||
private List<BusCailiaoshebeiEditPlanDto> listOfMaterialInventory;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,97 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import jakarta.validation.constraints.Size;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import lombok.experimental.Accessors;
|
||||
import org.dromara.cailiaoshebei.domain.BusCailiaoshebei;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/7/31 10:04
|
||||
* @Version 1.0
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusCailiaoshebei.class, reverseConvertGenerate = false)
|
||||
@Accessors(chain = true)
|
||||
public class BusCailiaoshebeiEditReq extends BaseEntity {
|
||||
/**
|
||||
* 主键ID (编辑时必填)
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 批次号不能为空
|
||||
*/
|
||||
@NotNull(message = "批次号不能为空", groups = { EditGroup.class })
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 供货商ID (必填)
|
||||
*/
|
||||
@NotNull(message = "供货商ID不能为空", groups = { AddGroup.class })
|
||||
private String supplierId;
|
||||
|
||||
/**
|
||||
* 供货商 (必填)
|
||||
*/
|
||||
@NotBlank(message = "供货商不能为空", groups = { AddGroup.class })
|
||||
private String supplier;
|
||||
|
||||
/**
|
||||
* 设备材料名称 (必填)
|
||||
*/
|
||||
@NotBlank(message = "设备材料名称不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 64, message = "设备材料名称长度不能超过64个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@NotBlank(message = "规格型号不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 128, message = "规格型号长度不能超过128个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 特征描述
|
||||
*/
|
||||
@NotBlank(message = "特征描述不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 128, message = "特征描述长度不能超过128个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String signalment;
|
||||
|
||||
/**
|
||||
* 计量单位 (必填)
|
||||
*/
|
||||
@NotBlank(message = "计量单位不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 10, message = "计量单位长度不能超过10个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 计划数量 (必填)
|
||||
*/
|
||||
@NotNull(message = "计划数量不能为空", groups = { AddGroup.class })
|
||||
private Long plan;
|
||||
|
||||
/**
|
||||
* 供货来源(字典) (必填)
|
||||
*/
|
||||
@NotBlank(message = "供货来源不能为空", groups = { AddGroup.class })
|
||||
@Size(max = 1, message = "供货来源只能是1个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String supply;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
@Size(max = 500, message = "备注长度不能超过500个字符", groups = {AddGroup.class, EditGroup.class})
|
||||
private String remark;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,48 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/8/1 20:27
|
||||
* @Version 1.0
|
||||
*/
|
||||
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public class BusCailiaoshebeiListReq implements Serializable {
|
||||
|
||||
/**
|
||||
* 项目ID(必填)
|
||||
*/
|
||||
@NotNull(message = "项目ID不能为空")
|
||||
private Long projectId;
|
||||
|
||||
|
||||
/**
|
||||
* 批次号(必填)
|
||||
*/
|
||||
@NotBlank(message = "项目ID不能为空")
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 供货商ID
|
||||
*/
|
||||
private Long supplierId;
|
||||
|
||||
/**
|
||||
* 供货来源(字典)
|
||||
*/
|
||||
private String supply;
|
||||
|
||||
/**
|
||||
* 物料编码
|
||||
*/
|
||||
private String materialCode;
|
||||
|
||||
}
|
@ -0,0 +1,19 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/8/1 19:50
|
||||
* @Version 1.0
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class BusCailiaoshebeiPiciAddReq implements Serializable {
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
}
|
@ -0,0 +1,72 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import lombok.experimental.Accessors;
|
||||
import org.dromara.cailiaoshebei.domain.BusCailiaoshebeiPici;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
/**
|
||||
* 物资-批次号业务对象 bus_cailiaoshebei_pici
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-07-31
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusCailiaoshebeiPici.class, reverseConvertGenerate = false)
|
||||
@Accessors(chain = true)
|
||||
public class BusCailiaoshebeiPiciBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
@NotNull(message = "id不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 批次类型
|
||||
*/
|
||||
private String batchType;
|
||||
|
||||
/**
|
||||
* 审批设计
|
||||
*/
|
||||
private String approvalDesign;
|
||||
|
||||
/**
|
||||
* 审批计划
|
||||
*/
|
||||
private String approvalPlan;
|
||||
|
||||
/**
|
||||
* 审批项目
|
||||
*/
|
||||
private String approvalProject;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
|
||||
/**
|
||||
* 查询数据判断
|
||||
*/
|
||||
private String cxsj;
|
||||
|
||||
}
|
@ -0,0 +1,32 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/8/1 19:59
|
||||
* @Version 1.0
|
||||
*/
|
||||
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public class BusCailiaoshebeiPiciPcListReq implements Serializable {
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
@NotNull(message = "项目ID不能为空")
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 批次号(模糊查询)
|
||||
*/
|
||||
@NotBlank(message = "批次号不能为空")
|
||||
private String batchNumber;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,60 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import org.dromara.cailiaoshebei.domain.BusLtn;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
|
||||
/**
|
||||
* 物资-物流单号业务对象 bus_ltn
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-14
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusLtn.class, reverseConvertGenerate = false)
|
||||
public class BusLtnBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 采购联系单id
|
||||
*/
|
||||
@NotNull(message = "采购联系单id不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private Long docId;
|
||||
|
||||
/**
|
||||
* 计划id
|
||||
*/
|
||||
@NotNull(message = "计划id不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private Long planId;
|
||||
|
||||
/**
|
||||
* 数量
|
||||
*/
|
||||
private BigDecimal num;
|
||||
|
||||
/**
|
||||
* 物流单号
|
||||
*/
|
||||
@NotBlank(message = "物流单号不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String ltn;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,39 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/8/2 16:08
|
||||
* @Version 1.0
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class BusMaterialbatchdemandplanAddReq implements Serializable {
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
@NotBlank(message = "批次号不能为空")
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
@NotBlank(message = "项目ID不能为空")
|
||||
private Long projectId;
|
||||
|
||||
|
||||
/**
|
||||
* 新增数据信息
|
||||
*/
|
||||
private List<BusMaterialbatchdemandplanBo> addDataList;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,116 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import org.dromara.cailiaoshebei.domain.BusMaterialbatchdemandplan;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
/**
|
||||
* 物资-批次需求计划业务对象 bus_materialbatchdemandplan
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-02
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusMaterialbatchdemandplan.class, reverseConvertGenerate = false)
|
||||
public class BusMaterialbatchdemandplanBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 基础信息ID
|
||||
*/
|
||||
private Long mrpBaseId;
|
||||
|
||||
/**
|
||||
* 材料设备ID
|
||||
*/
|
||||
private Long cailiaoshebeiId;
|
||||
|
||||
/**
|
||||
* 物资清单ID
|
||||
*/
|
||||
private Long suppliespriceId;
|
||||
|
||||
/**
|
||||
* 物料编码
|
||||
*/
|
||||
private String materialCode;
|
||||
|
||||
/**
|
||||
* 设备材料名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 供货公司
|
||||
*/
|
||||
private String supplierCompany;
|
||||
|
||||
/**
|
||||
* 预估供应周期
|
||||
*/
|
||||
private Long estimatedCycle;
|
||||
|
||||
/**
|
||||
* 需求数量
|
||||
*/
|
||||
private Long demandQuantity;
|
||||
|
||||
/**
|
||||
* 计划到场时间
|
||||
*/
|
||||
private LocalDate arrivalTime;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
|
||||
/**
|
||||
* 质量标准
|
||||
*/
|
||||
private String qs;
|
||||
|
||||
|
||||
/**
|
||||
* 主键集合
|
||||
*/
|
||||
private List<Long> ids;
|
||||
}
|
@ -0,0 +1,170 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import org.dromara.cailiaoshebei.domain.BusMaterialsorder;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
import java.time.LocalDate;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
/**
|
||||
* 物资-设备订货业务对象 bus_materialsorder
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-02
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusMaterialsorder.class, reverseConvertGenerate = false)
|
||||
public class BusMaterialsorderBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
private String batchNumber;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 材料设备ID
|
||||
*/
|
||||
private Long cailiaoshebeiId;
|
||||
|
||||
/**
|
||||
* 物资清单ID
|
||||
*/
|
||||
private Long suppliespriceId;
|
||||
|
||||
/**
|
||||
* 物料编码
|
||||
*/
|
||||
private String materialCode;
|
||||
|
||||
/**
|
||||
* 设备材料名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 计量单位
|
||||
*/
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 需求数量
|
||||
*/
|
||||
private int demandQuantity;
|
||||
|
||||
/**
|
||||
* 计划到场时间
|
||||
*/
|
||||
private LocalDate arrivalTime;
|
||||
|
||||
/**
|
||||
* 订货数量
|
||||
*/
|
||||
private Long orderQuantity;
|
||||
|
||||
/**
|
||||
* 预计到货时间
|
||||
*/
|
||||
private LocalDate expectedArrival;
|
||||
|
||||
/**
|
||||
* 预计生产完成时间
|
||||
*/
|
||||
private LocalDate productionTime;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 验收数量
|
||||
*/
|
||||
private int acceptanceQuantity;
|
||||
|
||||
/**
|
||||
* 实际到货时间
|
||||
*/
|
||||
private LocalDate actualArrival;
|
||||
|
||||
/**
|
||||
* 需求提交时间
|
||||
*/
|
||||
private LocalDate requiredTime;
|
||||
|
||||
/**
|
||||
* 订货时间
|
||||
*/
|
||||
private LocalDate orderTime;
|
||||
|
||||
/**
|
||||
* 验收时间
|
||||
*/
|
||||
private LocalDate receptionTime;
|
||||
|
||||
/**
|
||||
* 物资执行状态(字典)
|
||||
*/
|
||||
private String materialStatus;
|
||||
|
||||
/**
|
||||
* 物资预期类型(字典)
|
||||
*/
|
||||
private String overdueType;
|
||||
|
||||
/**
|
||||
* 逾期原因
|
||||
*/
|
||||
private String cause;
|
||||
|
||||
/**
|
||||
* 签收单(到货必填,pdf或图片)
|
||||
*/
|
||||
private String signatureForm;
|
||||
|
||||
/**
|
||||
* 退货单(退货必填,pdf或图片)
|
||||
*/
|
||||
private String returnedSalesReport;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 操作状态(字典operation_status)
|
||||
*/
|
||||
@NotBlank(message = "操作状态不能为空")
|
||||
private String operationStatus;
|
||||
/**
|
||||
* 单据类型(0:无单据 1:签收单,2:退货单 )
|
||||
*/
|
||||
private String billType;
|
||||
}
|
@ -0,0 +1,31 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import jakarta.validation.constraints.NotBlank;
|
||||
import jakarta.validation.constraints.NotNull;
|
||||
import lombok.Data;
|
||||
import lombok.experimental.Accessors;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* @Author 铁憨憨
|
||||
* @Date 2025/8/2 18:46
|
||||
* @Version 1.0
|
||||
*/
|
||||
|
||||
@Data
|
||||
@Accessors(chain = true)
|
||||
public class BusMaterialsorderListReq implements Serializable {
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
@NotNull(message = "项目ID不能为空")
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 批次号
|
||||
*/
|
||||
@NotBlank(message = "批次号不能为空")
|
||||
private String batchNumber;
|
||||
|
||||
}
|
@ -0,0 +1,59 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import org.dromara.cailiaoshebei.domain.BusMrpBase;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
|
||||
import java.time.LocalDate;
|
||||
|
||||
/**
|
||||
* 物资-批次需求计划基础信息业务对象 bus_mrp_base
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-13
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusMrpBase.class, reverseConvertGenerate = false)
|
||||
public class BusMrpBaseBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
@NotNull(message = "项目ID不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 计划编号
|
||||
*/
|
||||
@NotBlank(message = "计划编号不能为空", groups = { AddGroup.class, EditGroup.class })
|
||||
private String planCode;
|
||||
|
||||
/**
|
||||
* 物资类别
|
||||
*/
|
||||
private String matCat;
|
||||
|
||||
/**
|
||||
* 编制日期
|
||||
*/
|
||||
private LocalDate preparedDate;
|
||||
|
||||
/**
|
||||
* 审核状态
|
||||
*/
|
||||
private String status;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,102 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import org.dromara.cailiaoshebei.domain.BusPhysicalsupply;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
/**
|
||||
* 物资-使用情况业务对象 bus_physicalsupply
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-14
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusPhysicalsupply.class, reverseConvertGenerate = false)
|
||||
public class BusPhysicalsupplyBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 采购1 或 材料2 或 查询所有3
|
||||
*/
|
||||
private String findType;
|
||||
|
||||
/**
|
||||
* 项目ID
|
||||
*/
|
||||
private Long projectId;
|
||||
|
||||
/**
|
||||
* 材料名称
|
||||
*/
|
||||
private String name;
|
||||
|
||||
/**
|
||||
* 规格
|
||||
*/
|
||||
private String specification;
|
||||
|
||||
/**
|
||||
* 供应商
|
||||
*/
|
||||
private String supplier;
|
||||
|
||||
/**
|
||||
* 合同签订时间
|
||||
*/
|
||||
private Date contractSigning;
|
||||
|
||||
/**
|
||||
* 供货要求
|
||||
*/
|
||||
private String supplyRequirements;
|
||||
|
||||
/**
|
||||
* 生产周期
|
||||
*/
|
||||
private Long productionPhase;
|
||||
|
||||
/**
|
||||
* 运算周期
|
||||
*/
|
||||
private Long executionCycle;
|
||||
|
||||
/**
|
||||
* 安装量
|
||||
*/
|
||||
private String installationQuantity;
|
||||
|
||||
/**
|
||||
* 安装比列
|
||||
*/
|
||||
private String installationRatio;
|
||||
|
||||
/**
|
||||
* 备注
|
||||
*/
|
||||
private String remark;
|
||||
|
||||
/**
|
||||
* 采购提交
|
||||
*/
|
||||
private String purchaseSubmission;
|
||||
|
||||
/**
|
||||
* 材料提交
|
||||
*/
|
||||
private String submissionMaterials;
|
||||
|
||||
|
||||
}
|
@ -0,0 +1,167 @@
|
||||
package org.dromara.cailiaoshebei.domain.bo;
|
||||
|
||||
import org.dromara.cailiaoshebei.domain.BusPhysicalsupplySon;
|
||||
import org.dromara.common.mybatis.core.domain.BaseEntity;
|
||||
import org.dromara.common.core.validate.AddGroup;
|
||||
import org.dromara.common.core.validate.EditGroup;
|
||||
import io.github.linpeilie.annotations.AutoMapper;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import jakarta.validation.constraints.*;
|
||||
import java.util.Date;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
|
||||
/**
|
||||
* 物资-使用情况子数据业务对象 bus_physicalsupply_son
|
||||
*
|
||||
* @author Lion Li
|
||||
* @date 2025-08-14
|
||||
*/
|
||||
@Data
|
||||
@EqualsAndHashCode(callSuper = true)
|
||||
@AutoMapper(target = BusPhysicalsupplySon.class, reverseConvertGenerate = false)
|
||||
public class BusPhysicalsupplySonBo extends BaseEntity {
|
||||
|
||||
/**
|
||||
* 主键ID
|
||||
*/
|
||||
@NotNull(message = "主键ID不能为空", groups = { EditGroup.class })
|
||||
private Long id;
|
||||
|
||||
/**
|
||||
* 使用情况ID
|
||||
*/
|
||||
private Long physicalsupplyId;
|
||||
|
||||
/**
|
||||
* 到货要求
|
||||
*/
|
||||
private String deliveryRequirements;
|
||||
|
||||
/**
|
||||
* 转换为合同
|
||||
*/
|
||||
private String transition;
|
||||
|
||||
/**
|
||||
* 批次
|
||||
*/
|
||||
private String batch;
|
||||
|
||||
/**
|
||||
* 联系单下达时间
|
||||
*/
|
||||
private Date issuanceTime;
|
||||
|
||||
/**
|
||||
* 要求到货时间
|
||||
*/
|
||||
private Date requireDelivery;
|
||||
|
||||
/**
|
||||
* 要求到货数量
|
||||
*/
|
||||
private String requiredQuantity;
|
||||
|
||||
/**
|
||||
* 采购备注
|
||||
*/
|
||||
private String cgRemark;
|
||||
|
||||
/**
|
||||
* 计划到货时间
|
||||
*/
|
||||
private Date scheduledDelivery;
|
||||
|
||||
/**
|
||||
* 计划到货数量
|
||||
*/
|
||||
private String plannedQuantity;
|
||||
|
||||
/**
|
||||
* 差异量
|
||||
*/
|
||||
private String differenceQuantity;
|
||||
|
||||
/**
|
||||
* 供应商备注
|
||||
*/
|
||||
private String gysRemark;
|
||||
|
||||
/**
|
||||
* 实际到货时间
|
||||
*/
|
||||
private Date actualDelivery;
|
||||
|
||||
/**
|
||||
* 验收移交时间
|
||||
*/
|
||||
private Date acceptanceCheck;
|
||||
|
||||
/**
|
||||
* 交接方式
|
||||
*/
|
||||
private String associate;
|
||||
|
||||
/**
|
||||
* 实际到货验收数量
|
||||
*/
|
||||
private String actualAcceptance;
|
||||
|
||||
/**
|
||||
* 到货差异量
|
||||
*/
|
||||
private String dhDifferenceQuantity;
|
||||
|
||||
/**
|
||||
* 逾期状态
|
||||
*/
|
||||
private String expectedState;
|
||||
|
||||
/**
|
||||
* 到货备注
|
||||
*/
|
||||
private String dhRemark;
|
||||
|
||||
/**
|
||||
* 货物金额
|
||||
*/
|
||||
private String cargoAmount;
|
||||
|
||||
/**
|
||||
* 结算金额
|
||||
*/
|
||||
private String settlementAmount;
|
||||
|
||||
/**
|
||||
* 预付款
|
||||
*/
|
||||
private String advance;
|
||||
|
||||
/**
|
||||
* 投料款
|
||||
*/
|
||||
private String feed;
|
||||
|
||||
/**
|
||||
* 到货验收款
|
||||
*/
|
||||
private String acceptancePayment;
|
||||
|
||||
/**
|
||||
* 质保金
|
||||
*/
|
||||
private String qualityGuarantee;
|
||||
|
||||
/**
|
||||
* 调试款
|
||||
*/
|
||||
private String debugging;
|
||||
|
||||
/**
|
||||
* 结算备注
|
||||
*/
|
||||
private String jsRemark;
|
||||
|
||||
|
||||
}
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user