Commit 6caa9a95 authored by 麻笑宇's avatar 麻笑宇

1.人员增加设备类型

2.修改企业json
parent e6417a1b
......@@ -85,4 +85,8 @@ public class DPFilterParamDto {
* 业务状态
*/
private String status;
private String equipType;
private String phone;
}
......@@ -45,10 +45,10 @@
<if test="map.planName!=null">and c.name like concat('%',#{map.planName},'%')</if>
<if test="map.routeName!=null">and e.name like concat('%',#{map.routeName},'%')</if>
<if test="map.beginDate==''and map.beginDate!=null">
and a.begin_Time <![CDATA[>=]]> #{beginDate}
and a.begin_Time <![CDATA[>=]]> #{map.beginDate}
</if>
<if test="map.endDate != null and map.endDate != ''">
AND a.end_Time <![CDATA[<=]]> #{endDate}
AND a.end_Time <![CDATA[<=]]> #{map.endDate}
</if>
<if test="map.status!=null">and b.is_finish = #{map.status}</if>
<if test="map.isOk!=null">and pc.is_ok = #{map.isOk}</if>
......
......@@ -296,26 +296,20 @@ public class EnterpriseBizByTCMServiceImpl {
tzBaseEnterpriseInfoDto.setEquipCategory(ObjectUtils.isEmpty(tzBaseEnterpriseInfo.getEquipCategory()) ? new ArrayList() : JSON.parseArray(tzBaseEnterpriseInfo.getEquipCategory()));
}
ReginParams selectedOrgInfo = getSelectedOrgInfo();
String companyType = selectedOrgInfo.getCompany().getCompanyType();
// 修改当前登录人选择的单位类型
tzBaseEnterpriseInfoDto.setUnitType(companyType);
// 当前用户选择角色的许可信息(使用。。安改维。。检验检测。。)
List<BaseUnitLicence> unitLicences = baseUnitLicenceMapper.selectList(new LambdaQueryWrapper<BaseUnitLicence>()
.eq(BaseUnitLicence::getUnitCode, tzBaseEnterpriseInfo.getUseCode()));
List<BaseUnitLicenceDto> unitLicenceDtos = new ArrayList<>();
List<BaseUnitLicence> unitLicencesCollect;
if ("监管机构".equals(companyType)) {
if ("监管机构".equals(tzBaseEnterpriseInfoDto.getUnitType())) {
unitLicencesCollect = unitLicences;
} else {
Predicate<BaseUnitLicence> certTypePredicate;
if (INSPECTION_AND_TESTING_INSTITUTIONS.equals(companyType)) {
if (INSPECTION_AND_TESTING_INSTITUTIONS.equals(tzBaseEnterpriseInfoDto.getUnitType())) {
certTypePredicate = baseUnitLicence -> INSPECTION_AGENCY.equals(baseUnitLicence.getCertType()) ||
TESTING_INSTITUTIONS.equals(baseUnitLicence.getCertType());
} else {
certTypePredicate = baseUnitLicence -> companyType.contains(baseUnitLicence.getCertType());
certTypePredicate = baseUnitLicence -> tzBaseEnterpriseInfoDto.getUnitType().contains(baseUnitLicence.getCertType());
}
unitLicencesCollect = unitLicences.stream()
.filter(certTypePredicate)
......
......@@ -137,8 +137,8 @@
}
},
"keyParams": [
{ "key": "unitType", "label": "单位类型" },
{ "key": "useUnit", "label": "单位名称" },
{ "key": "unitType", "label": "企业类型" },
{ "key": "useUnit", "label": "企业名称" },
{ "key": "useUnitCertificate", "label": "证件类型" },
{ "key": "useUnitCode", "label": "证件号码" },
{ "key": "governingBody", "label": "管辖机构" },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment