Commit b981ff25 by 杨林龙

1.21.0开发仲利同步激活时间给仲利接口

1 parent f9c4711b
...@@ -31,8 +31,10 @@ public class SyncZhongLiDataComponent { ...@@ -31,8 +31,10 @@ public class SyncZhongLiDataComponent {
*/ */
@Async @Async
public void syncZhongLiInstallTime(WorkOrder workOrder) { public void syncZhongLiInstallTime(WorkOrder workOrder) {
log.info("syncZhongLiInstallTime start===");
// 仲利国际的工单才会推送 // 仲利国际的工单才会推送
if (!WorkOrderSourceEnum.ZLGJ.getCode().equals(workOrder.getOrderSource())) { if (!WorkOrderSourceEnum.ZLGJ.getCode().equals(workOrder.getOrderSource())) {
log.info("不是仲利国际的单===" + workOrder.getPartnerOrderNo());
return; return;
} }
...@@ -61,5 +63,6 @@ public class SyncZhongLiDataComponent { ...@@ -61,5 +63,6 @@ public class SyncZhongLiDataComponent {
String saveGpsEndDateUrl = PropertiesUtils.getProperty("zlgj.active.saveGpsEndDate.url"); String saveGpsEndDateUrl = PropertiesUtils.getProperty("zlgj.active.saveGpsEndDate.url");
String result = HttpUtils.post(saveGpsEndDateUrl, paramBaseJson.toJSONString()); String result = HttpUtils.post(saveGpsEndDateUrl, paramBaseJson.toJSONString());
log.info("调用仲利上传激活时间接口 返回的结果为:" + result); log.info("调用仲利上传激活时间接口 返回的结果为:" + result);
log.info("syncZhongLiInstallTime end===");
} }
} }
...@@ -2,6 +2,7 @@ package cn.com.glsx.stdinterface.modules.component; ...@@ -2,6 +2,7 @@ package cn.com.glsx.stdinterface.modules.component;
import cn.com.glsx.Application; import cn.com.glsx.Application;
import cn.com.glsx.stdinterface.modules.entity.WorkOrder; import cn.com.glsx.stdinterface.modules.entity.WorkOrder;
import cn.com.glsx.stdinterface.modules.mapper.WorkOrderMapper;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.junit.Test; import org.junit.Test;
import org.junit.runner.RunWith; import org.junit.runner.RunWith;
...@@ -9,8 +10,6 @@ import org.springframework.beans.factory.annotation.Autowired; ...@@ -9,8 +10,6 @@ import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest; import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.junit4.SpringRunner; import org.springframework.test.context.junit4.SpringRunner;
import static org.junit.Assert.*;
@Slf4j @Slf4j
@RunWith(SpringRunner.class) @RunWith(SpringRunner.class)
@SpringBootTest(classes = Application.class, webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT) @SpringBootTest(classes = Application.class, webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
...@@ -19,9 +18,12 @@ public class SyncZhongLiDataComponentTest { ...@@ -19,9 +18,12 @@ public class SyncZhongLiDataComponentTest {
@Autowired @Autowired
private SyncZhongLiDataComponent syncZhongLiDataComponent; private SyncZhongLiDataComponent syncZhongLiDataComponent;
@Autowired
private WorkOrderMapper workOrderMapper;
@Test @Test
public void syncZhongLiInstallTime() { public void syncZhongLiInstallTime() {
WorkOrder workOrder = new WorkOrder(); WorkOrder workOrder = workOrderMapper.selectByOrderNo("2022121516000001");
syncZhongLiDataComponent.syncZhongLiInstallTime(workOrder); syncZhongLiDataComponent.syncZhongLiInstallTime(workOrder);
} }
} }
\ No newline at end of file \ No newline at end of file
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!