初始化项目

This commit is contained in:
2026-03-19 21:55:47 +08:00
parent e963bfb9d5
commit fe408e4906
45 changed files with 8260 additions and 668 deletions

View File

@@ -0,0 +1,25 @@
@echo off
rem /**
rem * Copyright (c) 2013-Now https://jeesite.com All rights reserved.
rem * No deletion without permission, or be held responsible to law.
rem *
rem * Author: ThinkGem@163.com
rem */
echo.
echo [<5B><>Ϣ] <20><><EFBFBD>𹤳̵<F0B9A4B3>Maven<65><6E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
echo.
%~d0
cd %~dp0
if defined JAVA_HOME17 (
set "JAVA_HOME=%JAVA_HOME17%" & set "PATH=%JAVA_HOME17%\bin;%PATH%"
)
call mvn -v
echo.
cd ..
call mvn clean deploy -Dmaven.test.skip=true -Pdeploy
cd bin
pause

21
modules/biz/bin/deploy.sh Normal file
View File

@@ -0,0 +1,21 @@
#!/bin/sh
# /**
# * Copyright (c) 2013-Now https://jeesite.com All rights reserved.
# * No deletion without permission, or be held responsible to law.
# *
# * Author: ThinkGem@163.com
# */
echo ""
echo "[信息] 部署工程到Maven服务器。"
echo ""
if [ -n "$JAVA_HOME17" ] && [ -d "$JAVA_HOME17" ]; then
export JAVA_HOME="$JAVA_HOME17" PATH="$JAVA_HOME/bin:$PATH"
fi
mvn -v
echo ""
cd ..
mvn clean deploy -Dmaven.test.skip=true -Pdeploy
cd bin

View File

@@ -0,0 +1,25 @@
@echo off
rem /**
rem * Copyright (c) 2013-Now https://jeesite.com All rights reserved.
rem * No deletion without permission, or be held responsible to law.
rem *
rem * Author: ThinkGem@163.com
rem */
echo.
echo [<5B><>Ϣ] <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>װ<EFBFBD><D7B0><EFBFBD>̣<EFBFBD><CCA3><EFBFBD><EFBFBD><EFBFBD>jar<61><72><EFBFBD>ļ<EFBFBD><C4BC><EFBFBD>
echo.
%~d0
cd %~dp0
if defined JAVA_HOME17 (
set "JAVA_HOME=%JAVA_HOME17%" & set "PATH=%JAVA_HOME17%\bin;%PATH%"
)
call mvn -v
echo.
cd ..
call mvn clean install -Dmaven.test.skip=true -Ppackage
cd bin
pause

View File

@@ -0,0 +1,21 @@
#!/bin/sh
# /**
# * Copyright (c) 2013-Now https://jeesite.com All rights reserved.
# * No deletion without permission, or be held responsible to law.
# *
# * Author: ThinkGem@163.com
# */
echo ""
echo "[信息] 打包安装工程生成jar包文件。"
echo ""
if [ -n "$JAVA_HOME17" ] && [ -d "$JAVA_HOME17" ]; then
export JAVA_HOME="$JAVA_HOME17" PATH="$JAVA_HOME/bin:$PATH"
fi
mvn -v
echo ""
cd ..
mvn clean install -Dmaven.test.skip=true -Ppackage
cd bin

3590
modules/biz/db/biz.erm Normal file

File diff suppressed because it is too large Load Diff

46
modules/biz/pom.xml Normal file
View File

@@ -0,0 +1,46 @@
<?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>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.15.1.springboot3-SNAPSHOT</version>
<relativePath>../../parent/pom.xml</relativePath>
</parent>
<artifactId>jeesite-module-biz</artifactId>
<packaging>jar</packaging>
<name>JeeSite Module 业务模块</name>
<url>https://jeesite.com</url>
<inceptionYear>2013-Now</inceptionYear>
<dependencies>
<!-- 核心模块 --><!--suppress VulnerableLibrariesLocal -->
<dependency>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-core</artifactId>
<version>${project.parent.version}</version>
</dependency>
</dependencies>
<developers>
<developer>
<id>thinkgem</id>
<name>WangZhen</name>
<email>thinkgem at 163.com</email>
<roles><role>Project lead</role></roles>
<timezone>+8</timezone>
</developer>
</developers>
<organization>
<name>JeeSite</name>
<url>https://jeesite.com</url>
</organization>
</project>

View File

@@ -0,0 +1,12 @@
## 重要提示Tip
## 请勿在该配置文件中添加其它任何配置(添加也不会生效)。
## 该文件,仅仅是为了让 jeesite-biz.yml 文件,
## 在 IDEA 中有一个自动完成及帮助提示,并无其它用意。
## 参数配置请在 jeesite-bpm.yml 文件中添加。
spring:
config:
import:
- classpath:config/jeesite-biz.yml

View File

@@ -0,0 +1,4 @@
# 温馨提示不建议直接修改此文件为了平台升级方便建议将需要修改的参数值复制到application.yml里进行覆盖该参数值。
#biz:
# enabled: true

View File

@@ -0,0 +1 @@
5.15.1

View File

@@ -0,0 +1,25 @@
@echo off
rem /**
rem * Copyright (c) 2013-Now https://jeesite.com All rights reserved.
rem * No deletion without permission, or be held responsible to law.
rem *
rem * Author: ThinkGem@163.com
rem */
echo.
echo [<5B><>Ϣ] <20><><EFBFBD>𹤳̵<F0B9A4B3>Maven<65><6E><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
echo.
%~d0
cd %~dp0
if defined JAVA_HOME17 (
set "JAVA_HOME=%JAVA_HOME17%" & set "PATH=%JAVA_HOME17%\bin;%PATH%"
)
call mvn -v
echo.
cd ..
call mvn clean deploy -Dmaven.test.skip=true -Pdeploy
cd bin
pause

21
modules/erp/bin/deploy.sh Normal file
View File

@@ -0,0 +1,21 @@
#!/bin/sh
# /**
# * Copyright (c) 2013-Now https://jeesite.com All rights reserved.
# * No deletion without permission, or be held responsible to law.
# *
# * Author: ThinkGem@163.com
# */
echo ""
echo "[信息] 部署工程到Maven服务器。"
echo ""
if [ -n "$JAVA_HOME17" ] && [ -d "$JAVA_HOME17" ]; then
export JAVA_HOME="$JAVA_HOME17" PATH="$JAVA_HOME/bin:$PATH"
fi
mvn -v
echo ""
cd ..
mvn clean deploy -Dmaven.test.skip=true -Pdeploy
cd bin

View File

@@ -0,0 +1,25 @@
@echo off
rem /**
rem * Copyright (c) 2013-Now https://jeesite.com All rights reserved.
rem * No deletion without permission, or be held responsible to law.
rem *
rem * Author: ThinkGem@163.com
rem */
echo.
echo [<5B><>Ϣ] <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>װ<EFBFBD><D7B0><EFBFBD>̣<EFBFBD><CCA3><EFBFBD><EFBFBD><EFBFBD>jar<61><72><EFBFBD>ļ<EFBFBD><C4BC><EFBFBD>
echo.
%~d0
cd %~dp0
if defined JAVA_HOME17 (
set "JAVA_HOME=%JAVA_HOME17%" & set "PATH=%JAVA_HOME17%\bin;%PATH%"
)
call mvn -v
echo.
cd ..
call mvn clean install -Dmaven.test.skip=true -Ppackage
cd bin
pause

View File

