科室病种信息表

This commit is contained in:
zhangheng 2024-02-26 17:25:16 +08:00
parent a65481f7df
commit 32501a5ad2
14 changed files with 690 additions and 29 deletions

View File

@ -92,4 +92,12 @@ public class AgencyCategoryController extends BaseController {
public AjaxResult remove(@PathVariable Long[] ids) {
return toAjax(agencyCategoryService.deleteAgencyCategoryByIds(ids));
}
/**
* 查询机构类别信息列表 - 树图
*/
@GetMapping("/agencyCategoryList")
public AjaxResult agencyCategoryList() {
return AjaxResult.success(agencyCategoryService.agencyCategoryList());
}
}

View File

@ -0,0 +1,91 @@
package com.xinelu.manage.controller.departmentdiseasetype;
import com.xinelu.common.annotation.Log;
import com.xinelu.common.core.controller.BaseController;
import com.xinelu.common.core.domain.AjaxResult;
import com.xinelu.common.core.page.TableDataInfo;
import com.xinelu.common.enums.BusinessType;
import com.xinelu.common.utils.poi.ExcelUtil;
import com.xinelu.manage.domain.departmentdiseasetype.DepartmentDiseaseType;
import com.xinelu.manage.service.departmentdiseasetype.IDepartmentDiseaseTypeService;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.web.bind.annotation.*;
import javax.annotation.Resource;
import javax.servlet.http.HttpServletResponse;
import java.util.List;
/**
* 科室病种信息Controller
*
* @author xinelu
* @date 2024-02-26
*/
@RestController
@RequestMapping("/system/departmentDisease")
public class DepartmentDiseaseTypeController extends BaseController {
@Resource
private IDepartmentDiseaseTypeService departmentDiseaseTypeService;
/**
* 查询科室病种信息列表
*/
@PreAuthorize("@ss.hasPermi('system:departmentDisease:list')")
@GetMapping("/list")
public TableDataInfo list(DepartmentDiseaseType departmentDiseaseType) {
startPage();
List<DepartmentDiseaseType> list = departmentDiseaseTypeService.selectDepartmentDiseaseTypeList(departmentDiseaseType);
return getDataTable(list);
}
/**
* 导出科室病种信息列表
*/
@PreAuthorize("@ss.hasPermi('system:departmentDisease:export')")
@Log(title = "科室病种信息", businessType = BusinessType.EXPORT)
@PostMapping("/export")
public void export(HttpServletResponse response, DepartmentDiseaseType departmentDiseaseType) {
List<DepartmentDiseaseType> list = departmentDiseaseTypeService.selectDepartmentDiseaseTypeList(departmentDiseaseType);
ExcelUtil<DepartmentDiseaseType> util = new ExcelUtil<DepartmentDiseaseType>(DepartmentDiseaseType.class);
util.exportExcel(response, list, "科室病种信息数据");
}
/**
* 获取科室病种信息详细信息
*/
@PreAuthorize("@ss.hasPermi('system:departmentDisease:query')")
@GetMapping(value = "/{id}")
public AjaxResult getInfo(@PathVariable("id") Long id) {
return AjaxResult.success(departmentDiseaseTypeService.selectDepartmentDiseaseTypeById(id));
}
/**
* 新增科室病种信息
*/
@PreAuthorize("@ss.hasPermi('system:departmentDisease:add')")
@Log(title = "科室病种信息", businessType = BusinessType.INSERT)
@PostMapping
public AjaxResult add(@RequestBody DepartmentDiseaseType departmentDiseaseType) {
return toAjax(departmentDiseaseTypeService.insertDepartmentDiseaseType(departmentDiseaseType));
}
/**
* 修改科室病种信息
*/
@PreAuthorize("@ss.hasPermi('system:departmentDisease:edit')")
@Log(title = "科室病种信息", businessType = BusinessType.UPDATE)
@PutMapping
public AjaxResult edit(@RequestBody DepartmentDiseaseType departmentDiseaseType) {
return toAjax(departmentDiseaseTypeService.updateDepartmentDiseaseType(departmentDiseaseType));
}
/**
* 删除科室病种信息
*/
@PreAuthorize("@ss.hasPermi('system:departmentDisease:remove')")
@Log(title = "科室病种信息", businessType = BusinessType.DELETE)
@DeleteMapping("/{ids}")
public AjaxResult remove(@PathVariable Long[] ids) {
return toAjax(departmentDiseaseTypeService.deleteDepartmentDiseaseTypeByIds(ids));
}
}

