weaver-hrm-organization/src/com/engine/organization/mapper/department/DepartmentMapper.java

119 lines
2.2 KiB
Java
Raw Normal View History

2022-05-20 15:00:03 +08:00
package com.engine.organization.mapper.department;
import com.engine.organization.entity.department.po.DepartmentPO;
import org.apache.ibatis.annotations.Param;
2022-05-23 17:46:37 +08:00
import java.util.Collection;
2022-05-20 15:00:03 +08:00
import java.util.List;
2022-05-26 10:11:02 +08:00
import java.util.Map;
2022-05-20 15:00:03 +08:00
/**
* @Author weaver_cl
2022-06-14 11:07:48 +08:00
* @description:
2022-05-20 15:00:03 +08:00
* @Date 2022/5/20
* @Version V1.0
**/
public interface DepartmentMapper {
List<DepartmentPO> getDeptListByCompId(@Param("parentComp") Integer parentComp);
2022-05-20 15:00:03 +08:00
2022-05-23 17:46:37 +08:00
List<DepartmentPO> getDeptListByPId(@Param("PId") Long PId);
2022-05-20 15:00:03 +08:00
2022-05-27 18:05:15 +08:00
int countChildByPID(@Param("pid") Long pid);
/**
* 查询所有数据
*
* @return
*/
List<DepartmentPO> list();
2022-05-23 17:46:37 +08:00
/**
2022-05-27 18:05:15 +08:00
* 根据No查询数据
2022-05-23 17:46:37 +08:00
*
2022-05-27 18:05:15 +08:00
* @param deptNo
2022-05-23 17:46:37 +08:00
* @return
*/
2022-05-27 18:05:15 +08:00
List<DepartmentPO> listByNo(@Param("deptNo") String deptNo);
2022-05-23 17:46:37 +08:00
2022-05-27 18:05:15 +08:00
/**
* 根据搜索条件查询数据
*
* @return
*/
List<DepartmentPO> listByFilter(DepartmentPO departmentPO);
2022-05-26 10:11:02 +08:00
2022-05-23 17:46:37 +08:00
/**
2022-05-27 18:05:15 +08:00
* 浏览按钮展示数据用
2022-05-23 17:46:37 +08:00
*
* @param ids
* @return
*/
2022-05-27 18:05:15 +08:00
List<Map<String, Object>> listDeptsByIds(@Param("ids") Collection<Long> ids);
2022-05-23 17:46:37 +08:00
2022-06-20 18:31:11 +08:00
List<DepartmentPO> getDeptsByIds(@Param("ids") Collection<Long> ids);
2022-05-27 18:05:15 +08:00
/**
* 根据ID查询数据
*
* @param id
* @return
*/
DepartmentPO getDeptById(@Param("id") long id);
2022-05-23 17:46:37 +08:00
2022-05-27 18:05:15 +08:00
/**
* 根据ID查询名称
*
* @param id
* @return
*/
2022-05-23 17:46:37 +08:00
String getDeptNameById(@Param("id") int id);
2022-05-27 18:05:15 +08:00
/**
* 添加数据
*
* @param departmentPO
* @return
*/
int insertIgnoreNull(DepartmentPO departmentPO);
/**
* 更新主表内容
*
* @param departmentPO
* @return
*/
int updateBaseDept(DepartmentPO departmentPO);
/**
* 更新禁用标记
*
* @param departmentPO
* @return
*/
int updateForbiddenTagById(DepartmentPO departmentPO);
2022-06-02 15:43:19 +08:00
/**
* 批量禁用部门
*
* @param ids
* @return
*/
int forbiddenDepartmentByIds(@Param("ids") Collection<Long> ids);
2022-05-27 18:05:15 +08:00
/**
* 批量删除
*
* @param ids
*/
int deleteByIds(@Param("ids") Collection<Long> ids);
/**
* 查询所有被引用的ID
*
* @return
*/
List<String> listUsedId();
2022-05-20 15:00:03 +08:00
}