1.建垛更新时间设置值,修复排序无效问题

master
x_z 2 years ago
parent 0f4d098f83
commit 47033f83ec

@ -67,6 +67,7 @@ public class StackOrderService {
public void updateOrder(StackUploadRequest stackUploadRequest) { public void updateOrder(StackUploadRequest stackUploadRequest) {
stackUploadRequest.getStackOrderEntity().setUpdateTime(new Date());
stackOrderDao.updateById(stackUploadRequest.getStackOrderEntity()); stackOrderDao.updateById(stackUploadRequest.getStackOrderEntity());
} }
@ -77,9 +78,11 @@ public class StackOrderService {
public StackOrder insertOrder(StackOrder stackOrderEntity) { public StackOrder insertOrder(StackOrder stackOrderEntity) {
String stackId = idUtil.getStackId(stackOrderEntity.getCustomerId()); String stackId = idUtil.getStackId(stackOrderEntity.getCustomerId());
stackOrderEntity.setOrderId(stackId); stackOrderEntity.setOrderId(stackId);
Date date = new Date();
if (null == stackOrderEntity.getCreateTime()) { if (null == stackOrderEntity.getCreateTime()) {
stackOrderEntity.setCreateTime(new Date()); stackOrderEntity.setCreateTime(date);
} }
stackOrderEntity.setUpdateTime(date);
stackOrderEntity.setId(null); stackOrderEntity.setId(null);
stackOrderDao.insert(stackOrderEntity); stackOrderDao.insert(stackOrderEntity);
return stackOrderEntity; return stackOrderEntity;
@ -178,6 +181,7 @@ public class StackOrderService {
String stackId = idUtil.getStackId(customerId); String stackId = idUtil.getStackId(customerId);
stackOrder.setOrderId(stackId); stackOrder.setOrderId(stackId);
stackOrder.setCreateTime(new Date()); stackOrder.setCreateTime(new Date());
stackOrder.setUpdateTime(new Date());
stackOrder.setExportStatus(0); stackOrder.setExportStatus(0);
stackOrder.setCustomerId(customerId); stackOrder.setCustomerId(customerId);
stackOrder.setFromType(ConstantStatus.STACK_ORDER_FROM_TYPE_EXCEL); stackOrder.setFromType(ConstantStatus.STACK_ORDER_FROM_TYPE_EXCEL);

Loading…
Cancel
Save