View File

@ -11,6 +11,9 @@ import lombok.NoArgsConstructor;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import java.util.ArrayList;
import java.util.List;
/**
* 机构类别对象 agency_category
*
@ -73,6 +76,17 @@ public class AgencyCategory extends BaseEntity {
private String categoryRemark;
private List<AgencyCategory> children = new ArrayList<AgencyCategory>();
public List<AgencyCategory> getChildren() {
return children;
}
public void setChildren(List<AgencyCategory> children) {
this.children = children;
}
@Override
public String toString() {
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)

View File

@ -0,0 +1,92 @@
package com.xinelu.manage.domain.departmentdiseasetype;
import com.xinelu.common.annotation.Excel;
import com.xinelu.common.core.domain.BaseEntity;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.NoArgsConstructor;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
/**
* 科室病种信息对象 department_disease_type
*
* @author xinelu
* @date 2024-02-26
*/
@Data
@AllArgsConstructor
@NoArgsConstructor
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "科室病种信息对象", description = "department_disease_type")
public class DepartmentDiseaseType extends BaseEntity {
private static final long serialVersionUID = 1L;
/**
* 主键id
*/
private Long id;
/**
* 所属科室id
*/
@ApiModelProperty(value = "所属科室id")
@Excel(name = "所属科室id")
private Long departmentId;
/**
* 所属科室名称
*/
@ApiModelProperty(value = "所属科室名称")
@Excel(name = "所属科室名称")
private String departmentName;
/**
* 病种名称
*/
@ApiModelProperty(value = "病种名称")
@Excel(name = "病种名称")
private String diseaseTypeName;
/**
* 病种代码
*/
@ApiModelProperty(value = "病种代码")
@Excel(name = "病种代码")
private String diseaseTypeCode;
/**
* 对应诊断信息
*/
@ApiModelProperty(value = "对应诊断信息")
@Excel(name = "对应诊断信息")
private String diagnosisInfo;
/**
* 病种概述
*/
@ApiModelProperty(value = "病种概述")
@Excel(name = "病种概述")
private String diseaseTypeRemark;
@Override
public String toString() {
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
.append("id", getId())
.append("departmentId", getDepartmentId())
.append("departmentName", getDepartmentName())
.append("diseaseTypeName", getDiseaseTypeName())
.append("diseaseTypeCode", getDiseaseTypeCode())
.append("diagnosisInfo", getDiagnosisInfo())
.append("diseaseTypeRemark", getDiseaseTypeRemark())
.append("createBy", getCreateBy())
.append("createTime", getCreateTime())
.append("updateBy", getUpdateBy())
.append("updateTime", getUpdateTime())
.toString();
}
}

View File

@ -0,0 +1,62 @@
package com.xinelu.manage.mapper.departmentdiseasetype;
import com.xinelu.manage.domain.departmentdiseasetype.DepartmentDiseaseType;
import java.util.List;
/**
* 科室病种信息Mapper接口
*
* @author xinelu
* @date 2024-02-26
*/
public interface DepartmentDiseaseTypeMapper {
/**
* 查询科室病种信息
*
* @param id 科室病种信息主键
* @return 科室病种信息
*/
DepartmentDiseaseType selectDepartmentDiseaseTypeById(Long id);
/**
* 查询科室病种信息列表
*
* @param departmentDiseaseType 科室病种信息
* @return 科室病种信息集合
*/
List<DepartmentDiseaseType> selectDepartmentDiseaseTypeList(DepartmentDiseaseType departmentDiseaseType);
/**
* 新增科室病种信息
*
* @param departmentDiseaseType 科室病种信息
* @return 结果
*/
int insertDepartmentDiseaseType(DepartmentDiseaseType departmentDiseaseType);
/**
* 修改科室病种信息
*
* @param departmentDiseaseType 科室病种信息
* @return 结果
*/
int updateDepartmentDiseaseType(DepartmentDiseaseType departmentDiseaseType);
/**
* 删除科室病种信息
*
* @param id 科室病种信息主键
* @return 结果
*/
int deleteDepartmentDiseaseTypeById(Long id);
/**
* 批量删除科室病种信息
*
* @param ids 需要删除的数据主键集合
* @return 结果
*/
int deleteDepartmentDiseaseTypeByIds(Long[] ids);
}

