package cn.besteam.modules.system.service;
|
|
import cn.besteam.common.constant.DepartmentEnum;
|
import cn.besteam.modules.shiro.authc.util.EnvUtils;
|
import cn.besteam.modules.system.dto.ImportDTO;
|
import cn.besteam.modules.system.vo.SysDepartmentOfficeVO;
|
import cn.besteam.modules.system.dto.SysDepartmentOfficeQueryDTO;
|
import cn.besteam.modules.system.dto.SysDepartmentOfficeUpdateDTO;
|
import cn.besteam.modules.system.entity.SysDepartment;
|
import cn.besteam.modules.system.vo.*;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.extension.service.IService;
|
import org.apache.commons.collections.CollectionUtils;
|
|
import javax.servlet.http.HttpServletResponse;
|
import java.io.IOException;
|
import java.util.ArrayList;
|
import java.util.List;
|
import java.util.stream.Collectors;
|
|
/**
|
* @Description: 组织架构表
|
* @author: besteam
|
* @date: 2020-04-17
|
* @version: V1.0
|
*/
|
public interface ISysDepartmentService extends IService<SysDepartment> {
|
|
/**
|
* 获取部门、科室所在医院
|
*
|
* @param id
|
* @return
|
*/
|
SysDepartment getHospital(Integer id);
|
|
/**
|
* 获取父级ID列表,自顶向下
|
*
|
* @param id
|
* @return
|
*/
|
List<Integer> getParentIdList(Integer id);
|
|
/**
|
* 获取我所在的部门
|
*
|
* @return
|
*/
|
SysDepartment getMyDepartment(Integer userId);
|
|
/**
|
* 获取我能看到的医院列表
|
*
|
* @param userId
|
* @return
|
*/
|
List<SysDepartment> listMyHospital(Integer userId);
|
|
/**
|
* 组织架构导入
|
*
|
* @return
|
*/
|
boolean importDepartment(ImportDTO dto) throws IOException;
|
|
/**
|
* 下载导入模板
|
*
|
* @param response
|
*/
|
void downloadImportTemplate(HttpServletResponse response) throws IOException;
|
|
/**
|
* 生成树编码
|
*
|
* @param parentId
|
* @return
|
*/
|
String getTreeCode(Integer parentId);
|
|
/**
|
* 生成组织编码
|
*
|
* @param parentId
|
* @param orgType
|
* @return
|
*/
|
String getOrgCode(Integer parentId, Integer orgType);
|
|
/**
|
* 删除缓存
|
*
|
* @param id
|
* @return
|
*/
|
boolean deleteCache(Integer id);
|
|
/**
|
* 根据ID获取组织架构信息,被删除的也要查出来
|
* @param id
|
* @return
|
*/
|
SysDepartment getSysDepartmentById(Integer id);
|
|
|
/**
|
* 获取医院系统设置
|
* @return
|
*/
|
IPage<SysDepartmentVO> queryDepartmentPageList(Integer pageNo, Integer pageSize, SysDepartmentVO dto);
|
|
|
/**
|
* 获取收集小程序授权列表
|
* @param vo
|
* @return
|
*/
|
IPage<CollectAppletAuthorizationListVO> getCollectAppletAuthorization(CollectAppletAuthorizationVO vo, Integer pageNo, Integer pageSize);
|
|
|
/**
|
* 批量配置收集小程序授权
|
*/
|
void batchEditCollectAppletAuthorization(List<String> ids, Integer status, Integer userId);
|
|
|
|
/**
|
* 获取月报短信授权列表
|
* @param vo
|
* @return
|
*/
|
IPage<MonthlySmsAuthorizationListVO> getMonthlySmsAuthorization(MonthlySmsAuthorizationVO vo, Integer pageNo, Integer pageSize);
|
|
|
/**
|
* 批量配置月报短信授权
|
*/
|
void batchEditMonthlySmsAuthorization(List<String> ids, Integer status, Integer userId);
|
|
/**
|
* 发送预报表短信数据
|
*/
|
void sendMonthlySMS();
|
|
/**
|
* 更新缓存
|
*/
|
void joinCache();
|
|
List<Integer> getDeptIdListByTreeCode(String treeCode);
|
|
/**
|
* 科室列表分页查询
|
*
|
* @param queryVO
|
* @return
|
*/
|
IPage<SysDepartmentOfficeVO> queryOfficePageList(SysDepartmentOfficeQueryDTO queryVO);
|
|
/**
|
* 更新科室信息
|
* @param updateVO
|
* @return
|
*/
|
boolean updateOfficeInfo(SysDepartmentOfficeUpdateDTO updateVO);
|
|
/**
|
* 获取查询的医院id列表
|
* @param hospitalId
|
* @return
|
*/
|
List<Integer> getSearchHospitalIdList(Integer hospitalId);
|
|
}
|