Merge remote-tracking branch 'origin/springboot3' into springboot3_sas

This commit is contained in:
JEECG 2025-11-10 15:56:21 +08:00
commit 33cbc6e25b
6 changed files with 1727 additions and 1520 deletions

View File

@ -83,6 +83,7 @@ JeecgBoot低代码平台兼容所有J2EE项目开发支持信创国产化
- 官方网站: [http://www.jeecg.com](http://www.jeecg.com)
- 在线演示: [平台演示](https://boot3.jeecg.com) | [APP演示](https://jeecg.com/appIndex)
- 入门指南: [快速入门](http://www.jeecg.com/doc/quickstart) | [代码生成使用](https://help.jeecg.com/java/codegen/online) | [开发文档](https://help.jeecg.com) | [AI应用手册](https://help.jeecg.com/aigc) | [视频教程](http://jeecg.com/doc/video)
- AI编程实战视频 [JEECG低代码与Cursor+GitHub Copilot实现AI高效编程实战](https://www.bilibili.com/video/BV11XyaBVEoH)
- 技术支持: [反馈问题](https://github.com/jeecgboot/JeecgBoot/issues/new?template=bug_report.md) | [低代码体验一分钟](https://jeecg.blog.csdn.net/article/details/106079007)
- QQ交流群 964611995、⑩716488839(满)、⑨808791225(满)、其他(满)

View File

@ -1692,6 +1692,42 @@ public class SysUserController {
return Result.ok();
}
/**
* 添加用户后台租户模式专用敲敲云不要用这个
*
* @param jsonObject
* @return
*/
@RequiresPermissions("system:user:addTenantUser")
@RequestMapping(value = "/addTenantUser", method = RequestMethod.POST)
public Result<SysUser> addTenantUser(@RequestBody JSONObject jsonObject) {
Result<SysUser> result = new Result<SysUser>();
String selectedRoles = jsonObject.getString("selectedroles");
String selectedDeparts = jsonObject.getString("selecteddeparts");
try {
SysUser user = JSON.parseObject(jsonObject.toJSONString(), SysUser.class);
user.setCreateTime(new Date());//设置创建时间
String salt = oConvertUtils.randomGen(8);
user.setSalt(salt);
String passwordEncode = PasswordUtil.encrypt(user.getUsername(), user.getPassword(), salt);
user.setPassword(passwordEncode);
user.setStatus(1);
user.setDelFlag(CommonConstant.DEL_FLAG_0);
//用户表字段org_code不能在这里设置他的值
user.setOrgCode(null);
// 保存用户走一个service 保证事务
//获取租户ids
String relTenantIds = jsonObject.getString("relTenantIds");
sysUserService.saveUser(user, selectedRoles, selectedDeparts, relTenantIds, true);
baseCommonService.addLog("添加用户username " + user.getUsername(), CommonConstant.LOG_TYPE_2, 2);
result.success("添加成功!");
} catch (Exception e) {
log.error(e.getMessage(), e);
result.error500("操作失败");
}
return result;
}
/**
* 修改租户下的用户低代码应用专用接口
* @param sysUser

View File

@ -21,6 +21,13 @@ public class SysUserSysDepPostModel {
* 用户ID
*/
private String id;
/**
* 登录账号
*/
@Excel(name = "登录账号", width = 15)
private String username;
/* 真实姓名 */
private String realname;

View File

@ -141,8 +141,8 @@
"prettier": "^3.4.2",
"pretty-quick": "^4.0.0",
"rimraf": "^5.0.10",
"rollup": "^4.30.0",
"rollup-plugin-visualizer": "^5.13.1",
"rollup": "4.52.5",
"rollup-plugin-visualizer": "5.14.0",
"stylelint": "^16.12.0",
"stylelint-config-prettier": "^9.0.5",
"stylelint-config-recommended": "^14.0.1",

File diff suppressed because it is too large Load Diff

View File

@ -172,6 +172,11 @@ export const orgCategoryOptions = {
* 用户列表
*/
export const userColumns: BasicColumn[] = [
{
title: '用户账号',
dataIndex: 'username',
width: 120,
},
{
title: '姓名',
dataIndex: 'realname',
@ -208,4 +213,4 @@ export function positionChange(value, model, treeData) {
} else {
treeData.value = [];
}
}
}