diff --git a/pom.xml b/pom.xml
index 92825c2..9eb184e 100644
--- a/pom.xml
+++ b/pom.xml
@@ -28,7 +28,7 @@
5.3.3
2.0.34
6.4.4
- 2.13.0
+
3.2.2
5.2.3
3.3.2
@@ -198,11 +198,11 @@
-
- commons-io
- commons-io
- ${commons.io.version}
-
+
+
+
+
+
diff --git a/ruoyi-common/ruoyi-common-core/pom.xml b/ruoyi-common/ruoyi-common-core/pom.xml
index 69c0ef4..4608d20 100644
--- a/ruoyi-common/ruoyi-common-core/pom.xml
+++ b/ruoyi-common/ruoyi-common-core/pom.xml
@@ -61,10 +61,10 @@
-
- commons-io
- commons-io
-
+
+
+
+
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/controller/system/SysConfigController.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/controller/system/SysConfigController.java
index b0a947e..f2a5b15 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/controller/system/SysConfigController.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/controller/system/SysConfigController.java
@@ -110,6 +110,20 @@ public class SysConfigController extends BaseController {
return R.ok();
}
+ /**
+ * 根据参数键名修改参数配置
+ */
+ @SaCheckPermission("system:config:edit")
+ @Log(title = "参数管理", businessType = BusinessType.UPDATE)
+ @PutMapping("/updateByKey")
+ public R updateByKey(@RequestBody SysConfigBo config) {
+ boolean updated = configService.updateConfig(config);
+ if (!updated) {
+ R.fail("修改参数'" + config.getConfigName() + "'失败!");
+ }
+ return R.ok();
+ }
+
/**
* 删除参数配置
*/
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysClientBo.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysClientBo.java
index 00ba71d..624274d 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysClientBo.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysClientBo.java
@@ -24,7 +24,6 @@ public class SysClientBo extends BaseEntity {
/**
* id
*/
- @NotNull(message = "id不能为空", groups = { EditGroup.class })
private Long id;
/**
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysConfigBo.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysConfigBo.java
index 2cfbca8..e3f495f 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysConfigBo.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysConfigBo.java
@@ -24,7 +24,6 @@ public class SysConfigBo extends BaseEntity {
/**
* 参数主键
*/
- @NotNull(message = "参数主键不能为空", groups = { EditGroup.class })
private Long configId;
/**
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDeptBo.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDeptBo.java
index 12564cc..0658c02 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDeptBo.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDeptBo.java
@@ -26,7 +26,6 @@ public class SysDeptBo extends BaseEntity {
/**
* 部门id
*/
- @NotNull(message = "部门id不能为空", groups = { EditGroup.class })
private Long deptId;
/**
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDictDataBo.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDictDataBo.java
index 935f186..6d167fd 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDictDataBo.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDictDataBo.java
@@ -6,7 +6,6 @@ import com.ruoyi.common.orm.core.domain.BaseEntity;
import com.ruoyi.system.domain.SysDictData;
import io.github.linpeilie.annotations.AutoMapper;
import jakarta.validation.constraints.NotBlank;
-import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import lombok.Data;
import lombok.EqualsAndHashCode;
@@ -25,7 +24,6 @@ public class SysDictDataBo extends BaseEntity {
/**
* 字典编码
*/
- @NotNull(message = "字典编码不能为空", groups = { EditGroup.class })
private Long dictCode;
/**
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDictTypeBo.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDictTypeBo.java
index cdb6f68..85c31c4 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDictTypeBo.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysDictTypeBo.java
@@ -6,7 +6,6 @@ import com.ruoyi.common.orm.core.domain.BaseEntity;
import com.ruoyi.system.domain.SysDictType;
import io.github.linpeilie.annotations.AutoMapper;
import jakarta.validation.constraints.NotBlank;
-import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Pattern;
import jakarta.validation.constraints.Size;
import lombok.Data;
@@ -26,7 +25,6 @@ public class SysDictTypeBo extends BaseEntity {
/**
* 字典主键
*/
- @NotNull(message = "字典主键不能为空", groups = { EditGroup.class })
private Long dictId;
/**
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysMenuBo.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysMenuBo.java
index fd93474..660b2d6 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysMenuBo.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysMenuBo.java
@@ -26,7 +26,6 @@ public class SysMenuBo extends BaseEntity {
/**
* 菜单ID
*/
- @NotNull(message = "菜单ID不能为空", groups = { EditGroup.class })
private Long menuId;
/**
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysNoticeBo.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysNoticeBo.java
index 8a57be3..7305d54 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysNoticeBo.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysNoticeBo.java
@@ -7,7 +7,6 @@ import com.ruoyi.common.orm.core.domain.BaseEntity;
import com.ruoyi.system.domain.SysNotice;
import io.github.linpeilie.annotations.AutoMapper;
import jakarta.validation.constraints.NotBlank;
-import jakarta.validation.constraints.NotNull;
import jakarta.validation.constraints.Size;
import lombok.Data;
import lombok.EqualsAndHashCode;
@@ -26,7 +25,6 @@ public class SysNoticeBo extends BaseEntity {
/**
* 公告ID
*/
- @NotNull(message = "公告ID不能为空", groups = { EditGroup.class })
private Long noticeId;
/**
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysPostBo.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysPostBo.java
index e8a1c0f..2e69830 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysPostBo.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysPostBo.java
@@ -25,7 +25,6 @@ public class SysPostBo extends BaseEntity {
/**
* 岗位ID
*/
- @NotNull(message = "岗位ID不能为空", groups = { EditGroup.class })
private Long postId;
/**
diff --git a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysRoleBo.java b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysRoleBo.java
index 34c9751..0106993 100644
--- a/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysRoleBo.java
+++ b/ruoyi-modules/ruoyi-system/src/main/java/com/ruoyi/system/domain/bo/SysRoleBo.java
@@ -28,7 +28,6 @@ public class SysRoleBo extends BaseEntity {
/**
* 角色ID
*/
- @NotNull(message = "角色ID不能为空", groups = { EditGroup.class })
private Long roleId;
/**
diff --git a/ruoyi-ui/package.json b/ruoyi-ui/package.json
index f380540..b3a7c4d 100644
--- a/ruoyi-ui/package.json
+++ b/ruoyi-ui/package.json
@@ -50,6 +50,7 @@
"nprogress": "0.2.0",
"vue": "3.2.45",
"vue-cropper": "1.0.3",
+ "vue-i18n": "9.2.2",
"vue-router": "4.1.4",
"vuex": "4.0.2"
},
diff --git a/ruoyi-ui/src/api/system/config.js b/ruoyi-ui/src/api/system/config.js
index a404d82..92eccac 100644
--- a/ruoyi-ui/src/api/system/config.js
+++ b/ruoyi-ui/src/api/system/config.js
@@ -43,6 +43,18 @@ export function updateConfig(data) {
})
}
+// 修改参数配置
+export function updateConfigByKey(key, value) {
+ return request({
+ url: '/system/config/updateByKey',
+ method: 'put',
+ data: {
+ configKey: key,
+ configValue: value
+ }
+ });
+}
+
// 删除参数配置
export function delConfig(configId) {
return request({
diff --git a/ruoyi-ui/src/lang/index.js b/ruoyi-ui/src/lang/index.js
index dddb86b..b9cd739 100644
--- a/ruoyi-ui/src/lang/index.js
+++ b/ruoyi-ui/src/lang/index.js
@@ -4,6 +4,7 @@ import { createI18n } from 'vue-i18n';
// 本地语言包
import enUSLocale from './en_US';
import zhCNLocale from './zh_CN';
+import {useStorage} from "@vueuse/core";
const messages = {
zh_CN: {