Commit 5cf598a3 authored by 刘林's avatar 刘林

Merge remote-tracking branch 'origin/develop_tzs_register' into develop_tzs_register

parents ffbf9643 aa9192af
......@@ -7,7 +7,6 @@ import com.yeejoin.amos.boot.module.jg.api.vo.SortVo;
import com.yeejoin.amos.boot.module.jyjc.api.dto.InspectionTimelinesDto;
import com.yeejoin.amos.boot.module.jyjc.api.entity.JyjcInspectionResult;
import com.yeejoin.amos.boot.module.jyjc.api.model.JyjcInspectionResultModel;
import com.yeejoin.amos.boot.module.jyjc.api.vo.JyjcInspectionApplicationVo;
import com.yeejoin.amos.boot.module.jyjc.api.vo.JyjcInspectionResultVo;
import org.apache.ibatis.annotations.Param;
......@@ -23,7 +22,7 @@ public interface JyjcInspectionResultMapper extends BaseMapper<JyjcInspectionRes
Page<JyjcInspectionResultModel> selectJyjcInspectionResultpPage(@Param("page") Page<JyjcInspectionResultModel> page, @Param("jyjcInspectionResultModel") JyjcInspectionResultModel jyjcInspectionResultModel);
Page<JyjcInspectionResultModel> selectForPage(@Param("page") Page<JyjcInspectionResultModel> page, @Param("jyjcInspectionResultModel") JyjcInspectionResultModel jyjcInspectionResultModel, @Param("identity") String identity, @Param("sort") SortVo sortMap);
Page<JyjcInspectionResultModel> selectForPage(@Param("page") Page<JyjcInspectionResultModel> page, @Param("jyjcInspectionResultModel") JyjcInspectionResultModel jyjcInspectionResultModel, @Param("identity") String identity, @Param("sort") SortVo sortMap, @Param("companyType") String companyType);
List<InspectionTimelinesDto> queryInspectionTimelinessTopXX(@Param("top") String top, @Param("orgCode") String orgCode, @Param("dto") DPFilterParamDto dpFilterParamDto);
......
......@@ -252,6 +252,23 @@
and 1 = 2
</otherwise>
</choose>
<choose>
<when test="companyType == '使用单位'">
and res.biz_type in ('firstinspect','entrust', 'detection')
</when>
<when test="companyType == '安装改造维修单位'">
and res.biz_type = 'supervise'
</when>
<when test="companyType == '检验机构'">
and res.biz_type != 'detection'
</when>
<when test="companyType == '检测机构'">
and res.biz_type = 'detection'
</when>
<otherwise>
and 1 = 1
</otherwise>
</choose>
</where>
union all
<include refid="page-list3"/>
......@@ -298,6 +315,23 @@
and 1 = 2
</otherwise>
</choose>
<choose>
<when test="companyType == '使用单位'">
and res.biz_type in ('firstinspect','entrust', 'detection')
</when>
<when test="companyType == '安装改造维修单位'">
and res.biz_type = 'supervise'
</when>
<when test="companyType == '检验机构'">
and res.biz_type != 'detection'
</when>
<when test="companyType == '检测机构'">
and res.biz_type = 'detection'
</when>
<otherwise>
and 1 = 1
</otherwise>
</choose>
</where>
)
ORDER BY
......
......@@ -204,7 +204,7 @@ public class JyjcInspectionResultServiceImpl extends BaseService<JyjcInspectionR
// 判断当前登录人身份(报检机构、接收机构、即时报检又是接收机构、都不是(不存在此情况))
String identity = CommonServiceImpl.getCompanyIdentityByType(reginParams.getCompany().getCompanyType());
model.setCompanyCode(CommonServiceImpl.getUnitCode(reginParams.getCompany()));
Page<JyjcInspectionResultModel> resultPage = resultMapper.selectForPage(page, model, identity, sortMap);
Page<JyjcInspectionResultModel> resultPage = resultMapper.selectForPage(page, model, identity, sortMap, reginParams.getCompany().getCompanyType());
resultPage.getRecords().forEach(v -> {
if (ResultStatusEnum.NO_RESULT.getCode().equals(v.getResultStatus())) {
v.setResultStatusName(ResultStatusEnum.NO_RESULT.getName());
......
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