@@ -0,0 +1,21 @@
#!/bin/sh
# /**
# * Copyright (c) 2013-Now https://jeesite.com All rights reserved.
# * No deletion without permission, or be held responsible to law.
# *
# * Author: ThinkGem@163.com
# */
echo ""
echo "[信息] 打包安装工程生成jar包文件。"
echo ""
if [ -n "$JAVA_HOME17" ] && [ -d "$JAVA_HOME17" ]; then
export JAVA_HOME="$JAVA_HOME17" PATH="$JAVA_HOME/bin:$PATH"
fi
mvn -v
echo ""
cd ..
mvn clean install -Dmaven.test.skip=true -Ppackage
cd bin

3590
modules/erp/db/erp.erm Normal file

File diff suppressed because it is too large Load Diff

46
modules/erp/pom.xml Normal file
View File

@@ -0,0 +1,46 @@
<?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>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.15.1.springboot3-SNAPSHOT</version>
<relativePath>../../parent/pom.xml</relativePath>
</parent>
<artifactId>jeesite-module-erp</artifactId>
<packaging>jar</packaging>
<name>JeeSite Module 财务管理</name>
<url>https://jeesite.com</url>
<inceptionYear>2013-Now</inceptionYear>
<dependencies>
<!-- 核心模块 --><!--suppress VulnerableLibrariesLocal -->
<dependency>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-core</artifactId>
<version>${project.parent.version}</version>
</dependency>
</dependencies>
<developers>
<developer>
<id>thinkgem</id>
<name>WangZhen</name>
<email>thinkgem at 163.com</email>
<roles><role>Project lead</role></roles>
<timezone>+8</timezone>
</developer>
</developers>
<organization>
<name>JeeSite</name>
<url>https://jeesite.com</url>
</organization>
</project>

View File

@@ -0,0 +1,12 @@
## 重要提示Tip
## 请勿在该配置文件中添加其它任何配置(添加也不会生效)。
## 该文件,仅仅是为了让 jeesite-erp.yml 文件,
## 在 IDEA 中有一个自动完成及帮助提示,并无其它用意。
## 参数配置请在 jeesite-bpm.yml 文件中添加。
spring:
config:
import:
- classpath:config/jeesite-erp.yml

View File

@@ -0,0 +1,4 @@
# 温馨提示不建议直接修改此文件为了平台升级方便建议将需要修改的参数值复制到application.yml里进行覆盖该参数值。
#erp:
# enabled: true

View File

@@ -0,0 +1 @@
5.15.1

View File

@@ -1,39 +1,43 @@
<?xml version="1.0" encoding="UTF-8"?> <?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" <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"> 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> <modelVersion>4.0.0</modelVersion>
<groupId>com.jeesite</groupId> <groupId>com.jeesite</groupId>
<artifactId>jeesite-modules</artifactId> <artifactId>jeesite-modules</artifactId>
<version>5.15.1.springboot3-SNAPSHOT</version> <version>5.15.1.springboot3-SNAPSHOT</version>
<packaging>pom</packaging> <packaging>pom</packaging>
<name>JeeSite Modules</name> <name>JeeSite Modules</name>
<url>https://jeesite.com</url> <url>https://jeesite.com</url>
<inceptionYear>2013-Now</inceptionYear> <inceptionYear>2013-Now</inceptionYear>
<modules> <modules>
<module>ai</module> <module>ai</module>
<module>app</module> <module>app</module>
<module>cms</module> <module>cms</module>
<module>core</module> <module>biz</module>
<module>core/static</module> <module>erp</module>
<module>test</module> <module>core</module>
</modules> <module>core/static</module>
<module>test</module>
<developers> </modules>
<developer>
<id>thinkgem</id> <developers>
<name>WangZhen</name> <developer>
<email>thinkgem at 163.com</email> <id>thinkgem</id>
<roles><role>Project lead</role></roles> <name>WangZhen</name>
<timezone>+8</timezone> <email>thinkgem at 163.com</email>
</developer> <roles>
</developers> <role>Project lead</role>
</roles>
<organization> <timezone>+8</timezone>
<name>JeeSite</name> </developer>
<url>https://jeesite.com</url> </developers>
</organization>
<organization>
<name>JeeSite</name>
<url>https://jeesite.com</url>
</organization>
</project> </project>

View File

@@ -1,128 +1,148 @@
<?xml version="1.0" encoding="UTF-8"?> <?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" <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"> 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> <modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
<version>5.15.1.springboot3-SNAPSHOT</version>
<relativePath>../parent/pom.xml</relativePath>
</parent>
<artifactId>jeesite-web-api</artifactId>
<packaging>jar</packaging>
<description>专为分离端提供接口服务,关闭内置登录页和主框架页视图</description>
<name>JeeSite Web Api</name>
<url>https://jeesite.com</url>
<inceptionYear>2013-Now</inceptionYear>
<properties>
<finalName>mySpring</finalName><!-- war 或 jar 包的名称 -->
<start-class>com.jeesite.modules.ApiApplication</start-class>
<!-- Docker setting --> <parent>
<docker.run.port>8980:8980</docker.run.port> <groupId>com.jeesite</groupId>
<artifactId>jeesite-parent</artifactId>
</properties> <version>5.15.1.springboot3-SNAPSHOT</version>
<relativePath>../parent/pom.xml</relativePath>
</parent>
<dependencies> <artifactId>jeesite-web-api</artifactId>
<packaging>jar</packaging>
<!-- 核心模块 --><!--suppress VulnerableLibrariesLocal --> <description>专为分离端提供接口服务,关闭内置登录页和主框架页视图</description>
<dependency>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-core</artifactId>
<version>${project.parent.version}</version>
</dependency>
<!-- 测试模块 --> <name>JeeSite Web Api</name>
<dependency> <url>https://jeesite.com</url>
<groupId>com.jeesite</groupId> <inceptionYear>2013-Now</inceptionYear>
<artifactId>jeesite-module-test</artifactId>
<version>${project.parent.version}</version>
</dependency>
<!-- 在线文档接口 --> <properties>
<dependency>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-swagger</artifactId>
<version>${project.parent.version}</version>
</dependency>
<!-- 内容管理模块 --> <finalName>mySpring</finalName><!-- war 或 jar 包的名称 -->
<dependency> <start-class>com.jeesite.modules.ApiApplication</start-class>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-cms</artifactId>
<version>${project.parent.version}</version>
</dependency>
<!-- 移动端模块 --> <!-- Docker setting -->
<dependency> <docker.run.port>8980:8980</docker.run.port>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-app</artifactId>
<version>${project.parent.version}</version>
</dependency>
</dependencies> </properties>
<build> <dependencies>
<finalName>${finalName}</finalName>
<plugins> <dependency>
<plugin> <groupId>com.jeesite</groupId>
<groupId>org.springframework.boot</groupId> <artifactId>jeesite-module-biz</artifactId>
<artifactId>spring-boot-maven-plugin</artifactId> <version>${project.parent.version}</version>
<configuration> </dependency>
<includeSystemScope>true</includeSystemScope>
</configuration> <dependency>
</plugin> <groupId>com.jeesite</groupId>
<artifactId>jeesite-module-erp</artifactId>
<version>${project.parent.version}</version>
</dependency>
<!-- 核心模块 --><!--suppress VulnerableLibrariesLocal -->
<dependency>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-core</artifactId>
<version>${project.parent.version}</version>
</dependency>
<!-- 测试模块 -->
<dependency>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-test</artifactId>
<version>${project.parent.version}</version>
</dependency>
<!-- 在线文档接口 -->
<dependency>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-swagger</artifactId>
<version>${project.parent.version}</version>
</dependency>
<!-- 内容管理模块 -->
<dependency>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-cms</artifactId>
<version>${project.parent.version}</version>
</dependency>
<!-- 移动端模块 -->
<dependency>
<groupId>com.jeesite</groupId>
<artifactId>jeesite-module-app</artifactId>
<version>${project.parent.version}</version>
</dependency>
</dependencies>
<build>
<finalName>${finalName}</finalName>
<plugins>
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<includeSystemScope>true</includeSystemScope>
</configuration>
</plugin>
<!-- War 插件,自定义 war 包名称 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<warName>${finalName}</warName>
</configuration>
</plugin>
<!-- Eclipse 插件 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-eclipse-plugin</artifactId>
<configuration>
<wtpContextName>${finalName}</wtpContextName>
</configuration>
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>aliyun-repos</id>
<url>https://maven.aliyun.com/repository/public</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</repository>
<repository>
<id>jeesite-repos</id>
<url>https://maven.jeesite.net/repository/maven-public</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>aliyun-repos</id>
<url>https://maven.aliyun.com/repository/public</url>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
<pluginRepository>
<id>jeesite-repos</id>
<url>https://maven.jeesite.net/repository/maven-public</url>
</pluginRepository>
</pluginRepositories>
<!-- War 插件,自定义 war 包名称 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<configuration>
<warName>${finalName}</warName>
</configuration>
</plugin>
<!-- Eclipse 插件 -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-eclipse-plugin</artifactId>
<configuration>
<wtpContextName>${finalName}</wtpContextName>
</configuration>
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>aliyun-repos</id>
<url>https://maven.aliyun.com/repository/public</url>
<releases><enabled>true</enabled></releases>
<snapshots><enabled>false</enabled></snapshots>
</repository>
<repository>
<id>jeesite-repos</id>
<url>https://maven.jeesite.net/repository/maven-public</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>aliyun-repos</id>
<url>https://maven.aliyun.com/repository/public</url>
<releases><enabled>true</enabled></releases>
<snapshots><enabled>false</enabled></snapshots>
</pluginRepository>
<pluginRepository>
<id>jeesite-repos</id>
<url>https://maven.jeesite.net/repository/maven-public</url>
</pluginRepository>
</pluginRepositories>
</project> </project>

