添加提醒功能

This commit is contained in:
yangjun 2025-07-30 14:50:44 +08:00
parent c41bdb2a9c
commit 9b5ac54e38
1 changed files with 6 additions and 6 deletions

View File

@ -1913,8 +1913,8 @@ public class SysUserController {
*/ */
@RequiresPermissions("system:user:initialization") @RequiresPermissions("system:user:initialization")
@RequestMapping(value = "/initialization", method = RequestMethod.POST) @RequestMapping(value = "/initialization", method = RequestMethod.POST)
public Result<SysUser> initialization(@RequestBody JSONObject jsonObject) { public Result<Map<String,String>> initialization(@RequestBody JSONObject jsonObject) {
Result<SysUser> result = new Result<SysUser>(); Map<String,String> result = new HashMap<>();
String selectedRoles = "f6817f48af4fb3af11b9e8bf182f618b"; String selectedRoles = "f6817f48af4fb3af11b9e8bf182f618b";
String selectedDeparts = ""; String selectedDeparts = "";
try { try {
@ -1922,7 +1922,7 @@ public class SysUserController {
SysDepart depart = sysDepartService.getDepartById(user.getOrgCode()); SysDepart depart = sysDepartService.getDepartById(user.getOrgCode());
if(depart == null){ if(depart == null){
return result.error500("未找到当前机构信息"); return Result.error("未找到机构信息");
} }
selectedDeparts = depart.getId(); selectedDeparts = depart.getId();
user.setOrgCode(depart.getOrgCode()); user.setOrgCode(depart.getOrgCode());
@ -1950,11 +1950,11 @@ public class SysUserController {
orgApplyInfo.setBuildStatus("5"); orgApplyInfo.setBuildStatus("5");
orgApplyInfoService.updateById(orgApplyInfo); orgApplyInfoService.updateById(orgApplyInfo);
result.success("初始化成功!账号:" + jsonObject.getString("userName") + " 密码123456"); result.put("message","初始化成功!账号:" + jsonObject.getString("userName") + " 密码123456");
} catch (Exception e) { } catch (Exception e) {
log.error(e.getMessage(), e); log.error(e.getMessage(), e);
result.error500("操作失败"); return Result.error("初始化失败!");
} }
return result; return Result.ok(result);
} }
} }