|
@@ -21,6 +21,7 @@ import com.malk.utils.UtilMap;
|
|
|
import lombok.extern.slf4j.Slf4j;
|
|
import lombok.extern.slf4j.Slf4j;
|
|
|
import org.slf4j.MDC;
|
|
import org.slf4j.MDC;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
|
|
+import org.springframework.beans.factory.annotation.Value;
|
|
|
import org.springframework.stereotype.Service;
|
|
import org.springframework.stereotype.Service;
|
|
|
|
|
|
|
|
import java.time.LocalDateTime;
|
|
import java.time.LocalDateTime;
|
|
@@ -46,6 +47,9 @@ public class KdYdCustomerServiceImpl extends ServiceImpl<KdYdCustomerMapper, KdY
|
|
|
@Autowired
|
|
@Autowired
|
|
|
private KdYdCustomerLiaisonMapper kdYdCustomerLiaisonMapper;
|
|
private KdYdCustomerLiaisonMapper kdYdCustomerLiaisonMapper;
|
|
|
|
|
|
|
|
|
|
+ @Value(value = "${kd.host}")
|
|
|
|
|
+ private String kdHost;
|
|
|
|
|
+
|
|
|
@Override
|
|
@Override
|
|
|
public Map<String, Object> insertCustomer(Map map) {
|
|
public Map<String, Object> insertCustomer(Map map) {
|
|
|
Map<String, Object> result = new HashMap<>();
|
|
Map<String, Object> result = new HashMap<>();
|
|
@@ -69,7 +73,7 @@ public class KdYdCustomerServiceImpl extends ServiceImpl<KdYdCustomerMapper, KdY
|
|
|
formParams.put("jsons", jsonStr);
|
|
formParams.put("jsons", jsonStr);
|
|
|
|
|
|
|
|
System.out.println("====" + formParams);
|
|
System.out.println("====" + formParams);
|
|
|
- HttpResponse response = HttpRequest.post("http://113.45.187.194:70/xk/dyzn/WsBasedyzn.asmx/")//todo 待完善接口
|
|
|
|
|
|
|
+ HttpResponse response = HttpRequest.post("http://"+kdHost+":70/xk/dyzn/WsBasedyzn.asmx/")//todo 待完善接口
|
|
|
.headerMap(headers, true)
|
|
.headerMap(headers, true)
|
|
|
.form(formParams)
|
|
.form(formParams)
|
|
|
.timeout(30000) // 30秒超时
|
|
.timeout(30000) // 30秒超时
|
|
@@ -193,13 +197,13 @@ public class KdYdCustomerServiceImpl extends ServiceImpl<KdYdCustomerMapper, KdY
|
|
|
// 发送请求
|
|
// 发送请求
|
|
|
HttpResponse response = null;
|
|
HttpResponse response = null;
|
|
|
if (action == "add") {
|
|
if (action == "add") {
|
|
|
- response = HttpRequest.post("http://113.45.187.194:70/xk/dyzn/WsBasedyzn.asmx/")//todo 修改接口
|
|
|
|
|
|
|
+ response = HttpRequest.post("http://"+kdHost+":70/xk/dyzn/WsBasedyzn.asmx/")//todo 修改接口
|
|
|
.headerMap(headers, true)
|
|
.headerMap(headers, true)
|
|
|
.form(formParams)
|
|
.form(formParams)
|
|
|
.timeout(30000) // 30秒超时
|
|
.timeout(30000) // 30秒超时
|
|
|
.execute();
|
|
.execute();
|
|
|
} else {
|
|
} else {
|
|
|
- response = HttpRequest.post("http://113.45.187.194:70/xk/dyzn/WsBasedyzn.asmx/")
|
|
|
|
|
|
|
+ response = HttpRequest.post("http://"+kdHost+":70/xk/dyzn/WsBasedyzn.asmx/")
|
|
|
.headerMap(headers, true)
|
|
.headerMap(headers, true)
|
|
|
.form(formParams)
|
|
.form(formParams)
|
|
|
.timeout(30000) // 30秒超时
|
|
.timeout(30000) // 30秒超时
|