Merge remote-tracking branch 'origin/master'
commit
442fb1831f
@ -1,11 +0,0 @@
|
||||
#for test only!
|
||||
#Fri Feb 02 11:11:00 CST 2024
|
||||
jco.destination.pool_capacity=true
|
||||
jco.client.lang=zh
|
||||
jco.client.ashost=192.168.0.130
|
||||
jco.client.saprouter=
|
||||
jco.client.user=MES
|
||||
jco.client.sysnr=0
|
||||
jco.destination.peak_limit=20
|
||||
jco.client.passwd=123456
|
||||
jco.client.client=800
|
@ -0,0 +1,117 @@
|
||||
package com.op.mes.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||
import com.op.common.security.utils.SecurityUtils;
|
||||
import com.op.system.api.domain.SysDictType;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.op.common.log.annotation.Log;
|
||||
import com.op.common.log.enums.BusinessType;
|
||||
import com.op.common.security.annotation.RequiresPermissions;
|
||||
import com.op.mes.domain.MesBox;
|
||||
import com.op.mes.service.IMesBoxService;
|
||||
import com.op.common.core.web.controller.BaseController;
|
||||
import com.op.common.core.web.domain.AjaxResult;
|
||||
import com.op.common.core.utils.poi.ExcelUtil;
|
||||
import com.op.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 箱体类型Controller
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/mesBox")
|
||||
public class MesBoxController extends BaseController {
|
||||
@Autowired
|
||||
private IMesBoxService mesBoxService;
|
||||
|
||||
/**
|
||||
* 查询箱体类型列表
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBox:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(MesBox mesBox) {
|
||||
startPage();
|
||||
List<MesBox> list = mesBoxService.selectMesBoxList(mesBox);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出箱体类型列表
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBox:export")
|
||||
@Log(title = "箱体类型", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, MesBox mesBox) {
|
||||
List<MesBox> list = mesBoxService.selectMesBoxList(mesBox);
|
||||
ExcelUtil<MesBox> util = new ExcelUtil<MesBox>(MesBox.class);
|
||||
util.exportExcel(response, list, "箱体类型数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取箱体类型详细信息
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBox:query")
|
||||
@GetMapping(value = "/{boxId}")
|
||||
public AjaxResult getInfo(@PathVariable("boxId") Long boxId) {
|
||||
return success(mesBoxService.selectMesBoxByBoxId(boxId));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增箱体类型
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBox:add")
|
||||
@Log(title = "箱体类型", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody MesBox mesBox) {
|
||||
if (!mesBoxService.checkBoxTypeUnique(mesBox)) {
|
||||
return error("新增箱型'" + mesBox.getBoxName() + "'失败,箱体类型已存在");
|
||||
}
|
||||
return toAjax(mesBoxService.insertMesBox(mesBox));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改箱体类型
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBox:edit")
|
||||
@Log(title = "箱体类型", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody MesBox mesBox) {
|
||||
if (!mesBoxService.checkBoxTypeUnique(mesBox)) {
|
||||
return error("修改箱型'" + mesBox.getBoxName() + "'失败,箱体类型已存在");
|
||||
}
|
||||
return toAjax(mesBoxService.updateMesBox(mesBox));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除箱体类型
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBox:remove")
|
||||
@Log(title = "箱体类型", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{boxIds}")
|
||||
public AjaxResult remove(@PathVariable Long[] boxIds) {
|
||||
return toAjax(mesBoxService.deleteMesBoxByBoxIds(boxIds));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取字典选择框列表
|
||||
*/
|
||||
@GetMapping("/optionSelect")
|
||||
@DS("#header.poolName")
|
||||
public AjaxResult optionSelect() {
|
||||
List<MesBox> boxTypes = mesBoxService.selectDictTypeAll();
|
||||
return success(boxTypes);
|
||||
}
|
||||
}
|
@ -0,0 +1,115 @@
|
||||
package com.op.mes.controller;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||
import com.op.common.core.utils.StringUtils;
|
||||
import com.op.system.api.domain.SysDictData;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.op.common.log.annotation.Log;
|
||||
import com.op.common.log.enums.BusinessType;
|
||||
import com.op.common.security.annotation.RequiresPermissions;
|
||||
import com.op.mes.domain.MesBoxDetail;
|
||||
import com.op.mes.service.IMesBoxDetailService;
|
||||
import com.op.common.core.web.controller.BaseController;
|
||||
import com.op.common.core.web.domain.AjaxResult;
|
||||
import com.op.common.core.utils.poi.ExcelUtil;
|
||||
import com.op.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 箱体数据Controller
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/mesBoxDetail")
|
||||
public class MesBoxDetailController extends BaseController {
|
||||
@Autowired
|
||||
private IMesBoxDetailService mesBoxDetailService;
|
||||
|
||||
/**
|
||||
* 查询箱体数据列表
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBoxDetail:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(MesBoxDetail mesBoxDetail) {
|
||||
startPage();
|
||||
List<MesBoxDetail> list = mesBoxDetailService.selectMesBoxDetailList(mesBoxDetail);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出箱体数据列表
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBoxDetail:export")
|
||||
@Log(title = "箱体数据", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, MesBoxDetail mesBoxDetail) {
|
||||
List<MesBoxDetail> list = mesBoxDetailService.selectMesBoxDetailList(mesBoxDetail);
|
||||
ExcelUtil<MesBoxDetail> util = new ExcelUtil<MesBoxDetail>(MesBoxDetail. class);
|
||||
util.exportExcel(response, list, "箱体数据数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取箱体数据详细信息
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBoxDetail:query")
|
||||
@GetMapping(value = "/{boxCode}")
|
||||
public AjaxResult getInfo(@PathVariable("boxCode") Long boxCode) {
|
||||
return success(mesBoxDetailService.selectMesBoxDetailByBoxCode(boxCode));
|
||||
}
|
||||
|
||||
/**
|
||||
* 根据箱体类型查询箱体数据信息
|
||||
*/
|
||||
@GetMapping(value = "/type/{boxType}")
|
||||
@DS("#header.poolName")
|
||||
public AjaxResult dictType(@PathVariable String boxType) {
|
||||
List<SysDictData> data = mesBoxDetailService.selectBoxDataByType(boxType);
|
||||
if (StringUtils.isNull(data)) {
|
||||
data = new ArrayList<SysDictData>();
|
||||
}
|
||||
return success(data);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增箱体数据
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBoxDetail:add")
|
||||
@Log(title = "箱体数据", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody MesBoxDetail mesBoxDetail) {
|
||||
return toAjax(mesBoxDetailService.insertMesBoxDetail(mesBoxDetail));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改箱体数据
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBoxDetail:edit")
|
||||
@Log(title = "箱体数据", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody MesBoxDetail mesBoxDetail) {
|
||||
return toAjax(mesBoxDetailService.updateMesBoxDetail(mesBoxDetail));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除箱体数据
|
||||
*/
|
||||
@RequiresPermissions("mes:mesBoxDetail:remove")
|
||||
@Log(title = "箱体数据", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{boxCodes}")
|
||||
public AjaxResult remove(@PathVariable Long[] boxCodes) {
|
||||
return toAjax(mesBoxDetailService.deleteMesBoxDetailByBoxCodes(boxCodes));
|
||||
}
|
||||
}
|
@ -0,0 +1,61 @@
|
||||
package com.op.mes.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.op.mes.domain.MesBoxDetail;
|
||||
|
||||
/**
|
||||
* 字典数据Mapper接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
public interface MesBoxDetailMapper {
|
||||
/**
|
||||
* 查询字典数据
|
||||
*
|
||||
* @param boxCode 字典数据主键
|
||||
* @return 字典数据
|
||||
*/
|
||||
public MesBoxDetail selectMesBoxDetailByBoxCode(Long boxCode);
|
||||
|
||||
/**
|
||||
* 查询字典数据列表
|
||||
*
|
||||
* @param mesBoxDetail 字典数据
|
||||
* @return 字典数据集合
|
||||
*/
|
||||
public List<MesBoxDetail> selectMesBoxDetailList(MesBoxDetail mesBoxDetail);
|
||||
|
||||
/**
|
||||
* 新增字典数据
|
||||
*
|
||||
* @param mesBoxDetail 字典数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMesBoxDetail(MesBoxDetail mesBoxDetail);
|
||||
|
||||
/**
|
||||
* 修改字典数据
|
||||
*
|
||||
* @param mesBoxDetail 字典数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMesBoxDetail(MesBoxDetail mesBoxDetail);
|
||||
|
||||
/**
|
||||
* 删除字典数据
|
||||
*
|
||||
* @param boxCode 字典数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMesBoxDetailByBoxCode(Long boxCode);
|
||||
|
||||
/**
|
||||
* 批量删除字典数据
|
||||
*
|
||||
* @param boxCodes 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMesBoxDetailByBoxCodes(Long[] boxCodes);
|
||||
}
|
@ -0,0 +1,67 @@
|
||||
package com.op.mes.mapper;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.op.mes.domain.MesBox;
|
||||
|
||||
/**
|
||||
* 箱体类型Mapper接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
public interface MesBoxMapper {
|
||||
/**
|
||||
* 查询箱体类型
|
||||
*
|
||||
* @param boxId 箱体类型主键
|
||||
* @return 箱体类型
|
||||
*/
|
||||
public MesBox selectMesBoxByBoxId(Long boxId);
|
||||
|
||||
/**
|
||||
* 查询箱体类型列表
|
||||
*
|
||||
* @param mesBox 箱体类型
|
||||
* @return 箱体类型集合
|
||||
*/
|
||||
public List<MesBox> selectMesBoxList(MesBox mesBox);
|
||||
|
||||
/**
|
||||
* 新增箱体类型
|
||||
*
|
||||
* @param mesBox 箱体类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMesBox(MesBox mesBox);
|
||||
|
||||
/**
|
||||
* 修改箱体类型
|
||||
*
|
||||
* @param mesBox 箱体类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMesBox(MesBox mesBox);
|
||||
|
||||
/**
|
||||
* 删除箱体类型
|
||||
*
|
||||
* @param boxId 箱体类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMesBoxByBoxId(Long boxId);
|
||||
|
||||
/**
|
||||
* 批量删除箱体类型
|
||||
*
|
||||
* @param boxIds 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMesBoxByBoxIds(Long[] boxIds);
|
||||
|
||||
List<MesBox> selectDictTypeAll();
|
||||
|
||||
MesBox checkBoxTypeUnique(String boxType);
|
||||
|
||||
int countBoxDataByType(String boxType);
|
||||
}
|
@ -0,0 +1,64 @@
|
||||
package com.op.mes.service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.op.mes.domain.MesBoxDetail;
|
||||
import com.op.system.api.domain.SysDictData;
|
||||
|
||||
/**
|
||||
* 字典数据Service接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
public interface IMesBoxDetailService {
|
||||
/**
|
||||
* 查询字典数据
|
||||
*
|
||||
* @param boxCode 字典数据主键
|
||||
* @return 字典数据
|
||||
*/
|
||||
public MesBoxDetail selectMesBoxDetailByBoxCode(Long boxCode);
|
||||
|
||||
/**
|
||||
* 查询字典数据列表
|
||||
*
|
||||
* @param mesBoxDetail 字典数据
|
||||
* @return 字典数据集合
|
||||
*/
|
||||
public List<MesBoxDetail> selectMesBoxDetailList(MesBoxDetail mesBoxDetail);
|
||||
|
||||
/**
|
||||
* 新增字典数据
|
||||
*
|
||||
* @param mesBoxDetail 字典数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMesBoxDetail(MesBoxDetail mesBoxDetail);
|
||||
|
||||
/**
|
||||
* 修改字典数据
|
||||
*
|
||||
* @param mesBoxDetail 字典数据
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMesBoxDetail(MesBoxDetail mesBoxDetail);
|
||||
|
||||
/**
|
||||
* 批量删除字典数据
|
||||
*
|
||||
* @param boxCodes 需要删除的字典数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMesBoxDetailByBoxCodes(Long[] boxCodes);
|
||||
|
||||
/**
|
||||
* 删除字典数据信息
|
||||
*
|
||||
* @param boxCode 字典数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMesBoxDetailByBoxCode(Long boxCode);
|
||||
|
||||
List<SysDictData> selectBoxDataByType(String boxType);
|
||||
}
|
@ -0,0 +1,65 @@
|
||||
package com.op.mes.service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.op.mes.domain.MesBox;
|
||||
|
||||
/**
|
||||
* 箱体类型Service接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
public interface IMesBoxService {
|
||||
/**
|
||||
* 查询箱体类型
|
||||
*
|
||||
* @param boxId 箱体类型主键
|
||||
* @return 箱体类型
|
||||
*/
|
||||
public MesBox selectMesBoxByBoxId(Long boxId);
|
||||
|
||||
/**
|
||||
* 查询箱体类型列表
|
||||
*
|
||||
* @param mesBox 箱体类型
|
||||
* @return 箱体类型集合
|
||||
*/
|
||||
public List<MesBox> selectMesBoxList(MesBox mesBox);
|
||||
|
||||
/**
|
||||
* 新增箱体类型
|
||||
*
|
||||
* @param mesBox 箱体类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertMesBox(MesBox mesBox);
|
||||
|
||||
/**
|
||||
* 修改箱体类型
|
||||
*
|
||||
* @param mesBox 箱体类型
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateMesBox(MesBox mesBox);
|
||||
|
||||
/**
|
||||
* 批量删除箱体类型
|
||||
*
|
||||
* @param boxIds 需要删除的箱体类型主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMesBoxByBoxIds(Long[] boxIds);
|
||||
|
||||
/**
|
||||
* 删除箱体类型信息
|
||||
*
|
||||
* @param boxId 箱体类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteMesBoxByBoxId(Long boxId);
|
||||
|
||||
List<MesBox> selectDictTypeAll();
|
||||
|
||||
boolean checkBoxTypeUnique(MesBox mesBox);
|
||||
}
|
@ -0,0 +1,106 @@
|
||||
package com.op.mes.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||
import com.op.common.core.utils.DateUtils;
|
||||
import com.op.common.security.utils.SecurityUtils;
|
||||
import com.op.system.api.domain.SysDictData;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.op.mes.mapper.MesBoxDetailMapper;
|
||||
import com.op.mes.domain.MesBoxDetail;
|
||||
import com.op.mes.service.IMesBoxDetailService;
|
||||
|
||||
/**
|
||||
* 字典数据Service业务层处理
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
@Service
|
||||
public class MesBoxDetailServiceImpl implements IMesBoxDetailService {
|
||||
@Autowired
|
||||
private MesBoxDetailMapper mesBoxDetailMapper;
|
||||
|
||||
/**
|
||||
* 查询字典数据
|
||||
*
|
||||
* @param boxCode 字典数据主键
|
||||
* @return 字典数据
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public MesBoxDetail selectMesBoxDetailByBoxCode(Long boxCode) {
|
||||
return mesBoxDetailMapper.selectMesBoxDetailByBoxCode(boxCode);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询字典数据列表
|
||||
*
|
||||
* @param mesBoxDetail 字典数据
|
||||
* @return 字典数据
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public List<MesBoxDetail> selectMesBoxDetailList(MesBoxDetail mesBoxDetail) {
|
||||
return mesBoxDetailMapper.selectMesBoxDetailList(mesBoxDetail);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增字典数据
|
||||
*
|
||||
* @param mesBoxDetail 字典数据
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int insertMesBoxDetail(MesBoxDetail mesBoxDetail) {
|
||||
mesBoxDetail.setCreateBy(SecurityUtils.getUsername());
|
||||
mesBoxDetail.setCreateTime(DateUtils.getNowDate());
|
||||
return mesBoxDetailMapper.insertMesBoxDetail(mesBoxDetail);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改字典数据
|
||||
*
|
||||
* @param mesBoxDetail 字典数据
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int updateMesBoxDetail(MesBoxDetail mesBoxDetail) {
|
||||
mesBoxDetail.setUpdateBy(SecurityUtils.getUsername());
|
||||
mesBoxDetail.setUpdateTime(DateUtils.getNowDate());
|
||||
return mesBoxDetailMapper.updateMesBoxDetail(mesBoxDetail);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除字典数据
|
||||
*
|
||||
* @param boxCodes 需要删除的字典数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteMesBoxDetailByBoxCodes(Long[] boxCodes) {
|
||||
return mesBoxDetailMapper.deleteMesBoxDetailByBoxCodes(boxCodes);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除字典数据信息
|
||||
*
|
||||
* @param boxCode 字典数据主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteMesBoxDetailByBoxCode(Long boxCode) {
|
||||
return mesBoxDetailMapper.deleteMesBoxDetailByBoxCode(boxCode);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SysDictData> selectBoxDataByType(String boxType) {
|
||||
return null;
|
||||
}
|
||||
}
|
@ -0,0 +1,131 @@
|
||||
package com.op.mes.service.impl;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||
import com.op.common.core.constant.UserConstants;
|
||||
import com.op.common.core.exception.ServiceException;
|
||||
import com.op.common.core.utils.DateUtils;
|
||||
import com.op.common.core.utils.StringUtils;
|
||||
import com.op.common.security.utils.DictUtils;
|
||||
import com.op.common.security.utils.SecurityUtils;
|
||||
import com.op.system.api.domain.SysDictType;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.op.mes.mapper.MesBoxMapper;
|
||||
import com.op.mes.domain.MesBox;
|
||||
import com.op.mes.service.IMesBoxService;
|
||||
|
||||
/**
|
||||
* 箱体类型Service业务层处理
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
@Service
|
||||
public class MesBoxServiceImpl implements IMesBoxService {
|
||||
@Autowired
|
||||
private MesBoxMapper mesBoxMapper;
|
||||
|
||||
/**
|
||||
* 查询箱体类型
|
||||
*
|
||||
* @param boxId 箱体类型主键
|
||||
* @return 箱体类型
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public MesBox selectMesBoxByBoxId(Long boxId) {
|
||||
return mesBoxMapper.selectMesBoxByBoxId(boxId);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询箱体类型列表
|
||||
*
|
||||
* @param mesBox 箱体类型
|
||||
* @return 箱体类型
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public List<MesBox> selectMesBoxList(MesBox mesBox) {
|
||||
return mesBoxMapper.selectMesBoxList(mesBox);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增箱体类型
|
||||
*
|
||||
* @param mesBox 箱体类型
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int insertMesBox(MesBox mesBox) {
|
||||
mesBox.setCreateBy(SecurityUtils.getUsername());
|
||||
mesBox.setCreateTime(DateUtils.getNowDate());
|
||||
return mesBoxMapper.insertMesBox(mesBox);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改箱体类型
|
||||
*
|
||||
* @param mesBox 箱体类型
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int updateMesBox(MesBox mesBox) {
|
||||
mesBox.setUpdateBy(SecurityUtils.getUsername());
|
||||
mesBox.setUpdateTime(DateUtils.getNowDate());
|
||||
return mesBoxMapper.updateMesBox(mesBox);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除箱体类型
|
||||
*
|
||||
* @param boxIds 需要删除的箱体类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteMesBoxByBoxIds(Long[] boxIds) {
|
||||
int n = 0;
|
||||
for (Long boxId : boxIds) {
|
||||
MesBox boxType = selectMesBoxByBoxId(boxId);
|
||||
if (mesBoxMapper.countBoxDataByType(boxType.getBoxType()) > 0) {
|
||||
throw new ServiceException(String.format("%1$s已分配,不能删除", boxType.getBoxName()));
|
||||
}
|
||||
n += mesBoxMapper.deleteMesBoxByBoxIds(boxIds);
|
||||
}
|
||||
return n;
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除箱体类型信息
|
||||
*
|
||||
* @param boxId 箱体类型主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteMesBoxByBoxId(Long boxId) {
|
||||
return mesBoxMapper.deleteMesBoxByBoxId(boxId);
|
||||
}
|
||||
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public List<MesBox> selectDictTypeAll() {
|
||||
return mesBoxMapper.selectDictTypeAll();
|
||||
}
|
||||
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public boolean checkBoxTypeUnique(MesBox mesBox) {
|
||||
Long boxId = StringUtils.isNull(mesBox.getBoxId()) ? -1L : mesBox.getBoxId();
|
||||
MesBox boxType = mesBoxMapper.checkBoxTypeUnique(mesBox.getBoxType());
|
||||
if (StringUtils.isNotNull(boxType) && boxType.getBoxId().longValue() != boxId.longValue()) {
|
||||
return UserConstants.NOT_UNIQUE;
|
||||
}
|
||||
return UserConstants.UNIQUE;
|
||||
}
|
||||
}
|
@ -0,0 +1,225 @@
|
||||
<?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.op.mes.mapper.MesBoxDetailMapper">
|
||||
|
||||
<resultMap type="MesBoxDetail" id="MesBoxDetailResult">
|
||||
<result property="boxCode" column="box_code"/>
|
||||
<result property="boxSort" column="box_sort"/>
|
||||
<result property="boxLabel" column="box_label"/>
|
||||
<result property="boxKey" column="box_key"/>
|
||||
<result property="boxValue" column="box_value"/>
|
||||
<result property="boxType" column="box_type"/>
|
||||
<result property="cssClass" column="css_class"/>
|
||||
<result property="listClass" column="list_class"/>
|
||||
<result property="isDefault" column="is_default"/>
|
||||
<result property="status" column="status"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
<result property="length" column="length"/>
|
||||
<result property="width" column="width"/>
|
||||
<result property="height" column="height"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectMesBoxDetailVo">
|
||||
select box_code, box_sort, box_label, box_key,
|
||||
box_value, box_type, css_class, list_class,
|
||||
is_default, status, create_by, create_time,
|
||||
update_by, update_time, remark,
|
||||
length, width, height from mes_box_detail
|
||||
</sql>
|
||||
|
||||
<select id="selectMesBoxDetailList" parameterType="MesBoxDetail" resultMap="MesBoxDetailResult">
|
||||
<include refid="selectMesBoxDetailVo"/>
|
||||
<where>
|
||||
del_flag = '0'
|
||||
<if test="boxSort != null ">
|
||||
and box_sort = #{boxSort}
|
||||
</if>
|
||||
<if test="boxLabel != null and boxLabel != ''">
|
||||
and box_label = #{boxLabel}
|
||||
</if>
|
||||
<if test="boxKey != null and boxKey != ''">
|
||||
and box_key = #{boxKey}
|
||||
</if>
|
||||
<if test="boxValue != null and boxValue != ''">
|
||||
and box_value = #{boxValue}
|
||||
</if>
|
||||
<if test="boxType != null and boxType != ''">
|
||||
and box_type = #{boxType}
|
||||
</if>
|
||||
<if test="cssClass != null and cssClass != ''">
|
||||
and css_class = #{cssClass}
|
||||
</if>
|
||||
<if test="listClass != null and listClass != ''">
|
||||
and list_class = #{listClass}
|
||||
</if>
|
||||
<if test="isDefault != null and isDefault != ''">
|
||||
and is_default = #{isDefault}
|
||||
</if>
|
||||
<if test="status != null and status != ''">
|
||||
and status = #{status}
|
||||
</if>
|
||||
</where>
|
||||
order by box_sort
|
||||
</select>
|
||||
|
||||
<select id="selectMesBoxDetailByBoxCode" parameterType="Long"
|
||||
resultMap="MesBoxDetailResult">
|
||||
<include refid="selectMesBoxDetailVo"/>
|
||||
where box_code = #{boxCode}
|
||||
</select>
|
||||
|
||||
<insert id="insertMesBoxDetail" parameterType="MesBoxDetail">
|
||||
insert into mes_box_detail
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="boxCode != null">box_code,
|
||||
</if>
|
||||
<if test="boxSort != null">box_sort,
|
||||
</if>
|
||||
<if test="boxLabel != null">box_label,
|
||||
</if>
|
||||
<if test="boxKey != null">box_key,
|
||||
</if>
|
||||
<if test="boxValue != null">box_value,
|
||||
</if>
|
||||
<if test="boxType != null">box_type,
|
||||
</if>
|
||||
<if test="cssClass != null">css_class,
|
||||
</if>
|
||||
<if test="listClass != null">list_class,
|
||||
</if>
|
||||
<if test="isDefault != null">is_default,
|
||||
</if>
|
||||
<if test="status != null">status,
|
||||
</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>
|
||||
<if test="remark != null">remark,
|
||||
</if>
|
||||
<if test="length != null">length,
|
||||
</if>
|
||||
<if test="width != null">width,
|
||||
</if>
|
||||
<if test="height != null">height,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="boxCode != null">#{boxCode},
|
||||
</if>
|
||||
<if test="boxSort != null">#{boxSort},
|
||||
</if>
|
||||
<if test="boxLabel != null">#{boxLabel},
|
||||
</if>
|
||||
<if test="boxKey != null">#{boxKey},
|
||||
</if>
|
||||
<if test="boxValue != null">#{boxValue},
|
||||
</if>
|
||||
<if test="boxType != null">#{boxType},
|
||||
</if>
|
||||
<if test="cssClass != null">#{cssClass},
|
||||
</if>
|
||||
<if test="listClass != null">#{listClass},
|
||||
</if>
|
||||
<if test="isDefault != null">#{isDefault},
|
||||
</if>
|
||||
<if test="status != null">#{status},
|
||||
</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>
|
||||
<if test="remark != null">#{remark},
|
||||
</if>
|
||||
<if test="length != null">#{length},
|
||||
</if>
|
||||
<if test="width != null">#{width},
|
||||
</if>
|
||||
<if test="height != null">#{height},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateMesBoxDetail" parameterType="MesBoxDetail">
|
||||
update mes_box_detail
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="boxSort != null">box_sort =
|
||||
#{boxSort},
|
||||
</if>
|
||||
<if test="boxLabel != null">box_label =
|
||||
#{boxLabel},
|
||||
</if>
|
||||
<if test="boxKey != null">box_key =
|
||||
#{boxKey},
|
||||
</if>
|
||||
<if test="boxValue != null">box_value =
|
||||
#{boxValue},
|
||||
</if>
|
||||
<if test="boxType != null">box_type =
|
||||
#{boxType},
|
||||
</if>
|
||||
<if test="cssClass != null">css_class =
|
||||
#{cssClass},
|
||||
</if>
|
||||
<if test="listClass != null">list_class =
|
||||
#{listClass},
|
||||
</if>
|
||||
<if test="isDefault != null">is_default =
|
||||
#{isDefault},
|
||||
</if>
|
||||
<if test="status != null">status =
|
||||
#{status},
|
||||
</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>
|
||||
<if test="remark != null">remark =
|
||||
#{remark},
|
||||
</if>
|
||||
<if test="length != null">length =
|
||||
#{length},
|
||||
</if>
|
||||
<if test="width != null">width =
|
||||
#{width},
|
||||
</if>
|
||||
<if test="height != null">height =
|
||||
#{height},
|
||||
</if>
|
||||
</trim>
|
||||
where box_code = #{boxCode}
|
||||
</update>
|
||||
|
||||
<delete id="deleteMesBoxDetailByBoxCode" parameterType="Long">
|
||||
update mes_box_detail set del_flag = '1' where box_code = #{boxCode}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteMesBoxDetailByBoxCodes" parameterType="String">
|
||||
update mes_box_detail set del_flag = '1' where box_code in
|
||||
<foreach item="boxCode" collection="array" open="(" separator="," close=")">
|
||||
#{boxCode}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
@ -0,0 +1,144 @@
|
||||
<?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.op.mes.mapper.MesBoxMapper">
|
||||
|
||||
<resultMap type="MesBox" id="MesBoxResult">
|
||||
<result property="boxId" column="box_id"/>
|
||||
<result property="boxName" column="box_name"/>
|
||||
<result property="boxType" column="box_type"/>
|
||||
<result property="status" column="status"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="remark" column="remark"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectMesBoxVo">
|
||||
select box_id, box_name, box_type, status, create_by, create_time, update_by, update_time, remark from mes_box
|
||||
</sql>
|
||||
|
||||
<select id="selectMesBoxList" parameterType="MesBox" resultMap="MesBoxResult">
|
||||
<include refid="selectMesBoxVo"/>
|
||||
<where>
|
||||
del_flag = '0'
|
||||
<if test="boxName != null and boxName != ''">
|
||||
and box_name like concat('%', #{boxName}, '%')
|
||||
</if>
|
||||
<if test="boxType != null and boxType != ''">
|
||||
and box_type = #{boxType}
|
||||
</if>
|
||||
<if test="status != null and status != ''">
|
||||
and status = #{status}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectMesBoxByBoxId" parameterType="Long"
|
||||
resultMap="MesBoxResult">
|
||||
<include refid="selectMesBoxVo"/>
|
||||
where box_id = #{boxId} and del_flag = '0'
|
||||
</select>
|
||||
|
||||
<insert id="insertMesBox" parameterType="MesBox">
|
||||
insert into mes_box
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="boxId != null">box_id,
|
||||
</if>
|
||||
<if test="boxName != null">box_name,
|
||||
</if>
|
||||
<if test="boxType != null">box_type,
|
||||
</if>
|
||||
<if test="status != null">status,
|
||||
</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>
|
||||
<if test="remark != null">remark,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="boxId != null">#{boxId},
|
||||
</if>
|
||||
<if test="boxName != null">#{boxName},
|
||||
</if>
|
||||
<if test="boxType != null">#{boxType},
|
||||
</if>
|
||||
<if test="status != null">#{status},
|
||||
</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>
|
||||
<if test="remark != null">#{remark},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateMesBox" parameterType="MesBox">
|
||||
update mes_box
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="boxName != null">box_name =
|
||||
#{boxName},
|
||||
</if>
|
||||
<if test="boxType != null">box_type =
|
||||
#{boxType},
|
||||
</if>
|
||||
<if test="status != null">status =
|
||||
#{status},
|
||||
</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>
|
||||
<if test="remark != null">remark =
|
||||
#{remark},
|
||||
</if>
|
||||
</trim>
|
||||
where box_id = #{boxId}
|
||||
</update>
|
||||
|
||||
<select id="selectDictTypeAll" resultMap="MesBoxResult">
|
||||
<include refid="selectMesBoxVo"/>
|
||||
</select>
|
||||
|
||||
<select id="countBoxDataByType" resultType="Integer">
|
||||
select count(1) from mes_box_detail where box_type=#{boxType}
|
||||
</select>
|
||||
|
||||
<delete id="deleteMesBoxByBoxId" parameterType="Long">
|
||||
update mes_box set del_flag = '1' where box_id = #{boxId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteMesBoxByBoxIds" parameterType="String">
|
||||
update mes_box set del_flag = '1' where box_id in
|
||||
<foreach item="boxId" collection="array" open="(" separator="," close=")">
|
||||
#{boxId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<select id="checkBoxTypeUnique" parameterType="String" resultMap="MesBoxResult">
|
||||
select top 1 box_id, box_name, box_type, status, create_by, create_time, remark
|
||||
from mes_box
|
||||
where box_type = #{boxType}
|
||||
</select>
|
||||
</mapper>
|
@ -0,0 +1,114 @@
|
||||
package com.op.quality.controller;
|
||||
|
||||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||
import com.op.common.core.utils.poi.ExcelUtil;
|
||||
import com.op.quality.domain.QcDefectTypeClass;
|
||||
import com.op.quality.service.IQcDefectTypeClassService;
|
||||
import com.op.system.api.domain.SysDictData;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.PutMapping;
|
||||
import org.springframework.web.bind.annotation.DeleteMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import com.op.common.log.annotation.Log;
|
||||
import com.op.common.log.enums.BusinessType;
|
||||
import com.op.common.security.annotation.RequiresPermissions;
|
||||
import com.op.common.core.web.controller.BaseController;
|
||||
import com.op.common.core.web.domain.AjaxResult;
|
||||
import com.op.common.core.web.page.TableDataInfo;
|
||||
|
||||
/**
|
||||
* 故障类型-缺陷描述分类Controller
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/defectClass")
|
||||
public class QcDefectTypeClassController extends BaseController {
|
||||
@Autowired
|
||||
private IQcDefectTypeClassService qcDefectTypeClassService;
|
||||
|
||||
/**
|
||||
* 查询故障类型-缺陷描述分类列表
|
||||
*/
|
||||
@RequiresPermissions("system:class:list")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(QcDefectTypeClass qcDefectTypeClass) {
|
||||
startPage();
|
||||
List<QcDefectTypeClass> list = qcDefectTypeClassService.selectQcDefectTypeClassList(qcDefectTypeClass);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出故障类型-缺陷描述分类列表
|
||||
*/
|
||||
@RequiresPermissions("system:class:export")
|
||||
@Log(title = "故障类型-缺陷描述分类", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, QcDefectTypeClass qcDefectTypeClass) {
|
||||
List<QcDefectTypeClass> list = qcDefectTypeClassService.selectQcDefectTypeClassList(qcDefectTypeClass);
|
||||
ExcelUtil<QcDefectTypeClass> util = new ExcelUtil<QcDefectTypeClass>(QcDefectTypeClass. class);
|
||||
util.exportExcel(response, list, "故障类型-缺陷描述分类数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取故障类型-缺陷描述分类详细信息
|
||||
*/
|
||||
@RequiresPermissions("system:class:query")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") String id) {
|
||||
return success(qcDefectTypeClassService.selectQcDefectTypeClassById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增故障类型-缺陷描述分类
|
||||
*/
|
||||
@RequiresPermissions("system:class:add")
|
||||
@Log(title = "故障类型-缺陷描述分类", businessType = BusinessType.INSERT)
|
||||
@PostMapping
|
||||
public AjaxResult add(@RequestBody QcDefectTypeClass qcDefectTypeClass) {
|
||||
return toAjax(qcDefectTypeClassService.insertQcDefectTypeClass(qcDefectTypeClass));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改故障类型-缺陷描述分类
|
||||
*/
|
||||
@RequiresPermissions("system:class:edit")
|
||||
@Log(title = "故障类型-缺陷描述分类", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody QcDefectTypeClass qcDefectTypeClass) {
|
||||
return toAjax(qcDefectTypeClassService.updateQcDefectTypeClass(qcDefectTypeClass));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除故障类型-缺陷描述分类
|
||||
*/
|
||||
@RequiresPermissions("system:class:remove")
|
||||
@Log(title = "故障类型-缺陷描述分类", businessType = BusinessType.DELETE)
|
||||
@DeleteMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable String[] ids) {
|
||||
return toAjax(qcDefectTypeClassService.deleteQcDefectTypeClassByIds(ids));
|
||||
}
|
||||
|
||||
@GetMapping("/getClassInfoList")
|
||||
@DS("#header.poolName")
|
||||
public AjaxResult getClassInfoList(QcDefectTypeClass qcDefectTypeClass) {
|
||||
List<QcDefectTypeClass> list = qcDefectTypeClassService.getClassInfoList(qcDefectTypeClass);
|
||||
return success(list);
|
||||
}
|
||||
|
||||
@GetMapping("/getClassInfoListByCheckType")
|
||||
@DS("#header.poolName")
|
||||
public AjaxResult getClassInfoListByCheckType(QcDefectTypeClass qcDefectTypeClass) {
|
||||
List<QcDefectTypeClass> list = qcDefectTypeClassService.getClassInfoListByCheckType(qcDefectTypeClass);
|
||||
return success(list);
|
||||
}
|
||||
}
|
@ -0,0 +1,152 @@
|
||||
package com.op.quality.domain;
|
||||
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
import com.op.common.core.annotation.Excel;
|
||||
import com.op.common.core.web.domain.BaseEntity;
|
||||
|
||||
/**
|
||||
* 故障类型-缺陷描述分类对象 qc_defect_type_class
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
public class QcDefectTypeClass extends BaseEntity {
|
||||
private static final long serialVersionUID=1L;
|
||||
|
||||
/** 主键 */
|
||||
private String id;
|
||||
|
||||
/** 不良类型id */
|
||||
@Excel(name = "不良类型id")
|
||||
private String defectId;
|
||||
|
||||
/** 不良类型编码 */
|
||||
@Excel(name = "不良类型编码")
|
||||
private String defectCode;
|
||||
|
||||
/** 缺陷名称 */
|
||||
@Excel(name = "缺陷名称")
|
||||
private String className;
|
||||
|
||||
/** 工厂编码 */
|
||||
@Excel(name = "工厂编码")
|
||||
private String factoryCode;
|
||||
|
||||
/** 备用字段1 */
|
||||
@Excel(name = "备用字段1")
|
||||
private String attr1;
|
||||
|
||||
/** 备用字段2 */
|
||||
@Excel(name = "备用字段2")
|
||||
private String attr2;
|
||||
|
||||
/** 备用字段3 */
|
||||
@Excel(name = "备用字段3")
|
||||
private String attr3;
|
||||
|
||||
/** 删除标志 */
|
||||
private String delFlag;
|
||||
private String sort;
|
||||
private String checkType;
|
||||
|
||||
public String getCheckType() {
|
||||
return checkType;
|
||||
}
|
||||
|
||||
public void setCheckType(String checkType) {
|
||||
this.checkType = checkType;
|
||||
}
|
||||
|
||||
public String getSort() {
|
||||
return sort;
|
||||
}
|
||||
|
||||
public void setSort(String sort) {
|
||||
this.sort = sort;
|
||||
}
|
||||
|
||||
public void setId(String id){
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getId(){
|
||||
return id;
|
||||
}
|
||||
public void setDefectId(String defectId){
|
||||
this.defectId = defectId;
|
||||
}
|
||||
|
||||
public String getDefectId(){
|
||||
return defectId;
|
||||
}
|
||||
public void setDefectCode(String defectCode){
|
||||
this.defectCode = defectCode;
|
||||
}
|
||||
|
||||
public String getDefectCode(){
|
||||
return defectCode;
|
||||
}
|
||||
public void setClassName(String className){
|
||||
this.className = className;
|
||||
}
|
||||
|
||||
public String getClassName(){
|
||||
return className;
|
||||
}
|
||||
public void setFactoryCode(String factoryCode){
|
||||
this.factoryCode = factoryCode;
|
||||
}
|
||||
|
||||
public String getFactoryCode(){
|
||||
return factoryCode;
|
||||
}
|
||||
public void setAttr1(String attr1){
|
||||
this.attr1 = attr1;
|
||||
}
|
||||
|
||||
public String getAttr1(){
|
||||
return attr1;
|
||||
}
|
||||
public void setAttr2(String attr2){
|
||||
this.attr2 = attr2;
|
||||
}
|
||||
|
||||
public String getAttr2(){
|
||||
return attr2;
|
||||
}
|
||||
public void setAttr3(String attr3){
|
||||
this.attr3 = attr3;
|
||||
}
|
||||
|
||||
public String getAttr3(){
|
||||
return attr3;
|
||||
}
|
||||
public void setDelFlag(String delFlag){
|
||||
this.delFlag = delFlag;
|
||||
}
|
||||
|
||||
public String getDelFlag(){
|
||||
return delFlag;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString(){
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("id",getId())
|
||||
.append("defectId",getDefectId())
|
||||
.append("defectCode",getDefectCode())
|
||||
.append("className",getClassName())
|
||||
.append("remark",getRemark())
|
||||
.append("factoryCode",getFactoryCode())
|
||||
.append("attr1",getAttr1())
|
||||
.append("attr2",getAttr2())
|
||||
.append("attr3",getAttr3())
|
||||
.append("delFlag",getDelFlag())
|
||||
.append("createBy",getCreateBy())
|
||||
.append("createTime",getCreateTime())
|
||||
.append("updateBy",getUpdateBy())
|
||||
.append("updateTime",getUpdateTime())
|
||||
.toString();
|
||||
}
|
||||
}
|
@ -0,0 +1,66 @@
|
||||
package com.op.quality.mapper;
|
||||
|
||||
import com.op.quality.domain.QcDefectTypeClass;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 故障类型-缺陷描述分类Mapper接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
public interface QcDefectTypeClassMapper {
|
||||
/**
|
||||
* 查询故障类型-缺陷描述分类
|
||||
*
|
||||
* @param id 故障类型-缺陷描述分类主键
|
||||
* @return 故障类型-缺陷描述分类
|
||||
*/
|
||||
public QcDefectTypeClass selectQcDefectTypeClassById(String id);
|
||||
|
||||
/**
|
||||
* 查询故障类型-缺陷描述分类列表
|
||||
*
|
||||
* @param qcDefectTypeClass 故障类型-缺陷描述分类
|
||||
* @return 故障类型-缺陷描述分类集合
|
||||
*/
|
||||
public List<QcDefectTypeClass> selectQcDefectTypeClassList(QcDefectTypeClass qcDefectTypeClass);
|
||||
|
||||
/**
|
||||
* 新增故障类型-缺陷描述分类
|
||||
*
|
||||
* @param qcDefectTypeClass 故障类型-缺陷描述分类
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertQcDefectTypeClass(QcDefectTypeClass qcDefectTypeClass);
|
||||
|
||||
/**
|
||||
* 修改故障类型-缺陷描述分类
|
||||
*
|
||||
* @param qcDefectTypeClass 故障类型-缺陷描述分类
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateQcDefectTypeClass(QcDefectTypeClass qcDefectTypeClass);
|
||||
|
||||
/**
|
||||
* 删除故障类型-缺陷描述分类
|
||||
*
|
||||
* @param id 故障类型-缺陷描述分类主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcDefectTypeClassById(String id);
|
||||
|
||||
/**
|
||||
* 批量删除故障类型-缺陷描述分类
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcDefectTypeClassByIds(String[] ids);
|
||||
|
||||
List<QcDefectTypeClass> getClassInfoList(QcDefectTypeClass qcDefectTypeClass);
|
||||
|
||||
List<QcDefectTypeClass> getClassInfoListByCheckType(QcDefectTypeClass qcDefectTypeClass);
|
||||
}
|
@ -0,0 +1,67 @@
|
||||
package com.op.quality.service;
|
||||
|
||||
import com.op.quality.domain.QcDefectTypeClass;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* 故障类型-缺陷描述分类Service接口
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
public interface IQcDefectTypeClassService {
|
||||
/**
|
||||
* 查询故障类型-缺陷描述分类
|
||||
*
|
||||
* @param id 故障类型-缺陷描述分类主键
|
||||
* @return 故障类型-缺陷描述分类
|
||||
*/
|
||||
public QcDefectTypeClass selectQcDefectTypeClassById(String id);
|
||||
|
||||
/**
|
||||
* 查询故障类型-缺陷描述分类列表
|
||||
*
|
||||
* @param qcDefectTypeClass 故障类型-缺陷描述分类
|
||||
* @return 故障类型-缺陷描述分类集合
|
||||
*/
|
||||
public List<QcDefectTypeClass> selectQcDefectTypeClassList(QcDefectTypeClass qcDefectTypeClass);
|
||||
|
||||
/**
|
||||
* 新增故障类型-缺陷描述分类
|
||||
*
|
||||
* @param qcDefectTypeClass 故障类型-缺陷描述分类
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertQcDefectTypeClass(QcDefectTypeClass qcDefectTypeClass);
|
||||
|
||||
/**
|
||||
* 修改故障类型-缺陷描述分类
|
||||
*
|
||||
* @param qcDefectTypeClass 故障类型-缺陷描述分类
|
||||
* @return 结果
|
||||
*/
|
||||
public int updateQcDefectTypeClass(QcDefectTypeClass qcDefectTypeClass);
|
||||
|
||||
/**
|
||||
* 批量删除故障类型-缺陷描述分类
|
||||
*
|
||||
* @param ids 需要删除的故障类型-缺陷描述分类主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcDefectTypeClassByIds(String[] ids);
|
||||
|
||||
/**
|
||||
* 删除故障类型-缺陷描述分类信息
|
||||
*
|
||||
* @param id 故障类型-缺陷描述分类主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteQcDefectTypeClassById(String id);
|
||||
|
||||
List<QcDefectTypeClass> getClassInfoList(QcDefectTypeClass qcDefectTypeClass);
|
||||
|
||||
List<QcDefectTypeClass> getClassInfoListByCheckType(QcDefectTypeClass qcDefectTypeClass);
|
||||
}
|
@ -0,0 +1,114 @@
|
||||
package com.op.quality.service.impl;
|
||||
|
||||
import java.security.Security;
|
||||
import java.util.List;
|
||||
|
||||
import com.baomidou.dynamic.datasource.annotation.DS;
|
||||
import com.op.common.core.utils.DateUtils;
|
||||
import com.op.common.core.utils.uuid.IdUtils;
|
||||
import com.op.common.security.utils.SecurityUtils;
|
||||
import com.op.quality.domain.QcDefectTypeClass;
|
||||
import com.op.quality.mapper.QcDefectTypeClassMapper;
|
||||
import com.op.quality.service.IQcDefectTypeClassService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
|
||||
/**
|
||||
* 故障类型-缺陷描述分类Service业务层处理
|
||||
*
|
||||
* @author Open Platform
|
||||
* @date 2024-08-20
|
||||
*/
|
||||
@Service
|
||||
public class QcDefectTypeClassServiceImpl implements IQcDefectTypeClassService {
|
||||
@Autowired
|
||||
private QcDefectTypeClassMapper qcDefectTypeClassMapper;
|
||||
|
||||
/**
|
||||
* 查询故障类型-缺陷描述分类
|
||||
*
|
||||
* @param id 故障类型-缺陷描述分类主键
|
||||
* @return 故障类型-缺陷描述分类
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public QcDefectTypeClass selectQcDefectTypeClassById(String id) {
|
||||
return qcDefectTypeClassMapper.selectQcDefectTypeClassById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询故障类型-缺陷描述分类列表
|
||||
*
|
||||
* @param qcDefectTypeClass 故障类型-缺陷描述分类
|
||||
* @return 故障类型-缺陷描述分类
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public List<QcDefectTypeClass> selectQcDefectTypeClassList(QcDefectTypeClass qcDefectTypeClass) {
|
||||
return qcDefectTypeClassMapper.selectQcDefectTypeClassList(qcDefectTypeClass);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增故障类型-缺陷描述分类
|
||||
*
|
||||
* @param qcDefectTypeClass 故障类型-缺陷描述分类
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int insertQcDefectTypeClass(QcDefectTypeClass qcDefectTypeClass) {
|
||||
qcDefectTypeClass.setCreateTime(DateUtils.getNowDate());
|
||||
qcDefectTypeClass.setId(IdUtils.fastSimpleUUID());
|
||||
qcDefectTypeClass.setCreateBy(SecurityUtils.getUsername());
|
||||
return qcDefectTypeClassMapper.insertQcDefectTypeClass(qcDefectTypeClass);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改故障类型-缺陷描述分类
|
||||
*
|
||||
* @param qcDefectTypeClass 故障类型-缺陷描述分类
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int updateQcDefectTypeClass(QcDefectTypeClass qcDefectTypeClass) {
|
||||
qcDefectTypeClass.setUpdateTime(DateUtils.getNowDate());
|
||||
qcDefectTypeClass.setUpdateBy(SecurityUtils.getUsername());
|
||||
return qcDefectTypeClassMapper.updateQcDefectTypeClass(qcDefectTypeClass);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除故障类型-缺陷描述分类
|
||||
*
|
||||
* @param ids 需要删除的故障类型-缺陷描述分类主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteQcDefectTypeClassByIds(String[] ids) {
|
||||
return qcDefectTypeClassMapper.deleteQcDefectTypeClassByIds(ids);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除故障类型-缺陷描述分类信息
|
||||
*
|
||||
* @param id 故障类型-缺陷描述分类主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@DS("#header.poolName")
|
||||
public int deleteQcDefectTypeClassById(String id) {
|
||||
return qcDefectTypeClassMapper.deleteQcDefectTypeClassById(id);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<QcDefectTypeClass> getClassInfoList(QcDefectTypeClass qcDefectTypeClass) {
|
||||
return qcDefectTypeClassMapper.getClassInfoList(qcDefectTypeClass);
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<QcDefectTypeClass> getClassInfoListByCheckType(QcDefectTypeClass qcDefectTypeClass) {
|
||||
return qcDefectTypeClassMapper.getClassInfoListByCheckType(qcDefectTypeClass);
|
||||
}
|
||||
}
|
@ -0,0 +1,202 @@
|
||||
<?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.op.quality.mapper.QcDefectTypeClassMapper">
|
||||
|
||||
<resultMap type="QcDefectTypeClass" id="QcDefectTypeClassResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="defectId" column="defect_id"/>
|
||||
<result property="defectCode" column="defect_code"/>
|
||||
<result property="className" column="class_name"/>
|
||||
<result property="remark" column="remark"/>
|
||||
<result property="factoryCode" column="factory_code"/>
|
||||
<result property="attr1" column="attr1"/>
|
||||
<result property="attr2" column="attr2"/>
|
||||
<result property="attr3" column="attr3"/>
|
||||
<result property="delFlag" column="del_flag"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
<result property="sort" column="sort"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectQcDefectTypeClassVo">
|
||||
select id, defect_id, defect_code, class_name, remark, factory_code, attr1,
|
||||
attr2, attr3, del_flag, create_by, create_time, update_by, update_time ,sort
|
||||
from qc_defect_type_class
|
||||
</sql>
|
||||
|
||||
<select id="selectQcDefectTypeClassList" parameterType="QcDefectTypeClass" resultMap="QcDefectTypeClassResult">
|
||||
<include refid="selectQcDefectTypeClassVo"/>
|
||||
<where>
|
||||
<if test="defectId != null and defectId != ''">
|
||||
and defect_id = #{defectId}
|
||||
</if>
|
||||
<if test="defectCode != null and defectCode != ''">
|
||||
and defect_code = #{defectCode}
|
||||
</if>
|
||||
<if test="className != null and className != ''">
|
||||
and class_name like concat('%', #{className}, '%')
|
||||
</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">
|
||||
and factory_code = #{factoryCode}
|
||||
</if>
|
||||
<if test="attr1 != null and attr1 != ''">
|
||||
and attr1 = #{attr1}
|
||||
</if>
|
||||
<if test="attr2 != null and attr2 != ''">
|
||||
and attr2 = #{attr2}
|
||||
</if>
|
||||
<if test="attr3 != null and attr3 != ''">
|
||||
and attr3 = #{attr3}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectQcDefectTypeClassById" parameterType="String"
|
||||
resultMap="QcDefectTypeClassResult">
|
||||
<include refid="selectQcDefectTypeClassVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
<select id="getClassInfoList" resultType="com.op.quality.domain.QcDefectTypeClass">
|
||||
select id,
|
||||
class_name className
|
||||
from qc_defect_type_class
|
||||
where defect_code = #{defectCode}
|
||||
and del_flag = '0'
|
||||
order by sort
|
||||
</select>
|
||||
<select id="getClassInfoListByCheckType" resultType="com.op.quality.domain.QcDefectTypeClass">
|
||||
select id,
|
||||
class_name className
|
||||
from qc_defect_type_class
|
||||
where defect_code in(select defect_code from qc_defect_type where del_flag='0' and defect_type = #{checkType})
|
||||
and del_flag = '0'
|
||||
order by sort
|
||||
</select>
|
||||
|
||||
<insert id="insertQcDefectTypeClass" parameterType="QcDefectTypeClass">
|
||||
insert into qc_defect_type_class
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">id,
|
||||
</if>
|
||||
<if test="defectId != null and defectId != ''">defect_id,
|
||||
</if>
|
||||
<if test="defectCode != null and defectCode != ''">defect_code,
|
||||
</if>
|
||||
<if test="className != null">class_name,
|
||||
</if>
|
||||
<if test="remark != null">remark,
|
||||
</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">factory_code,
|
||||
</if>
|
||||
<if test="attr1 != null">attr1,
|
||||
</if>
|
||||
<if test="attr2 != null">attr2,
|
||||
</if>
|
||||
<if test="attr3 != null">attr3,
|
||||
</if>
|
||||
<if test="delFlag != null and delFlag != ''">del_flag,
|
||||
</if>
|
||||
<if test="createBy != null and createBy != ''">create_by,
|
||||
</if>
|
||||
<if test="createTime != null">create_time,
|
||||
</if>
|
||||
<if test="updateBy != null and updateBy != ''">update_by,
|
||||
</if>
|
||||
<if test="updateTime != null">update_time,
|
||||
</if>
|
||||
<if test="sort != null">sort,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="id != null">#{id},
|
||||
</if>
|
||||
<if test="defectId != null and defectId != ''">#{defectId},
|
||||
</if>
|
||||
<if test="defectCode != null and defectCode != ''">#{defectCode},
|
||||
</if>
|
||||
<if test="className != null">#{className},
|
||||
</if>
|
||||
<if test="remark != null">#{remark},
|
||||
</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">#{factoryCode},
|
||||
</if>
|
||||
<if test="attr1 != null">#{attr1},
|
||||
</if>
|
||||
<if test="attr2 != null">#{attr2},
|
||||
</if>
|
||||
<if test="attr3 != null">#{attr3},
|
||||
</if>
|
||||
<if test="delFlag != null and delFlag != ''">#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null and createBy != ''">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null and updateBy != ''">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},</if>
|
||||
<if test="sort != null">#{sort},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateQcDefectTypeClass" parameterType="QcDefectTypeClass">
|
||||
update qc_defect_type_class
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="defectId != null and defectId != ''">defect_id =
|
||||
#{defectId},
|
||||
</if>
|
||||
<if test="defectCode != null and defectCode != ''">defect_code =
|
||||
#{defectCode},
|
||||
</if>
|
||||
<if test="className != null">class_name =
|
||||
#{className},
|
||||
</if>
|
||||
<if test="remark != null">remark =
|
||||
#{remark},
|
||||
</if>
|
||||
<if test="factoryCode != null and factoryCode != ''">factory_code =
|
||||
#{factoryCode},
|
||||
</if>
|
||||
<if test="attr1 != null">attr1 =
|
||||
#{attr1},
|
||||
</if>
|
||||
<if test="attr2 != null">attr2 =
|
||||
#{attr2},
|
||||
</if>
|
||||
<if test="attr3 != null">attr3 =
|
||||
#{attr3},
|
||||
</if>
|
||||
<if test="delFlag != null and delFlag != ''">del_flag =
|
||||
#{delFlag},
|
||||
</if>
|
||||
<if test="createBy != null and createBy != ''">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">create_time =
|
||||
#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null and updateBy != ''">update_by =
|
||||
#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">update_time =
|
||||
#{updateTime},
|
||||
</if>
|
||||
<if test="sort != null">sort = #{sort},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteQcDefectTypeClassById" parameterType="String">
|
||||
delete from qc_defect_type_class where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteQcDefectTypeClassByIds" parameterType="String">
|
||||
delete from qc_defect_type_class where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue