Commit 1fada70f by wutong

调拨数据同步插入DB时,将毫秒设为0

parent bbe8f5c4
......@@ -187,8 +187,11 @@ public class TransferDetailsServiceImpl {
}
try {
DcBaseTransferInboundMapper mapper12 = SessionUtil.getSession().getMapper(DcBaseTransferInboundMapper.class);
int i = mapper12.updateByExampleSelective(dcBaseTransferInbound, DcBaseTransferInboundExample.newAndCreateCriteria().andBailunSkuEqualTo(dcBaseTransferInbound.getBailunSku())
.andTransferOrderIdEqualTo(dcBaseTransferInbound.getTransferOrderId()).andCreateTimeEqualTo(dcBaseTransferInbound.getCreateTime()).example());
int i = mapper12.updateByExampleSelective(dcBaseTransferInbound, DcBaseTransferInboundExample.newAndCreateCriteria()
.andBailunSkuEqualTo(dcBaseTransferInbound.getBailunSku())
.andTransferOrderIdEqualTo(dcBaseTransferInbound.getTransferOrderId())
.andCreateTimeEqualTo(dcBaseTransferInbound.getCreateTime().withNano(0))
.example());
if (i == 0) {
mapper12.insertSelective(dcBaseTransferInbound);
}
......
......@@ -8,9 +8,9 @@ public class TransferDetailsTest {
@Test
public void test() {
JobPointLog jobPointLog = new JobPointLog();
jobPointLog.setStartTime(LocalDateTime.of(2019,04,17,14,53,14));
jobPointLog.setEndTime(LocalDateTime.of(2019,04,17,14,53,15));
jobPointLog.setType(5);
jobPointLog.setStartTime(LocalDateTime.of(2019,01,7,0,0,0));
jobPointLog.setEndTime(LocalDateTime.of(2019,01,8,0,0,0));
jobPointLog.setType(12);
jobPointLog.setIntervalTime(1);
jobPointLog.setPageIndex(1);
jobPointLog.setPageSize(1000);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment