| | |
| | | queryWrapper.ge(Company::getFsDate, Utils.Date.getStart(company.getFsDate())); |
| | | queryWrapper.le(Company::getFsDate, Utils.Date.getEnd(company.getFsDate())); |
| | | } |
| | | if (company.getQueryHiddenDanger() != null && Constants.equalsInteger(company.getQueryHiddenDanger(),Constants.ONE)) { |
| | | queryWrapper.apply(" t.id in ( select hdp.COMPANY_ID from hidden_danger_param hdp where hdp.ISDELETED = 0 and hdp.STATUS = 0 and hdp.TYPE = 0 ) "); |
| | | } |
| | | queryWrapper.orderByDesc(Company::getCreateDate); |
| | | queryWrapper.leftJoin(Company.class,Company::getId,Company::getParentId); |
| | | queryWrapper.select(" t.* ") |
| | |
| | | queryWrapper.leftJoin(Member.class,Member::getId,Company::getHeadId); |
| | | queryWrapper.leftJoin(SystemUser.class,SystemUser::getId,Company::getEditor); |
| | | queryWrapper.eq(Company::getIsdeleted,Constants.ZERO); |
| | | queryWrapper.eq(type!=null,Company::getType,type); |
| | | if(Objects.nonNull(type) && ( Constants.equalsInteger(type,Constants.ONE) || Constants.equalsInteger(type,Constants.ZERO))){ |
| | | queryWrapper.eq(type!=null,Company::getType,type); |
| | | }else{ |
| | | String companySpecialId = systemDictDataBiz.queryByCode(Constants.SYSTEM,Constants.SPECIAL_COMPANY_ID).getCode(); |
| | | if(StringUtils.isNotBlank(companySpecialId)){ |
| | | queryWrapper.apply(" (find_in_set('"+companySpecialId+"',REPLACE(t.company_path,'/',',')) or t.parent_id is null ) "); |
| | | } |
| | | } |
| | | queryWrapper.orderByAsc(true,"t.sortnum"); |
| | | List<Company> companyList = companyJoinMapper.selectJoinList(Company.class,queryWrapper); |
| | | //配置组员人员类型来源方式 0自建 1ERP |