md
211
emis-server/pom.xml
Normal file
@ -0,0 +1,211 @@
|
|||||||
|
<?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">
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<parent>
|
||||||
|
<artifactId>emis</artifactId>
|
||||||
|
<groupId>com.xdadan</groupId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
<relativePath>../pom.xml</relativePath>
|
||||||
|
</parent>
|
||||||
|
<packaging>jar</packaging>
|
||||||
|
<artifactId>emis-server</artifactId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
|
||||||
|
<description>emis web 服务入口</description>
|
||||||
|
|
||||||
|
<properties>
|
||||||
|
<java.version>8</java.version>
|
||||||
|
<target.dir>pub</target.dir>
|
||||||
|
</properties>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
|
||||||
|
<!-- 核心模块-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.xdadan</groupId>
|
||||||
|
<artifactId>emis-framework</artifactId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.xdadan</groupId>
|
||||||
|
<artifactId>emis-system-web</artifactId>
|
||||||
|
<version>1.0.1</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- 业务模块-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.xdadan</groupId>
|
||||||
|
<artifactId>emis-biz-web</artifactId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>io.nats</groupId>
|
||||||
|
<artifactId>jnats</artifactId>
|
||||||
|
<version>2.16.14</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>mysql</groupId>
|
||||||
|
<artifactId>mysql-connector-java</artifactId>
|
||||||
|
<version>8.0.16</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- spring-boot-devtools -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-devtools</artifactId>
|
||||||
|
<optional>true</optional> <!-- 表示依赖不会传递 -->
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.guardsquare</groupId>
|
||||||
|
<artifactId>proguard-base</artifactId>
|
||||||
|
<version>7.1.0</version>
|
||||||
|
<scope>runtime</scope>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.guardsquare</groupId>
|
||||||
|
<artifactId>proguard-core</artifactId>
|
||||||
|
<version>7.1.0</version>
|
||||||
|
<scope>runtime</scope>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
|
</dependencies>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<source>1.8</source>
|
||||||
|
<target>1.8</target>
|
||||||
|
<encoding>UTF-8</encoding>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<!-- proguard混淆插件-->
|
||||||
|
<!-- <plugin>-->
|
||||||
|
<!-- <groupId>com.github.wvengen</groupId>-->
|
||||||
|
<!-- <artifactId>proguard-maven-plugin</artifactId>-->
|
||||||
|
<!-- <version>2.2.0</version>-->
|
||||||
|
<!-- <executions>-->
|
||||||
|
<!-- <execution>-->
|
||||||
|
<!-- <!– 打包的时候开始混淆–>-->
|
||||||
|
<!-- <phase>package</phase>-->
|
||||||
|
<!-- <goals>-->
|
||||||
|
<!-- <goal>proguard</goal>-->
|
||||||
|
<!-- </goals>-->
|
||||||
|
<!-- </execution>-->
|
||||||
|
<!-- </executions>-->
|
||||||
|
<!-- <configuration>-->
|
||||||
|
<!-- <injar>${project.build.finalName}.jar</injar>-->
|
||||||
|
<!-- <!–输出的jar–>-->
|
||||||
|
<!-- <outjar>${project.build.finalName}.jar</outjar>-->
|
||||||
|
<!-- <!– 是否混淆–>-->
|
||||||
|
<!-- <obfuscate>true</obfuscate>-->
|
||||||
|
<!-- <proguardInclude>${project.basedir}/proguard.cfg</proguardInclude>-->
|
||||||
|
<!-- <libs>-->
|
||||||
|
<!-- <!– 添加依赖 java8–>-->
|
||||||
|
<!-- <lib>${java.home}/lib/rt.jar</lib>-->
|
||||||
|
<!-- <lib>${java.home}/lib/jce.jar</lib>-->
|
||||||
|
<!-- </libs>-->
|
||||||
|
<!-- </configuration>-->
|
||||||
|
<!-- <dependencies>-->
|
||||||
|
<!-- <!– https://mvnrepository.com/artifact/net.sf.proguard/proguard-base –>-->
|
||||||
|
<!-- <dependency>-->
|
||||||
|
<!-- <groupId>net.sf.proguard</groupId>-->
|
||||||
|
<!-- <artifactId>proguard-base</artifactId>-->
|
||||||
|
<!-- <version>6.2.2</version>-->
|
||||||
|
<!-- </dependency>-->
|
||||||
|
<!-- </dependencies>-->
|
||||||
|
<!-- </plugin>-->
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||||
|
<version>2.1.1.RELEASE</version>
|
||||||
|
<configuration>
|
||||||
|
<fork>true</fork> <!-- 如果没有该配置,devtools不会生效 -->
|
||||||
|
</configuration>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<goals>
|
||||||
|
<goal>repackage</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<includeSystemScope>true</includeSystemScope>
|
||||||
|
<executable>true</executable>
|
||||||
|
<mainClass>com.xdadan.erp.LaunchApplication</mainClass>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<!-- https://mvnrepository.com/artifact/org.apache.maven.plugins/maven-deploy-plugin -->
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-deploy-plugin</artifactId>
|
||||||
|
<version>3.0.0-M1</version>
|
||||||
|
<!--deploy 时忽略 model-->
|
||||||
|
<configuration>
|
||||||
|
<skip>true</skip>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<artifactId>maven-antrun-plugin</artifactId>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<phase>package</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>run</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<tasks>
|
||||||
|
<delete verbose="true" includeemptydirs="true">
|
||||||
|
<fileset dir="${target.dir}">
|
||||||
|
<include name="**/*"/>
|
||||||
|
</fileset>
|
||||||
|
</delete>
|
||||||
|
<mkdir dir="${target.dir}"/>
|
||||||
|
<mkdir dir="${target.dir}/config"/>
|
||||||
|
<copy todir="${target.dir}" overwrite="true" >
|
||||||
|
<fileset dir="${project.build.directory}" erroronmissingdir="false">
|
||||||
|
<include name="*.jar"/>
|
||||||
|
</fileset>
|
||||||
|
</copy>
|
||||||
|
<copy todir="${target.dir}" file="${basedir}/../logback-spring.xml" overwrite="true"/>
|
||||||
|
<copy todir="${target.dir}" file="${basedir}/../config.properties" overwrite="true"/>
|
||||||
|
<copy todir="${target.dir}/config" file="${basedir}/../config/app.properties" overwrite="true"/>
|
||||||
|
<copy todir="${target.dir}" file="${basedir}/../startup.sh" overwrite="true"/>
|
||||||
|
|
||||||
|
</tasks>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-war-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<configuration>
|
||||||
|
<failOnMissingWebXml>false</failOnMissingWebXml>
|
||||||
|
<warName>${project.artifactId}</warName>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
</plugins>
|
||||||
|
|
||||||
|
<finalName>${project.artifactId}</finalName>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
</project>
|
||||||
253
emis-server/pom_proguard.xml
Normal file
@ -0,0 +1,253 @@
|
|||||||
|
<?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">
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
<parent>
|
||||||
|
<artifactId>emis</artifactId>
|
||||||
|
<groupId>com.xdadan</groupId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
<relativePath>../pom.xml</relativePath>
|
||||||
|
</parent>
|
||||||
|
<packaging>jar</packaging>
|
||||||
|
<artifactId>emis-launcher</artifactId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
|
||||||
|
<description>web服务入口</description>
|
||||||
|
|
||||||
|
<properties>
|
||||||
|
<java.version>8</java.version>
|
||||||
|
<target.dir>pub</target.dir>
|
||||||
|
</properties>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
|
||||||
|
<!-- 核心模块-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.xdadan</groupId>
|
||||||
|
<artifactId>emis-framework</artifactId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.xdadan</groupId>
|
||||||
|
<artifactId>emis-system-web</artifactId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- 业务模块-->
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.xdadan</groupId>
|
||||||
|
<artifactId>emis-biz-web</artifactId>
|
||||||
|
<version>1.0.0</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.alibaba.boot</groupId>
|
||||||
|
<artifactId>nacos-config-spring-boot-starter</artifactId>
|
||||||
|
<version>0.2.12</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.alibaba.boot</groupId>
|
||||||
|
<artifactId>nacos-discovery-spring-boot-starter</artifactId>
|
||||||
|
<version>0.2.12</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.alibaba.boot</groupId>
|
||||||
|
<artifactId>nacos-config-spring-boot-actuator</artifactId>
|
||||||
|
<version>0.2.12</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.alibaba.boot</groupId>
|
||||||
|
<artifactId>nacos-discovery-spring-boot-actuator</artifactId>
|
||||||
|
<version>0.2.12</version>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- spring-boot-devtools -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-devtools</artifactId>
|
||||||
|
<optional>true</optional> <!-- 表示依赖不会传递 -->
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<!-- swagger3-->
|
||||||
|
<!-- <dependency>-->
|
||||||
|
<!-- <groupId>io.springfox</groupId>-->
|
||||||
|
<!-- <artifactId>springfox-boot-starter</artifactId>-->
|
||||||
|
<!-- </dependency>-->
|
||||||
|
|
||||||
|
<!-- 防止进入swagger页面报类型转换错误,排除3.0.0中的引用,手动增加1.6.2版本 -->
|
||||||
|
<!-- <dependency>-->
|
||||||
|
<!-- <groupId>io.swagger</groupId>-->
|
||||||
|
<!-- <artifactId>swagger-models</artifactId>-->
|
||||||
|
<!-- <version>1.6.2</version>-->
|
||||||
|
<!-- </dependency>-->
|
||||||
|
|
||||||
|
<!-- Mysql驱动包 -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>mysql</groupId>
|
||||||
|
<artifactId>mysql-connector-java</artifactId>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.guardsquare</groupId>
|
||||||
|
<artifactId>proguard-base</artifactId>
|
||||||
|
<version>7.1.0</version>
|
||||||
|
<scope>runtime</scope>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.guardsquare</groupId>
|
||||||
|
<artifactId>proguard-core</artifactId>
|
||||||
|
<version>7.1.0</version>
|
||||||
|
<scope>runtime</scope>
|
||||||
|
</dependency>
|
||||||
|
|
||||||
|
|
||||||
|
</dependencies>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-compiler-plugin</artifactId>
|
||||||
|
<configuration>
|
||||||
|
<source>1.8</source>
|
||||||
|
<target>1.8</target>
|
||||||
|
<encoding>UTF-8</encoding>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<!-- proguard混淆插件-->
|
||||||
|
<plugin>
|
||||||
|
<groupId>com.github.wvengen</groupId>
|
||||||
|
<artifactId>proguard-maven-plugin</artifactId>
|
||||||
|
<version>2.2.0</version>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<!-- 打包的时候开始混淆-->
|
||||||
|
<phase>package</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>proguard</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
<configuration>
|
||||||
|
<injar>${project.build.finalName}.jar</injar>
|
||||||
|
<!--输出的jar-->
|
||||||
|
<outjar>${project.build.finalName}.jar</outjar>
|
||||||
|
<!-- 是否混淆-->
|
||||||
|
<obfuscate>true</obfuscate>
|
||||||
|
<proguardInclude>${project.basedir}/proguard.cfg</proguardInclude>
|
||||||
|
<libs>
|
||||||
|
<!-- 添加依赖 java8-->
|
||||||
|
<lib>${java.home}/lib/rt.jar</lib>
|
||||||
|
<lib>${java.home}/lib/jce.jar</lib>
|
||||||
|
</libs>
|
||||||
|
</configuration>
|
||||||
|
<dependencies>
|
||||||
|
<!-- https://mvnrepository.com/artifact/net.sf.proguard/proguard-base -->
|
||||||
|
<dependency>
|
||||||
|
<groupId>net.sf.proguard</groupId>
|
||||||
|
<artifactId>proguard-base</artifactId>
|
||||||
|
<version>6.2.2</version>
|
||||||
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.springframework.boot</groupId>
|
||||||
|
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||||
|
<version>2.1.1.RELEASE</version>
|
||||||
|
<configuration>
|
||||||
|
<fork>true</fork> <!-- 如果没有该配置,devtools不会生效 -->
|
||||||
|
</configuration>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<goals>
|
||||||
|
<goal>repackage</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<includeSystemScope>true</includeSystemScope>
|
||||||
|
<executable>true</executable>
|
||||||
|
<mainClass>com.xdadan.erp.LaunchApplication</mainClass>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<artifactId>maven-antrun-plugin</artifactId>
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<phase>package</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>run</goal>
|
||||||
|
</goals>
|
||||||
|
<configuration>
|
||||||
|
<tasks>
|
||||||
|
<delete verbose="true" includeemptydirs="true">
|
||||||
|
<fileset dir="${target.dir}">
|
||||||
|
<include name="**/*"/>
|
||||||
|
</fileset>
|
||||||
|
</delete>
|
||||||
|
<mkdir dir="${target.dir}"/>
|
||||||
|
<!-- <mkdir dir="${target.dir}/config"/>-->
|
||||||
|
<copy todir="${target.dir}" overwrite="true" >
|
||||||
|
<fileset dir="${project.build.directory}" erroronmissingdir="false">
|
||||||
|
<include name="*.jar"/>
|
||||||
|
</fileset>
|
||||||
|
</copy>
|
||||||
|
<copy todir="${target.dir}" file="${basedir}/../logback-spring.xml" overwrite="true"/>
|
||||||
|
<!-- <copy todir="${target.dir}" file="${basedir}/../config.properties" overwrite="true"/>-->
|
||||||
|
<!-- <copy todir="${target.dir}/config" file="${basedir}/../config/app.yml" overwrite="true"/>-->
|
||||||
|
<copy todir="${target.dir}" file="${basedir}/../startup.sh" overwrite="true"/>
|
||||||
|
|
||||||
|
</tasks>
|
||||||
|
</configuration>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-assembly-plugin</artifactId>
|
||||||
|
<version>2.2.1</version>
|
||||||
|
<configuration>
|
||||||
|
<finalName>${project.build.finalName}</finalName>
|
||||||
|
<appendAssemblyId>false</appendAssemblyId>
|
||||||
|
<descriptors>
|
||||||
|
<descriptor>src/main/assembly/assembly.xml</descriptor>
|
||||||
|
</descriptors>
|
||||||
|
</configuration>
|
||||||
|
|
||||||
|
<executions>
|
||||||
|
<execution>
|
||||||
|
<id>make-assembly</id>
|
||||||
|
<phase>package</phase>
|
||||||
|
<goals>
|
||||||
|
<goal>single</goal>
|
||||||
|
</goals>
|
||||||
|
</execution>
|
||||||
|
</executions>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-war-plugin</artifactId>
|
||||||
|
<version>3.1.0</version>
|
||||||
|
<configuration>
|
||||||
|
<failOnMissingWebXml>false</failOnMissingWebXml>
|
||||||
|
<warName>${project.artifactId}</warName>
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
|
||||||
|
</plugins>
|
||||||
|
|
||||||
|
<finalName>${project.artifactId}</finalName>
|
||||||
|
</build>
|
||||||
|
|
||||||
|
</project>
|
||||||
52
emis-server/proguard.cfg
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
#指定Java的版本
|
||||||
|
-target 1.8
|
||||||
|
#proguard会对代码进行优化压缩,他会删除从未使用的类或者类成员变量等
|
||||||
|
-dontshrink
|
||||||
|
#是否关闭字节码级别的优化,如果不开启则设置如下配置
|
||||||
|
-dontoptimize
|
||||||
|
#混淆时不生成大小写混合的类名,默认是可以大小写混合
|
||||||
|
-dontusemixedcaseclassnames
|
||||||
|
# 对于类成员的命名的混淆采取唯一策略
|
||||||
|
-useuniqueclassmembernames
|
||||||
|
#混淆时不生成大小写混合的类名,默认是可以大小写混合
|
||||||
|
-dontusemixedcaseclassnames
|
||||||
|
#混淆类名之后,对使用Class.forName('className')之类的地方进行相应替代
|
||||||
|
-adaptclassstrings
|
||||||
|
|
||||||
|
#对异常、注解信息予以保留
|
||||||
|
-keepattributes Exceptions,InnerClasses,Signature,Deprecated,SourceFile,LineNumberTable,*Annotation*,EnclosingMethod
|
||||||
|
# 此选项将保存接口中的所有原始名称(不混淆)-->
|
||||||
|
-keepnames interface ** { *; }
|
||||||
|
# 此选项将保存所有软件包中的所有原始接口文件(不进行混淆)
|
||||||
|
#-keep interface * extends * { *; }
|
||||||
|
#保留参数名,因为控制器,或者Mybatis等接口的参数如果混淆会导致无法接受参数,xml文件找不到参数
|
||||||
|
-keepparameternames
|
||||||
|
# 保留枚举成员及方法
|
||||||
|
-keepclassmembers enum * { *; }
|
||||||
|
|
||||||
|
# 不混淆所有的set/get方法
|
||||||
|
-keepclassmembers public class * {void set*(***);*** get*();}
|
||||||
|
|
||||||
|
# 指定要保留在输出文件内的目录(解决 spring autowire 装配失败的问题)
|
||||||
|
-keepdirectories
|
||||||
|
#-keepdirectories target\classes\cn\XXX\busi\online\cgform\business\RestBusiness.class
|
||||||
|
#-keepdirectories cn.XXX.busi.online.cgform.business.*
|
||||||
|
|
||||||
|
# 不混淆所有类,保存原始定义的注释-
|
||||||
|
-keepclassmembers class * {
|
||||||
|
@org.springframework.context.annotation.Bean *;
|
||||||
|
@org.springframework.beans.factory.annotation.Autowired *;
|
||||||
|
@org.springframework.beans.factory.annotation.Value *;
|
||||||
|
@org.springframework.stereotype.Service *;
|
||||||
|
@org.springframework.stereotype.Component *;
|
||||||
|
}
|
||||||
|
|
||||||
|
#忽略warn消息
|
||||||
|
-ignorewarnings
|
||||||
|
#忽略note消息
|
||||||
|
-dontnote
|
||||||
|
#打印配置信息
|
||||||
|
-printconfiguration
|
||||||
|
-keep public class com.xdadan.erp.LaunchApplication {
|
||||||
|
public static void main(java.lang.String[]);
|
||||||
|
}
|
||||||
@ -0,0 +1,73 @@
|
|||||||
|
package com.xdadan.erp;
|
||||||
|
|
||||||
|
import com.xdadan.erp.common.utils.PropertyUtil;
|
||||||
|
import org.springframework.boot.WebApplicationType;
|
||||||
|
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||||
|
import org.springframework.boot.autoconfigure.jdbc.DataSourceAutoConfiguration;
|
||||||
|
import org.springframework.boot.builder.SpringApplicationBuilder;
|
||||||
|
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
|
||||||
|
import org.springframework.scheduling.annotation.EnableScheduling;
|
||||||
|
|
||||||
|
import java.io.File;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 启动程序
|
||||||
|
*
|
||||||
|
* @author xdadan
|
||||||
|
*/
|
||||||
|
@EnableScheduling
|
||||||
|
@SpringBootApplication(exclude = { DataSourceAutoConfiguration.class })
|
||||||
|
public class LaunchApplication extends SpringBootServletInitializer {
|
||||||
|
|
||||||
|
public static void main(String[] args) throws Exception {
|
||||||
|
initByLocal(args);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 通过本地配置文件运行
|
||||||
|
* @param args
|
||||||
|
*/
|
||||||
|
private static void initByLocal(String[] args){
|
||||||
|
String configFile = "";
|
||||||
|
try {
|
||||||
|
File directory = new File(".");
|
||||||
|
System.out.println(directory.getCanonicalPath());
|
||||||
|
System.out.println(directory.getAbsolutePath());
|
||||||
|
|
||||||
|
configFile = PropertyUtil.getPropertyValue("config.properties", "config.file");
|
||||||
|
System.out.println("use config file:" + configFile);
|
||||||
|
|
||||||
|
} catch (Exception e) {
|
||||||
|
// TODO Auto-generated catch block
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
|
||||||
|
new SpringApplicationBuilder(
|
||||||
|
LaunchApplication.class)
|
||||||
|
.properties("spring.config.location=" + configFile)
|
||||||
|
.web(WebApplicationType.SERVLET).run(args);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
// @Override
|
||||||
|
// public void onStartup(ServletContext servletContext) throws ServletException {
|
||||||
|
// super.onStartup(servletContext);
|
||||||
|
// servletContext.setSessionTrackingModes(Collections.singleton(SessionTrackingMode.COOKIE));
|
||||||
|
// SessionCookieConfig sessionCookieConfig = servletContext.getSessionCookieConfig();
|
||||||
|
// sessionCookieConfig.setHttpOnly(true);
|
||||||
|
// }
|
||||||
|
|
||||||
|
|
||||||
|
// @Bean
|
||||||
|
// public DefaultWebSessionManager sessionManager() {
|
||||||
|
// DefaultWebSessionManager defaultWebSessionManager = new DefaultWebSessionManager();
|
||||||
|
// defaultWebSessionManager.setGlobalSessionTimeout(60 * 30 * 1000);
|
||||||
|
// defaultWebSessionManager.setDeleteInvalidSessions(true);
|
||||||
|
// defaultWebSessionManager.setSessionValidationSchedulerEnabled(true);
|
||||||
|
// defaultWebSessionManager.setSessionIdCookieEnabled(true);
|
||||||
|
// // tomcat的JESSIONID自动生成模块
|
||||||
|
// defaultWebSessionManager.setSessionIdUrlRewritingEnabled(false);
|
||||||
|
// return defaultWebSessionManager;
|
||||||
|
// }
|
||||||
|
}
|
||||||
@ -0,0 +1,18 @@
|
|||||||
|
package com.xdadan.erp;
|
||||||
|
|
||||||
|
import org.springframework.boot.builder.SpringApplicationBuilder;
|
||||||
|
import org.springframework.boot.web.servlet.support.SpringBootServletInitializer;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* web容器中进行部署
|
||||||
|
*
|
||||||
|
* @author xdadan
|
||||||
|
*/
|
||||||
|
public class LaunchServletInitializer extends SpringBootServletInitializer
|
||||||
|
{
|
||||||
|
@Override
|
||||||
|
protected SpringApplicationBuilder configure(SpringApplicationBuilder application)
|
||||||
|
{
|
||||||
|
return application.sources(LaunchApplication.class);
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,46 @@
|
|||||||
|
package com.xdadan.erp.mq.nats;
|
||||||
|
|
||||||
|
|
||||||
|
import com.xdadan.erp.common.utils.StringUtils;
|
||||||
|
import io.nats.client.Connection;
|
||||||
|
import io.nats.client.Nats;
|
||||||
|
import io.nats.client.Options;
|
||||||
|
import org.springframework.context.annotation.Bean;
|
||||||
|
import org.springframework.context.annotation.Configuration;
|
||||||
|
|
||||||
|
import java.io.IOException;
|
||||||
|
import java.time.Duration;
|
||||||
|
|
||||||
|
@Configuration
|
||||||
|
public class NatsConfig {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* nats 连接
|
||||||
|
* @param properties nats 配置文件类
|
||||||
|
* @return nats 连接
|
||||||
|
* @throws IOException
|
||||||
|
* @throws InterruptedException
|
||||||
|
*/
|
||||||
|
@Bean(name = "natsConnection")
|
||||||
|
public Connection natsConnection(NatsProperties properties) throws IOException, InterruptedException {
|
||||||
|
String[] str = properties.getNatsUrls().split(",");
|
||||||
|
Options.Builder builder = new Options.Builder()
|
||||||
|
.servers(str)
|
||||||
|
.connectionListener(new NatsMessageListener()) // 指定监听器
|
||||||
|
.maxReconnects(properties.getMaxReconnect())
|
||||||
|
.reconnectWait(Duration.ofSeconds(properties.getReconnectWait()))
|
||||||
|
.connectionTimeout(Duration.ofSeconds(properties.getConnectionTimeout()));
|
||||||
|
|
||||||
|
// 配置用户名和密码
|
||||||
|
if (!StringUtils.isEmpty(properties.getUserName()) && !StringUtils.isEmpty(properties.getPassword())) {
|
||||||
|
builder.userInfo(properties.getUserName().toCharArray(),properties.getPassword().toCharArray());
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!StringUtils.isEmpty(properties.getToken())) {
|
||||||
|
builder.token(properties.getToken().toCharArray());
|
||||||
|
}
|
||||||
|
|
||||||
|
return Nats.connect(builder.build());
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
||||||
@ -0,0 +1,26 @@
|
|||||||
|
package com.xdadan.erp.mq.nats;
|
||||||
|
|
||||||
|
import com.xdadan.erp.common.utils.spring.SpringUtils;
|
||||||
|
import io.nats.client.Connection;
|
||||||
|
import io.nats.client.ConnectionListener;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import java.nio.charset.StandardCharsets;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
public class NatsMessageListener implements ConnectionListener {
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void connectionEvent(Connection conn, Events events) {
|
||||||
|
log.info(String.format("nats connection status: %s", conn.getStatus()));
|
||||||
|
|
||||||
|
// 连接成功后进行消息订阅
|
||||||
|
if(Connection.Status.CONNECTED.equals(conn.getStatus())){
|
||||||
|
log.info("NATS conneted");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,35 @@
|
|||||||
|
package com.xdadan.erp.mq.nats;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.boot.context.properties.ConfigurationProperties;
|
||||||
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
|
/**
|
||||||
|
#nats 相关配置
|
||||||
|
nats.nats-urls=nats://xxx:4222
|
||||||
|
nats.max-reconnect=60
|
||||||
|
nats.reconnect-wait=2
|
||||||
|
nats.connection-timeout=2
|
||||||
|
nats.user-name=nats
|
||||||
|
nats.password=nats
|
||||||
|
*/
|
||||||
|
@Component
|
||||||
|
@ConfigurationProperties(prefix = "nats")
|
||||||
|
@Data
|
||||||
|
public class NatsProperties {
|
||||||
|
|
||||||
|
private String natsUrls;
|
||||||
|
|
||||||
|
private String token = null;
|
||||||
|
|
||||||
|
private int maxReconnect = 60;
|
||||||
|
|
||||||
|
private int reconnectWait = 2;
|
||||||
|
|
||||||
|
private int connectionTimeout = 2;
|
||||||
|
|
||||||
|
private String userName;
|
||||||
|
|
||||||
|
private String password;
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1,48 @@
|
|||||||
|
package com.xdadan.erp.tst;
|
||||||
|
|
||||||
|
|
||||||
|
import com.xdadan.erp.common.core.controller.BaseController;
|
||||||
|
import com.xdadan.erp.common.utils.spring.SpringUtils;
|
||||||
|
import io.nats.client.Connection;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.web.bind.annotation.GetMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import javax.annotation.Resource;
|
||||||
|
import java.nio.charset.StandardCharsets;
|
||||||
|
|
||||||
|
@Slf4j
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/tst/mq/nats")
|
||||||
|
public class TestController extends BaseController
|
||||||
|
{
|
||||||
|
@Resource(name="natsConnection")
|
||||||
|
private Connection natsConnection;
|
||||||
|
|
||||||
|
@GetMapping("/publish")
|
||||||
|
public void publish(String subject,String msg)
|
||||||
|
{
|
||||||
|
// 发送测试消息
|
||||||
|
// sendMqMsg("IM-BINDGROUP","111,1");
|
||||||
|
sendMqMsg(subject,msg);
|
||||||
|
}
|
||||||
|
|
||||||
|
private void sendMqMsg(String subject,String msg){
|
||||||
|
|
||||||
|
if(natsConnection==null) {
|
||||||
|
log.info("NATS服务器未连接!!!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
try {
|
||||||
|
log.info("发送 MQ NATS 消息: subject:{} , msg:{}",subject,msg);
|
||||||
|
natsConnection.publish(subject, msg.getBytes(StandardCharsets.UTF_8));
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.info("发送 MQ NATS 异常: subject:{} , msg:{}, e:",subject,msg,e.getMessage());
|
||||||
|
e.printStackTrace();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
@ -0,0 +1 @@
|
|||||||
|
restart.include.json=/com.alibaba.fastjson.*.jar
|
||||||
183
emis-server/src/main/resources/application_local.yml
Normal file
@ -0,0 +1,183 @@
|
|||||||
|
# 项目相关配置
|
||||||
|
pay:
|
||||||
|
# 名称
|
||||||
|
name: ddoms2
|
||||||
|
# 版本
|
||||||
|
version: 1.0.0
|
||||||
|
# 版权年份
|
||||||
|
copyrightYear: 2022
|
||||||
|
# 实例演示开关
|
||||||
|
demoEnabled: false
|
||||||
|
# profile: xdadan/uploadPath
|
||||||
|
# 获取ip地址开关
|
||||||
|
addressEnabled: false
|
||||||
|
# 验证码类型 math 数组计算 char 字符验证
|
||||||
|
captchaType: char
|
||||||
|
|
||||||
|
# 开发环境配置
|
||||||
|
#server:
|
||||||
|
# # 服务器的HTTP端口,默认为8080
|
||||||
|
# port: 8080
|
||||||
|
# servlet:
|
||||||
|
# # 应用的访问路径
|
||||||
|
# context-path: /
|
||||||
|
# tomcat:
|
||||||
|
# # tomcat的URI编码
|
||||||
|
# uri-encoding: UTF-8
|
||||||
|
# # 连接数满后的排队数,默认为100
|
||||||
|
# accept-count: 1000
|
||||||
|
# threads:
|
||||||
|
# # tomcat最大线程数,默认为200
|
||||||
|
# max: 800
|
||||||
|
# # Tomcat启动初始化的线程数,默认值10
|
||||||
|
# min-spare: 100
|
||||||
|
|
||||||
|
# 日志配置
|
||||||
|
logging:
|
||||||
|
level:
|
||||||
|
com.xdadan: debug
|
||||||
|
org.springframework: warn
|
||||||
|
|
||||||
|
# Spring配置
|
||||||
|
spring:
|
||||||
|
# 资源信息
|
||||||
|
messages:
|
||||||
|
# 国际化资源文件路径
|
||||||
|
basename: i18n/messages
|
||||||
|
# profiles:
|
||||||
|
# active: druid
|
||||||
|
# 文件上传
|
||||||
|
servlet:
|
||||||
|
multipart:
|
||||||
|
# 单个文件大小
|
||||||
|
max-file-size: 1000MB
|
||||||
|
# 设置总上传的文件大小
|
||||||
|
max-request-size: 20000MB
|
||||||
|
cache:
|
||||||
|
# 指定所使用的缓存管理器
|
||||||
|
type: REDIS
|
||||||
|
cache-names: redisCache
|
||||||
|
redis:
|
||||||
|
cache-null-values: true
|
||||||
|
use-key-prefix: true
|
||||||
|
time-to-live: 0
|
||||||
|
# 服务模块
|
||||||
|
devtools:
|
||||||
|
restart:
|
||||||
|
# 热部署开关
|
||||||
|
enabled: true
|
||||||
|
|
||||||
|
# token配置
|
||||||
|
token:
|
||||||
|
# 令牌自定义标识
|
||||||
|
header: X-Token
|
||||||
|
# 令牌密钥
|
||||||
|
secret: 10942fd6f30d45a567e7ec84b18f9ca7c1
|
||||||
|
# 令牌有效期(默认30分钟)
|
||||||
|
expireTime: 30
|
||||||
|
|
||||||
|
# MyBatis配置
|
||||||
|
#mybatis:
|
||||||
|
# # 搜索指定包别名
|
||||||
|
# typeAliasesPackage: com.xdadan.**.domain
|
||||||
|
# # 配置mapper的扫描,找到所有的mapper.xml映射文件
|
||||||
|
# mapperLocations: classpath*:mapper/**/*Mapper.xml
|
||||||
|
# # 加载全局的配置文件
|
||||||
|
# configLocation: classpath:mybatis/mybatis-config.xml
|
||||||
|
|
||||||
|
mybatis-plus:
|
||||||
|
type-aliases-package: com.xdadan.**.domain
|
||||||
|
mapper-locations: classpath*:mapper/**/*Mapper.xml
|
||||||
|
config-location: classpath:mybatis/mybatis-config.xml
|
||||||
|
global-config:
|
||||||
|
#主键类型 0:"数据库ID自增", 1:"用户输入ID",2:"全局唯一ID (数字类型唯一ID)", 3:"全局唯一ID UUID";
|
||||||
|
id-type: 1
|
||||||
|
#驼峰下划线转换
|
||||||
|
db-column-underline: true
|
||||||
|
configuration:
|
||||||
|
#配置打印sql
|
||||||
|
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
||||||
|
|
||||||
|
saas:
|
||||||
|
tenant:
|
||||||
|
enable: true
|
||||||
|
column: tenant_id
|
||||||
|
filterTables:
|
||||||
|
ignoreTables:
|
||||||
|
- sys_account
|
||||||
|
- sys_account_log
|
||||||
|
- sys_api_log
|
||||||
|
- sys_appinfo
|
||||||
|
- sys_config
|
||||||
|
- sys_cost_time
|
||||||
|
- sys_dept
|
||||||
|
- sys_dict_data
|
||||||
|
- sys_dict_type
|
||||||
|
- sys_domain
|
||||||
|
- sys_dynamic_ds
|
||||||
|
- sys_dynamic_sql
|
||||||
|
- sys_file_info
|
||||||
|
- sys_i18n
|
||||||
|
- sys_im_friend
|
||||||
|
- sys_im_group
|
||||||
|
- sys_im_group_user
|
||||||
|
- sys_im_message
|
||||||
|
- sys_job
|
||||||
|
- sys_job_log
|
||||||
|
- sys_logininfor
|
||||||
|
- sys_mail_queue
|
||||||
|
- sys_menu
|
||||||
|
- sys_merchant
|
||||||
|
- sys_merchant_service
|
||||||
|
- sys_merchant_user_rel
|
||||||
|
- sys_mq_queues
|
||||||
|
- sys_notice
|
||||||
|
- sys_oper_log
|
||||||
|
- sys_post
|
||||||
|
- sys_role
|
||||||
|
- sys_role_dept
|
||||||
|
- sys_role_menu
|
||||||
|
- sys_role_merchant
|
||||||
|
- sys_role_tenant
|
||||||
|
- sys_sequence
|
||||||
|
- sys_service
|
||||||
|
- sys_storage
|
||||||
|
- sys_tenant
|
||||||
|
- sys_tenant_domain_apply
|
||||||
|
- sys_upapi_log
|
||||||
|
- sys_user
|
||||||
|
- sys_user_copy1
|
||||||
|
- sys_user_post
|
||||||
|
- sys_user_role
|
||||||
|
- sys_validate_record
|
||||||
|
- sys_zone_banner
|
||||||
|
- sys_zone_config
|
||||||
|
- sys_zone_nav
|
||||||
|
ignoreLoginNames:
|
||||||
|
- padmin
|
||||||
|
|
||||||
|
# PageHelper分页插件
|
||||||
|
pagehelper:
|
||||||
|
helperDialect: mysql
|
||||||
|
supportMethodsArguments: true
|
||||||
|
params: count=countSql
|
||||||
|
|
||||||
|
# Knife4j配置
|
||||||
|
knife4j:
|
||||||
|
# 是否开启增强模式
|
||||||
|
enable: true
|
||||||
|
basic:
|
||||||
|
enable: true
|
||||||
|
username: admin
|
||||||
|
password: 654321
|
||||||
|
setting:
|
||||||
|
language: zh-CN
|
||||||
|
|
||||||
|
# 防止XSS攻击
|
||||||
|
xss:
|
||||||
|
# 过滤开关
|
||||||
|
enabled: true
|
||||||
|
# 排除链接(多个用逗号分隔)
|
||||||
|
excludes: /system/notice
|
||||||
|
# 匹配链接
|
||||||
|
urlPatterns: /system/*,/monitor/*,/tool/*
|
||||||
2
emis-server/src/main/resources/banner.txt
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
Application Version: ${pay.version}
|
||||||
|
Spring Boot Version: ${spring-boot.version}
|
||||||
38
emis-server/src/main/resources/i18n/messages.properties
Normal file
@ -0,0 +1,38 @@
|
|||||||
|
#错误消息
|
||||||
|
not.null=* 必须填写
|
||||||
|
user.jcaptcha.error=验证码错误
|
||||||
|
user.jcaptcha.expire=验证码已失效
|
||||||
|
user.smscode.expire=验证码已失效
|
||||||
|
user.not.exists=用户不存在/密码错误
|
||||||
|
user.password.not.match=用户不存在/密码错误
|
||||||
|
user.password.retry.limit.count=密码输入错误{0}次
|
||||||
|
user.password.retry.limit.exceed=密码输入错误{0}次,帐户锁定10分钟
|
||||||
|
user.password.delete=对不起,您的账号已被删除
|
||||||
|
user.blocked=用户已封禁,请联系管理员
|
||||||
|
role.blocked=角色已封禁,请联系管理员
|
||||||
|
user.logout.success=退出成功
|
||||||
|
|
||||||
|
length.not.valid=长度必须在{min}到{max}个字符之间
|
||||||
|
|
||||||
|
user.username.not.valid=* 2到20个汉字、字母、数字或下划线组成,且必须以非数字开头
|
||||||
|
user.password.not.valid=* 5-50个字符
|
||||||
|
|
||||||
|
user.email.not.valid=邮箱格式错误
|
||||||
|
user.mobile.phone.number.not.valid=手机号格式错误
|
||||||
|
user.login.success=登录成功
|
||||||
|
user.register.success=注册成功
|
||||||
|
user.notfound=请重新登录
|
||||||
|
user.forcelogout=管理员强制退出,请重新登录
|
||||||
|
user.unknown.error=未知错误,请重新登录
|
||||||
|
|
||||||
|
##文件上传消息
|
||||||
|
upload.exceed.maxSize=上传的文件大小超出限制的文件大小!<br/>允许的文件最大大小是:{0}MB!
|
||||||
|
upload.filename.exceed.length=上传的文件名最长{0}个字符
|
||||||
|
|
||||||
|
##权限
|
||||||
|
no.permission=您没有数据的权限,请联系管理员添加权限 [{0}]
|
||||||
|
no.create.permission=您没有创建数据的权限,请联系管理员添加权限 [{0}]
|
||||||
|
no.update.permission=您没有修改数据的权限,请联系管理员添加权限 [{0}]
|
||||||
|
no.delete.permission=您没有删除数据的权限,请联系管理员添加权限 [{0}]
|
||||||
|
no.export.permission=您没有导出数据的权限,请联系管理员添加权限 [{0}]
|
||||||
|
no.view.permission=您没有查看数据的权限,请联系管理员添加权限 [{0}]
|
||||||
52
emis-server/src/main/resources/logback.xml
Normal file
@ -0,0 +1,52 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<configuration debug="false">
|
||||||
|
<contextName>allinone-server</contextName>
|
||||||
|
<statusListener class="ch.qos.logback.core.status.NopStatusListener" />
|
||||||
|
<appender name="all_console" class="ch.qos.logback.core.ConsoleAppender">
|
||||||
|
<encoder>
|
||||||
|
<charset>UTF-8</charset>
|
||||||
|
<pattern>[%contextName][%p][%d{yyyy-MM-dd HH:mm:ss}][%t][%C{3}.%M\(line:%L\)]:> %m%n</pattern>
|
||||||
|
</encoder>
|
||||||
|
</appender>
|
||||||
|
<appender name="all_error" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||||
|
<filter class="ch.qos.logback.classic.filter.LevelFilter">
|
||||||
|
<level>ERROR</level>
|
||||||
|
<onMatch>ACCEPT</onMatch>
|
||||||
|
<onMismatch>DENY</onMismatch>
|
||||||
|
</filter>
|
||||||
|
<File>./logs/app_all_error.log</File>
|
||||||
|
<rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
||||||
|
<FileNamePattern>./logs/app_all_error.%i.log</FileNamePattern>
|
||||||
|
<MinIndex>1</MinIndex>
|
||||||
|
<MaxIndex>10</MaxIndex>
|
||||||
|
</rollingPolicy>
|
||||||
|
<triggeringPolicy class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
||||||
|
<MaxFileSize>10MB</MaxFileSize>
|
||||||
|
</triggeringPolicy>
|
||||||
|
<layout class="ch.qos.logback.classic.PatternLayout">
|
||||||
|
<Pattern>[%contextName][%p][%d{yyyy-MM-dd HH:mm:ss}][%t][%C{3}.%M\(line:%L\)]:> %m%n</Pattern>
|
||||||
|
</layout>
|
||||||
|
</appender>
|
||||||
|
<appender name="all_info" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||||
|
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
|
||||||
|
<level>INFO</level>
|
||||||
|
</filter>
|
||||||
|
<File>./logs/app_all_info.log</File>
|
||||||
|
<rollingPolicy class="ch.qos.logback.core.rolling.FixedWindowRollingPolicy">
|
||||||
|
<FileNamePattern>./logs/app_all_info.%i.log</FileNamePattern>
|
||||||
|
<MinIndex>1</MinIndex>
|
||||||
|
<MaxIndex>10</MaxIndex>
|
||||||
|
</rollingPolicy>
|
||||||
|
<triggeringPolicy class="ch.qos.logback.core.rolling.SizeBasedTriggeringPolicy">
|
||||||
|
<MaxFileSize>10MB</MaxFileSize>
|
||||||
|
</triggeringPolicy>
|
||||||
|
<layout class="ch.qos.logback.classic.PatternLayout">
|
||||||
|
<Pattern>[%contextName][%p][%d{yyyy-MM-dd HH:mm:ss}][%t][%C{3}.%M\(line:%L\)]:> %m%n</Pattern>
|
||||||
|
</layout>
|
||||||
|
</appender>
|
||||||
|
<root level="INFO" >
|
||||||
|
<appender-ref ref="all_info" />
|
||||||
|
<appender-ref ref="all_error" />
|
||||||
|
<appender-ref ref="all_console" />
|
||||||
|
</root>
|
||||||
|
</configuration>
|
||||||
20
emis-server/src/main/resources/mybatis/mybatis-config.xml
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
<?xml version="1.0" encoding="UTF-8" ?>
|
||||||
|
<!DOCTYPE configuration
|
||||||
|
PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
|
||||||
|
"http://mybatis.org/dtd/mybatis-3-config.dtd">
|
||||||
|
<configuration>
|
||||||
|
<!-- 全局参数 -->
|
||||||
|
<settings>
|
||||||
|
<!-- 使全局的映射器启用或禁用缓存 -->
|
||||||
|
<setting name="cacheEnabled" value="true" />
|
||||||
|
<!-- 允许JDBC 支持自动生成主键 -->
|
||||||
|
<setting name="useGeneratedKeys" value="true" />
|
||||||
|
<!-- 配置默认的执行器.SIMPLE就是普通执行器;REUSE执行器会重用预处理语句(prepared statements);BATCH执行器将重用语句并执行批量更新 -->
|
||||||
|
<setting name="defaultExecutorType" value="SIMPLE" />
|
||||||
|
<!-- 指定 MyBatis 所用日志的具体实现 -->
|
||||||
|
<setting name="logImpl" value="SLF4J" />
|
||||||
|
<!-- 使用驼峰命名法转换字段 -->
|
||||||
|
<!-- <setting name="mapUnderscoreToCamelCase" value="true"/> -->
|
||||||
|
</settings>
|
||||||
|
|
||||||
|
</configuration>
|
||||||
BIN
emis-server/src/main/resources/static/images/slidepic_1.jpg
Normal file
|
After Width: | Height: | Size: 70 KiB |
BIN
emis-server/src/main/resources/static/images/slidepic_2.jpg
Normal file
|
After Width: | Height: | Size: 62 KiB |
BIN
emis-server/src/main/resources/static/images/slidepic_3.jpg
Normal file
|
After Width: | Height: | Size: 45 KiB |
BIN
emis-server/src/main/resources/static/images/slidepic_4.jpg
Normal file
|
After Width: | Height: | Size: 94 KiB |
BIN
emis-server/src/main/resources/static/images/slidepic_5.jpg
Normal file
|
After Width: | Height: | Size: 49 KiB |
BIN
emis-server/src/main/resources/static/images/slidepic_6.jpg
Normal file
|
After Width: | Height: | Size: 76 KiB |
BIN
emis-server/src/main/resources/static/images/slidepic_7.jpg
Normal file
|
After Width: | Height: | Size: 96 KiB |