View File

@@ -0,0 +1,109 @@
package com.jeesite.modules.utils;
import javax.crypto.Cipher;
import javax.crypto.spec.IvParameterSpec;
import javax.crypto.spec.SecretKeySpec;
import java.nio.charset.StandardCharsets;
import java.util.Base64;
import java.util.Arrays;
import java.util.concurrent.ThreadLocalRandom;
/**
* AES加密解密工具类CBC/PKCS5Padding
* 优化说明修复密钥BUG+解决换行问题+性能优化+安全加固+零依赖
*/
public class AesUtil {
private static final LoggerUtils logger = LoggerUtils.getInstance();
private static final String AES_KEY_HEX = "AD42F6697B035B7580E4FEF93BE20BAD"; // 你的32位16进制密钥
private static final String CHARSET = StandardCharsets.UTF_8.name();
private static final int IV_LENGTH = 16; // AES CBC IV固定16字节
private static final String TRANSFORMATION = "AES/CBC/PKCS5Padding";
private static final String ALGORITHM = "AES";
private static final ThreadLocal<Cipher> ENCRYPT_CIPHER = ThreadLocal.withInitial(() -> {
try {
return Cipher.getInstance(TRANSFORMATION);
} catch (Exception e) {
throw new RuntimeException(e);
}
});
private static final ThreadLocal<Cipher> DECRYPT_CIPHER = ThreadLocal.withInitial(() -> {
try {
return Cipher.getInstance(TRANSFORMATION);
} catch (Exception e) {
throw new RuntimeException(e);
}
});
/**
* 加密
*/
public static String encrypt(String content) {
return encrypt(content, hex2Bytes(AES_KEY_HEX));
}
/**
* 解密
*/
public static String decrypt(String content) {
return decrypt(content, hex2Bytes(AES_KEY_HEX));
}
public static String encrypt(String content, byte[] key) {
if (content == null || content.isEmpty()) {
return "";
}
try {
SecretKeySpec secretKey = new SecretKeySpec(key, ALGORITHM);
IvParameterSpec iv = new IvParameterSpec(Arrays.copyOf(key, IV_LENGTH));
Cipher cipher = ENCRYPT_CIPHER.get();
cipher.init(Cipher.ENCRYPT_MODE, secretKey, iv);
byte[] encryptBytes = cipher.doFinal(content.getBytes(CHARSET));
return Base64.getEncoder().encodeToString(encryptBytes);
} catch (Exception e) {
throw new RuntimeException(e);
}
}
public static String decrypt(String content, byte[] key) {
if (content == null || content.isEmpty()) {
return "";
}
try {
SecretKeySpec secretKey = new SecretKeySpec(key, ALGORITHM);
IvParameterSpec iv = new IvParameterSpec(Arrays.copyOf(key, IV_LENGTH));
Cipher cipher = DECRYPT_CIPHER.get();
cipher.init(Cipher.DECRYPT_MODE, secretKey, iv);
byte[] decryptBytes = cipher.doFinal(Base64.getDecoder().decode(content));
String result = new String(decryptBytes, CHARSET);
return result.trim();
} catch (Exception e) {
throw new RuntimeException(e);
}
}
/**
* 32位16进制字符串转16字节数组解决你的密钥长度BUG的核心方法
*/
private static byte[] hex2Bytes(String hexStr) {
if (hexStr == null || hexStr.length() % 2 != 0) {
throw new IllegalArgumentException("密钥必须是偶数长度的16进制字符串");
}
byte[] bytes = new byte[hexStr.length() / 2];
for (int i = 0; i < bytes.length; i++) {
bytes[i] = (byte) Integer.parseInt(hexStr.substring(i * 2, i * 2 + 2), 16);
}
return bytes;
}
/**
* 生成随机16字节IV向量方案2安全随机IV新业务推荐使用
*/
private static byte[] generateRandomIV() {
byte[] iv = new byte[IV_LENGTH];
ThreadLocalRandom.current().nextBytes(iv);
return iv;
}
}

View File

@@ -0,0 +1,53 @@
package com.jeesite.modules.utils;
import java.time.LocalDate;
import java.time.format.DateTimeFormatter;
public class DateUtils {
private static final DateTimeFormatter MONTH_FORMATTER = DateTimeFormatter.ofPattern("MM");
private static final DateTimeFormatter YEAR_FORMATTER = DateTimeFormatter.ofPattern("yyyy");
private static final DateTimeFormatter DATE_FORMATTER = DateTimeFormatter.ofPattern("yyyyMMdd");
private static final DateTimeFormatter YEAR_MONTH_CN_FORMATTER = DateTimeFormatter.ofPattern("yyyy年MM月");
private static final DateTimeFormatter SHORT_YEAR_MONTH_CN_FORMATTER = DateTimeFormatter.ofPattern("yy年MM月");
public static String dsValue() {
LocalDate currentDate = LocalDate.now();
return currentDate.format(DATE_FORMATTER);
}
public static String dsValueDaysAgo(long days) {
LocalDate targetDate = LocalDate.now().minusDays(days);
return targetDate.format(DATE_FORMATTER);
}
public static String getCurrentYear() {
LocalDate currentDate = LocalDate.now();
return currentDate.format(YEAR_FORMATTER);
}
public static String getCurrentMonth() {
LocalDate currentDate = LocalDate.now();
return currentDate.format(MONTH_FORMATTER);
}
public static String getCurrentYearMonthCN() {
LocalDate currentDate = LocalDate.now();
return currentDate.format(YEAR_MONTH_CN_FORMATTER);
}
public static String getCurrentShortYearMonthCN() {
LocalDate currentDate = LocalDate.now();
return currentDate.format(SHORT_YEAR_MONTH_CN_FORMATTER);
}
public static String getYear(LocalDate date) {
return date.format(YEAR_FORMATTER);
}
public static String getMonth(LocalDate date) {
return date.format(MONTH_FORMATTER);
}
}

