Merge branch 'master' of http://122.51.230.86:3000/dianliang/lanan-system
This commit is contained in:
commit
e3188a4c8d
@ -45,9 +45,9 @@ public class RepairProjectController {
|
||||
@PostMapping("/create")
|
||||
@Operation(summary = "创建维修项目")
|
||||
@PreAuthorize("@ss.hasPermission('repair:project:create')")
|
||||
public CommonResult<Boolean> createRepairProject(@Valid @RequestBody RepairProjectSaveReqVO createReqVO) {
|
||||
repairProjectService.saveRepairProject(createReqVO);
|
||||
return success(true);
|
||||
public CommonResult<RepairProject> createRepairProject(@Valid @RequestBody RepairProjectSaveReqVO createReqVO) {
|
||||
RepairProject repairProject = repairProjectService.saveRepairProject(createReqVO);
|
||||
return success(repairProject);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -44,9 +44,8 @@ public class RepairWaresController {
|
||||
@PostMapping("/create")
|
||||
@Operation(summary = "创建配件库")
|
||||
@PreAuthorize("@ss.hasPermission('repair:wares:create')")
|
||||
public CommonResult<Boolean> createWares(@Valid @RequestBody RepairWaresSaveReqVO createReqVO) {
|
||||
waresService.saveWares(createReqVO);
|
||||
return success(true);
|
||||
public CommonResult<RepairWares> createWares(@Valid @RequestBody RepairWaresSaveReqVO createReqVO) {
|
||||
return success(waresService.saveWares(createReqVO));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -23,7 +23,7 @@ public interface RepairProjectService extends IService<RepairProject> {
|
||||
* @author PQZ
|
||||
* @date 14:51 2024/9/12
|
||||
**/
|
||||
void saveRepairProject(RepairProjectSaveReqVO saveReqVO);
|
||||
RepairProject saveRepairProject(RepairProjectSaveReqVO saveReqVO);
|
||||
|
||||
/**
|
||||
* 删除维修项目
|
||||
|
@ -23,7 +23,7 @@ public interface RepairWaresService extends IService<RepairWares> {
|
||||
* @author PQZ
|
||||
* @date 9:33 2024/9/18
|
||||
**/
|
||||
void saveWares(RepairWaresSaveReqVO saveReqVO);
|
||||
RepairWares saveWares(RepairWaresSaveReqVO saveReqVO);
|
||||
|
||||
/**
|
||||
* @param id 配件id
|
||||
|
@ -36,9 +36,10 @@ public class RepairProjectServiceImpl extends ServiceImpl<RepairProjectMapper, R
|
||||
* @date 14:51 2024/9/12
|
||||
**/
|
||||
@Override
|
||||
public void saveRepairProject(RepairProjectSaveReqVO saveReqVO) {
|
||||
public RepairProject saveRepairProject(RepairProjectSaveReqVO saveReqVO) {
|
||||
RepairProject repairProject = BeanUtils.toBean(saveReqVO, RepairProject.class);
|
||||
saveOrUpdate(repairProject);
|
||||
return getById(repairProject.getId());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -38,9 +38,10 @@ public class RepairWaresServiceImpl extends ServiceImpl<RepairWaresMapper, Repai
|
||||
* @date 9:33 2024/9/18
|
||||
**/
|
||||
@Override
|
||||
public void saveWares(RepairWaresSaveReqVO saveReqVO) {
|
||||
public RepairWares saveWares(RepairWaresSaveReqVO saveReqVO) {
|
||||
RepairWares repairWares = BeanUtils.toBean(saveReqVO, RepairWares.class);
|
||||
saveOrUpdate(repairWares);
|
||||
return getById(repairWares.getId());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -22,7 +22,7 @@
|
||||
<where>
|
||||
drw.deleted = 0
|
||||
<if test="entity.name != null and entity.name != ''">
|
||||
and drw.name = #{entity.name}
|
||||
and drw.name like concat('%', #{entity.name}, '%')
|
||||
</if>
|
||||
</where>
|
||||
GROUP BY
|
||||
|
Loading…
Reference in New Issue
Block a user