refactor(oa): 仓库主表相关重构

- 移除了 ISysOaWarehouseMasterService 中的 updateReturnType 和 updateWithdrawLock 方法
- 更新了 SysOaWarehouseMaster、SysOaWarehouseMasterBo 和 SysOaWarehouseMasterVo 中的 withdrawlock 字段,改为 withdrawLock
- 删除了 SysOaWarehouseMasterController 中的 updateReturnType 和 updateWithdrawLock 接口
- 更新了 SysOaWarehouseMasterMapper.xml 中的相关 SQL 语句- 移除了 SysOaWarehouseMasterServiceImpl 中的 updateReturnType 和 updateWithdrawLock 方法
This commit is contained in:
2025-08-19 16:50:44 +08:00
parent 268a7a3117
commit e2500e06df
7 changed files with 9 additions and 31 deletions

View File

@@ -134,16 +134,6 @@ public class SysOaWarehouseMasterController extends BaseController {
return toAjax(iSysOaWarehouseMasterService.updateMasterAndInsertBatchWare(bo)); return toAjax(iSysOaWarehouseMasterService.updateMasterAndInsertBatchWare(bo));
} }
// 修改returnType
@PutMapping("/returnType")
public R<Void> updateReturnType(@RequestParam Long masterId, @RequestParam Integer returnType) {
return toAjax(iSysOaWarehouseMasterService.updateReturnType(masterId, returnType));
}
// 修改withdrawlock
@PutMapping("/withdrawLock")
public R<Void> updateWithdrawLock(@RequestParam Long masterId, @RequestParam Integer withdrawlock) {
return toAjax(iSysOaWarehouseMasterService.updateWithdrawLock(masterId, withdrawlock));
}
// 明细退库 // 明细退库
@PostMapping("/returnDetail") @PostMapping("/returnDetail")
public R<Void> returnDetail(@RequestBody List<ReturnDetailBo> returnDetails) { public R<Void> returnDetail(@RequestBody List<ReturnDetailBo> returnDetails) {

View File

@@ -60,6 +60,6 @@ public class SysOaWarehouseMaster extends BaseEntity {
private Integer isLike; private Integer isLike;
private Long status; private Long status;
private Integer returnType; private Integer returnType;
private Integer withdrawlock; private Integer withdrawLock;
} }

View File

@@ -76,6 +76,6 @@ public class SysOaWarehouseMasterBo extends BaseEntity {
private Integer returnType; private Integer returnType;
private Integer withdrawlock; private Integer withdrawLock;
} }

View File

@@ -87,7 +87,7 @@ public class SysOaWarehouseMasterVo {
* 日志操作次数 * 日志操作次数
*/ */
private Integer logCount; private Integer logCount;
private Integer withdrawlock; private Integer withdrawLock;
} }

View File

@@ -72,7 +72,6 @@ public interface ISysOaWarehouseMasterService {
* @return * @return
*/ */
int redoMaster(Long masterId); int redoMaster(Long masterId);
boolean updateReturnType(Long masterId, Integer returnType);
boolean returnDetail(List<ReturnDetailBo> returnDetails); boolean returnDetail(List<ReturnDetailBo> returnDetails);
/** /**
@@ -88,5 +87,4 @@ public interface ISysOaWarehouseMasterService {
*/ */
Boolean updateRemark(Long masterId, String remark); Boolean updateRemark(Long masterId, String remark);
int updateWithdrawLock(Long masterId, Integer withdrawlock);
} }

View File

@@ -88,7 +88,7 @@ public class SysOaWarehouseMasterServiceImpl implements ISysOaWarehouseMasterSer
lqw.eq(bo.getType()!= null, "sowm.type",bo.getType()) lqw.eq(bo.getType()!= null, "sowm.type",bo.getType())
.eq(bo.getProjectId()!= null, "sowm.project_id", bo.getProjectId()) .eq(bo.getProjectId()!= null, "sowm.project_id", bo.getProjectId())
.eq(bo.getReturnType() != null, "sowm.return_type", bo.getReturnType()) .eq(bo.getReturnType() != null, "sowm.return_type", bo.getReturnType())
.eq(bo.getWithdrawlock()!= null, "sowm.withdrawlock", bo.getWithdrawlock()) .eq(bo.getWithdrawLock()!= null, "sowm.withdraw_lock", bo.getWithdrawLock())
// 其他过滤…… // 其他过滤……
.eq("sowm.del_flag",0) .eq("sowm.del_flag",0)
.orderByDesc("sowm.update_time"); .orderByDesc("sowm.update_time");
@@ -304,14 +304,7 @@ public class SysOaWarehouseMasterServiceImpl implements ISysOaWarehouseMasterSer
return baseMapper.deleteById(masterId); return baseMapper.deleteById(masterId);
} }
// 2. 修改returnType
@Override
public boolean updateReturnType(Long masterId, Integer returnType) {
SysOaWarehouseMaster update = new SysOaWarehouseMaster();
update.setMasterId(masterId);
update.setReturnType(returnType);
return baseMapper.updateById(update) > 0;
}
@Override @Override
public boolean updateIsLike(Long masterId, Integer isLike) { public boolean updateIsLike(Long masterId, Integer isLike) {
@@ -331,11 +324,4 @@ public class SysOaWarehouseMasterServiceImpl implements ISysOaWarehouseMasterSer
return baseMapper.updateById(update) > 0; return baseMapper.updateById(update) > 0;
} }
@Override
public int updateWithdrawLock(Long masterId, Integer withdrawlock) {
SysOaWarehouseMaster update = new SysOaWarehouseMaster();
update.setMasterId(masterId);
update.setReturnType(withdrawlock);
return baseMapper.updateById(update);
}
} }

View File

@@ -22,6 +22,8 @@
<result property="status" column="status"/> <result property="status" column="status"/>
<result property="nearestEndTime" column="nearest_end_time"/> <result property="nearestEndTime" column="nearest_end_time"/>
<result property="logCount" column="logCount"/> <result property="logCount" column="logCount"/>
<result property="returnType" column="return_type"/>
<result property="withdrawLock" column="withdraw_lock"/>
<collection property="warehouseList" <collection property="warehouseList"
column="master_id" column="master_id"
@@ -73,6 +75,8 @@
sowm.sign_user, sowm.sign_user,
sowm.remark, sowm.remark,
sowm.status, sowm.status,
sown.return_type,
sown.withdraw_lock,
${ew.sqlSelect}, ${ew.sqlSelect},
sop.project_name, sop.project_name,
IFNULL(log_count.log_count, 0) AS logCount IFNULL(log_count.log_count, 0) AS logCount