View File

@@ -0,0 +1,48 @@
package com.jeesite.modules.utils;
import java.util.Random;
public class KeyUtil {
public static String ObjKey(int length, int type) {
Random random = new Random();
StringBuffer key = new StringBuffer();
if (type == 1) {
String str = "0123456789";
for (int i = 0; i < length; ++i) {
//从62个的数字或字母中选择
int number = random.nextInt(10);
//将产生的数字通过length次承载到key中
key.append(str.charAt(number));
}
return key.toString();
} else if (type == 2) {
String str = "ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
for (int i = 0; i < length; ++i) {
//从62个的数字或字母中选择
int number = random.nextInt(36);
//将产生的数字通过length次承载到key中
key.append(str.charAt(number));
}
return key.toString();
} else if (type == 3) {
String str = "abcdefghijklmnopqrstuvwxyz0123456789";
for (int i = 0; i < length; ++i) {
//从62个的数字或字母中选择
int number = random.nextInt(36);
//将产生的数字通过length次承载到key中
key.append(str.charAt(number));
}
return key.toString();
} else {
String str = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789";
for (int i = 0; i < length; ++i) {
//从62个的数字或字母中选择
int number = random.nextInt(62);
//将产生的数字通过length次承载到key中
key.append(str.charAt(number));
}
return key.toString();
}
}
}

View File

@@ -0,0 +1,187 @@
package com.jeesite.modules.utils;
import java.io.*;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Paths;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.concurrent.locks.ReentrantLock;
public class LoggerUtils {
// 日志级别
public enum Level {
DEBUG, INFO, WARN, ERROR
}
// 单例实例
private static volatile LoggerUtils instance;
private String baseLogPath;
private final SimpleDateFormat logDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss.SSS");
// 线程安全锁
private final ReentrantLock lock = new ReentrantLock();
// 禁止外部实例化
private LoggerUtils(String baseLogPath) {
this.baseLogPath = baseLogPath;
initLogDir(); // 初始化日志目录
}
public static LoggerUtils getInstance() {
return getInstance("/ogsapp/logs");
}
/**
* 获取单例实例(自定义日志路径)
*
* @param baseLogPath 日志根目录(支持相对路径或绝对路径)
*/
public static LoggerUtils getInstance(String baseLogPath) {
if (instance == null) {
synchronized (LoggerUtils.class) {
if (instance == null) {
instance = new LoggerUtils(baseLogPath);
}
}
}
return instance;
}
/**
* 初始化日志目录(若不存在则创建多级目录)
*/
private void initLogDir() {
try {
Files.createDirectories(Paths.get(baseLogPath));
} catch (IOException e) {
throw new RuntimeException("初始化日志目录失败:" + baseLogPath, e);
}
}
private String getCurrentLogFilePath(Level level) {
String fileName = level + "_APP" + ".log";
return baseLogPath + File.separator + fileName;
}
// ------------------------------ 日志方法(支持多类型可变参数) ------------------------------
/**
* 记录DEBUG级别日志支持1到多个任意类型参数
*/
public void debug(Object... messages) {
log(Level.DEBUG, joinMessages(messages), null);
}
/**
* 记录INFO级别日志支持1到多个任意类型参数
*/
public void info(Object... messages) {
log(Level.INFO, joinMessages(messages), null);
}
/**
* 记录WARN级别日志支持1到多个任意类型参数
*/
public void warn(Object... messages) {
log(Level.WARN, joinMessages(messages), null);
}
/**
* 记录WARN级别日志支持1到多个任意类型参数+异常)
*/
public void warn(Object[] messages, Throwable throwable) {
log(Level.WARN, joinMessages(messages), throwable);
}
/**
* 记录ERROR级别日志支持1到多个任意类型参数
*/
public void error(Object... messages) {
log(Level.ERROR, joinMessages(messages), null);
}
/**
* 记录ERROR级别日志支持1到多个任意类型参数+异常)
*/
public void error(Object[] messages, Throwable throwable) {
log(Level.ERROR, joinMessages(messages), throwable);
}
// ------------------------------ 核心方法 ------------------------------
/**
* 核心日志写入逻辑
*/
private void log(Level level, String message, Throwable throwable) {
// 构建日志内容
StringBuilder logContent = new StringBuilder();
logContent.append("[").append(logDateFormat.format(new Date())).append("] "); // 时间戳
logContent.append("[").append(level.name()).append("] "); // 日志级别
logContent.append("[Thread-").append(Thread.currentThread().getId()).append("] "); // 线程ID
logContent.append(message); // 拼接后的消息
// 追加异常堆栈信息(如果有)
if (throwable != null) {
logContent.append("\n").append(getStackTrace(throwable));
}
logContent.append("\n"); // 每条日志换行
// 加锁写入文件(保证线程安全)
lock.lock();
try (BufferedWriter writer = new BufferedWriter(
new OutputStreamWriter(
new FileOutputStream(getCurrentLogFilePath(level), true), // 追加模式
StandardCharsets.UTF_8 // 避免中文乱码
)
)) {
System.out.print(logContent);
writer.write(logContent.toString());
writer.flush();
} catch (IOException e) {
System.err.println("日志写入失败:" + e.getMessage());
} finally {
lock.unlock();
}
}
/**
* 拼接多类型可变参数为单个字符串自动转换任意类型为字符串处理null
*
* @param messages 1到多个任意类型参数不可为空数组
* @return 拼接后的字符串
*/
private String joinMessages(Object... messages) {
if (messages == null || messages.length == 0) {
throw new IllegalArgumentException("日志消息至少需要1个参数");
}
StringBuilder sb = new StringBuilder();
for (Object msg : messages) {
sb.append(msg);
}
return sb.toString();
}
/**
* 异常堆栈信息转为字符串
*/
private String getStackTrace(Throwable throwable) {
StringWriter sw = new StringWriter();
PrintWriter pw = new PrintWriter(sw);
throwable.printStackTrace(pw);
return sw.toString();
}
/**
* 动态修改日志路径
*/
public void setBaseLogPath(String baseLogPath) {
this.baseLogPath = baseLogPath;
initLogDir();
}
}

View File

