diff --git a/src/main/java/com/glxp/udi/admin/service/product/StackOrderService.java b/src/main/java/com/glxp/udi/admin/service/product/StackOrderService.java index 8194b29..c3e2cf8 100644 --- a/src/main/java/com/glxp/udi/admin/service/product/StackOrderService.java +++ b/src/main/java/com/glxp/udi/admin/service/product/StackOrderService.java @@ -67,6 +67,7 @@ public class StackOrderService { public void updateOrder(StackUploadRequest stackUploadRequest) { + stackUploadRequest.getStackOrderEntity().setUpdateTime(new Date()); stackOrderDao.updateById(stackUploadRequest.getStackOrderEntity()); } @@ -77,9 +78,11 @@ public class StackOrderService { public StackOrder insertOrder(StackOrder stackOrderEntity) { String stackId = idUtil.getStackId(stackOrderEntity.getCustomerId()); stackOrderEntity.setOrderId(stackId); + Date date = new Date(); if (null == stackOrderEntity.getCreateTime()) { - stackOrderEntity.setCreateTime(new Date()); + stackOrderEntity.setCreateTime(date); } + stackOrderEntity.setUpdateTime(date); stackOrderEntity.setId(null); stackOrderDao.insert(stackOrderEntity); return stackOrderEntity; @@ -178,6 +181,7 @@ public class StackOrderService { String stackId = idUtil.getStackId(customerId); stackOrder.setOrderId(stackId); stackOrder.setCreateTime(new Date()); + stackOrder.setUpdateTime(new Date()); stackOrder.setExportStatus(0); stackOrder.setCustomerId(customerId); stackOrder.setFromType(ConstantStatus.STACK_ORDER_FROM_TYPE_EXCEL);