新增方法 更新pacs抓取数据对应项的item
This commit is contained in:
parent
3ed71a7fad
commit
7a6b710b88
@ -54,7 +54,13 @@ public class InspectPacsDataController {
|
|||||||
pacsDataService.updatePacsData(updateReqVO);
|
pacsDataService.updatePacsData(updateReqVO);
|
||||||
return success(true);
|
return success(true);
|
||||||
}
|
}
|
||||||
|
@PutMapping("/updatePacsDataitem")
|
||||||
|
@Operation(summary = "更新pacs抓取数据对应项的item")
|
||||||
|
public CommonResult<Boolean> updatePacsDataitem(@Valid @RequestBody InspectPacsDataSaveReqVO updateReqVO)
|
||||||
|
{
|
||||||
|
pacsDataService.updatePacsDataitem(updateReqVO);
|
||||||
|
return success(true);
|
||||||
|
}
|
||||||
@DeleteMapping("/delete")
|
@DeleteMapping("/delete")
|
||||||
@Operation(summary = "删除pacs抓取数据")
|
@Operation(summary = "删除pacs抓取数据")
|
||||||
@Parameter(name = "id", description = "编号", required = true)
|
@Parameter(name = "id", description = "编号", required = true)
|
||||||
|
@ -40,6 +40,10 @@ public interface InspectPacsDataService {
|
|||||||
* @param id 编号
|
* @param id 编号
|
||||||
*/
|
*/
|
||||||
void deletePacsData(Integer id);
|
void deletePacsData(Integer id);
|
||||||
|
/*
|
||||||
|
* 根据体检编号更新pacsdata表的item字段
|
||||||
|
* */
|
||||||
|
void updatePacsDataitem(InspectPacsDataSaveReqVO updateReqVO);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 获得pacs抓取数据
|
* 获得pacs抓取数据
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
package cn.iocoder.yudao.module.inspect.service.inspectpacsdata;
|
package cn.iocoder.yudao.module.inspect.service.inspectpacsdata;
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import org.springframework.validation.annotation.Validated;
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
|
||||||
@ -61,7 +62,15 @@ public class InspectPacsDataServiceImpl implements InspectPacsDataService {
|
|||||||
// 删除
|
// 删除
|
||||||
pacsDataMapper.deleteById(id);
|
pacsDataMapper.deleteById(id);
|
||||||
}
|
}
|
||||||
|
@Override
|
||||||
|
public void updatePacsDataitem(InspectPacsDataSaveReqVO updateReqVO)
|
||||||
|
{
|
||||||
|
LambdaUpdateWrapper<InspectPacsDataDO> updateWrapper = new LambdaUpdateWrapper<>();
|
||||||
|
updateWrapper.eq(InspectPacsDataDO::getCode, updateReqVO.getCode())
|
||||||
|
.eq(InspectPacsDataDO::getType, updateReqVO.getType())
|
||||||
|
.set(InspectPacsDataDO::getItem, updateReqVO.getItem());
|
||||||
|
pacsDataMapper.update(null, updateWrapper);
|
||||||
|
}
|
||||||
private void validatePacsDataExists(Integer id) {
|
private void validatePacsDataExists(Integer id) {
|
||||||
if (pacsDataMapper.selectById(id) == null) {
|
if (pacsDataMapper.selectById(id) == null) {
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user