@@ -58,70 +58,11 @@ jdbc:
# Mysql 数据库配置 # Mysql 数据库配置
type: mysql type: mysql
driver: com.mysql.cj.jdbc.Driver driver: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://127.0.0.1:13306/my_app?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true url: jdbc:mysql://192.168.31.182:13306/system?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true
username: dream username: dream
password: info_dream password: info_dream
testSql: SELECT 1 testSql: SELECT 1
# # Oracle 数据库配置
# type: oracle
# driver: oracle.jdbc.OracleDriver
# url: jdbc:oracle:thin:@127.0.0.1:1521/orcl
# username: jeesite
# password: jeesite
# testSql: SELECT 1 FROM DUAL
# # Sql Server 数据库配置2008 版本,请打开 /modules/core/pom.xml 文件,替换为 SqlServer 2008 驱动并编译打包 core 模块)
# type: mssql
# driver: net.sourceforge.jtds.jdbc.Driver
# url: jdbc:jtds:sqlserver://127.0.0.1:1433/jeesite
# username: jeesite
# password: jeesite
# testSql: SELECT 1
# # Sql Server 数据库配置2012 及以上版本,请打开 /modules/core/pom.xml 文件,替换为 SqlServer 2021 驱动并编译打包 core 模块)
# type: mssql2012
# driver: com.microsoft.sqlserver.jdbc.SQLServerDriver
# url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=jeesite;encrypt=true;trustServerCertificate=true
# username: jeesite
# password: jeesite
# testSql: SELECT 1
# # PostgreSql 数据库配置
# type: postgresql
# driver: org.postgresql.Driver
# url: jdbc:postgresql://127.0.0.1:5432/jeesite
# username: jeesite
# password: jeesite
# testSql: SELECT 1
# # 达梦数据库配置,请勿使用 sysdba 用户
# type: dameng
# driver: dm.jdbc.driver.DmDriver
# url: jdbc:dm://127.0.0.1:5236/jeesite5?schema=jeesite5
# username: jeesite
# password: jeesite123
# testSql: SELECT 1 FROM DUAL
# # 人大金仓数据库配置
# type: kingbase
# driver: com.kingbase8.Driver
# url: jdbc:kingbase8://127.0.0.1:54321/jeesite?currentSchema=jeesite&UseServerPrepare=false
# username: jeesite
# password: jeesite
# testSql: SELECT 1 FROM DUAL
# # H2 数据库配置(请打开 /modules/core/pom.xml 文件,打开 H2 DB 驱动并编译打包 core 模块)
# type: h2
# driver: org.h2.Driver
# url: jdbc:h2:~/jeesite-db/jeesite
# username: jeesite
# password: jeesite
# testSql: SELECT 1
# 更多数据库的支持列表:
# https://jeesite.com/docs/technology/#%E4%B8%83%E3%80%81%E5%B7%B2%E6%94%AF%E6%8C%81%E6%95%B0%E6%8D%AE%E5%BA%93
# 连接信息加密 # 连接信息加密
encrypt: encrypt:
@@ -140,127 +81,6 @@ jdbc:
# 最大激活连接数 # 最大激活连接数
maxActive: 20 maxActive: 20
# # 连接超时参数,单位毫秒 v5.5.2+
# connectTimeout: ~
# socketTimeout: ~
#
# # 查询超时时间,事务超时时间 v5.7.1+
# queryTimeout: ~
# transactionQueryTimeout: ~
#
# # 获取连接等待超时时间单位毫秒1分钟4.0.6+
# maxWait: 60000
#
# # 连接失败后中断,默认为 false 时,会一直尝试连接,为 true 时自动中断尝试v5.9.0+
# breakAfterAcquireFailure: false
#
# # 从池中取出和归还连接前进行检验如果检验失败则从池中去除连接并尝试取出另一个4.0.6+
# testOnBorrow: false
# testOnReturn: false
#
# # 间隔多久才进行一次检测检测需要关闭的空闲连接单位毫秒1分钟4.0.6+
# timeBetweenEvictionRunsMillis: 60000
#
# # 一个连接在池中最小空闲的时间单位毫秒20分钟4.0.6+
# minEvictableIdleTimeMillis: 1200000
# # 一个连接在池中最大空闲的时间单位毫秒30分钟4.1.2+
# maxEvictableIdleTimeMillis: 1800000
#
# # 连接池中的minIdle数量以内的连接空闲时间超过minEvictableIdleTimeMillis则会执行keepAlive操作4.1.8+
# keepAlive: false
#
# # 是否自动回收泄露的连接和超时时间单位秒35分钟4.0.6+
# removeAbandoned: false
# removeAbandonedTimeout: 2100
#
# # 是否缓存 PreparedStatement 对象的最大数量4.1.5+
# maxPoolPreparedStatementPerConnectionSize: ~
#
# # 设置连接属性,可获取到表的 remark (备注)
# remarksReporting: false
# # 读写分离配置专业版v4.3.0
# readwriteSplitting:
# # 读库的数据源名称列表(默认数据源)
# readDataSourceNames: ds_read_01, ds_read_02
# # 负载均衡算法ROUND_ROBIN轮询、RANDOM随机、自定义类名
# loadBalancerAlgorithm: RANDOM
#
# # 多数据源名称列表,多个用逗号隔开,使用方法:@MyBatisDao(dataSourceName="ds2")
# # v5.11.1+ 支持 dataSourceNames 免配置,自动读取 jdbc.数据源名.type 的属性
# dataSourceNames: ds_read_01, ds_read_02
#
# # 默认数据源的从库01
# ds_read_01:
# type: mysql
# driver: com.mysql.cj.jdbc.Driver
# url: jdbc:mysql://127.0.0.1:3306/jeesite_test?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai
# username: root
# password: 123456
# testSql: SELECT 1
# pool:
# init: 1
# minIdle: 3
# maxActive: 20
#
# # 默认数据源的从库02
# ds_read_02:
# type: mysql
# driver: com.mysql.cj.jdbc.Driver
# url: jdbc:mysql://127.0.0.1:3306/jeesite_test2?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai
# username: root
# password: 123456
# testSql: SELECT 1
# pool:
# init: 1
# minIdle: 3
# maxActive: 20
# # 多数据源名称列表,多个用逗号隔开,使用方法:@MyBatisDao(dataSourceName="ds2")
# # v5.11.1+ 支持 dataSourceNames 免配置,自动读取 jdbc.数据源名.type 的属性
# dataSourceNames: ds2
#
# # 多数据源配置ds2
# ds2:
# type: mysql
# driver: com.mysql.cj.jdbc.Driver
# url: jdbc:mysql://127.0.0.1:3306/jeesite2?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai
# username: root
# password: 123456
# testSql: SELECT 1
# # 其它数据源支持密码加密
# encrypt:
# username: false
# password: true
# # 其它数据源支持连接池设置
# pool:
# init: 1
# minIdle: 3
# maxActive: 20
# # 其它数据源支持读写分离
# readwriteSplitting:
# readDataSourceNames: ~
# loadBalancerAlgorithm: RANDOM
# # 数据源映射Dao类名 = 数据源名称),优先于 @MyBatisDao(dataSourceName="ds2") 设置 v4.3.0
# # Dao类名不仅支持某个具体 Dao类名还支持 Dao 里的某个方法指定数据源名称,还支持包路径指定数据源等
# # 数据源名指定 {dynamic} 时支持动态,相当于 @MyBatisDao(dataSourceName=DataSourceHolder.DYNAMIC)
# # 数据源支持指定变量 {corpCode}、 {userCode}、{userCache中的Key名}、{yml或sys_config中的Key名}
# # 从上到下,先匹配先受用规则,默认数据源名为 default 扩展数据源为 dataSourceNames 列表里自定义的名字
# mybatisDaoAndDataSourceMappings: |
# TestDataChildDao = ds2
# EmpUserDao.findList = ds2
# com.jeesite.modules.sys. = default
# com.jeesite.modules.filemanager. = ds2
# # 表名和字段名(前缀|后缀是否强制大写v4.1.8+
# tableAndColumn:
# prefixSuffix: "`|`"
# forceUpperCase: true
#
# # 表名前缀
# tablePrefix: js_
#======================================# #======================================#
#========== Spring settings ===========# #========== Spring settings ===========#
#======================================# #======================================#

View File

