调整初始密码位置

master
RuoYi 6 years ago committed by Limy
parent db507b1624
commit c824e6cefa

@ -22,7 +22,6 @@ import com.ruoyi.framework.shiro.service.SysPasswordService;
import com.ruoyi.framework.util.ShiroUtils;
import com.ruoyi.framework.web.base.BaseController;
import com.ruoyi.system.domain.SysUser;
import com.ruoyi.system.service.ISysConfigService;
import com.ruoyi.system.service.ISysPostService;
import com.ruoyi.system.service.ISysRoleService;
import com.ruoyi.system.service.ISysUserService;
@ -47,9 +46,6 @@ public class SysUserController extends BaseController
@Autowired
private ISysPostService postService;
@Autowired
private ISysConfigService configService;
@Autowired
private SysPasswordService passwordService;
@ -90,8 +86,7 @@ public class SysUserController extends BaseController
ExcelUtil<SysUser> util = new ExcelUtil<SysUser>(SysUser.class);
List<SysUser> userList = util.importExcel(file.getInputStream());
String operName = getSysUser().getLoginName();
String password = configService.selectConfigByKey("sys.user.initPassword");
String message = userService.importUser(userList, updateSupport, operName, password);
String message = userService.importUser(userList, updateSupport, operName);
return AjaxResult.success(message);
}

@ -145,8 +145,7 @@ public interface ISysUserService
* @param userList
* @param isUpdateSupport
* @param operName
* @param password
* @return
*/
public String importUser(List<SysUser> userList, Boolean isUpdateSupport, String operName, String password);
public String importUser(List<SysUser> userList, Boolean isUpdateSupport, String operName);
}

@ -22,6 +22,7 @@ import com.ruoyi.system.mapper.SysRoleMapper;
import com.ruoyi.system.mapper.SysUserMapper;
import com.ruoyi.system.mapper.SysUserPostMapper;
import com.ruoyi.system.mapper.SysUserRoleMapper;
import com.ruoyi.system.service.ISysConfigService;
import com.ruoyi.system.service.ISysUserService;
/**
@ -49,6 +50,9 @@ public class SysUserServiceImpl implements ISysUserService
@Autowired
private SysUserRoleMapper userRoleMapper;
@Autowired
private ISysConfigService configService;
/**
*
*
@ -368,7 +372,7 @@ public class SysUserServiceImpl implements ISysUserService
* @param password
* @return
*/
public String importUser(List<SysUser> userList, Boolean isUpdateSupport, String operName, String password)
public String importUser(List<SysUser> userList, Boolean isUpdateSupport, String operName)
{
if (StringUtils.isNull(userList) || userList.size() == 0)
{
@ -378,6 +382,7 @@ public class SysUserServiceImpl implements ISysUserService
int failureNum = 0;
StringBuilder successMsg = new StringBuilder();
StringBuilder failureMsg = new StringBuilder();
String password = configService.selectConfigByKey("sys.user.initPassword");
for (SysUser user : userList)
{
try

Loading…
Cancel
Save