add mes module

plp
chenyuan 2 years ago
parent 42eb696cc9
commit 71dca95ea3

@ -23,6 +23,7 @@
<!-- <module>yudao-module-mall</module>--> <!-- <module>yudao-module-mall</module>-->
<module>yudao-module-crm</module> <module>yudao-module-crm</module>
<module>yudao-module-erp</module> <module>yudao-module-erp</module>
<module>yudao-module-mes</module>
</modules> </modules>
<name>${project.artifactId}</name> <name>${project.artifactId}</name>

@ -158,7 +158,7 @@ CREATE TABLE `mes_record_ganzao`
CREATE TABLE `mes_record_wet` CREATE TABLE `mes_record_jiashi`
( (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id', `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id',
`record_id` bigint NOT NULL DEFAULT '0' COMMENT '记录id', `record_id` bigint NOT NULL DEFAULT '0' COMMENT '记录id',
@ -213,7 +213,7 @@ CREATE TABLE `mes_record_reya`
PRIMARY KEY (`id`) USING BTREE PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='热压记录表'; ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='热压记录表';
CREATE TABLE `mes_record_cut` CREATE TABLE `mes_record_qiebian`
( (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id', `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id',
`record_id` bigint NOT NULL DEFAULT '0' COMMENT '记录id', `record_id` bigint NOT NULL DEFAULT '0' COMMENT '记录id',
@ -240,7 +240,7 @@ CREATE TABLE `mes_record_cut`
PRIMARY KEY (`id`) USING BTREE PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='切边记录表'; ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='切边记录表';
CREATE TABLE `mes_record_check` CREATE TABLE `mes_record_pinjian`
( (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id', `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id',
`record_id` bigint NOT NULL DEFAULT '0' COMMENT '记录id', `record_id` bigint NOT NULL DEFAULT '0' COMMENT '记录id',
@ -266,7 +266,7 @@ CREATE TABLE `mes_record_check`
PRIMARY KEY (`id`) USING BTREE PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='检验记录表'; ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='检验记录表';
CREATE TABLE `mes_record_package` CREATE TABLE `mes_record_dabao`
( (
`id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id', `id` bigint NOT NULL AUTO_INCREMENT COMMENT 'id',
`record_id` bigint NOT NULL DEFAULT '0' COMMENT '记录id', `record_id` bigint NOT NULL DEFAULT '0' COMMENT '记录id',
@ -286,4 +286,4 @@ CREATE TABLE `mes_record_package`
`deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '是否删除', `deleted` bit(1) NOT NULL DEFAULT b'0' COMMENT '是否删除',
`tenant_id` bigint NOT NULL DEFAULT '0' COMMENT '租户编号', `tenant_id` bigint NOT NULL DEFAULT '0' COMMENT '租户编号',
PRIMARY KEY (`id`) USING BTREE PRIMARY KEY (`id`) USING BTREE
) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='检验记录表'; ) ENGINE=InnoDB AUTO_INCREMENT=1 DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci ROW_FORMAT=DYNAMIC COMMENT='打包记录表';

@ -0,0 +1,23 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao</artifactId>
<version>${revision}</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<modules>
<module>yudao-module-mes-api</module>
<module>yudao-module-mes-biz</module>
</modules>
<artifactId>yudao-module-mes</artifactId>
<packaging>pom</packaging>
<name>${project.artifactId}</name>
<description>
report 模块,主要实现数据可视化报表等功能。
</description>
</project>

@ -0,0 +1,26 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-module-mes</artifactId>
<version>${revision}</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>yudao-module-mes-api</artifactId>
<packaging>jar</packaging>
<name>${project.artifactId}</name>
<description>
report 模块 API暴露给其它模块调用
</description>
<dependencies>
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-common</artifactId>
</dependency>
</dependencies>
</project>

@ -0,0 +1,4 @@
/**
* api git
*/
package cn.iocoder.yudao.module.mes.api;

@ -0,0 +1,15 @@
package cn.iocoder.yudao.module.mes.enums;
import cn.iocoder.yudao.framework.common.exception.ErrorCode;
/**
* Report
*
* report 使 1-003-000-000
*/
public interface ErrorCodeConstants {
// ========== GoView 模块 1-003-000-000 ==========
ErrorCode GO_VIEW_PROJECT_NOT_EXISTS = new ErrorCode(1_003_000_000, "GoView 项目不存在");
}

@ -0,0 +1,79 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<parent>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-module-mes</artifactId>
<version>${revision}</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>yudao-module-mes-biz</artifactId>
<packaging>jar</packaging>
<name>${project.artifactId}</name>
<description>
report 模块,主要实现数据可视化报表等功能:
1. 基于「积木报表」实现,打印设计、报表设计、图形设计、大屏设计等。
</description>
<dependencies>
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-module-mes-api</artifactId>
<version>${revision}</version>
</dependency>
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-module-system-api</artifactId>
<version>${revision}</version>
</dependency>
<!-- 业务组件 -->
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-spring-boot-starter-biz-tenant</artifactId>
</dependency>
<!-- Web 相关 -->
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-spring-boot-starter-web</artifactId>
</dependency>
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-spring-boot-starter-security</artifactId>
</dependency>
<!-- DB 相关 -->
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-spring-boot-starter-mybatis</artifactId>
</dependency>
<!-- Test 测试相关 -->
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-spring-boot-starter-test</artifactId>
</dependency>
<!-- 积木报表-->
<dependency>
<groupId>org.jeecgframework.jimureport</groupId>
<artifactId>jimureport-spring-boot-starter</artifactId>
</dependency>
<!-- 单独依赖升级版本解决低版本validator失败问题 -->
<dependency>
<groupId>xerces</groupId>
<artifactId>xercesImpl</artifactId>
</dependency>
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-spring-boot-starter-excel</artifactId>
</dependency>
</dependencies>
</project>

@ -0,0 +1,6 @@
/**
* RESTful API
* 1. admin yudao-ui-admin
* 2. app APP yudao-ui-app Controller VO App
*/
package cn.iocoder.yudao.module.mes.controller;

@ -0,0 +1,4 @@
/**
* TODO
*/
package cn.iocoder.yudao.module.mes.convert.ajreport;

@ -0,0 +1,4 @@
/**
* TODO
*/
package cn.iocoder.yudao.module.mes.dal.dataobject.ajreport;

@ -0,0 +1,4 @@
/**
* TODO
*/
package cn.iocoder.yudao.module.mes.dal.mysql.ajreport;

@ -0,0 +1,6 @@
/**
* report framework
*
* @author
*/
package cn.iocoder.yudao.module.mes.framework;

@ -0,0 +1,33 @@
package cn.iocoder.yudao.module.mes.framework.security.config;
import cn.iocoder.yudao.framework.security.config.AuthorizeRequestsCustomizer;
import cn.iocoder.yudao.module.system.api.oauth2.OAuth2TokenApi;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
import org.springframework.security.config.annotation.web.configurers.ExpressionUrlAuthorizationConfigurer;
import javax.annotation.Resource;
/**
* Report Security
*/
@Configuration("mesSecurityConfiguration")
public class SecurityConfiguration {
@Resource
private OAuth2TokenApi oauth2TokenApi;
@Bean("mesAuthorizeRequestsCustomizer")
public AuthorizeRequestsCustomizer authorizeRequestsCustomizer() {
return new AuthorizeRequestsCustomizer() {
@Override
public void customize(ExpressionUrlAuthorizationConfigurer<HttpSecurity>.ExpressionInterceptUrlRegistry registry) {
registry.antMatchers("/mes/open/**").permitAll(); // 积木报表
}
};
}
}

@ -0,0 +1,4 @@
/**
*
*/
package cn.iocoder.yudao.module.mes.framework.security.core;

@ -0,0 +1,24 @@
package cn.iocoder.yudao.module.mes.framework.web.config;
import cn.iocoder.yudao.framework.swagger.config.YudaoSwaggerAutoConfiguration;
import org.springdoc.core.GroupedOpenApi;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
/**
* mes web Configuration
*
* @author
*/
@Configuration(proxyBeanMethods = false)
public class MesWebConfiguration {
/**
* crm API
*/
@Bean
public GroupedOpenApi mesGroupedOpenApi() {
return YudaoSwaggerAutoConfiguration.buildGroupedOpenApi("mes");
}
}

@ -0,0 +1,4 @@
/**
* crm web
*/
package cn.iocoder.yudao.module.mes.framework.web;

@ -0,0 +1,9 @@
/**
* report
* 1. URL /jmreport jimu_
*
*
* 1. Controller URL /report/ Module
* 2. DataObject report_ 便
*/
package cn.iocoder.yudao.module.mes;

@ -0,0 +1,4 @@
/**
* TODO
*/
package cn.iocoder.yudao.module.mes.service.ajreport;

@ -0,0 +1,53 @@
spring:
main:
lazy-initialization: true # 开启懒加载,加快速度
banner-mode: off # 单元测试,禁用 Banner
--- #################### 数据库相关配置 ####################
spring:
# 数据源配置项
datasource:
name: ruoyi-vue-pro
url: jdbc:h2:mem:testdb;MODE=MYSQL;DATABASE_TO_UPPER=false;NON_KEYWORDS=value; # MODE 使用 MySQL 模式DATABASE_TO_UPPER 配置表和字段使用小写
driver-class-name: org.h2.Driver
username: sa
password:
druid:
async-init: true # 单元测试,异步初始化 Druid 连接池,提升启动速度
initial-size: 1 # 单元测试,配置为 1提升启动速度
sql:
init:
schema-locations: classpath:/sql/create_tables.sql
# Redis 配置。Redisson 默认的配置足够使用,一般不需要进行调优
redis:
host: 127.0.0.1 # 地址
port: 16379 # 端口(单元测试,使用 16379 端口)
database: 0 # 数据库索引
mybatis:
lazy-initialization: true # 单元测试,设置 MyBatis Mapper 延迟加载,加速每个单元测试
--- #################### 定时任务相关配置 ####################
--- #################### 配置中心相关配置 ####################
--- #################### 服务保障相关配置 ####################
# Lock4j 配置项(单元测试,禁用 Lock4j
--- #################### 监控相关配置 ####################
--- #################### 芋道相关配置 ####################
# 芋道配置项,设置当前项目所有自定义的配置
yudao:
info:
base-package: cn.iocoder.yudao.module
captcha:
timeout: 5m
width: 160
height: 60
enable: true

@ -0,0 +1,4 @@
<configuration>
<!-- 引用 Spring Boot 的 logback 基础配置 -->
<include resource="org/springframework/boot/logging/logback/defaults.xml" />
</configuration>

@ -113,7 +113,12 @@
<groupId>cn.iocoder.boot</groupId> <groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-spring-boot-starter-protection</artifactId> <artifactId>yudao-spring-boot-starter-protection</artifactId>
</dependency> </dependency>
<!-- ERP 相关模块。默认注释,保证编译速度 -->
<dependency>
<groupId>cn.iocoder.boot</groupId>
<artifactId>yudao-module-mes-biz</artifactId>
<version>${revision}</version>
</dependency>
</dependencies> </dependencies>
<build> <build>

Loading…
Cancel
Save