rev:库存变动时盘点是否整出

This commit is contained in:
zhangzq
2024-07-03 16:26:07 +08:00
parent c405992abc
commit 8baa74c927
2 changed files with 9 additions and 4 deletions

View File

@@ -31,7 +31,7 @@ import java.util.*;
**/
@RestController
@RequiredArgsConstructor
@RequestMapping("/api/bmCustomer")
@RequestMapping("/api/customerbase")
@Slf4j
public class BmCustomerController {

View File

@@ -66,10 +66,15 @@ public class StIvtStructattrServiceImpl extends ServiceImpl<StIvtStructattrMappe
}
@Override
public void changeStruct(String struct_code, String vehicle_code, String task_type, BigDecimal change_qty,Boolean growth) {
this.update(new UpdateWrapper<StIvtStructattr>()
.set("update_time",DateUtil.now())
UpdateWrapper<StIvtStructattr> wrapper = new UpdateWrapper<StIvtStructattr>()
.set("update_time", DateUtil.now())
.set("lock_type", StatusEnum.LOCK.code("无锁"))
.eq("struct_code",struct_code));
.eq("struct_code", struct_code);
//如果是整出
if (!growth && change_qty==null){
wrapper.set("vehicle_code",null);
}
this.update(wrapper);
List<MdPbVehicleMater> vehicleMaters = vehicleMaterService.list(new QueryWrapper<MdPbVehicleMater>().eq("vehicle_code", vehicle_code));
List<StIvtStructivtflow> records = new ArrayList<>();
StIvtStructattr attr = this.getOne(new QueryWrapper<StIvtStructattr>().eq("struct_code", struct_code).select("stor_code"));