| | |
| | | package org.springblade.modules.partyOrganization.service.impl; |
| | | |
| | | import com.baomidou.mybatisplus.core.metadata.IPage; |
| | | import org.springblade.common.cache.SysCache; |
| | | import org.springblade.common.param.CommonParamSet; |
| | | import org.springblade.core.mp.base.BaseServiceImpl; |
| | | import org.springblade.core.secure.utils.AuthUtil; |
| | | import org.springblade.modules.house.vo.HouseVO; |
| | | import org.springblade.modules.partyOrganization.entity.PartyOrganization; |
| | | import org.springblade.modules.partyOrganization.mapper.PartyOrganizationMapper; |
| | | import org.springblade.modules.partyOrganization.service.IPartyOrganizationService; |
| | |
| | | import org.springframework.beans.factory.annotation.Autowired; |
| | | import org.springframework.stereotype.Service; |
| | | |
| | | import java.util.List; |
| | | |
| | | @Service |
| | | public class PartyOrganizationServiceImpl extends BaseServiceImpl<PartyOrganizationMapper, PartyOrganization> implements IPartyOrganizationService { |
| | | |
| | | @Autowired |
| | | private IDeptService deptService; |
| | | |
| | | @Override |
| | | public IPage<PartyOrganizationVO> getPage(IPage<PartyOrganizationVO> page, PartyOrganizationVO partyOrganizationVO) { |
| | | |
| | | Dept dept = deptService.getById(AuthUtil.getDeptId()); |
| | | if (null!=dept){ |
| | | partyOrganizationVO.setAreaId(dept.getRegionCode()); |
| | | } |
| | | return page.setRecords(baseMapper.getPage(page,partyOrganizationVO)); |
| | | CommonParamSet commonParamSet = new CommonParamSet<>().invoke(PartyOrganizationVO.class, partyOrganizationVO); |
| | | return page.setRecords(baseMapper.getPage(page, |
| | | partyOrganizationVO, |
| | | commonParamSet.getRegionChildCodesList(), |
| | | commonParamSet.getIsAdministrator())); |
| | | } |
| | | } |