@@ -29,10 +29,12 @@
"@ant-design/icons-vue": "7.0.1", "@ant-design/icons-vue": "7.0.1",
"@element-plus/icons-vue": "^2.3.2", "@element-plus/icons-vue": "^2.3.2",
"@jeesite/assets": "workspace:*", "@jeesite/assets": "workspace:*",
"@jeesite/biz": "workspace:*",
"@jeesite/cms": "workspace:*", "@jeesite/cms": "workspace:*",
"@jeesite/core": "workspace:*", "@jeesite/core": "workspace:*",
"@jeesite/dbm": "workspace:*", "@jeesite/dbm": "workspace:*",
"@jeesite/dfm": "workspace:*", "@jeesite/dfm": "workspace:*",
"@jeesite/erp": "workspace:*",
"@jeesite/test": "workspace:*", "@jeesite/test": "workspace:*",
"@jeesite/types": "workspace:*", "@jeesite/types": "workspace:*",
"@jeesite/vite": "workspace:*", "@jeesite/vite": "workspace:*",

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.2 KiB

After

Width:  |  Height:  |  Size: 14 KiB

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 9.0 KiB

After

Width:  |  Height:  |  Size: 31 KiB

View File

@@ -0,0 +1,22 @@
- 官方网站:<https://jeesite.com>
- 使用文档:<https://jeesite.com/docs>
- 后端代码:<https://gitee.com/thinkgem/jeesite5>
- 前端代码:<https://gitee.com/thinkgem/jeesite-vue>
------
<div align="center">
如果你喜欢 JeeSite请给她一个 ⭐️ Star您的支持将是我们前行的动力。
</div>
------
- 问题反馈:<https://gitee.com/thinkgem/jeesite-vue/issues> [【新手必读】](https://gitee.com/thinkgem/jeesite5/issues/I18ARR)
- 需求收集:<https://gitee.com/thinkgem/jeesite-vue/issues/new>
- QQ 群:`127515876``209330483``223507718``709534275``730390092``1373527``183903863(外包)`
- 微信群:添加客服微信 <http://s.jeesite.com> 邀请您进群
- 关注微信公众号,了解最新动态:
<p style="padding-left:40px">
<img alt="JeeSite微信公众号" src="https://jeesite.com/assets/images/mp.png" width="220" height="220">
</p>

View File

@@ -0,0 +1,30 @@
{
"name": "@jeesite/biz",
"version": "5.15.1",
"private": true,
"type": "module",
"scripts": {
"type:check": "vue-tsc --noEmit --skipLibCheck",
"uninstall": "rimraf node_modules",
"update": "ncu -u"
},
"dependencies": {
"qs": "6.14.0"
},
"devDependencies": {
"@types/qs": "6.9.18"
},
"homepage": "https://jeesite.com",
"repository": {
"type": "git",
"url": "https://gitee.com/thinkgem/jeesite-vue.git"
},
"bugs": {
"url": "https://gitee.com/thinkgem/jeesite-vue/issues"
},
"author": {
"name": "ThinkGem",
"email": "thinkgem@163.com",
"url": "https://gitee.com/thinkgem"
}
}

View File

@@ -0,0 +1,20 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@jeesite/biz/*": ["./*"]
}
},
"include": [
"./**/*.ts",
"./**/*.tsx",
"./**/*.vue"
],
"exclude": [
"node_modules",
"vite.config.ts",
"_lib",
"dist"
]
}

View File

@@ -4,7 +4,7 @@
--> -->
<template> <template>
<div class="anticon" :class="getAppLogoClass" @click="goHome"> <div class="anticon" :class="getAppLogoClass" @click="goHome">
<img src="@jeesite/assets/images/logo.png" v-show="!!!showTitle" /> <img src="@jeesite/assets/images/logo.png" v-show="showTitle" />
<div class="ml-2 truncate md:opacity-100" :class="getTitleClass" v-show="showTitle"> <div class="ml-2 truncate md:opacity-100" :class="getTitleClass" v-show="showTitle">
{{ getTitle }} {{ getTitle }}
</div> </div>

View File

@@ -1,19 +1,6 @@
<template> <template>
<RouterView> <RouterView>
<template #default="{ Component, route }"> <template #default="{ Component, route }">
<!--<transition
:name="
getTransitionName({
route,
openCache,
enableTransition: getEnableTransition,
cacheTabs: getCaches,
def: getBasicTransition,
})
"
mode="out-in"
appear
>-->
<keep-alive v-if="openCache" :include="getCaches"> <keep-alive v-if="openCache" :include="getCaches">
<component :is="Component" :key="route.fullPath" /> <component :is="Component" :key="route.fullPath" />
</keep-alive> </keep-alive>

View File

@@ -38,20 +38,15 @@
<Button type="link" size="small" @click="setLoginState(LoginStateEnum.RESET_PASSWORD)"> <Button type="link" size="small" @click="setLoginState(LoginStateEnum.RESET_PASSWORD)">
{{ t('sys.login.forgetPassword') }} {{ t('sys.login.forgetPassword') }}
</Button> </Button>
<!--<Button type="link" size="small" @click="setLoginState(LoginStateEnum.REGISTER)">
{{ t('sys.login.registerButton') }}
</Button>-->
</FormItem> </FormItem>
</ACol> </ACol>
</ARow> </ARow>
<FormItem class="enter-x"> <FormItem class="enter-x">
<Button type="primary" size="large" block @click="handleLogin" :loading="loading"> <Button type="primary" size="defult" block @click="handleLogin" :loading="loading">
{{ t('sys.login.loginButton') }} {{ t('sys.login.loginButton') }}
</Button> </Button>
</FormItem> </FormItem>
</Form> </Form>
</div> </div>
</template> </template>
@@ -94,7 +89,7 @@
const emit = defineEmits(['demoMode']); const emit = defineEmits(['demoMode']);
const formData = reactive({ const formData = reactive({
account: 'system', account: '',
password: '', password: '',
validCode: '', validCode: '',
}); });

View File

@@ -253,12 +253,7 @@ function createAxios(opt?: Partial<CreateAxiosOptions>) {
authenticationHeader: 'x-token', authenticationHeader: 'x-token',
authenticationScheme: '', authenticationScheme: '',
// 请求超时时间默认3分钟 // 请求超时时间默认3分钟
timeout: 3 * 60 * 1000, timeout: 15 * 60 * 1000,
// 基础接口地址
// baseURL: globSetting.apiUrl,
// 默认请求头设置
// headers: { 'Content-Type': ContentTypeEnum.JSON },
// 如果是form-data格式
headers: { headers: {
'content-type': ContentTypeEnum.FORM_URLENCODED, 'content-type': ContentTypeEnum.FORM_URLENCODED,
'x-requested-with': 'XMLHttpRequest', 'x-requested-with': 'XMLHttpRequest',
@@ -297,11 +292,3 @@ function createAxios(opt?: Partial<CreateAxiosOptions>) {
); );
} }
export const defHttp = createAxios(); export const defHttp = createAxios();
// other api url
// export const otherHttp = createAxios({
// requestOptions: {
// apiUrl: 'xxx',
// urlPrefix: 'xxx',
// },
// });

View File

@@ -0,0 +1,22 @@
- 官方网站:<https://jeesite.com>
- 使用文档:<https://jeesite.com/docs>
- 后端代码:<https://gitee.com/thinkgem/jeesite5>
- 前端代码:<https://gitee.com/thinkgem/jeesite-vue>
------
<div align="center">
如果你喜欢 JeeSite请给她一个 ⭐️ Star您的支持将是我们前行的动力。
</div>
------
- 问题反馈:<https://gitee.com/thinkgem/jeesite-vue/issues> [【新手必读】](https://gitee.com/thinkgem/jeesite5/issues/I18ARR)
- 需求收集:<https://gitee.com/thinkgem/jeesite-vue/issues/new>
- QQ 群:`127515876``209330483``223507718``709534275``730390092``1373527``183903863(外包)`
- 微信群:添加客服微信 <http://s.jeesite.com> 邀请您进群
- 关注微信公众号,了解最新动态:
<p style="padding-left:40px">
<img alt="JeeSite微信公众号" src="https://jeesite.com/assets/images/mp.png" width="220" height="220">
</p>

