mirror of
https://github.com/continew-org/continew-admin.git
synced 2025-10-30 02:57:09 +08:00
feat: 公告支持设置通知范围
This commit is contained in:
@@ -43,10 +43,12 @@ import top.continew.starter.core.util.validate.ValidationUtils;
|
||||
import top.continew.starter.extension.crud.annotation.CrudRequestMapping;
|
||||
import top.continew.starter.extension.crud.controller.BaseController;
|
||||
import top.continew.starter.extension.crud.enums.Api;
|
||||
import top.continew.starter.extension.crud.model.query.SortQuery;
|
||||
import top.continew.starter.extension.crud.model.resp.BaseIdResp;
|
||||
import top.continew.starter.extension.crud.util.ValidateGroup;
|
||||
|
||||
import java.io.IOException;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 用户管理 API
|
||||
@@ -63,6 +65,11 @@ public class UserController extends BaseController<UserService, UserResp, UserDe
|
||||
|
||||
private final UserService userService;
|
||||
|
||||
@Override
|
||||
public List<UserResp> list(UserQuery query, SortQuery sortQuery) {
|
||||
return super.list(query, sortQuery);
|
||||
}
|
||||
|
||||
@Override
|
||||
public BaseIdResp<Long> add(@Validated(ValidateGroup.Crud.Add.class) @RequestBody UserReq req) {
|
||||
String rawPassword = ExceptionUtils.exToNull(() -> SecureUtils.decryptByRsaPrivateKey(req.getPassword()));
|
||||
|
||||
@@ -5,6 +5,8 @@ databaseChangeLog:
|
||||
file: db/changelog/mysql/continew-admin_column.sql
|
||||
- include:
|
||||
file: db/changelog/mysql/continew-admin_data.sql
|
||||
- include:
|
||||
file: db/changelog/mysql/continew-admin_change_v3.4.0.sql
|
||||
# PostgreSQL
|
||||
# - include:
|
||||
# file: db/changelog/postgresql/continew-admin_table.sql
|
||||
|
||||
@@ -0,0 +1,6 @@
|
||||
-- 消息通知表 新增通知范围 和 通知用户两个字段
|
||||
START TRANSACTION;
|
||||
ALTER TABLE sys_notice
|
||||
ADD COLUMN notice_scope INT NOT NULL COMMENT '通知范围' AFTER terminate_time,
|
||||
ADD COLUMN notice_users JSON DEFAULT NULL COMMENT '通知用户' AFTER notice_scope;
|
||||
COMMIT;
|
||||
Reference in New Issue
Block a user