Commit 23d1a954 authored by jyx's avatar jyx

代码优化

parent 367c12cb
...@@ -57,12 +57,19 @@ object GravityEngineManager { ...@@ -57,12 +57,19 @@ object GravityEngineManager {
override fun onSuccess(responseJson: JSONObject?, initializeBody: JSONObject?) { override fun onSuccess(responseJson: JSONObject?, initializeBody: JSONObject?) {
//responseJson=={"nameValuePairs":{"token":"b10c4ce9-b40b-3f89-b442-237fe82e5efd"}} //responseJson=={"nameValuePairs":{"token":"b10c4ce9-b40b-3f89-b442-237fe82e5efd"}}
responseJson?.let {
val json = JsonUtil.toJson(it)
LogUtil.d("mcg --> gravityEngineSDKInstance onSuccess=$json")
TrackManager.getInstance().ylclReport(json)
}
var json = ""
var json2 = ""
if (responseJson != null) {
json = JsonUtil.toJson(responseJson)
}
if (initializeBody != null) {
json2 = JsonUtil.toJson(initializeBody)
}
LogUtil.d("mcg --> gravityEngineSDKInstance onSuccess=$json")
LogUtil.d("mcg --> gravityEngineSDKInstance onSuccess=$json2")
TrackManager.getInstance().ylclReport(json, json2)
enableAutoTrack(gravityEngineSDKInstance) enableAutoTrack(gravityEngineSDKInstance)
} }
......
...@@ -87,9 +87,9 @@ public class TrackManager { ...@@ -87,9 +87,9 @@ public class TrackManager {
} }
} }
public void ylclReport(String vo) { public void ylclReport(String json1, String json2) {
if (trackPresenter != null) { if (trackPresenter != null) {
trackPresenter.ylclReport(vo); trackPresenter.ylclReport(json1, json2);
} }
} }
} }
...@@ -270,10 +270,11 @@ public class TrackPresenter extends BaseTrackPresenter { ...@@ -270,10 +270,11 @@ public class TrackPresenter extends BaseTrackPresenter {
}); });
} }
public void ylclReport(String json) { public void ylclReport(String json1,String json2) {
HashMap<String, Object> vo = new HashMap<>(); HashMap<String, Object> vo = new HashMap<>();
vo.put("device", new DeviceUuidFactory().getDeviceUuid()); vo.put("device", new DeviceUuidFactory().getDeviceUuid());
vo.put("param", json); vo.put("param", json1);
vo.put("param2", json2);
AppHttpManager.getInstance(loanApplication) AppHttpManager.getInstance(loanApplication)
.call(loanService.ylclReport(vo), .call(loanService.ylclReport(vo),
new BaseSubscriber<BaseResponse<Object>>() { new BaseSubscriber<BaseResponse<Object>>() {
......
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