View File

@@ -0,0 +1,30 @@
{
"name": "@jeesite/erp",
"version": "5.15.1",
"private": true,
"type": "module",
"scripts": {
"type:check": "vue-tsc --noEmit --skipLibCheck",
"uninstall": "rimraf node_modules",
"update": "ncu -u"
},
"dependencies": {
"qs": "6.14.0"
},
"devDependencies": {
"@types/qs": "6.9.18"
},
"homepage": "https://jeesite.com",
"repository": {
"type": "git",
"url": "https://gitee.com/thinkgem/jeesite-vue.git"
},
"bugs": {
"url": "https://gitee.com/thinkgem/jeesite-vue/issues"
},
"author": {
"name": "ThinkGem",
"email": "thinkgem@163.com",
"url": "https://gitee.com/thinkgem"
}
}

View File

@@ -0,0 +1,20 @@
{
"extends": "../../tsconfig.json",
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@jeesite/erp/*": ["./*"]
}
},
"include": [
"./**/*.ts",
"./**/*.tsx",
"./**/*.vue"
],
"exclude": [
"node_modules",
"vite.config.ts",
"_lib",
"dist"
]
}

31
web-vue/pnpm-lock.yaml generated
View File

@@ -23,6 +23,9 @@ importers:
'@jeesite/assets': '@jeesite/assets':
specifier: workspace:* specifier: workspace:*
version: link:packages/assets version: link:packages/assets
'@jeesite/biz':
specifier: workspace:*
version: link:packages/biz
'@jeesite/cms': '@jeesite/cms':
specifier: workspace:* specifier: workspace:*
version: link:packages/cms version: link:packages/cms
@@ -35,6 +38,9 @@ importers:
'@jeesite/dfm': '@jeesite/dfm':
specifier: workspace:* specifier: workspace:*
version: link:packages/dfm version: link:packages/dfm
'@jeesite/erp':
specifier: workspace:*
version: link:packages/erp
'@jeesite/test': '@jeesite/test':
specifier: workspace:* specifier: workspace:*
version: link:packages/test version: link:packages/test
@@ -213,6 +219,16 @@ importers:
packages/assets: {} packages/assets: {}
packages/biz:
dependencies:
qs:
specifier: 6.14.0
version: 6.14.0
devDependencies:
'@types/qs':
specifier: 6.9.18
version: 6.9.18
packages/cms: packages/cms:
dependencies: dependencies:
'@jeesite/cms-lib': '@jeesite/cms-lib':
@@ -385,6 +401,16 @@ importers:
specifier: 4.0.15 specifier: 4.0.15
version: 4.0.15(@types/node@24.10.2)(jiti@2.6.1)(less@4.4.2)(terser@5.44.1)(yaml@2.8.2) version: 4.0.15(@types/node@24.10.2)(jiti@2.6.1)(less@4.4.2)(terser@5.44.1)(yaml@2.8.2)
packages/erp:
dependencies:
qs:
specifier: 6.14.0
version: 6.14.0
devDependencies:
'@types/qs':
specifier: 6.9.18
version: 6.9.18
packages/test: {} packages/test: {}
packages/tests: packages/tests:
@@ -2297,6 +2323,9 @@ packages:
'@types/qs@6.14.0': '@types/qs@6.14.0':
resolution: {integrity: sha512-eOunJqu0K1923aExK6y8p6fsihYEn/BYuQ4g0CxAAgFc4b/ZLN4CrsRZ55srTdqoiLzU2B2evC+apEIxprEzkQ==} resolution: {integrity: sha512-eOunJqu0K1923aExK6y8p6fsihYEn/BYuQ4g0CxAAgFc4b/ZLN4CrsRZ55srTdqoiLzU2B2evC+apEIxprEzkQ==}
'@types/qs@6.9.18':
resolution: {integrity: sha512-kK7dgTYDyGqS+e2Q4aK9X3D7q234CIZ1Bv0q/7Z5IwRDoADNU81xXJK/YVyLbLTZCoIwUoDoffFeF+p/eIklAA==}
'@types/range-parser@1.2.7': '@types/range-parser@1.2.7':
resolution: {integrity: sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==} resolution: {integrity: sha512-hKormJbkJqzQGhziax5PItDUTMAM9uE2XXQmM37dyd4hVM+5aVl7oVxMVUiVQn2oCQFN/LKCZdvSM0pFRqbSmQ==}
@@ -8088,6 +8117,8 @@ snapshots:
'@types/qs@6.14.0': {} '@types/qs@6.14.0': {}
'@types/qs@6.9.18': {}
'@types/range-parser@1.2.7': {} '@types/range-parser@1.2.7': {}
'@types/resolve@1.20.2': {} '@types/resolve@1.20.2': {}

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.7 KiB

After

Width:  |  Height:  |  Size: 4.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.2 KiB

After

Width:  |  Height:  |  Size: 14 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 7.5 KiB

After

Width:  |  Height:  |  Size: 53 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

After

Width:  |  Height:  |  Size: 53 KiB

View File

@@ -4,8 +4,6 @@
*/ */
package com.jeesite.modules; package com.jeesite.modules;
import com.jeesite.common.config.Global;
import com.jeesite.common.io.FileUtils;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication; import org.springframework.boot.SpringApplication;
@@ -15,28 +13,22 @@ import org.springframework.boot.web.servlet.support.SpringBootServletInitializer
/** /**
* Application * Application
*
* @author ThinkGem * @author ThinkGem
*/ */
@SpringBootApplication @SpringBootApplication
public class Application extends SpringBootServletInitializer { public class Application extends SpringBootServletInitializer {
private static final Logger logger = LoggerFactory.getLogger(Application.class); private static final Logger logger = LoggerFactory.getLogger(Application.class);
public static void main(String[] args) { public static void main(String[] args) {
SpringApplication.run(Application.class, args); SpringApplication.run(Application.class, args);
logger.info( }
"\n\n==============================================================\n"
+ "\n 启动完成访问地址http://127.0.0.1:{}\n" @Override
+ "\n 默认管理账号: system 密码: admin\n" protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
+ "\n==============================================================\n", this.setRegisterErrorPageFilter(false);
Global.getProperty("server.port") + FileUtils.path("/" return builder.sources(Application.class);
+ Global.getProperty("server.servlet.context-path"))); }
}
@Override
protected SpringApplicationBuilder configure(SpringApplicationBuilder builder) {
this.setRegisterErrorPageFilter(false); // 错误页面有容器来处理而不是SpringBoot
return builder.sources(Application.class);
}
} }

View File

