futian.liu
2023-12-22 fd95223d9703b9c038ed3c782474c885052dda08
consum-base/src/main/java/com/consum/base/controller/FinSysTenantUserController.java
@@ -22,7 +22,7 @@
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.multipart.MultipartFile;
import com.alibaba.excel.EasyExcel;
import com.alibaba.excel.EasyExcelFactory;
import com.alibaba.excel.context.AnalysisContext;
import com.alibaba.excel.event.AnalysisEventListener;
import com.alibaba.excel.exception.ExcelDataConvertException;
@@ -124,13 +124,6 @@
            String tel = finSysTenantUser.getUserPhone() != null
                ? AESUtils.decryptStrAES(finSysTenantUser.getUserPhone(), PlatformRSAUtils.AES_KEY) : null;
            finSysTenantUser.setUserPhone(StringUtils.isNotEmpty(tel) ? PhoneNumberUtils.maskMobile(tel) : "");
            // 列表不需要查询角色,只显示列表所需要的信息
            /*List<S_role> list = finSysTenantUserService.getByUserId(finSysTenantUser.getSysUserId());
            StringBuilder roleStr = new StringBuilder();
            list.forEach(s_role -> roleStr.append(s_role.getRole_name()).append(" "));
            finSysTenantUser.setRoleStr(roleStr.toString());
            finSysTenantUser.setIsSupplier(finSysTenantUser.getSupplierId() != null ? "是" : "否");*/
        }
        return ResponseValue.success(pager);
@@ -300,7 +293,8 @@
        List<S_role> roles = this.roleService.select(new S_role());
        ArrayList<FinSysTenantUser> finSysTenantUsers = new ArrayList<>();
        EasyExcel.read(file.getInputStream(), ImportUserParam.class, new AnalysisEventListener<ImportUserParam>() {
        EasyExcelFactory
            .read(file.getInputStream(), ImportUserParam.class, new AnalysisEventListener<ImportUserParam>() {
            @Override
            public void invoke(ImportUserParam data, AnalysisContext context) {
                if (StringUtils.isEmpty(data.getUserName()) || StringUtils.isEmpty(data.getUserCode())
@@ -552,7 +546,7 @@
        Long sysUserId = finSysTenantUser.getSysUserId();
        List<S_role> roleList = finSysTenantUserService.getRoleBySysUserId(sysUserId);
        // 过滤仓库管理员的显示
        roleList.removeIf(role -> role.getRole_name().equals("仓库管理员"));
        roleList.removeIf(role -> "仓库管理员".equals(role.getRole_name()));
        HashMap<String, Object> map = new HashMap<>();
        map.put("list", roleList);
@@ -680,7 +674,7 @@
        return ResponseValue.success(1);
    }
    private Set<String> picFormatArr = new HashSet<String>() {
    private final Set<String> picFormatArr = new HashSet<String>() {
        {
            add(".pjp");
            add(".svgz");