View File

@ -102,8 +102,8 @@ public class AgencyServiceImpl implements IAgencyService {
@Override
public List<AgencyVO> agencyList() {
List<Agency> agencies = agencyMapper.selectAgencyList(null);
List<Agency> agencies1 = buildDeptTree(agencies);
return agencies1.stream().map(AgencyVO::new).collect(Collectors.toList());
List<Agency> agenciesTree = buildDeptTree(agencies);
return agenciesTree.stream().map(AgencyVO::new).collect(Collectors.toList());
}
public List<Agency> buildDeptTree(List<Agency> agencies) {

View File

@ -2,6 +2,7 @@ package com.xinelu.manage.service.agencycategory;
import com.xinelu.manage.domain.agencycategory.AgencyCategory;
import com.xinelu.manage.vo.agencycategory.AgencyCategoryVO;
import java.util.List;
@ -59,4 +60,11 @@ public interface IAgencyCategoryService {
* @return 结果
*/
int deleteAgencyCategoryById(Long id);
/**
* 查询机构类别信息列表 - 树图
*
* @return AgencyVO
*/
List<AgencyCategoryVO> agencyCategoryList();
}

View File

@ -3,14 +3,19 @@ package com.xinelu.manage.service.agencycategory.impl;
import com.xinelu.common.constant.Constants;
import com.xinelu.common.utils.DateUtils;
import com.xinelu.common.utils.SecurityUtils;
import com.xinelu.common.utils.StringUtils;
import com.xinelu.common.utils.codes.GenerateSystemCodeUtil;
import com.xinelu.manage.domain.agencycategory.AgencyCategory;
import com.xinelu.manage.mapper.agencycategory.AgencyCategoryMapper;
import com.xinelu.manage.service.agencycategory.IAgencyCategoryService;
import com.xinelu.manage.vo.agencycategory.AgencyCategoryVO;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.Iterator;
import java.util.List;
import java.util.stream.Collectors;
/**
@ -99,4 +104,65 @@ public class AgencyCategoryServiceImpl implements IAgencyCategoryService {
public int deleteAgencyCategoryById(Long id) {
return agencyCategoryMapper.deleteAgencyCategoryById(id);
}
/**
* 查询机构类别信息列表 - 树图
*
* @return AgencyCategoryVO
*/
@Override
public List<AgencyCategoryVO> agencyCategoryList() {
List<AgencyCategory> agencyCategoryList = agencyCategoryMapper.selectAgencyCategoryList(null);
List<AgencyCategory> agencyTree = buildDeptTree(agencyCategoryList);
return agencyTree.stream().map(AgencyCategoryVO::new).collect(Collectors.toList());
}
public List<AgencyCategory> buildDeptTree(List<AgencyCategory> agencyCategoryList) {
List<AgencyCategory> returnList = new ArrayList<AgencyCategory>();
List<Long> tempList = new ArrayList<Long>();
for (AgencyCategory agencyCategory : agencyCategoryList) {
tempList.add(agencyCategory.getId());
}
for (AgencyCategory agencyCategory : agencyCategoryList) {
// 如果是顶级节点, 遍历该父节点的所有子节点
if (!tempList.contains(agencyCategory.getParentCategoryId())) {
recursionFn(agencyCategoryList, agencyCategory);
returnList.add(agencyCategory);
}
}
if (returnList.isEmpty()) {
returnList = agencyCategoryList;
}
return returnList;
}
private void recursionFn(List<AgencyCategory> list, AgencyCategory t) {
// 得到子节点列表
List<AgencyCategory> childList = getChildList(list, t);
t.setChildren(childList);
for (AgencyCategory tChild : childList) {
if (hasChild(list, tChild)) {
recursionFn(list, tChild);
}
}
}
private List<AgencyCategory> getChildList(List<AgencyCategory> list, AgencyCategory t) {
List<AgencyCategory> tlist = new ArrayList<AgencyCategory>();
Iterator<AgencyCategory> it = list.iterator();
while (it.hasNext()) {
AgencyCategory n = (AgencyCategory) it.next();
if (StringUtils.isNotNull(n.getParentCategoryId()) && n.getParentCategoryId().longValue() == t.getId().longValue()) {
tlist.add(n);
}
}
return tlist;
}
/**
* 判断是否有子节点
*/
private boolean hasChild(List<AgencyCategory> list, AgencyCategory t) {
return getChildList(list, t).size() > 0;
}
}

View File

@ -0,0 +1,62 @@
package com.xinelu.manage.service.departmentdiseasetype;
import com.xinelu.manage.domain.departmentdiseasetype.DepartmentDiseaseType;
import java.util.List;
/**
* 科室病种信息Service接口
*
* @author xinelu
* @date 2024-02-26
*/
public interface IDepartmentDiseaseTypeService {
/**
* 查询科室病种信息
*
* @param id 科室病种信息主键
* @return 科室病种信息
*/
DepartmentDiseaseType selectDepartmentDiseaseTypeById(Long id);
/**
* 查询科室病种信息列表
*
* @param departmentDiseaseType 科室病种信息
* @return 科室病种信息集合
*/
List<DepartmentDiseaseType> selectDepartmentDiseaseTypeList(DepartmentDiseaseType departmentDiseaseType);
/**
* 新增科室病种信息
*
* @param departmentDiseaseType 科室病种信息
* @return 结果
*/
int insertDepartmentDiseaseType(DepartmentDiseaseType departmentDiseaseType);
/**
* 修改科室病种信息
*
* @param departmentDiseaseType 科室病种信息
* @return 结果
*/
int updateDepartmentDiseaseType(DepartmentDiseaseType departmentDiseaseType);
/**
* 批量删除科室病种信息
*
* @param ids 需要删除的科室病种信息主键集合
* @return 结果
*/
int deleteDepartmentDiseaseTypeByIds(Long[] ids);
/**
* 删除科室病种信息信息
*
* @param id 科室病种信息主键
* @return 结果
*/
int deleteDepartmentDiseaseTypeById(Long id);
}

View File

@ -0,0 +1,91 @@
package com.xinelu.manage.service.departmentdiseasetype.impl;
import com.xinelu.common.utils.DateUtils;
import com.xinelu.manage.domain.departmentdiseasetype.DepartmentDiseaseType;
import com.xinelu.manage.mapper.departmentdiseasetype.DepartmentDiseaseTypeMapper;
import com.xinelu.manage.service.departmentdiseasetype.IDepartmentDiseaseTypeService;
import org.springframework.stereotype.Service;
import javax.annotation.Resource;
import java.util.List;
/**
* 科室病种信息Service业务层处理
*
* @author xinelu
* @date 2024-02-26
*/
@Service
public class DepartmentDiseaseTypeServiceImpl implements IDepartmentDiseaseTypeService {
@Resource
private DepartmentDiseaseTypeMapper departmentDiseaseTypeMapper;
/**
* 查询科室病种信息
*
* @param id 科室病种信息主键
* @return 科室病种信息
*/
@Override
public DepartmentDiseaseType selectDepartmentDiseaseTypeById(Long id) {
return departmentDiseaseTypeMapper.selectDepartmentDiseaseTypeById(id);
}
/**
* 查询科室病种信息列表
*
* @param departmentDiseaseType 科室病种信息
* @return 科室病种信息
*/
@Override
public List<DepartmentDiseaseType> selectDepartmentDiseaseTypeList(DepartmentDiseaseType departmentDiseaseType) {
return departmentDiseaseTypeMapper.selectDepartmentDiseaseTypeList(departmentDiseaseType);
}
/**
* 新增科室病种信息
*
* @param departmentDiseaseType 科室病种信息
* @return 结果
*/
@Override
public int insertDepartmentDiseaseType(DepartmentDiseaseType departmentDiseaseType) {
departmentDiseaseType.setCreateTime(DateUtils.getNowDate());
return departmentDiseaseTypeMapper.insertDepartmentDiseaseType(departmentDiseaseType);
}
/**
* 修改科室病种信息
*
* @param departmentDiseaseType 科室病种信息
* @return 结果
*/
@Override
public int updateDepartmentDiseaseType(DepartmentDiseaseType departmentDiseaseType) {
departmentDiseaseType.setUpdateTime(DateUtils.getNowDate());
return departmentDiseaseTypeMapper.updateDepartmentDiseaseType(departmentDiseaseType);
}
/**
* 批量删除科室病种信息
*
* @param ids 需要删除的科室病种信息主键
* @return 结果
*/
@Override
public int deleteDepartmentDiseaseTypeByIds(Long[] ids) {
return departmentDiseaseTypeMapper.deleteDepartmentDiseaseTypeByIds(ids);
}
/**
* 删除科室病种信息信息
*
* @param id 科室病种信息主键
* @return 结果
*/
@Override
public int deleteDepartmentDiseaseTypeById(Long id) {
return departmentDiseaseTypeMapper.deleteDepartmentDiseaseTypeById(id);
}
}

View File

@ -1,13 +0,0 @@
package com.xinelu.manage.service.impl;
import org.springframework.stereotype.Service;
/**
* @Description 测试service实现类
* @Author 纪寒
* @Date 2024-02-18 16:37:41
* @Version 1.0
*/
@Service
public class ManageTestServiceImpl {
}

View File

@ -1,14 +0,0 @@
package com.xinelu.manage.vo;
import lombok.Data;
/**
* @Description 测试VO类
* @Author 纪寒
* @Date 2024-02-18 16:33:23
* @Version 1.0
*/
@Data
public class ManageTestVO {
private Long id;
}

View File

@ -0,0 +1,43 @@
package com.xinelu.manage.vo.agencycategory;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.xinelu.manage.domain.agencycategory.AgencyCategory;
import java.io.Serializable;
import java.util.List;
import java.util.stream.Collectors;
public class AgencyCategoryVO implements Serializable {
private static final long serialVersionUID = 1L;
/**
* 节点ID
*/
private Long id;
/**
* 节点名称
*/
private String label;
/**
* 子节点
*/
@JsonInclude(JsonInclude.Include.NON_EMPTY)
private List<AgencyCategoryVO> children;
public AgencyCategoryVO(AgencyCategory agencyCategory) {
this.id = agencyCategory.getId();
this.label = agencyCategory.getCategoryName();
this.children = agencyCategory.getChildren().stream().map(AgencyCategoryVO::new).collect(Collectors.toList());
}
public Long getId() {
return id;
}
public void setId(Long id) {
this.id = id;
}
}

View File

@ -0,0 +1,151 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.xinelu.manage.mapper.departmentdiseasetype.DepartmentDiseaseTypeMapper">
<resultMap type="DepartmentDiseaseType" id="DepartmentDiseaseTypeResult">
<result property="id" column="id"/>
<result property="departmentId" column="department_id"/>
<result property="departmentName" column="department_name"/>
<result property="diseaseTypeName" column="disease_type_name"/>
<result property="diseaseTypeCode" column="disease_type_code"/>
<result property="diagnosisInfo" column="diagnosis_info"/>
<result property="diseaseTypeRemark" column="disease_type_remark"/>
<result property="createBy" column="create_by"/>
<result property="createTime" column="create_time"/>
<result property="updateBy" column="update_by"/>
<result property="updateTime" column="update_time"/>
</resultMap>
<sql id="selectDepartmentDiseaseTypeVo">
select id, department_id, department_name, disease_type_name, disease_type_code, diagnosis_info, disease_type_remark, create_by, create_time, update_by, update_time from department_disease_type
</sql>
<select id="selectDepartmentDiseaseTypeList" parameterType="DepartmentDiseaseType" resultMap="DepartmentDiseaseTypeResult">
<include refid="selectDepartmentDiseaseTypeVo"/>
<where>
<if test="departmentId != null ">
and department_id = #{departmentId}
</if>
<if test="departmentName != null and departmentName != ''">
and department_name like concat('%', #{departmentName}, '%')
</if>
<if test="diseaseTypeName != null and diseaseTypeName != ''">
and disease_type_name like concat('%', #{diseaseTypeName}, '%')
</if>
<if test="diseaseTypeCode != null and diseaseTypeCode != ''">
and disease_type_code = #{diseaseTypeCode}
</if>
<if test="diagnosisInfo != null and diagnosisInfo != ''">
and diagnosis_info = #{diagnosisInfo}
</if>
<if test="diseaseTypeRemark != null and diseaseTypeRemark != ''">
and disease_type_remark = #{diseaseTypeRemark}
</if>
</where>
</select>
<select id="selectDepartmentDiseaseTypeById" parameterType="Long"
resultMap="DepartmentDiseaseTypeResult">
<include refid="selectDepartmentDiseaseTypeVo"/>
where id = #{id}
</select>
<insert id="insertDepartmentDiseaseType" parameterType="DepartmentDiseaseType" useGeneratedKeys="true"
keyProperty="id">
insert into department_disease_type
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="departmentId != null">department_id,
</if>
<if test="departmentName != null">department_name,
</if>
<if test="diseaseTypeName != null">disease_type_name,
</if>
<if test="diseaseTypeCode != null">disease_type_code,
</if>
<if test="diagnosisInfo != null">diagnosis_info,
</if>
<if test="diseaseTypeRemark != null">disease_type_remark,
</if>
<if test="createBy != null">create_by,
</if>
<if test="createTime != null">create_time,
</if>
<if test="updateBy != null">update_by,
</if>
<if test="updateTime != null">update_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="departmentId != null">#{departmentId},
</if>
<if test="departmentName != null">#{departmentName},
</if>
<if test="diseaseTypeName != null">#{diseaseTypeName},
</if>
<if test="diseaseTypeCode != null">#{diseaseTypeCode},
</if>
<if test="diagnosisInfo != null">#{diagnosisInfo},
</if>
<if test="diseaseTypeRemark != null">#{diseaseTypeRemark},
</if>
<if test="createBy != null">#{createBy},
</if>
<if test="createTime != null">#{createTime},
</if>
<if test="updateBy != null">#{updateBy},
</if>
<if test="updateTime != null">#{updateTime},
</if>
</trim>
</insert>
<update id="updateDepartmentDiseaseType" parameterType="DepartmentDiseaseType">
update department_disease_type
<trim prefix="SET" suffixOverrides=",">
<if test="departmentId != null">department_id =
#{departmentId},
</if>
<if test="departmentName != null">department_name =
#{departmentName},
</if>
<if test="diseaseTypeName != null">disease_type_name =
#{diseaseTypeName},
</if>
<if test="diseaseTypeCode != null">disease_type_code =
#{diseaseTypeCode},
</if>
<if test="diagnosisInfo != null">diagnosis_info =
#{diagnosisInfo},
</if>
<if test="diseaseTypeRemark != null">disease_type_remark =
#{diseaseTypeRemark},
</if>
<if test="createBy != null">create_by =
#{createBy},
</if>
<if test="createTime != null">create_time =
#{createTime},
</if>
<if test="updateBy != null">update_by =
#{updateBy},
</if>
<if test="updateTime != null">update_time =
#{updateTime},
</if>
</trim>
where id = #{id}
</update>
<delete id="deleteDepartmentDiseaseTypeById" parameterType="Long">
delete from department_disease_type where id = #{id}
</delete>
<delete id="deleteDepartmentDiseaseTypeByIds" parameterType="String">
delete from department_disease_type where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>
</delete>
</mapper>