@@ -58,70 +58,11 @@ jdbc:
# Mysql 数据库配置 # Mysql 数据库配置
type: mysql type: mysql
driver: com.mysql.cj.jdbc.Driver driver: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://127.0.0.1:13306/my_app?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true url: jdbc:mysql://192.168.31.182:13306/system?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai&nullCatalogMeansCurrent=true
username: dream username: dream
password: info_dream password: info_dream
testSql: SELECT 1 testSql: SELECT 1
# # Oracle 数据库配置
# type: oracle
# driver: oracle.jdbc.OracleDriver
# url: jdbc:oracle:thin:@127.0.0.1:1521/orcl
# username: jeesite
# password: jeesite
# testSql: SELECT 1 FROM DUAL
# # Sql Server 数据库配置2008 版本,请打开 /modules/core/pom.xml 文件,替换为 SqlServer 2008 驱动并编译打包 core 模块)
# type: mssql
# driver: net.sourceforge.jtds.jdbc.Driver
# url: jdbc:jtds:sqlserver://127.0.0.1:1433/jeesite
# username: jeesite
# password: jeesite
# testSql: SELECT 1
# # Sql Server 数据库配置2012 及以上版本,请打开 /modules/core/pom.xml 文件,替换为 SqlServer 2021 驱动并编译打包 core 模块)
# type: mssql2012
# driver: com.microsoft.sqlserver.jdbc.SQLServerDriver
# url: jdbc:sqlserver://127.0.0.1:1433;DatabaseName=jeesite;encrypt=true;trustServerCertificate=true
# username: jeesite
# password: jeesite
# testSql: SELECT 1
# # PostgreSql 数据库配置
# type: postgresql
# driver: org.postgresql.Driver
# url: jdbc:postgresql://127.0.0.1:5432/jeesite
# username: jeesite
# password: jeesite
# testSql: SELECT 1
# # 达梦数据库配置,请勿使用 sysdba 用户
# type: dameng
# driver: dm.jdbc.driver.DmDriver
# url: jdbc:dm://127.0.0.1:5236/jeesite5?schema=jeesite5
# username: jeesite
# password: jeesite123
# testSql: SELECT 1 FROM DUAL
# # 人大金仓数据库配置
# type: kingbase
# driver: com.kingbase8.Driver
# url: jdbc:kingbase8://127.0.0.1:54321/jeesite?currentSchema=jeesite&UseServerPrepare=false
# username: jeesite
# password: jeesite
# testSql: SELECT 1 FROM DUAL
# # H2 数据库配置(请打开 /modules/core/pom.xml 文件,打开 H2 DB 驱动并编译打包 core 模块)
# type: h2
# driver: org.h2.Driver
# url: jdbc:h2:~/jeesite-db/jeesite
# username: jeesite
# password: jeesite
# testSql: SELECT 1
# 更多数据库的支持列表:
# https://jeesite.com/docs/technology/#%E4%B8%83%E3%80%81%E5%B7%B2%E6%94%AF%E6%8C%81%E6%95%B0%E6%8D%AE%E5%BA%93
# 连接信息加密 # 连接信息加密
encrypt: encrypt:
@@ -140,127 +81,6 @@ jdbc:
# 最大激活连接数 # 最大激活连接数
maxActive: 20 maxActive: 20
# # 连接超时参数,单位毫秒 v5.5.2+
# connectTimeout: ~
# socketTimeout: ~
#
# # 查询超时时间,事务超时时间 v5.7.1+
# queryTimeout: ~
# transactionQueryTimeout: ~
#
# # 获取连接等待超时时间单位毫秒1分钟4.0.6+
# maxWait: 60000
#
# # 连接失败后中断,默认为 false 时,会一直尝试连接,为 true 时自动中断尝试v5.9.0+
# breakAfterAcquireFailure: false
#
# # 从池中取出和归还连接前进行检验如果检验失败则从池中去除连接并尝试取出另一个4.0.6+
# testOnBorrow: false
# testOnReturn: false
#
# # 间隔多久才进行一次检测检测需要关闭的空闲连接单位毫秒1分钟4.0.6+
# timeBetweenEvictionRunsMillis: 60000
#
# # 一个连接在池中最小空闲的时间单位毫秒20分钟4.0.6+
# minEvictableIdleTimeMillis: 1200000
# # 一个连接在池中最大空闲的时间单位毫秒30分钟4.1.2+
# maxEvictableIdleTimeMillis: 1800000
#
# # 连接池中的minIdle数量以内的连接空闲时间超过minEvictableIdleTimeMillis则会执行keepAlive操作4.1.8+
# keepAlive: false
#
# # 是否自动回收泄露的连接和超时时间单位秒35分钟4.0.6+
# removeAbandoned: false
# removeAbandonedTimeout: 2100
#
# # 是否缓存 PreparedStatement 对象的最大数量4.1.5+
# maxPoolPreparedStatementPerConnectionSize: ~
#
# # 设置连接属性,可获取到表的 remark (备注)
# remarksReporting: false
# # 读写分离配置专业版v4.3.0
# readwriteSplitting:
# # 读库的数据源名称列表(默认数据源)
# readDataSourceNames: ds_read_01, ds_read_02
# # 负载均衡算法ROUND_ROBIN轮询、RANDOM随机、自定义类名
# loadBalancerAlgorithm: RANDOM
#
# # 多数据源名称列表,多个用逗号隔开,使用方法:@MyBatisDao(dataSourceName="ds2")
# # v5.11.1+ 支持 dataSourceNames 免配置,自动读取 jdbc.数据源名.type 的属性
# dataSourceNames: ds_read_01, ds_read_02
#
# # 默认数据源的从库01
# ds_read_01:
# type: mysql
# driver: com.mysql.cj.jdbc.Driver
# url: jdbc:mysql://127.0.0.1:3306/jeesite_test?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai
# username: root
# password: 123456
# testSql: SELECT 1
# pool:
# init: 1
# minIdle: 3
# maxActive: 20
#
# # 默认数据源的从库02
# ds_read_02:
# type: mysql
# driver: com.mysql.cj.jdbc.Driver
# url: jdbc:mysql://127.0.0.1:3306/jeesite_test2?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai
# username: root
# password: 123456
# testSql: SELECT 1
# pool:
# init: 1
# minIdle: 3
# maxActive: 20
# # 多数据源名称列表,多个用逗号隔开,使用方法:@MyBatisDao(dataSourceName="ds2")
# # v5.11.1+ 支持 dataSourceNames 免配置,自动读取 jdbc.数据源名.type 的属性
# dataSourceNames: ds2
#
# # 多数据源配置ds2
# ds2:
# type: mysql
# driver: com.mysql.cj.jdbc.Driver
# url: jdbc:mysql://127.0.0.1:3306/jeesite_test?useSSL=false&allowPublicKeyRetrieval=true&useUnicode=true&characterEncoding=utf-8&zeroDateTimeBehavior=CONVERT_TO_NULL&serverTimezone=Asia/Shanghai
# username: root
# password: 123456
# testSql: SELECT 1
# # 其它数据源支持密码加密
# encrypt:
# username: false
# password: true
# # 其它数据源支持连接池设置
# pool:
# init: 1
# minIdle: 3
# maxActive: 20
# # 其它数据源支持读写分离
# readwriteSplitting:
# readDataSourceNames: ~
# loadBalancerAlgorithm: RANDOM
# # 数据源映射Dao类名 = 数据源名称),优先于 @MyBatisDao(dataSourceName="ds2") 设置 v4.3.0
# # Dao类名不仅支持某个具体 Dao类名还支持 Dao 里的某个方法指定数据源名称,还支持包路径指定数据源等
# # 数据源名指定 {dynamic} 时支持动态,相当于 @MyBatisDao(dataSourceName=DataSourceHolder.DYNAMIC)
# # 数据源支持指定变量 {corpCode}、 {userCode}、{userCache中的Key名}、{yml或sys_config中的Key名}
# # 从上到下,先匹配先受用规则,默认数据源名为 default 扩展数据源为 dataSourceNames 列表里自定义的名字
# mybatisDaoAndDataSourceMappings: |
# TestDataChildDao = ds2
# EmpUserDao.findList = ds2
# com.jeesite.modules.sys. = default
# com.jeesite.modules.filemanager. = ds2
# # 表名和字段名(前缀|后缀是否强制大写v4.1.8+
# tableAndColumn:
# prefixSuffix: "`|`"
# forceUpperCase: true
#
# # 表名前缀
# tablePrefix: js_
#======================================# #======================================#
#========== Spring settings ===========# #========== Spring settings ===========#
#======================================# #======================================#