diff --git a/db/mfish_nocode.sql b/db/mfish_nocode.sql
index 7110a80d..e0e96963 100644
--- a/db/mfish_nocode.sql
+++ b/db/mfish_nocode.sql
@@ -1015,23 +1015,24 @@ CREATE TABLE `sys_config` (
-- ----------------------------
DROP TABLE IF EXISTS `sys_db_connect`;
CREATE TABLE `sys_db_connect` (
- `id` varchar(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '库信息id',
- `tenant_id` varchar(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci DEFAULT NULL COMMENT '租户ID',
- `db_title` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据库标题',
- `db_name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据库名',
- `db_type` tinyint(1) NULL DEFAULT NULL COMMENT '数据库类型(0 mysql 1 oracle 2 pgsql)',
- `pool_type` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '连接池类型(Druid,Hikari)',
- `host` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '主机',
- `port` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '端口号',
- `username` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据库登录用户名',
- `password` varchar(300) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据库登录密码',
- `options` varchar(1000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据源配置项(JSON格式)',
- `remark` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注',
- `create_by` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建人',
- `create_time` datetime NULL DEFAULT NULL COMMENT '创建时间',
- `update_by` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '修改人',
- `update_time` datetime NULL DEFAULT NULL COMMENT '修改时间',
- PRIMARY KEY (`id`) USING BTREE
+ `id` varchar(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '库信息id',
+ `tenant_id` varchar(36) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '租户ID',
+ `db_title` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据库标题',
+ `db_name` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据库名',
+ `db_type` tinyint(1) NULL DEFAULT NULL COMMENT '数据库类型(0 mysql 1 oracle 2 pgsql)',
+ `pool_type` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '连接池类型(Druid,Hikari)',
+ `host` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '主机',
+ `port` varchar(10) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '端口号',
+ `username` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据库登录用户名',
+ `password` varchar(300) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据库登录密码',
+ `options` varchar(1000) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '数据源配置项(JSON格式)',
+ `is_public` tinyint(1) NULL DEFAULT 0 COMMENT '是否公开连接 0为私有的 1公开的',
+ `remark` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '备注',
+ `create_by` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '创建人',
+ `create_time` datetime NULL DEFAULT NULL COMMENT '创建时间',
+ `update_by` varchar(50) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NULL DEFAULT NULL COMMENT '修改人',
+ `update_time` datetime NULL DEFAULT NULL COMMENT '修改时间',
+ PRIMARY KEY (`id`) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci COMMENT = '数据库连接信息' ROW_FORMAT = DYNAMIC;
diff --git a/mf-common/mf-common-core/pom.xml b/mf-common/mf-common-core/pom.xml
index 860df4e5..360e37d7 100644
--- a/mf-common/mf-common-core/pom.xml
+++ b/mf-common/mf-common-core/pom.xml
@@ -81,5 +81,13 @@
cn.idev.excel
fastexcel
+
+ com.google.zxing
+ core
+
+
+ com.google.zxing
+ javase
+
\ No newline at end of file
diff --git a/mf-common/mf-common-core/src/main/java/cn/com/mfish/common/core/utils/AuthInfoUtils.java b/mf-common/mf-common-core/src/main/java/cn/com/mfish/common/core/utils/AuthInfoUtils.java
index 90dc616b..8ab248a1 100644
--- a/mf-common/mf-common-core/src/main/java/cn/com/mfish/common/core/utils/AuthInfoUtils.java
+++ b/mf-common/mf-common-core/src/main/java/cn/com/mfish/common/core/utils/AuthInfoUtils.java
@@ -2,8 +2,10 @@ package cn.com.mfish.common.core.utils;
import cn.com.mfish.common.core.constants.Constants;
import cn.com.mfish.common.core.constants.RPCConstants;
+import cn.com.mfish.common.core.exception.MyRuntimeException;
import cn.com.mfish.common.core.exception.OAuthValidateException;
import cn.com.mfish.common.core.utils.http.WebRequest;
+import jakarta.servlet.http.HttpServletRequest;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.lang3.StringUtils;
@@ -177,4 +179,18 @@ public class AuthInfoUtils {
}
return roleIds.stream().anyMatch(AuthInfoUtils::isSuperRole);
}
+
+ /**
+ * 是否内部请求
+ *
+ * @return 是否
+ */
+ public static boolean isInnerRequest() {
+ HttpServletRequest request = ServletUtils.getRequest();
+ if (request == null) {
+ throw new MyRuntimeException("错误:未获取到请求信息");
+ }
+ String source = request.getHeader(RPCConstants.REQ_ORIGIN);
+ return !StringUtils.isEmpty(source) && source.equals(RPCConstants.INNER);
+ }
}
diff --git a/mf-oauth/src/main/java/cn/com/mfish/oauth/common/QRCodeUtils.java b/mf-common/mf-common-core/src/main/java/cn/com/mfish/common/core/utils/QRCodeUtils.java
similarity index 97%
rename from mf-oauth/src/main/java/cn/com/mfish/oauth/common/QRCodeUtils.java
rename to mf-common/mf-common-core/src/main/java/cn/com/mfish/common/core/utils/QRCodeUtils.java
index 02b72116..f02d4cc1 100644
--- a/mf-oauth/src/main/java/cn/com/mfish/oauth/common/QRCodeUtils.java
+++ b/mf-common/mf-common-core/src/main/java/cn/com/mfish/common/core/utils/QRCodeUtils.java
@@ -1,6 +1,5 @@
-package cn.com.mfish.oauth.common;
+package cn.com.mfish.common.core.utils;
-import cn.com.mfish.common.core.utils.StringUtils;
import com.google.zxing.BarcodeFormat;
import com.google.zxing.EncodeHintType;
import com.google.zxing.MultiFormatWriter;
@@ -70,7 +69,7 @@ public class QRCodeUtils {
Hashtable hints = new Hashtable<>();
hints.put(EncodeHintType.ERROR_CORRECTION, ErrorCorrectionLevel.H);
hints.put(EncodeHintType.CHARACTER_SET, CHARSET);
- hints.put(EncodeHintType.MARGIN, 2);
+ hints.put(EncodeHintType.MARGIN, 0);
BitMatrix bitMatrix = new MultiFormatWriter().encode(content, BarcodeFormat.QR_CODE, QRCODE_SIZE, QRCODE_SIZE, hints);
int width = bitMatrix.getWidth();
int height = bitMatrix.getHeight();
diff --git a/mf-common/mf-common-oauth/src/main/java/cn/com/mfish/common/oauth/aspect/AuthorizationAspect.java b/mf-common/mf-common-oauth/src/main/java/cn/com/mfish/common/oauth/aspect/AuthorizationAspect.java
index a4157c94..bb2c8aad 100644
--- a/mf-common/mf-common-oauth/src/main/java/cn/com/mfish/common/oauth/aspect/AuthorizationAspect.java
+++ b/mf-common/mf-common-oauth/src/main/java/cn/com/mfish/common/oauth/aspect/AuthorizationAspect.java
@@ -1,13 +1,10 @@
package cn.com.mfish.common.oauth.aspect;
-import cn.com.mfish.common.core.constants.RPCConstants;
import cn.com.mfish.common.core.exception.MyRuntimeException;
-import cn.com.mfish.common.core.utils.ServletUtils;
-import cn.com.mfish.common.core.utils.StringUtils;
+import cn.com.mfish.common.core.utils.AuthInfoUtils;
import cn.com.mfish.common.oauth.annotation.RequiresPermissions;
import cn.com.mfish.common.oauth.annotation.RequiresRoles;
import cn.com.mfish.common.oauth.common.OauthUtils;
-import jakarta.servlet.http.HttpServletRequest;
import lombok.extern.slf4j.Slf4j;
import org.aspectj.lang.JoinPoint;
import org.aspectj.lang.annotation.Aspect;
@@ -29,13 +26,8 @@ public class AuthorizationAspect {
@Before("@annotation(cn.com.mfish.common.oauth.annotation.RequiresPermissions)" +
"||@annotation(cn.com.mfish.common.oauth.annotation.RequiresRoles)")
public void doBefore(JoinPoint joinPoint) {
- HttpServletRequest request = ServletUtils.getRequest();
- if (request == null) {
- throw new MyRuntimeException("错误:未获取到请求信息");
- }
- String source = request.getHeader(RPCConstants.REQ_ORIGIN);
//判断如果是内部Feign接口请求不需要验证按钮权限
- if (!StringUtils.isEmpty(source) && source.equals(RPCConstants.INNER)) {
+ if(AuthInfoUtils.isInnerRequest()){
return;
}
MethodSignature methodSignature = (MethodSignature) joinPoint.getSignature();
diff --git a/mf-common/mf-common-oauth/src/main/java/cn/com/mfish/common/oauth/aspect/DataScopeAspect.java b/mf-common/mf-common-oauth/src/main/java/cn/com/mfish/common/oauth/aspect/DataScopeAspect.java
index c34ec567..7cae082b 100644
--- a/mf-common/mf-common-oauth/src/main/java/cn/com/mfish/common/oauth/aspect/DataScopeAspect.java
+++ b/mf-common/mf-common-oauth/src/main/java/cn/com/mfish/common/oauth/aspect/DataScopeAspect.java
@@ -1,6 +1,7 @@
package cn.com.mfish.common.oauth.aspect;
import cn.com.mfish.common.core.annotation.GlobalException;
+import cn.com.mfish.common.core.utils.AuthInfoUtils;
import cn.com.mfish.common.oauth.annotation.DataScope;
import cn.com.mfish.common.oauth.annotation.DataScopes;
import cn.com.mfish.common.oauth.common.DataScopeUtils;
@@ -31,6 +32,10 @@ public class DataScopeAspect {
@Before("@annotation(cn.com.mfish.common.oauth.annotation.DataScopes)||@annotation(cn.com.mfish.common.oauth.annotation.DataScope)")
public void doBefore(JoinPoint joinPoint) {
+ // 内部Feign请求不进行数据权限限制
+ if (AuthInfoUtils.isInnerRequest()) {
+ return;
+ }
MethodSignature methodSignature = (MethodSignature) joinPoint.getSignature();
Method method = methodSignature.getMethod();
List list = new ArrayList<>();
diff --git a/mf-oauth/pom.xml b/mf-oauth/pom.xml
index a29567d7..2e89d255 100644
--- a/mf-oauth/pom.xml
+++ b/mf-oauth/pom.xml
@@ -30,14 +30,6 @@
shiro-web
jakarta
-
- com.google.zxing
- core
-
-
- com.google.zxing
- javase
-
com.github.binarywang
weixin-java-miniapp
diff --git a/mf-oauth/src/main/java/cn/com/mfish/oauth/controller/QRCodeController.java b/mf-oauth/src/main/java/cn/com/mfish/oauth/controller/QRCodeController.java
index 465f7afc..108bb828 100644
--- a/mf-oauth/src/main/java/cn/com/mfish/oauth/controller/QRCodeController.java
+++ b/mf-oauth/src/main/java/cn/com/mfish/oauth/controller/QRCodeController.java
@@ -7,7 +7,7 @@ import cn.com.mfish.common.core.web.Result;
import cn.com.mfish.common.oauth.common.SerConstant;
import cn.com.mfish.common.oauth.entity.WeChatToken;
import cn.com.mfish.common.oauth.validator.WeChatTokenValidator;
-import cn.com.mfish.oauth.common.QRCodeUtils;
+import cn.com.mfish.common.core.utils.QRCodeUtils;
import cn.com.mfish.oauth.entity.QRCode;
import cn.com.mfish.oauth.entity.QRCodeImg;
import cn.com.mfish.oauth.entity.RedisQrCode;
diff --git a/mf-oauth/src/main/resources/static/css/login.css b/mf-oauth/src/main/resources/static/css/login.css
index 2396f747..96060d7d 100644
--- a/mf-oauth/src/main/resources/static/css/login.css
+++ b/mf-oauth/src/main/resources/static/css/login.css
@@ -165,8 +165,10 @@ html, body {
}
.login .qrcode-img .qrcode {
- border-color: transparent;
+ margin: 8px;
+ padding: 12px;
box-shadow: 0 0 8px #c6c4ce;
+ border-radius: 8px;
width: 240px;
height: 240px;
}
diff --git a/mf-start/mf-start-boot/lib/mf-common-bi-mf-1.3.2-pg.jar b/mf-start/mf-start-boot/lib/mf-common-bi-mf-1.3.2-pg.jar
index 80ae8cd8..e7d9e720 100644
Binary files a/mf-start/mf-start-boot/lib/mf-common-bi-mf-1.3.2-pg.jar and b/mf-start/mf-start-boot/lib/mf-common-bi-mf-1.3.2-pg.jar differ
diff --git a/mf-start/mf-start-boot/lib/mf-nocode-mf-1.3.2.jar b/mf-start/mf-start-boot/lib/mf-nocode-mf-1.3.2.jar
index 3ecb32fc..25a3aaba 100644
Binary files a/mf-start/mf-start-boot/lib/mf-nocode-mf-1.3.2.jar and b/mf-start/mf-start-boot/lib/mf-nocode-mf-1.3.2.jar differ
diff --git a/mf-start/mf-start-nocode/lib/mf-common-bi-mf-1.3.2-pg.jar b/mf-start/mf-start-nocode/lib/mf-common-bi-mf-1.3.2-pg.jar
index 80ae8cd8..e7d9e720 100644
Binary files a/mf-start/mf-start-nocode/lib/mf-common-bi-mf-1.3.2-pg.jar and b/mf-start/mf-start-nocode/lib/mf-common-bi-mf-1.3.2-pg.jar differ
diff --git a/mf-start/mf-start-nocode/lib/mf-nocode-mf-1.3.2.jar b/mf-start/mf-start-nocode/lib/mf-nocode-mf-1.3.2.jar
index 3ecb32fc..25a3aaba 100644
Binary files a/mf-start/mf-start-nocode/lib/mf-nocode-mf-1.3.2.jar and b/mf-start/mf-start-nocode/lib/mf-nocode-mf-1.3.2.jar differ
diff --git a/pom.xml b/pom.xml
index d6368e4d..00b097e9 100644
--- a/pom.xml
+++ b/pom.xml
@@ -47,9 +47,9 @@
4.6.7.B
3.18.1
7.17.0
- 2.3.1
+ 2.3.2
1.79
- 23.5.0.24.07
+ 23.7.0.25.01
42.7.4
12.8.1.jre11
1.1.0