This commit is contained in:
zhongchao
2022-03-22 10:07:10 +08:00
parent 3a14b5e37d
commit a39f310331
42 changed files with 1317 additions and 201 deletions

View File

@@ -10,12 +10,12 @@ import com.mogo.commons.AbsMogoApplication;
import com.mogo.eagle.core.data.BaseData;
import com.mogo.eagle.core.data.map.MogoLocation;
import com.mogo.eagle.core.function.call.map.CallerMapUIServiceManager;
import com.mogo.eagle.core.network.MoGoRetrofitFactory;
import com.mogo.eagle.core.network.RequestOptions;
import com.mogo.eagle.core.network.SubscribeImpl;
import com.mogo.eagle.core.network.utils.GsonUtil;
import com.mogo.eagle.core.utilcode.util.NetworkUtils;
import com.mogo.map.location.IMogoLocationClient;
import com.mogo.module.common.MogoApisHandler;
import io.reactivex.schedulers.Schedulers;
import okhttp3.MediaType;
@@ -79,8 +79,7 @@ public class DelayCheckUtil implements Handler.Callback {
private void startEmptyRequest() {
requestTime = SystemClock.elapsedRealtime();
requestStartSystemTime = System.currentTimeMillis();
MogoApisHandler.getInstance().getApis().getNetworkApi()
.create(DelayCheckApiServices.class, DelayCheckHttpConstant.getBaseUrl())
MoGoRetrofitFactory.getInstance(DelayCheckHttpConstant.getBaseUrl()).create(DelayCheckApiServices.class)
.emptyInterface().subscribeOn(Schedulers.io()).observeOn(Schedulers.io())
.subscribe(new SubscribeImpl<BaseData>(RequestOptions.create(context)) {
@Override
@@ -128,8 +127,7 @@ public class DelayCheckUtil implements Handler.Callback {
RequestBody params = RequestBody.create(MediaType.get("application/json"), GsonUtil.jsonFromObject(request));
MogoApisHandler.getInstance().getApis().getNetworkApi()
.create(DelayCheckApiServices.class, DelayCheckHttpConstant.getBaseUrl())
MoGoRetrofitFactory.getInstance(DelayCheckHttpConstant.getBaseUrl()).create(DelayCheckApiServices.class)
.uploadDelayCheckData(params).observeOn(Schedulers.io()).subscribeOn(Schedulers.io())
.subscribe(new SubscribeImpl<DelayCheckResponse>(RequestOptions.create(context)) {
@Override