feat:用户信息导入

new-v20240713
wangxy 8 months ago
parent 60dca4343d
commit 52db177a98

@ -27,7 +27,6 @@ public class SysUser extends BaseEntity
private Long userId;
/** 部门ID */
@Excel(name = "部门编号", type = Type.IMPORT)
private Long deptId;
/** 部门父ID */
@ -48,7 +47,6 @@ public class SysUser extends BaseEntity
private String userType;
/** 用户邮箱 */
@Excel(name = "用户邮箱")
private String email;
/** 手机号码 */
@ -89,7 +87,6 @@ public class SysUser extends BaseEntity
/** 部门对象 */
@Excels({
@Excel(name = "部门名称", targetAttr = "deptName", type = Type.EXPORT),
@Excel(name = "部门负责人", targetAttr = "leader", type = Type.EXPORT)
})
private SysDept dept;

@ -499,7 +499,8 @@ public class SysUserServiceImpl implements ISysUserService
if (StringUtils.isNull(u))
{
BeanValidators.validateWithException(validator, user);
user.setPassword(Md5Utils.hash(user.getLoginName() + password));
user.setSalt(ShiroUtils.randomSalt());
user.setPassword(Md5Utils.hash(user.getLoginName() + password + user.getSalt()));
user.setCreateBy(operName);
userMapper.insertUser(user);
successNum++;

Loading…
Cancel
Save