Commit 5cde5d64 authored by 蔡镇泽's avatar 蔡镇泽

失能人员信息列表省市区、机构

parent 1ed2d148
......@@ -6,11 +6,11 @@ import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
/**
* 失能人员申请历史Mapper
* 省市区Mapper
*
* @author czz
*/
@Mapper
@Repository
public interface DistrictMapper extends BaseMapper<ChFndDistrict> {
public interface FndDistrictMapper extends BaseMapper<ChFndDistrict> {
}
package com.hungraim.ism.dao;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hungraim.ltc.pojo.entity.disable.ChFndStreet;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Repository;
/**
* 街道Mapper
*
* @author czz
*/
@Mapper
@Repository
public interface FndStreetMapper extends BaseMapper<ChFndStreet> {
}
......@@ -3,8 +3,9 @@ package com.hungraim.ism.service.impl;
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.hungraim.ism.dao.DisableApplyMapper;
import com.hungraim.ism.dao.DistrictMapper;
import com.hungraim.ism.dao.FndDistrictMapper;
import com.hungraim.ism.dao.FndOrganMapper;
import com.hungraim.ism.dao.FndStreetMapper;
import com.hungraim.ism.pojo.vo.disable.DisableExamineInfoVO;
import com.hungraim.ism.pojo.vo.disable.DisableVO;
import com.hungraim.ism.pojo.vo.disable.ExamineRecord;
......@@ -12,9 +13,11 @@ import com.hungraim.ism.service.DisableService;
import com.hungraim.ltc.pojo.entity.disable.ChDisableApply;
import com.hungraim.ltc.pojo.entity.disable.ChFndDistrict;
import com.hungraim.ltc.pojo.entity.disable.ChFndOrgan;
import com.hungraim.ltc.pojo.entity.disable.ChFndStreet;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.ArrayList;
import java.util.List;
@Service
......@@ -23,9 +26,11 @@ public class DisableServiceImpl implements DisableService {
@Autowired
private DisableApplyMapper disableApplyMapper;
@Autowired
private DistrictMapper districtMapper;
private FndDistrictMapper districtMapper;
@Autowired
private FndOrganMapper fndOrganMapper;
@Autowired
private FndStreetMapper fndStreetMapper;
@Override
public Page<DisableVO> disableList(String organId, String districtProvincial, String districtCity,
......@@ -58,13 +63,29 @@ public class DisableServiceImpl implements DisableService {
@Override
public List<ChFndDistrict> district(String districtLevel, String districtCode) {
QueryWrapper<ChFndDistrict> queryWrapper = new QueryWrapper<ChFndDistrict>();
if ("4".equals(districtCode)) {
QueryWrapper<ChFndStreet> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("AREA_CODE", districtCode);
queryWrapper.eq("IS_VALID", 0);
List<ChFndStreet> fndStreets = fndStreetMapper.selectList(queryWrapper);
List<ChFndDistrict> resuts = new ArrayList<>();
for (ChFndStreet chFndStreet : fndStreets) {
ChFndDistrict chFndDistrict = new ChFndDistrict();
chFndDistrict.setDistrictCode(chFndStreet.getStreetCode());
chFndDistrict.setDistrictName(chFndStreet.getStreetName());
chFndDistrict.setParentDistirctCode(chFndStreet.getAreaCode());
}
return resuts;
} else {
QueryWrapper<ChFndDistrict> queryWrapper = new QueryWrapper<>();
queryWrapper.eq("IS_VALID", "Y");
queryWrapper.eq("DISTRICT_LEVEL", districtLevel);
if (!"1".equals(districtLevel)) {
queryWrapper.eq("PARENT_DISTIRCT_CODE", districtCode);
}
return districtMapper.selectList(queryWrapper);
}
}
@Override
public List<ChFndOrgan> fndOrganRoot() {
......
......@@ -16,7 +16,7 @@
e.SRV_ORGEN_ID srvOrgenId,
e.MODE_ID modeId,
e.EVALUATE_TIME evaluateTime
from CH_DISABLE_EVALUATE e,CH_SRV_ORGAN o
from CH_DISABLE_EVALUATE e,CH_FND_ORGAN o
where e.organ_id = o.ORGAN_ID
<if test="organId != null">
and e.organ_Id = #{organId}
......
package com.hungraim.ltc.pojo.entity.disable;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;
/**
* 街道信息
*/
@Data
@TableName("CH_FND_STREET")
public class ChFndStreet {
private String streetCode;
private Integer isValid;
private String streetName;
private String areaCode;
}
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