|
|
@ -1,7 +1,10 @@ |
|
|
|
package com.ruoyi.system.service.impl; |
|
|
|
|
|
|
|
import java.util.List; |
|
|
|
|
|
|
|
import com.ruoyi.common.core.redis.RedisCache; |
|
|
|
import com.ruoyi.common.utils.DateUtils; |
|
|
|
import com.ruoyi.common.utils.ShiroUtils; |
|
|
|
import com.ruoyi.system.service.IOutsourceStorageOrderService; |
|
|
|
import com.ruoyi.warehouse.domain.WarehouseStorageOrder; |
|
|
|
import com.ruoyi.warehouse.domain.WarehouseStorageOrderDetail; |
|
|
@ -28,6 +31,8 @@ public class OutsourceStorageOrderServiceImpl implements IOutsourceStorageOrderS |
|
|
|
@Autowired |
|
|
|
private WarehouseStorageOrderMapper warehouseStorageOrderMapper; |
|
|
|
|
|
|
|
@Autowired |
|
|
|
private RedisCache redisCache; |
|
|
|
|
|
|
|
@Override |
|
|
|
public WarehouseStorageOrder selectWarehouseStorageOrderByWarehouseStorageId(Long warehouseStorageId) { |
|
|
@ -52,11 +57,13 @@ public class OutsourceStorageOrderServiceImpl implements IOutsourceStorageOrderS |
|
|
|
@Override |
|
|
|
public int insertWarehouseStorageOrder(WarehouseStorageOrder warehouseStorageOrder) |
|
|
|
{ |
|
|
|
String loginName = ShiroUtils.getLoginName(); |
|
|
|
warehouseStorageOrder.setCreateTime(DateUtils.getNowDate()); |
|
|
|
warehouseStorageOrder.setWarehouseOrderType("3"); |
|
|
|
warehouseStorageOrder.setWarehouseStorageType("4"); |
|
|
|
warehouseStorageOrder.setWarehouseStorageCode("RK20231102002"); |
|
|
|
warehouseStorageOrder.setCreateBy("张三"); |
|
|
|
String warehouseStorageCode = redisCache.generateBillNo("RK"); |
|
|
|
warehouseStorageOrder.setWarehouseStorageCode(warehouseStorageCode); |
|
|
|
warehouseStorageOrder.setCreateBy(loginName); |
|
|
|
int rows = warehouseStorageOrderMapper.insertWarehouseStorageOrder(warehouseStorageOrder); |
|
|
|
insertWarehouseStorageOrderDetail(warehouseStorageOrder); |
|
|
|
return rows; |
|
|
|