Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
505c68fb6b | ||
|
|
053d819d27 |
+28
-23
@@ -35,12 +35,11 @@ android {
|
||||
|
||||
defaultConfig {
|
||||
applicationId "com.arpa.hndahesudintocctmsdriver"
|
||||
minSdkVersion 24
|
||||
minSdkVersion 23
|
||||
targetSdkVersion 30
|
||||
versionCode 65
|
||||
versionName "3.3.5"
|
||||
versionCode 59
|
||||
versionName "3.2.9"
|
||||
flavorDimensions "CHANNEL_VALUE"
|
||||
flavorDimensions "app_icon"
|
||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||
javaCompileOptions {
|
||||
|
||||
@@ -57,7 +56,27 @@ android {
|
||||
// 还可以添加 'x86', 'x86_64', 'mips', 'mips64' , 'arm64-v8a'
|
||||
|
||||
}
|
||||
|
||||
manifestPlaceholders = [
|
||||
JPUSH_PKGNAME : applicationId,
|
||||
JPUSH_APPKEY : "571d93ae5117da6dee848c92", //JPush 上注册的包名对应的 Appkey.
|
||||
JPUSH_CHANNEL : "developer-default", //暂时填写默认值即可.
|
||||
MEIZU_APPKEY : "MZ-魅族的APPKEY",
|
||||
MEIZU_APPID : "MZ-魅族的APPID",
|
||||
XIAOMI_APPID : "MI-小米的APPID",
|
||||
XIAOMI_APPKEY : "MI-小米的APPKEY",
|
||||
OPPO_APPKEY : "OP-oppo的APPKEY",
|
||||
OPPO_APPID : "OP-oppo的APPID",
|
||||
OPPO_APPSECRET : "OP-oppo的APPSECRET",
|
||||
VIVO_APPKEY : "vivo的APPKEY",
|
||||
VIVO_APPID : "vivo的APPID"
|
||||
]
|
||||
}
|
||||
// sourceSets {
|
||||
// main {
|
||||
// jniLibs.srcDirs = ['libs']
|
||||
// }
|
||||
// }
|
||||
|
||||
sourceSets {
|
||||
main {
|
||||
@@ -96,14 +115,7 @@ android {
|
||||
|
||||
productFlavors {
|
||||
qa {
|
||||
applicationId "com.arpa.hndahesudintocctmsdriver.text"
|
||||
manifestPlaceholders = [CHANNEL_VALUE: "司机测试",
|
||||
app_icon : "@drawable/diver_logo_text",
|
||||
GAODEKEY : "6791d69f6221a0841b521763af86eb01",
|
||||
JPUSH_PKGNAME: applicationId,
|
||||
JPUSH_APPKEY : "fba6f55621c670d8c1fe9191", //JPush 上注册的包名对应的 Appkey.
|
||||
JPUSH_CHANNEL: "developer-default"//暂时填写默认值即可.
|
||||
]
|
||||
manifestPlaceholders = [CHANNEL_VALUE: "好运司机测试"]
|
||||
buildConfigField("String", "OPEN_AL_URL", "\"https://oapi-staging.alct56.com\"")
|
||||
buildConfigField("String", "BASE_URL", "\"http://app.test.dahehuoyun.com/api/\"")
|
||||
buildConfigField "boolean", "isTest", "true"
|
||||
@@ -111,14 +123,7 @@ android {
|
||||
resValue "string", "appName", "司机测试"
|
||||
}
|
||||
product {
|
||||
applicationId "com.arpa.hndahesudintocctmsdriver"
|
||||
manifestPlaceholders = [CHANNEL_VALUE: "大河好运司机",
|
||||
app_icon : "@drawable/diver_logo",
|
||||
GAODEKEY : "c68051b43e79e47a1556fc695371c902",
|
||||
JPUSH_PKGNAME: applicationId,
|
||||
JPUSH_APPKEY : "fba6f55621c670d8c1fe9191", //JPush 上注册的包名对应的 Appkey.
|
||||
JPUSH_CHANNEL: "developer-default"//暂时填写默认值即可.
|
||||
]
|
||||
manifestPlaceholders = [CHANNEL_VALUE: "大河好运司机"]
|
||||
buildConfigField("String", "OPEN_AL_URL", "\"https://oapi.alct56.com\"")
|
||||
buildConfigField("String", "BASE_URL", "\"http://app.dahehuoyun.com/api/\"")
|
||||
buildConfigField "boolean", "isTest", "false"
|
||||
@@ -127,9 +132,9 @@ android {
|
||||
}
|
||||
|
||||
}
|
||||
// productFlavors.all { flavor ->
|
||||
// flavor.manifestPlaceholders = [CHANNEL_VALUE: name]
|
||||
// }
|
||||
productFlavors.all { flavor ->
|
||||
flavor.manifestPlaceholders = [CHANNEL_VALUE: name]
|
||||
}
|
||||
|
||||
|
||||
android.applicationVariants.all { variant ->
|
||||
|
||||
@@ -11,7 +11,6 @@
|
||||
<!-- 录音 -->
|
||||
<uses-permission android:name="android.permission.RECORD_AUDIO" />
|
||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" />
|
||||
<uses-permission android:name="android.permission.MANAGE_EXTERNAL_STORAGE" />
|
||||
<!--播音-->
|
||||
<uses-permission android:name="android.permission.WAKE_LOCK" />
|
||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
||||
@@ -45,7 +44,7 @@
|
||||
<uses-permission android:name="android.permission.ACCESS_FINE_LOCATION" />
|
||||
<uses-permission android:name="android.permission.EACCES" />
|
||||
<uses-permission android:name="android.permission.REQUEST_INSTALL_PACKAGES" />
|
||||
|
||||
<uses-permission android:name="android.permission.MANAGE_EXTERNAL_STORAGE" />
|
||||
<uses-feature
|
||||
android:name="android.hardware.nfc"
|
||||
android:required="true" />
|
||||
@@ -54,7 +53,7 @@
|
||||
android:name="com.arpa.hndahesudintocctmsdriver.App"
|
||||
android:allowBackup="true"
|
||||
android:excludeFromRecents="true"
|
||||
android:icon="@mipmap/diver_logo"
|
||||
android:icon="@drawable/diver_logo"
|
||||
android:label="@string/appName"
|
||||
android:largeHeap="true"
|
||||
android:requestLegacyExternalStorage="true"
|
||||
@@ -94,7 +93,6 @@
|
||||
android:screenOrientation="portrait" />
|
||||
<activity
|
||||
android:name="com.arpa.hndahesudintocctmsdriver.ui.auth.PhotoCarActivity"
|
||||
android:windowSoftInputMode="adjustPan|stateHidden"
|
||||
android:screenOrientation="portrait" />
|
||||
<activity
|
||||
android:name="com.arpa.hndahesudintocctmsdriver.ui.auth.VehicleAuthActivity"
|
||||
@@ -162,7 +160,6 @@
|
||||
</activity>
|
||||
<activity
|
||||
android:name="com.arpa.hndahesudintocctmsdriver.ui.auth.CertificatesActivity"
|
||||
android:windowSoftInputMode="adjustPan|stateHidden"
|
||||
android:screenOrientation="portrait"/>
|
||||
<activity
|
||||
android:name="com.arpa.hndahesudintocctmsdriver.ui.auth.AddCarSuccActivity"
|
||||
@@ -172,7 +169,6 @@
|
||||
android:screenOrientation="portrait"/>
|
||||
<activity
|
||||
android:name="com.arpa.hndahesudintocctmsdriver.ui.login.WelcomeActivity"
|
||||
android:exported="true"
|
||||
android:screenOrientation="portrait">
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
@@ -266,11 +262,10 @@
|
||||
<!--高德地图-->
|
||||
<meta-data
|
||||
android:name="com.amap.api.v2.apikey"
|
||||
android:value="${GAODEKEY}" />
|
||||
android:value="78019612271411eca3af34db91930620" />
|
||||
<!-- android:value="702eaa84675618b8eb69298d9fd42ca3" />-->
|
||||
|
||||
<service android:name="com.amap.api.location.APSService"
|
||||
android:foregroundServiceType="location"></service>
|
||||
<service android:name="com.amap.api.location.APSService"></service>
|
||||
|
||||
<!--百度地图-->
|
||||
<meta-data
|
||||
@@ -279,7 +274,7 @@
|
||||
<!-- 极光-->
|
||||
<meta-data
|
||||
android:name="JPUSH_APPKEY"
|
||||
android:value="fba6f55621c670d8c1fe9191" /> <!-- </>值来自开发者平台取得的AppKey -->
|
||||
android:value="571d93ae5117da6dee848c92" /> <!-- </>值来自开发者平台取得的AppKey -->
|
||||
|
||||
<meta-data
|
||||
android:name="JPUSH_CHANNEL"
|
||||
@@ -402,7 +397,7 @@
|
||||
</receiver>
|
||||
<provider
|
||||
android:name="androidx.core.content.FileProvider"
|
||||
android:authorities="${applicationId}.fileprovider"
|
||||
android:authorities="com.arpa.hndahesudintocctmsdriver.fileprovider"
|
||||
android:exported="false"
|
||||
android:grantUriPermissions="true"
|
||||
tools:ignore="WrongManifestParent">
|
||||
|
||||
@@ -9,26 +9,39 @@ import android.content.IntentFilter;
|
||||
import android.content.pm.ApplicationInfo;
|
||||
import android.content.res.Configuration;
|
||||
import android.content.res.Resources;
|
||||
import android.os.Environment;
|
||||
import android.util.Log;
|
||||
|
||||
import androidx.core.app.ActivityCompat;
|
||||
|
||||
import com.alct.mdp.MDPLocationCollectionManager;
|
||||
import com.arpa.hndahesudintocctmsdriver.report.JTTProcess;
|
||||
import com.arpa.hndahesudintocctmsdriver.request.net.Api;
|
||||
import com.arpa.hndahesudintocctmsdriver.ui.MainActivity;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.BillLocationUtils;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.SPUtils;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.location.LocationGDUtil;
|
||||
import com.dahe.mylibrary.CommonBaseLibrary;
|
||||
import com.dahe.mylibrary.utils.TimeUtil;
|
||||
import com.dahe.mylibrary.utils.ToastUtils;
|
||||
import com.esign.esignsdk.EsignSdk;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.sp.SPUtil;
|
||||
import com.gyf.cactus.Cactus;
|
||||
import com.gyf.cactus.callback.CactusBackgroundCallback;
|
||||
import com.gyf.cactus.callback.CactusCallback;
|
||||
import com.permissionx.guolindev.PermissionX;
|
||||
import com.tencent.bugly.crashreport.CrashReport;
|
||||
import com.umeng.commonsdk.UMConfigure;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.IOException;
|
||||
import java.util.Timer;
|
||||
import java.util.TimerTask;
|
||||
|
||||
import cn.jiguang.verifysdk.api.JVerificationInterface;
|
||||
|
||||
public class App extends Application {
|
||||
public class App extends Application implements CactusCallback {
|
||||
|
||||
// String key = "f9d35b1133cff1f6e3960c89b249e03f";
|
||||
String key = "19ac0aa74338e487e45057faf7212401";
|
||||
@@ -41,6 +54,7 @@ public class App extends Application {
|
||||
public static int APP_STATUS = APP_STATUS_KILLED; // 记录App的启动状态
|
||||
private Context con;
|
||||
public static App mApplication = null;
|
||||
|
||||
@Override
|
||||
public void onCreate() {
|
||||
super.onCreate();
|
||||
@@ -82,6 +96,11 @@ public class App extends Application {
|
||||
PendingIntent.getActivity(this, 0, new Intent(this, MainActivity.class), PendingIntent.FLAG_UPDATE_CURRENT);
|
||||
Cactus.getInstance()
|
||||
.isDebug(true)
|
||||
.setTitle("好运司机")
|
||||
.setContent("您的接单助手!")
|
||||
.setChannelId("gld")
|
||||
.setChannelName("好运司机")
|
||||
.setServiceId(Integer.MAX_VALUE)
|
||||
//可选,设置通知栏点击事件
|
||||
.setPendingIntent(pendingIntent)
|
||||
.setBackgroundMusicEnabled(true)//可选,退到后台是否可以播放音乐
|
||||
@@ -90,9 +109,8 @@ public class App extends Application {
|
||||
// .addCallback(new CactusCallback())//可选,运行时回调
|
||||
.setCrashRestartUIEnabled(true) //可选,设置奔溃可以重启,google原生rom android 10以下可以正常重启
|
||||
.setCrashRestartUIEnabled(true)//可选,设置奔溃可以重启,google原生rom android 10以下可以正常重启
|
||||
.setTitle("大河好运")
|
||||
.setContent("大河好运司机端为您提供服务")
|
||||
.setSmallIcon(R.drawable.diver_logo)
|
||||
.addCallback(this)
|
||||
.addBackgroundCallback(new CactusBackgroundCallback() {
|
||||
@Override
|
||||
public void onBackground(boolean b) {
|
||||
@@ -150,4 +168,62 @@ public class App extends Application {
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void doWork(int i) {
|
||||
|
||||
|
||||
new Timer().schedule(new TimerTask() {
|
||||
@Override
|
||||
public void run() {
|
||||
FileOutputStream fos = null;
|
||||
try {
|
||||
String nowString = TimeUtil.getNowString(TimeUtil.DEFAULT_FORMAT);
|
||||
String content = i + "当前时间:"+nowString;
|
||||
String fileName = "location" + ".txt";
|
||||
|
||||
if (Environment.getExternalStorageState().equals(
|
||||
Environment.MEDIA_MOUNTED)) {
|
||||
//获取文件输出路径
|
||||
String path = Environment.getExternalStorageDirectory()
|
||||
+ "/crashinfo2/";
|
||||
//创建文件夹和文件
|
||||
File dir = new File(path);
|
||||
if (!dir.exists()) {
|
||||
dir.mkdirs();
|
||||
}
|
||||
// File file = new File(path + fileName);
|
||||
// if (!file.exists())
|
||||
// file.createNewFile();
|
||||
//创建输出流
|
||||
fos = new FileOutputStream(path + fileName,true);
|
||||
File file = new File(path + fileName);
|
||||
if (file.exists()){
|
||||
fos.write('\r');
|
||||
}
|
||||
//向文件中写出数据
|
||||
fos.write(content.toString().getBytes());
|
||||
}
|
||||
|
||||
|
||||
fos.flush();
|
||||
fos.close();
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
} finally {
|
||||
try {
|
||||
if (fos != null) {
|
||||
fos.close();
|
||||
}
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
}, 100, 1000);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onStop() {
|
||||
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -66,11 +66,6 @@ public class CarDelBean {
|
||||
private String owner;
|
||||
private String roadLicense;
|
||||
private String roadLicensePhoto;
|
||||
private String trailerLicenseId;
|
||||
|
||||
private String policyPhotoUrl;
|
||||
private String insuranceCompany;
|
||||
private String insuranceEndDay;
|
||||
private String roadLicenseSend;
|
||||
private String roadLicenseValidity;
|
||||
private String threeImage;
|
||||
@@ -84,14 +79,6 @@ public class CarDelBean {
|
||||
private String carPlateColorValue;
|
||||
private String needUpQCPhoto;
|
||||
|
||||
public String getTrailerLicenseId() {
|
||||
return trailerLicenseId;
|
||||
}
|
||||
|
||||
public void setTrailerLicenseId(String trailerLicenseId) {
|
||||
this.trailerLicenseId = trailerLicenseId;
|
||||
}
|
||||
|
||||
public String getNeedUpQCPhoto() {
|
||||
return needUpQCPhoto;
|
||||
}
|
||||
@@ -108,30 +95,6 @@ public class CarDelBean {
|
||||
this.carPlateColorValue = carPlateColorValue;
|
||||
}
|
||||
|
||||
public String getPolicyPhotoUrl() {
|
||||
return policyPhotoUrl == null ? "" : policyPhotoUrl;
|
||||
}
|
||||
|
||||
public void setPolicyPhotoUrl(String policyPhotoUrl) {
|
||||
this.policyPhotoUrl = policyPhotoUrl;
|
||||
}
|
||||
|
||||
public String getInsuranceCompany() {
|
||||
return insuranceCompany == null ? "" : insuranceCompany;
|
||||
}
|
||||
|
||||
public void setInsuranceCompany(String insuranceCompany) {
|
||||
this.insuranceCompany = insuranceCompany;
|
||||
}
|
||||
|
||||
public String getInsuranceEndDay() {
|
||||
return insuranceEndDay == null ? "" : insuranceEndDay;
|
||||
}
|
||||
|
||||
public void setInsuranceEndDay(String insuranceEndDay) {
|
||||
this.insuranceEndDay = insuranceEndDay;
|
||||
}
|
||||
|
||||
public String getCarEnergyTypValue() {
|
||||
return carEnergyTypValue;
|
||||
}
|
||||
@@ -308,15 +271,6 @@ public class CarDelBean {
|
||||
private String threeImage;
|
||||
private String type;
|
||||
private String vehicleNumber;
|
||||
private String trailerLicenseId;
|
||||
|
||||
public String getTrailerLicenseId() {
|
||||
return trailerLicenseId;
|
||||
}
|
||||
|
||||
public void setTrailerLicenseId(String trailerLicenseId) {
|
||||
this.trailerLicenseId = trailerLicenseId;
|
||||
}
|
||||
|
||||
public String getBackImage() {
|
||||
return backImage == null ? "" : backImage;
|
||||
|
||||
@@ -48,33 +48,6 @@ public class DriverExpireBean {
|
||||
public static class DataDTO {
|
||||
private String driverLicenseUpdateUrl;
|
||||
private String idCardUpdateUrl;
|
||||
private String qualificationUpdateUrl;
|
||||
private String roadLicenseUpdateUrl;
|
||||
private String insuranceUpdateUrl;
|
||||
|
||||
public String getRoadLicenseUpdateUrl() {
|
||||
return roadLicenseUpdateUrl;
|
||||
}
|
||||
|
||||
public void setRoadLicenseUpdateUrl(String roadLicenseUpdateUrl) {
|
||||
this.roadLicenseUpdateUrl = roadLicenseUpdateUrl;
|
||||
}
|
||||
|
||||
public String getInsuranceUpdateUrl() {
|
||||
return insuranceUpdateUrl;
|
||||
}
|
||||
|
||||
public void setInsuranceUpdateUrl(String insuranceUpdateUrl) {
|
||||
this.insuranceUpdateUrl = insuranceUpdateUrl;
|
||||
}
|
||||
|
||||
public String getQualificationUpdateUrl() {
|
||||
return qualificationUpdateUrl;
|
||||
}
|
||||
|
||||
public void setQualificationUpdateUrl(String qualificationUpdateUrl) {
|
||||
this.qualificationUpdateUrl = qualificationUpdateUrl;
|
||||
}
|
||||
|
||||
public String getDriverLicenseUpdateUrl() {
|
||||
return driverLicenseUpdateUrl;
|
||||
|
||||
-9
@@ -59,7 +59,6 @@ public class OCRVehicleBackLicenseBean {
|
||||
private int id;
|
||||
private String url;
|
||||
private String checkRecord;
|
||||
private String isSave;
|
||||
private String approvedCapacity;
|
||||
private String allCapacity;
|
||||
private String size;
|
||||
@@ -72,14 +71,6 @@ public class OCRVehicleBackLicenseBean {
|
||||
private String carNumber;
|
||||
private int licenseId;
|
||||
|
||||
public String getIsSave() {
|
||||
return isSave;
|
||||
}
|
||||
|
||||
public void setIsSave(String isSave) {
|
||||
this.isSave = isSave;
|
||||
}
|
||||
|
||||
public int getLicenseId() {
|
||||
return licenseId;
|
||||
}
|
||||
|
||||
@@ -49,9 +49,7 @@ public class OCRVehicleLicenseBean {
|
||||
private String address;
|
||||
private int carId;
|
||||
private String carNumber;
|
||||
private boolean carExist;
|
||||
private String dateIssue;
|
||||
private String backImage;
|
||||
private String engineNumber;
|
||||
private int id;
|
||||
private String model;
|
||||
@@ -62,41 +60,6 @@ public class OCRVehicleLicenseBean {
|
||||
private String type;
|
||||
private String url;
|
||||
private String vehicleNumber;
|
||||
private String licenseId;
|
||||
|
||||
public String getLicenseId() {
|
||||
return licenseId;
|
||||
}
|
||||
|
||||
public void setLicenseId(String licenseId) {
|
||||
this.licenseId = licenseId;
|
||||
}
|
||||
|
||||
private DataDto2 existCarInfo;
|
||||
|
||||
public DataDto2 getExistCarInfo() {
|
||||
return existCarInfo;
|
||||
}
|
||||
|
||||
public void setExistCarInfo(DataDto2 existCarInfo) {
|
||||
this.existCarInfo = existCarInfo;
|
||||
}
|
||||
|
||||
public boolean isCarExist() {
|
||||
return carExist;
|
||||
}
|
||||
|
||||
public String getBackImage() {
|
||||
return backImage;
|
||||
}
|
||||
|
||||
public void setBackImage(String backImage) {
|
||||
this.backImage = backImage;
|
||||
}
|
||||
|
||||
public void setCarExist(boolean carExist) {
|
||||
this.carExist = carExist;
|
||||
}
|
||||
|
||||
public String getAddress() {
|
||||
return address == null ? "" : address;
|
||||
@@ -210,44 +173,4 @@ public class OCRVehicleLicenseBean {
|
||||
this.vehicleNumber = vehicleNumber;
|
||||
}
|
||||
}
|
||||
|
||||
public static class DataDto2 {
|
||||
private String backImage;
|
||||
private String carId;
|
||||
private String licenseId;
|
||||
|
||||
private CarDelBean.DataDTO trailerResVo;
|
||||
|
||||
public CarDelBean.DataDTO getTrailerResVo() {
|
||||
return trailerResVo;
|
||||
}
|
||||
|
||||
public void setTrailerResVo(CarDelBean.DataDTO trailerResVo) {
|
||||
this.trailerResVo = trailerResVo;
|
||||
}
|
||||
|
||||
public String getLicenseId() {
|
||||
return licenseId;
|
||||
}
|
||||
|
||||
public void setLicenseId(String licenseId) {
|
||||
this.licenseId = licenseId;
|
||||
}
|
||||
|
||||
public String getBackImage() {
|
||||
return backImage == null ? "" : backImage;
|
||||
}
|
||||
|
||||
public void setBackImage(String backImage) {
|
||||
this.backImage = backImage;
|
||||
}
|
||||
|
||||
public String getCarId() {
|
||||
return carId;
|
||||
}
|
||||
|
||||
public void setCarId(String carId) {
|
||||
this.carId = carId;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,21 +0,0 @@
|
||||
package com.arpa.hndahesudintocctmsdriver.event;
|
||||
|
||||
/**
|
||||
* @author hlh
|
||||
* @version 1.0.0
|
||||
* @date 2021/11/2 18:51
|
||||
* @description:
|
||||
*/
|
||||
public class RefreshCarListEvent {
|
||||
private String message;
|
||||
|
||||
public RefreshCarListEvent(String message) {
|
||||
this.message = message;
|
||||
}
|
||||
public String getMessage() {
|
||||
return message;
|
||||
}
|
||||
public void setMessage(String message) {
|
||||
this.message = message;
|
||||
}
|
||||
}
|
||||
@@ -124,17 +124,6 @@ public class AuthRequest {
|
||||
RequestUtil.start(1, "saveCarRoadLicenseNo", re, con, hd);
|
||||
}
|
||||
|
||||
//车辆交强保险
|
||||
public void saveTrafficInsurance(Context con, Handler hd, String id, String insuranceEndDay, String insuranceCompany) {
|
||||
String mt = "{\n" +
|
||||
"\t\"carId\": \"" + id + "\",\n" +
|
||||
"\t\"insuranceEndDay\": \"" + insuranceEndDay + "\",\n" +
|
||||
"\t\"insuranceCompany\": \"" + insuranceCompany + "\",\n" +
|
||||
"}";
|
||||
Request re = OkHttpUtil.posts(new OkDate(RequestConstant.getTrafficInsurance(), mt), getToken(con), con);
|
||||
RequestUtil.start(1, "saveTrafficInsurance", re, con, hd);
|
||||
}
|
||||
|
||||
//获取资格证认证信息
|
||||
public void isDriverAuthQualification(Context con, Handler hd) {
|
||||
Request re = OkHttpUtil.posts(new OkDate(RequestConstant.getIsAuthDriverAuthQualification(), ""), getToken(con), con);
|
||||
|
||||
@@ -89,11 +89,6 @@ public class HuoYuanRequset{
|
||||
Request re = OkHttpUtil.posts(new OkDate(RequestConstant.getUNLOADING(), gson.toJson(lub)),getToken(con),con);
|
||||
RequestUtil.start(1, ShangChuangImgActivity.TYPE_NAME[1],re,con,hd);
|
||||
}
|
||||
//卸货-补传
|
||||
public void dischargeCargo4(LUInputBean lub){
|
||||
Request re = OkHttpUtil.posts(new OkDate(RequestConstant.getUNLOADING4(), gson.toJson(lub)),getToken(con),con);
|
||||
RequestUtil.start(1, ShangChuangImgActivity.TYPE_NAME[1],re,con,hd);
|
||||
}
|
||||
//回单
|
||||
public void receipt(UploadReceiptInputBean urib){
|
||||
Request re = OkHttpUtil.posts(new OkDate(RequestConstant.getUploadReceipt(), gson.toJson(urib)),getToken(con),con);
|
||||
|
||||
@@ -49,8 +49,8 @@ public class OCRRequest {
|
||||
RequestUtil.start(12, CertificatesActivity.TYPE_NAME[2],re,con,hd);
|
||||
}
|
||||
//行驶证背面识别
|
||||
public void OCRVehicleLicenseBack(Context con, Handler hd, File file,String carId,String carNum,boolean isSave){
|
||||
Request re = OkHttpUtil.postFiles(new OkDate(RequestConstant.getVehicleLicenseBack()),file,getToken(con),carId,carNum,isSave);
|
||||
public void OCRVehicleLicenseBack(Context con, Handler hd, File file,String carId,String carNum){
|
||||
Request re = OkHttpUtil.postFiles(new OkDate(RequestConstant.getVehicleLicenseBack()),file,getToken(con),carId,carNum);
|
||||
RequestUtil.start(12, CertificatesActivity.TYPE_NAME_BANK[2],re,con,hd);
|
||||
}
|
||||
|
||||
|
||||
@@ -67,8 +67,6 @@ public class RequestConstant {
|
||||
private static final String LOADING="/app/driver/waybill/loadingV2";
|
||||
//卸货
|
||||
private static final String UNLOADING="/app/driver/waybill/unloadV2";
|
||||
//卸货-补传
|
||||
private static final String UNLOADING4 = "/app/driver/waybill/unloadV4";
|
||||
//上传回单
|
||||
private static final String UPLOAD_RECEIPT="/app/driver/waybill/uploadReceipt";
|
||||
//轨迹跟踪
|
||||
@@ -86,7 +84,7 @@ public class RequestConstant {
|
||||
//车辆详情
|
||||
private static final String GET_CAR_DEL="/app/carDriver/getCarInfo";
|
||||
//删除车辆
|
||||
private static final String DEL_CAR = "/app/carDriver/unBindCar";
|
||||
private static final String DEL_CAR="/app/carDriver/removeCar";
|
||||
//上传车辆照片
|
||||
private static final String SAVECARIMG="/app/carDriver/saveCarImg";
|
||||
//上传头像保存
|
||||
@@ -130,9 +128,6 @@ public class RequestConstant {
|
||||
private static final String DRIVER_AUTH_SAVECARREGISTERNO="/app/carDriver/saveCarRegisterNo";
|
||||
//道路运输信息
|
||||
private static final String DRIVER_AUTH_SAVECARROADLICENSENO="/app/carDriver/saveCarRoadLicenseNo";
|
||||
|
||||
//交强险
|
||||
private static final String DRIVER_TRAFFIC_INSU = "/app/carDriver/saveCarInsurace";
|
||||
//党员认证
|
||||
private static final String PARTY_MEMBER="/app/user/partyMember";
|
||||
//实名认证
|
||||
@@ -214,13 +209,9 @@ public class RequestConstant {
|
||||
return BASE_URL + BANK_CARD_LIST;
|
||||
}
|
||||
|
||||
public static String getXiaoXiListUrl() {
|
||||
return BASE_URL + XIAOXI_LIST;
|
||||
}
|
||||
public static String getXiaoXiListUrl() { return BASE_URL + XIAOXI_LIST; }
|
||||
|
||||
public static String getXiaoxiAll() {
|
||||
return BASE_URL + XIAOXI_ALL;
|
||||
}
|
||||
public static String getXiaoxiAll() { return BASE_URL +XIAOXI_ALL; }
|
||||
|
||||
public static String getOrderList() {
|
||||
return BASE_URL +ORDER_LIST;
|
||||
@@ -250,10 +241,6 @@ public class RequestConstant {
|
||||
return BASE_URL +UNLOADING;
|
||||
}
|
||||
|
||||
public static String getUNLOADING4() {
|
||||
return BASE_URL + UNLOADING4;
|
||||
}
|
||||
|
||||
public static String getGetEvaluate() {
|
||||
return BASE_URL +GET_EVALUATE;
|
||||
}
|
||||
@@ -306,25 +293,15 @@ public class RequestConstant {
|
||||
return BASE_URL +ISAUTH_IDCARD;
|
||||
}
|
||||
|
||||
public static String getIsauthDriverauthLicense() {
|
||||
return BASE_URL + ISAUTH_DRIVERAUTH_LICENSE;
|
||||
}
|
||||
public static String getIsauthDriverauthLicense() { return BASE_URL +ISAUTH_DRIVERAUTH_LICENSE; }
|
||||
|
||||
public static String getUploadReceipt() {
|
||||
return BASE_URL + UPLOAD_RECEIPT;
|
||||
}
|
||||
public static String getUploadReceipt() { return BASE_URL +UPLOAD_RECEIPT; }
|
||||
|
||||
public static String getUPLOAD() {
|
||||
return BASE_URL + UPLOAD;
|
||||
}
|
||||
public static String getUPLOAD() { return BASE_URL +UPLOAD; }
|
||||
|
||||
public static String getTrackTracking() {
|
||||
return BASE_URL + TRACK_TRACKING;
|
||||
}
|
||||
public static String getTrackTracking() {return BASE_URL +TRACK_TRACKING; }
|
||||
|
||||
public static String getEvaluationV2() {
|
||||
return BASE_URL + EVALUATION_V2;
|
||||
}
|
||||
public static String getEvaluationV2() { return BASE_URL +EVALUATION_V2; }
|
||||
|
||||
public static String getDRIVERAUTHIDCARD() {
|
||||
return BASE_URL +DRIVERAUTHIDCARD;
|
||||
@@ -342,49 +319,27 @@ public class RequestConstant {
|
||||
return BASE_URL +SAVECARIMG;
|
||||
}
|
||||
|
||||
public static String getUploadHead() {
|
||||
return BASE_URL + UPLOAD_HEAD;
|
||||
}
|
||||
public static String getUploadHead() { return BASE_URL +UPLOAD_HEAD; }
|
||||
|
||||
public static String getInsBankcard() {
|
||||
return BASE_URL +INS_BANKCARD;
|
||||
}
|
||||
|
||||
public static String getDelCar() {
|
||||
return BASE_URL + DEL_CAR;
|
||||
}
|
||||
public static String getDelCar() { return BASE_URL +DEL_CAR; }
|
||||
|
||||
public static String getXiaoxiDel() {
|
||||
return BASE_URL + XIAOXI_DEL;
|
||||
}
|
||||
public static String getXiaoxiDel() { return BASE_URL +XIAOXI_DEL; }
|
||||
|
||||
public static String getCOMPLAINT() {
|
||||
return BASE_URL + COMPLAINT;
|
||||
}
|
||||
public static String getCOMPLAINT() { return BASE_URL+COMPLAINT; }
|
||||
|
||||
public static String getXiaoxiDelAll() {
|
||||
return BASE_URL + XIAOXI_DEL_ALL;
|
||||
}
|
||||
public static String getXiaoxiDelAll() { return BASE_URL+XIAOXI_DEL_ALL; }
|
||||
|
||||
public static String getDriverAuthQualification() {
|
||||
return BASE_URL + DRIVER_AUTH_QUALIFICATION;
|
||||
}
|
||||
public static String getDriverAuthQualification() { return BASE_URL+DRIVER_AUTH_QUALIFICATION; }
|
||||
|
||||
public static String getDriverSaveCarRegisterNo() {
|
||||
return BASE_URL + DRIVER_AUTH_SAVECARREGISTERNO;
|
||||
}
|
||||
public static String getDriverSaveCarRegisterNo() { return BASE_URL+DRIVER_AUTH_SAVECARREGISTERNO; }
|
||||
|
||||
public static String getDriverSaveCarRoadLicenseNo() {
|
||||
return BASE_URL + DRIVER_AUTH_SAVECARROADLICENSENO;
|
||||
}
|
||||
public static String getDriverSaveCarRoadLicenseNo() { return BASE_URL+DRIVER_AUTH_SAVECARROADLICENSENO; }
|
||||
|
||||
public static String getTrafficInsurance() {
|
||||
return BASE_URL + DRIVER_TRAFFIC_INSU;
|
||||
}
|
||||
|
||||
public static String getSaveDrawCar() {
|
||||
return BASE_URL + SAVE_DRAW_CAR;
|
||||
}
|
||||
public static String getSaveDrawCar() { return BASE_URL+SAVE_DRAW_CAR; }
|
||||
|
||||
public static String getIsAuthDriverAuthQualification() {
|
||||
return BASE_URL+IS_AUTH_DRIVER_AUTH_QUALIFICATION;
|
||||
@@ -426,9 +381,7 @@ public class RequestConstant {
|
||||
return BASE_URL+WITHDRAWALS_CONFIG;
|
||||
}
|
||||
|
||||
public static String getGetErrorOrder() {
|
||||
return BASE_URL + GET_ERROR_ORDER;
|
||||
}
|
||||
public static String getGetErrorOrder() { return BASE_URL+GET_ERROR_ORDER; }
|
||||
|
||||
public static String getGetExampleList() {
|
||||
return BASE_URL+GET_EXAMPLE_LIST;
|
||||
|
||||
@@ -15,15 +15,6 @@ public class LUInputBean {
|
||||
private String locationAddress;
|
||||
private String longitude;
|
||||
private String waybillId;
|
||||
private String realLoadTime;
|
||||
|
||||
public String getRealLoadTime() {
|
||||
return realLoadTime;
|
||||
}
|
||||
|
||||
public void setRealLoadTime(String realLoadTime) {
|
||||
this.realLoadTime = realLoadTime;
|
||||
}
|
||||
|
||||
public List<Integer> getImageId() {
|
||||
return imageId;
|
||||
|
||||
@@ -10,7 +10,6 @@ import android.util.Log;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.arpa.hndahesudintocctmsdriver.R;
|
||||
import com.arpa.hndahesudintocctmsdriver.request.HuoYuanRequset;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.cache.CacheGroup;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.http.RequsetCodeConstants;
|
||||
@@ -28,14 +27,11 @@ public class MakeUpService extends Service {
|
||||
public void palyMp3(){
|
||||
Log.e("开始播放","-----");
|
||||
try {
|
||||
MediaPlayer mediaPlayer = MediaPlayer.create(this, R.raw.kujp9scu);
|
||||
mediaPlayer.setOnPreparedListener(new MediaPlayer.OnPreparedListener() {
|
||||
@Override
|
||||
public void onPrepared(MediaPlayer mediaPlayer) {
|
||||
AssetFileDescriptor fd =getAssets().openFd("kujp9scu.mp3");
|
||||
mediaPlayer.setDataSource(fd);
|
||||
mediaPlayer.setLooping(false);//设置为循环播放
|
||||
mediaPlayer.prepare();//初始化播放器MediaPlayer
|
||||
mediaPlayer.start();
|
||||
}
|
||||
});
|
||||
mediaPlayer.prepareAsync();
|
||||
Log.e("播放成功","-----");
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
|
||||
@@ -3,15 +3,12 @@ package com.arpa.hndahesudintocctmsdriver.service;
|
||||
import android.app.Service;
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.Environment;
|
||||
import android.os.Handler;
|
||||
import android.os.IBinder;
|
||||
import android.util.Log;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.amap.api.location.AMapLocation;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.FileIOUtils;
|
||||
import com.google.gson.Gson;
|
||||
import com.arpa.hndahesudintocctmsdriver.bean.BaseBean;
|
||||
import com.arpa.hndahesudintocctmsdriver.request.HuoYuanRequset;
|
||||
@@ -21,13 +18,8 @@ import com.arpa.hndahesudintocctmsdriver.util.sp.SPUtil;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.cache.CacheGroup;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.http.RequsetCodeConstants;
|
||||
|
||||
import java.io.File;
|
||||
import java.text.DateFormat;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
import java.util.Timer;
|
||||
import java.util.TimerTask;
|
||||
import java.util.logging.Filter;
|
||||
|
||||
/**
|
||||
* @author hlh
|
||||
@@ -40,7 +32,7 @@ public class TrackService extends Service {
|
||||
private Context con;
|
||||
private TrackInputBean tib=new TrackInputBean();
|
||||
private LocationGDUtil l;
|
||||
private int timeSum=1000*60;
|
||||
private int timeSum=1000*60*3;
|
||||
private String snn="";
|
||||
private Gson gson=new Gson();
|
||||
private HuoYuanRequset hyr;
|
||||
@@ -59,30 +51,7 @@ public class TrackService extends Service {
|
||||
}
|
||||
break;
|
||||
case LocationGDUtil.RES:
|
||||
if(CacheGroup.cacheList.get("getLocation")!=null){
|
||||
AMapLocation location = gson.fromJson(CacheGroup.cacheList.get("getLocation"), AMapLocation.class);
|
||||
String time2 = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(new Date());
|
||||
String time = new SimpleDateFormat("yyyy-MM-dd").format(new Date());
|
||||
// 当前时间:${time2},经纬度:${it.latitude}:${it.longitude}
|
||||
FileIOUtils.writeFileFromString(
|
||||
Environment.getExternalStorageDirectory()
|
||||
.toString() + "/crashinfo/" + "crash-"+time+".txt",
|
||||
"当前时间:"+time2+",经纬度:"+location.getLatitude()+":"+location.getLongitude(),
|
||||
true
|
||||
);
|
||||
// genzong(location);
|
||||
CacheGroup.cacheList.remove("getLocation");
|
||||
}
|
||||
break;
|
||||
case 16:
|
||||
String time2 = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").format(new Date());
|
||||
String time = new SimpleDateFormat("yyyy-MM-dd").format(new Date());
|
||||
FileIOUtils.writeFileFromString(
|
||||
Environment.getExternalStorageDirectory()
|
||||
.toString() + "/crashinfo/" + "crash-"+time+".txt",
|
||||
"当前时间:"+time2+",定位失败",
|
||||
true
|
||||
);
|
||||
genzong();
|
||||
break;
|
||||
}
|
||||
return false;
|
||||
@@ -125,13 +94,13 @@ public class TrackService extends Service {
|
||||
super.onDestroy();
|
||||
}
|
||||
|
||||
public void genzong(AMapLocation location){
|
||||
public void genzong(){
|
||||
//经度
|
||||
tib.setLatitude(location.getLatitude()+"");
|
||||
tib.setLatitude(l.getLatitude()+"");
|
||||
//纬度
|
||||
tib.setLongitude(location.getLongitude()+"");
|
||||
Log.e("经度",location.getLatitude()+"");
|
||||
Log.e("维度",location.getLongitude()+"");
|
||||
tib.setLongitude(l.getLongitude()+"");
|
||||
Log.e("经度",l.getLatitude()+"");
|
||||
Log.e("维度",l.getLongitude()+"");
|
||||
//单号
|
||||
tib.setShippingNoteNumber(snn);
|
||||
hyr.trackTracking(tib);
|
||||
|
||||
@@ -1,9 +1,6 @@
|
||||
package com.arpa.hndahesudintocctmsdriver.ui.alert;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.os.Build;
|
||||
import android.provider.Settings;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
@@ -58,7 +55,6 @@ public class UpAppAlert extends CenterPopupView {
|
||||
protected int getImplLayoutId() {
|
||||
return R.layout.alert_up_app;
|
||||
}
|
||||
|
||||
public UpAppAlert(@NonNull @NotNull Context context) {
|
||||
super(context);
|
||||
|
||||
@@ -92,9 +88,9 @@ public class UpAppAlert extends CenterPopupView {
|
||||
System.exit(1);
|
||||
});
|
||||
tv_confirm.setOnClickListener(v -> {
|
||||
new AppUpdater.Builder(con)
|
||||
new AppUpdater.Builder()
|
||||
.setUrl(url)
|
||||
.build()
|
||||
.build(con)
|
||||
.setUpdateCallback(new AppUpdateCallback() {
|
||||
@Override
|
||||
public void onStart(String url) {
|
||||
@@ -102,7 +98,6 @@ public class UpAppAlert extends CenterPopupView {
|
||||
tv_confirm.setVisibility(GONE);
|
||||
up_div.setVisibility(VISIBLE);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onProgress(long progress, long total, boolean isChange) {
|
||||
// Log.e("progress",progress+"");
|
||||
|
||||
-36
@@ -18,13 +18,10 @@ import android.widget.Toast;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.alibaba.fastjson.JSON;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.arpa.hndahesudintocctmsdriver.parts.UserParts;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.string.StringUtil;
|
||||
import com.bumptech.glide.Glide;
|
||||
import com.esign.esignsdk.EsignSdk;
|
||||
import com.esign.esignsdk.data.AuthEvent;
|
||||
import com.github.gzuliyujiang.wheelpicker.DatePicker;
|
||||
import com.github.gzuliyujiang.wheelpicker.annotation.DateMode;
|
||||
import com.google.gson.Gson;
|
||||
@@ -48,8 +45,6 @@ import com.arpa.hndahesudintocctmsdriver.util.statusbar.StateStyleUtil;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.view.BaseAppCompatActivity;
|
||||
import com.lxj.xpopup.util.SmartGlideImageLoader;
|
||||
|
||||
import org.greenrobot.eventbus.Subscribe;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.List;
|
||||
|
||||
@@ -106,7 +101,6 @@ public class AuthQualificationActivity extends BaseAppCompatActivity {
|
||||
BaseBean bb = gson.fromJson(CacheGroup.cacheList.get("driverAuthQualification"), BaseBean.class);
|
||||
if (bb.getCode() == 200) {
|
||||
// initAuth();
|
||||
isAuth = true;
|
||||
//判断是否从车辆进来 carId为空从个人认证进来需跳转实名认证,不为空车辆信息进入,需跳转车辆照片
|
||||
if (TextUtils.isEmpty(carId)) {
|
||||
//从业资格证->实名认证
|
||||
@@ -161,7 +155,6 @@ public class AuthQualificationActivity extends BaseAppCompatActivity {
|
||||
// finish();
|
||||
EsignSdk.getInstance().startH5Activity(act, StringUtil.isNull(String.valueOf(bb.getData()), ""));
|
||||
} else {
|
||||
finish();
|
||||
Toast.makeText(con, bb.getMsg(), Toast.LENGTH_LONG).show();
|
||||
}//Log.e("url",CacheGroup.cacheList.get("authUrl"));
|
||||
CacheGroup.cacheList.remove("authUrl");
|
||||
@@ -250,14 +243,12 @@ public class AuthQualificationActivity extends BaseAppCompatActivity {
|
||||
}
|
||||
});
|
||||
value2.setOnClickListener(v -> {
|
||||
if (!isAuth) {
|
||||
DatePicker picker = new DatePicker(this);
|
||||
picker.setBodyWidth(300);
|
||||
picker.setOnDatePickedListener((year, month, day) -> value2.setText(year + "-" + month + "-" + day));
|
||||
picker.getWheelLayout().setDateMode(DateMode.YEAR_MONTH_DAY);
|
||||
picker.getWheelLayout().setDateLabel("年", "月", "日");
|
||||
picker.show();
|
||||
}
|
||||
});
|
||||
submit.setOnClickListener(v -> {
|
||||
if (!isAuth) {
|
||||
@@ -388,31 +379,4 @@ public class AuthQualificationActivity extends BaseAppCompatActivity {
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Subscribe
|
||||
public void processResult(AuthEvent auth) {
|
||||
//添加实名/意愿/签署完成之后的逻辑
|
||||
Log.e("-回调信息-", auth.result);
|
||||
JSONObject jsonObject = JSON.parseObject(auth.result);
|
||||
if ("success".equalsIgnoreCase(jsonObject.getString("res"))) {
|
||||
if ("sign".equalsIgnoreCase(jsonObject.getString("key"))) {
|
||||
Toast.makeText(con, "签署场景成功", Toast.LENGTH_SHORT).show();
|
||||
} else if ("realName".equalsIgnoreCase(jsonObject.getString("key"))) {
|
||||
Toast.makeText(con, "实名认证成功", Toast.LENGTH_SHORT).show();
|
||||
} else {
|
||||
Toast.makeText(con, "意愿认证成功", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
finish();
|
||||
} else {
|
||||
if ("sign".equalsIgnoreCase(jsonObject.getString("key"))) {
|
||||
Toast.makeText(con, "签署场景失败", Toast.LENGTH_SHORT).show();
|
||||
} else if ("realName".equalsIgnoreCase(jsonObject.getString("key"))) {
|
||||
Toast.makeText(con, "实名认证失败", Toast.LENGTH_SHORT).show();
|
||||
} else {
|
||||
Toast.makeText(con, "意愿认证失败", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
EsignSdk.getInstance().finishH5Activity();
|
||||
finish();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+17
-84
@@ -37,7 +37,6 @@ import com.bumptech.glide.Glide;
|
||||
import com.bumptech.glide.request.RequestOptions;
|
||||
import com.bumptech.glide.request.target.Target;
|
||||
import com.dahe.mylibrary.utils.ActivityUtils;
|
||||
import com.dahe.mylibrary.utils.ToastUtils;
|
||||
import com.esign.esignsdk.EsignSdk;
|
||||
import com.esign.esignsdk.data.AuthEvent;
|
||||
import com.github.gzuliyujiang.wheelpicker.contract.OnOptionPickedListener;
|
||||
@@ -158,9 +157,6 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
|| CacheGroup.cacheList.get("saveVehicleLicense") != null || CacheGroup.cacheList.get("authUrl") != null
|
||||
|| CacheGroup.cacheList.get("saveDrawCar") != null) {
|
||||
if (CacheGroup.cacheList.get("driverAuthIdCard") != null) {
|
||||
if (customDialog != null) {
|
||||
customDialog.dismiss();
|
||||
}
|
||||
BaseBean bb = gson.fromJson(CacheGroup.cacheList.get("driverAuthIdCard"), BaseBean.class);
|
||||
if (bb.getCode() == 200) {
|
||||
Toast.makeText(con, "保存成功", Toast.LENGTH_SHORT).show();
|
||||
@@ -178,9 +174,6 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
}
|
||||
|
||||
if (CacheGroup.cacheList.get("driverAuthLicense") != null) {
|
||||
if (customDialog != null) {
|
||||
customDialog.dismiss();
|
||||
}
|
||||
BaseBean bb = gson.fromJson(CacheGroup.cacheList.get("driverAuthLicense"), BaseBean.class);
|
||||
if (bb.getCode() == 200) {
|
||||
Toast.makeText(con, "保存成功", Toast.LENGTH_SHORT).show();
|
||||
@@ -213,9 +206,6 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
}
|
||||
|
||||
if (CacheGroup.cacheList.get("saveVehicleLicense") != null) {
|
||||
if (customDialog != null) {
|
||||
customDialog.dismiss();
|
||||
}
|
||||
CarZhengBean czb = gson.fromJson(CacheGroup.cacheList.get("saveVehicleLicense"), CarZhengBean.class);
|
||||
if (czb.getCode() == 200) {
|
||||
String needUpQCPhoto = czb.getData().getNeedUpQCPhoto();//是否需要上传从业资格证
|
||||
@@ -224,19 +214,13 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
Toast.makeText(con, "车辆行驶证保存成功", Toast.LENGTH_SHORT).show();
|
||||
|
||||
VehicleEvent ve = new VehicleEvent(String.valueOf(czb.getData().getCarId()));
|
||||
EventBus.getDefault().postSticky(ve);
|
||||
EventBus.getDefault().post(ve);
|
||||
|
||||
// TODO: 2023/8/23
|
||||
if ("1".equals(isTrailer)) {//判断是否跳转挂车行驶证
|
||||
Intent in = new Intent(con, CertificatesActivity.class);
|
||||
in.putExtra("index", 3);
|
||||
in.putExtra("carId", String.valueOf(czb.getData().getCarId()));
|
||||
if (olb != null && olb.getData() != null && olb.getData().isCarExist()) {
|
||||
CarDelBean carDelBean = new CarDelBean();
|
||||
carDelBean.setRes(1);//保留字段 1:为绑定车辆,可以进行修改挂车信息
|
||||
carDelBean.setData(gson.fromJson(gson.toJson(olb.getData().getExistCarInfo()), CarDelBean.DataDTO.class));
|
||||
in.putExtra("cheData", gson.toJson(carDelBean));
|
||||
}
|
||||
startActivity(in);
|
||||
} else if ("1".equals(needUpQCPhoto)) {//判断是否跳转从业资格证
|
||||
Intent in = new Intent(con, AuthQualificationActivity.class);
|
||||
@@ -247,7 +231,6 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
} else if ("1".equals(needUpRLPhoto)) {//判断是否跳转道路运输许可证
|
||||
Intent in = new Intent(con, PhotoCarActivity.class);
|
||||
in.putExtra("type", 3);
|
||||
in.putExtra("carExist", true);
|
||||
in.putExtra("carId", String.valueOf(czb.getData().getCarId()));
|
||||
startActivity(in);
|
||||
} else {
|
||||
@@ -280,9 +263,6 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
CacheGroup.cacheList.remove("saveVehicleLicense");
|
||||
}
|
||||
if (CacheGroup.cacheList.get("saveDrawCar") != null) {
|
||||
if (customDialog != null) {
|
||||
customDialog.dismiss();
|
||||
}
|
||||
Log.e("-saveDrawCar-", CacheGroup.cacheList.get("saveDrawCar"));
|
||||
CarZhengBean bb = gson.fromJson(CacheGroup.cacheList.get("saveDrawCar"), CarZhengBean.class);
|
||||
if (bb.getCode() == 200) {
|
||||
@@ -303,7 +283,6 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
} else if ("1".equals(needUpRLPhoto)) {//现判断是否跳转道路运输许可证
|
||||
Intent in = new Intent(con, PhotoCarActivity.class);
|
||||
in.putExtra("type", 3);
|
||||
in.putExtra("carExist", true);
|
||||
in.putExtra("carId", carId);
|
||||
startActivity(in);
|
||||
} else {
|
||||
@@ -357,11 +336,8 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
}//Log.e("url",CacheGroup.cacheList.get("authUrl"));
|
||||
CacheGroup.cacheList.remove("authUrl");
|
||||
} else {
|
||||
//重复代码?
|
||||
initView(null);
|
||||
if (!(CacheGroup.cacheList.get(TYPE_NAME_BANK[2]) != null || CacheGroup.cacheList.get(TYPE_NAME_BANK[3]) != null)) {
|
||||
initData();
|
||||
}
|
||||
pathOrcRes();
|
||||
}
|
||||
break;
|
||||
@@ -439,7 +415,6 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
// there_div.setVisibility(View.VISIBLE);
|
||||
if (c_str != null && !c_str.equals("")) {
|
||||
cdb = gson.fromJson(c_str, CarDelBean.class);
|
||||
oCrcarId = cdb.getData().getTrailerResVo().getTrailerLicenseId() + "";
|
||||
initView(null);
|
||||
initData();
|
||||
} else {
|
||||
@@ -685,9 +660,7 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
break;
|
||||
case 3:
|
||||
Log.e("挂车信息", gson.toJson(cdb));
|
||||
if (cdb != null && cdb.getData().getTrailerResVo() != null
|
||||
&& !TextUtils.isEmpty(cdb.getData().getTrailerResVo().getFrontImage())
|
||||
&& !TextUtils.isEmpty(cdb.getData().getTrailerResVo().getBackImage())) {
|
||||
if (cdb != null && cdb.getData().getTrailerResVo() != null) {
|
||||
url1 = StringUtil.isNull(cdb.getData().getTrailerResVo().getFrontImage(), "");
|
||||
url2 = StringUtil.isNull(cdb.getData().getTrailerResVo().getBackImage(), "");
|
||||
url3 = StringUtil.isNull(cdb.getData().getTrailerResVo().getThreeImage(), "");
|
||||
@@ -696,17 +669,15 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
value3.setText(StringUtil.isNull(cdb.getData().getTrailerResVo().getOwner(), "空数据"));
|
||||
value4.setText(StringUtil.isNull(cdb.getData().getTrailerResVo().getVehicleNumber(), "空数据"));
|
||||
value6.setText(StringUtil.isNull(cdb.getData().getCarEnergyTypValue(), "空数据"));
|
||||
submit.setBackgroundResource(R.drawable.bg_btn_grey);
|
||||
Glide.with(con).load(url1).into(img1);
|
||||
Glide.with(con).load(url2).into(img2);
|
||||
Glide.with(con).load(url3).into(img3);
|
||||
if (cdb.getRes() != 1) {
|
||||
submit.setBackgroundResource(R.drawable.bg_btn_grey);
|
||||
u_img.setText("已上传");
|
||||
u_img2.setText("已上传");
|
||||
u_img3.setText("点击查看");
|
||||
isAuth = true;
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
@@ -765,8 +736,7 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
value1.setText(ocb.getData().getName());
|
||||
value2.setText(ocb.getData().getCardId());
|
||||
value3.setText(ocb.getData().getAddress());
|
||||
// Glide.with(con).load(url1).into(img1);
|
||||
Glide.with(con).load(path).into(img1);
|
||||
Glide.with(con).load(url1).into(img1);
|
||||
fontId = ocb.getData().getId();
|
||||
} else {
|
||||
Toast.makeText(con, "识别失败", Toast.LENGTH_SHORT).show();
|
||||
@@ -778,8 +748,7 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
if (ocbb.getCode() == 200) {
|
||||
url2 = ocbb.getData().getUrl();
|
||||
value4.setText(ocbb.getData().getEndTime());
|
||||
// Glide.with(con).load(url2).into(img2);
|
||||
Glide.with(con).load(path).into(img2);
|
||||
Glide.with(con).load(url2).into(img2);
|
||||
startTime = ocbb.getData().getStartTime();
|
||||
backId = ocbb.getData().getId();
|
||||
|
||||
@@ -803,8 +772,7 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
value2.setText(StringUtil.isNull(od.getStartTime(), "识别异常"));
|
||||
value3.setText(StringUtil.isNull(od.getAllowType(), "识别异常"));
|
||||
value4.setText(StringUtil.isNull(od.getEndTime(), "识别异常"));
|
||||
// Glide.with(con).load(url1).into(img1);
|
||||
Glide.with(con).load(path).into(img1);
|
||||
Glide.with(con).load(url1).into(img1);
|
||||
fontId = od.getId();
|
||||
} else {
|
||||
Toast.makeText(con, "识别失败", Toast.LENGTH_SHORT).show();
|
||||
@@ -816,8 +784,7 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
if (odlb.getCode() == 200) {
|
||||
url2 = odlb.getData().getUrl();
|
||||
backId = odlb.getData().getId();
|
||||
// Glide.with(con).load(url2).into(img2);
|
||||
Glide.with(con).load(path).into(img2);
|
||||
Glide.with(con).load(url2).into(img2);
|
||||
//自动调取提交功能,实现页面自动跳转
|
||||
subimt();
|
||||
} else {
|
||||
@@ -833,22 +800,13 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
Log.e("olb", CacheGroup.cacheList.get(TYPE_NAME[2]));
|
||||
olb = gson.fromJson(CacheGroup.cacheList.get(TYPE_NAME[2]), OCRVehicleLicenseBean.class);
|
||||
if (olb.getCode() == 200) {
|
||||
if (olb.getData().isCarExist()) {
|
||||
value1.setEnabled(false);
|
||||
Glide.with(con).load(olb.getData().getExistCarInfo().getBackImage()).into(img2);
|
||||
url2 = olb.getData().getExistCarInfo().getBackImage();
|
||||
ToastUtils.showLongToast(con, "该车辆已存在,请仔细核对相关信息");
|
||||
} else {
|
||||
value1.setEnabled(true);
|
||||
}
|
||||
url1 = olb.getData().getUrl();
|
||||
value1.setText(olb.getData().getCarNumber());
|
||||
value2.setText(olb.getData().getType());
|
||||
value3.setText(olb.getData().getOwner());
|
||||
value4.setText(olb.getData().getVehicleNumber());
|
||||
fontId = olb.getData().getId();
|
||||
// Glide.with(con).load(url1).into(img1);
|
||||
Glide.with(con).load(path).into(img1);
|
||||
Glide.with(con).load(url1).into(img1);
|
||||
oCrcarId = olb.getData().getCarId() + "";
|
||||
Log.e("-cardId-", oCrcarId);
|
||||
} else {
|
||||
@@ -861,9 +819,8 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
if (oblb.getCode() == 200) {
|
||||
url2 = oblb.getData().getUrl();
|
||||
backId = oblb.getData().getId();
|
||||
// Glide.with(con).load(url2).into(img2);
|
||||
Glide.with(con).load(path).into(img2);
|
||||
//自动调取提交功能,实现页面自动跳转实现页面自动跳转
|
||||
Glide.with(con).load(url2).into(img2);
|
||||
//自动调取提交功能,实现页面自动跳转
|
||||
subimt();
|
||||
} else {
|
||||
Toast.makeText(con, oblb.getMsg(), Toast.LENGTH_SHORT).show();
|
||||
@@ -875,8 +832,7 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
if (ub.getCode() == 200) {
|
||||
url3 = ub.getData().getUrl();
|
||||
fid = ub.getData().getId();
|
||||
// Glide.with(con).load(url3).into(img3);
|
||||
Glide.with(con).load(path).into(img3);
|
||||
Glide.with(con).load(url3).into(img3);
|
||||
} else {
|
||||
Toast.makeText(con, ub.getMsg(), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
@@ -920,7 +876,7 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
customDialog.dismiss();
|
||||
return;
|
||||
}
|
||||
new OCRRequest().OCRVehicleLicenseBack(con, hd, new File(path), oCrcarId, carNum, olb.getData().isCarExist());
|
||||
new OCRRequest().OCRVehicleLicenseBack(con, hd, new File(path), oCrcarId, carNum);
|
||||
|
||||
} else {
|
||||
new AuthRequest().upload(con, hd, new File(path));
|
||||
@@ -936,16 +892,7 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
customDialog.dismiss();
|
||||
return;
|
||||
}
|
||||
// if (cdb != null && cdb.getData().getTrailerResVo() &&cdb.getRes() == 1)
|
||||
boolean isExist = false;
|
||||
if (olb != null) {//主页识别成功后获取
|
||||
isExist = olb.getData().isCarExist();
|
||||
} else {
|
||||
if (cdb != null && cdb.getData().getTrailerResVo() != null && cdb.getRes() == 1) {//上个页面带来数据
|
||||
isExist = true;
|
||||
}
|
||||
}
|
||||
new OCRRequest().OCRVehicleLicenseBack(con, hd, new File(path), oCrcarId, carNum, isExist);
|
||||
new OCRRequest().OCRVehicleLicenseBack(con, hd, new File(path), oCrcarId, carNum);
|
||||
} else {
|
||||
new AuthRequest().upload(con, hd, new File(path));
|
||||
}
|
||||
@@ -968,8 +915,6 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
switch (index) {
|
||||
case 0:
|
||||
if (ocb != null && ocbb != null) {
|
||||
customDialog = new CustomDialog(con, "网络请求中...");
|
||||
customDialog.show();
|
||||
IDInputBean ib = new IDInputBean();
|
||||
ib.setIdcarName(str1);
|
||||
ib.setIdcard(str2);
|
||||
@@ -992,8 +937,6 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
//olb
|
||||
//{"档案编号","初次领证日期","准驾车型","有效期限(止)"},
|
||||
if (odl != null && odlb != null) {
|
||||
customDialog = new CustomDialog(con, "网络请求中...");
|
||||
customDialog.show();
|
||||
Log.e("ocr", new Gson().toJson(odl));
|
||||
LicenseInputBean iib = new LicenseInputBean();
|
||||
iib.setArchivesName(str1);
|
||||
@@ -1010,25 +953,20 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
if ((olb != null && !olb.getData().isCarExist() && oblb != null) || (olb != null && olb.getData().isCarExist())) {
|
||||
if (olb != null && oblb != null) {
|
||||
// if (curColor == null || curEnergy == null) {
|
||||
// Toast.makeText(con, "请完善内容", Toast.LENGTH_SHORT).show();
|
||||
// return;
|
||||
// }
|
||||
customDialog = new CustomDialog(con, "网络请求中...");
|
||||
customDialog.show();
|
||||
HashMap<String, Object> map = new HashMap<>();
|
||||
if ("".equals(url3)) {
|
||||
map.put("imgId", fid);
|
||||
}
|
||||
map.put("licenseId", olb.getData().isCarExist() ? olb.getData().getExistCarInfo().getLicenseId() : oblb.getData().getLicenseId());
|
||||
map.put("licenseId", oblb.getData().getLicenseId());
|
||||
map.put("carNumber", str1);
|
||||
map.put("type", str2);
|
||||
map.put("owner", str3);
|
||||
map.put("vehicleNumber", str4);
|
||||
// if (olb.getData().isCarExist()) {
|
||||
// map.put("carId", olb.getData().getCarId());
|
||||
// }
|
||||
// map.put("carPlateColor", curColor.getValue());
|
||||
// map.put("carEnergyTyp", curEnergy.getValue());
|
||||
new AuthRequest().saveVehicleLicense(con, hd, MapUtil.mapJson(map));
|
||||
@@ -1037,27 +975,22 @@ public class CertificatesActivity extends BaseAppCompatActivity {
|
||||
}
|
||||
break;
|
||||
case 3:
|
||||
if (olb != null || (cdb != null && cdb.getRes() == 1)) {
|
||||
if (olb != null && oblb != null) {
|
||||
// if (curEnergy==null){
|
||||
// Toast.makeText(con,"请完善内容",Toast.LENGTH_SHORT).show();
|
||||
// return;
|
||||
// }
|
||||
customDialog = new CustomDialog(con, "网络请求中...");
|
||||
customDialog.show();
|
||||
Map<String, Object> map = new HashMap<>();
|
||||
if ("".equals(url3)) {
|
||||
map.put("imgId", fid);
|
||||
}
|
||||
// map.put("licenseId", oblb.getData().getLicenseId());
|
||||
map.put("licenseId", oblb.getData().getLicenseId());
|
||||
map.put("carId", carId);
|
||||
map.put("carNumberDraw", str1);
|
||||
map.put("type", str2);
|
||||
map.put("owner", str3);
|
||||
// map.put("carEnergyTyp", curEnergy.getValue());
|
||||
map.put("vehicleNumber", str4);
|
||||
if (cdb != null && cdb.getRes() == 1 && cdb.getData() != null && cdb.getData().getTrailerResVo() != null) {
|
||||
map.put("oldTrailerNumber", cdb.getData().getTrailerResVo().getCarNumber());
|
||||
}
|
||||
new AuthRequest().saveDrawCar(con, hd, MapUtil.mapJson(map));
|
||||
} else {
|
||||
Toast.makeText(con, "请先上传资料", Toast.LENGTH_SHORT).show();
|
||||
|
||||
@@ -24,7 +24,6 @@ import com.arpa.hndahesudintocctmsdriver.bean.UploadBean;
|
||||
import com.arpa.hndahesudintocctmsdriver.request.AuthRequest;
|
||||
import com.arpa.hndahesudintocctmsdriver.request.UserRequset;
|
||||
import com.arpa.hndahesudintocctmsdriver.ui.my.WoDeFragment;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.alert.CustomDialog;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.cache.CacheGroup;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.file.ImageFileCompressUtil;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.img.GetImageAlert;
|
||||
@@ -32,8 +31,6 @@ import com.arpa.hndahesudintocctmsdriver.util.statusbar.StateStyleUtil;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.view.BaseAppCompatActivity;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.view.BaseRecyclerView;
|
||||
import com.bumptech.glide.Glide;
|
||||
import com.github.gzuliyujiang.wheelpicker.DatePicker;
|
||||
import com.github.gzuliyujiang.wheelpicker.annotation.DateMode;
|
||||
import com.google.gson.Gson;
|
||||
import com.luck.picture.lib.PictureSelector;
|
||||
import com.luck.picture.lib.config.PictureConfig;
|
||||
@@ -52,24 +49,23 @@ import java.util.List;
|
||||
*/
|
||||
public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnClickListener {
|
||||
|
||||
private String[] titles = {"车辆照片", "NFC照片", "车辆登记证书", "道路运输许可证", "车辆交强险"};
|
||||
private String[] name1 = {"车辆照片", "NFC照片", "车辆登记证书照片", "道路运输许可证照片", "车辆交强险照片"};
|
||||
private String[] name2 = {"请上传车辆照片", "请上传NFC照片", "请上传车辆登记证书照片", "请上传道路运输许可证照片", "请上传车辆交强险照片"};
|
||||
private Boolean[] isShowEdit = {false, false, true, true, true};
|
||||
private Boolean[] isShowSkip = {true, false, false, true, true};
|
||||
private String[] titles = {"车辆照片", "NFC照片", "车辆登记证书", "道路运输许可证"};
|
||||
private String[] name1 = {"车辆照片", "NFC照片", "车辆登记证书照片", "道路运输许可证照片"};
|
||||
private String[] name2 = {"请上传车辆照片", "请上传NFC照片", "请上传车辆登记证书照片", "请上传道路运输许可证照片"};
|
||||
private Boolean[] isShowEdit = {false, false, true, true};
|
||||
private Boolean[] isShowSkip = {true, false, false, true};
|
||||
private String[] tips = {
|
||||
"",
|
||||
"*注意: 没有粘贴NFC芯片的车辆无需上传,可直接跳过",
|
||||
"*注意: 没有可直接跳过,等候下次上传",
|
||||
"*注意: 4.5吨以下车辆不需要上传,可直接跳过",
|
||||
""};
|
||||
"*注意: 4.5吨以下车辆不需要上传,可直接跳过"};
|
||||
|
||||
|
||||
private BaseRecyclerView brv;
|
||||
private ImageView img;
|
||||
private TextView title1, title2, title3, zjimg_name, upload_img, tvTips, tvSkip, value2;
|
||||
private TextView title1, title2, title3, zjimg_name, upload_img, tvTips, tvSkip;
|
||||
private EditText value1;
|
||||
private LinearLayout llInfo, llDate;
|
||||
private LinearLayout llInfo;
|
||||
private RelativeLayout up_img;
|
||||
private Button submit;
|
||||
|
||||
@@ -79,9 +75,7 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
|
||||
private int type;//页面类型
|
||||
private String path, carId, url;//图片路径
|
||||
private boolean carExist = false;
|
||||
private GetImageAlert gia = new GetImageAlert();
|
||||
private CustomDialog customDialog;
|
||||
|
||||
@Override
|
||||
public void msgMethod(Message m) {
|
||||
@@ -115,16 +109,10 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
case 3:
|
||||
new AuthRequest().saveCarImg(con, hd, carId, ub.getData().getId(), 2);
|
||||
break;
|
||||
case 4:
|
||||
new AuthRequest().saveCarImg(con, hd, carId, ub.getData().getId(), 7);
|
||||
break;
|
||||
}
|
||||
url = ub.getData().getUrl();
|
||||
// Glide.with(con).load(url).into(img);
|
||||
Glide.with(con).load(path).into(img);
|
||||
Glide.with(con).load(url).into(img);
|
||||
|
||||
if (customDialog != null && customDialog.isShowing())
|
||||
customDialog.dismiss();
|
||||
CacheGroup.cacheList.remove("upload");
|
||||
}
|
||||
|
||||
@@ -144,9 +132,6 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
case 3:
|
||||
Toast.makeText(con, "上传道路运输证成功", Toast.LENGTH_SHORT).show();
|
||||
break;
|
||||
case 4:
|
||||
Toast.makeText(con, "交强险证件上传成功", Toast.LENGTH_SHORT).show();
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
Toast.makeText(con, bb.getMsg(), Toast.LENGTH_SHORT).show();
|
||||
@@ -173,13 +158,13 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
IsAuthDriverAuthQualificationBean ib = gson.fromJson(CacheGroup.cacheList.get("saveCarRoadLicenseNo"), IsAuthDriverAuthQualificationBean.class);
|
||||
if (ib.getCode() == 200) {
|
||||
//判断是否需要跳转挂车行驶证页面
|
||||
if (!"".equals(carId) && cdb.getData() != null) {
|
||||
if (cdb.getData().getIsTrailer() == 1 && cdb.getData().getTrailerResVo() != null && !TextUtils.isEmpty(cdb.getData().getTrailerResVo().getCarNumber())) {//需要挂车,并且传过挂车直接结束
|
||||
if (!"".equals(carId) ){
|
||||
if (cdb.getData().getIsTrailer() == 1&&!TextUtils.isEmpty(cdb.getData().getTrailerResVo().getCarNumber())){//需要挂车,并且传过挂车直接结束
|
||||
finish();
|
||||
Intent in = new Intent(con, AddCarSuccActivity.class);
|
||||
in.putExtra("type", 3);
|
||||
con.startActivity(in);
|
||||
} else if (cdb.getData().getIsTrailer() == 1 && cdb.getData().getTrailerResVo() != null && TextUtils.isEmpty(cdb.getData().getTrailerResVo().getCarNumber())) {//需要挂车,没传过挂车,到挂车页面
|
||||
}else if(cdb.getData().getIsTrailer() == 1&&TextUtils.isEmpty(cdb.getData().getTrailerResVo().getCarNumber())){//需要挂车,没传过挂车,到挂车页面
|
||||
finish();
|
||||
Intent in = new Intent(con, CertificatesActivity.class);
|
||||
in.putExtra("index", 3);
|
||||
@@ -202,11 +187,8 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
con.startActivity(in);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
finish();
|
||||
}
|
||||
|
||||
|
||||
// if (!"".equals(carId) && cdb.getData().getIsTrailer() == 1) {
|
||||
// if (!"".equals(carId)) {
|
||||
// finish();
|
||||
@@ -231,23 +213,8 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
}
|
||||
CacheGroup.cacheList.remove("saveCarRoadLicenseNo");
|
||||
}
|
||||
|
||||
if (CacheGroup.cacheList.get("saveTrafficInsurance") != null) {
|
||||
Log.e("is", CacheGroup.cacheList.get("saveTrafficInsurance"));
|
||||
IsAuthDriverAuthQualificationBean ddb = gson.fromJson(CacheGroup.cacheList.get("saveTrafficInsurance"), IsAuthDriverAuthQualificationBean.class);
|
||||
if (ddb.getCode() == 200) {
|
||||
Toast.makeText(con, "保存成功", Toast.LENGTH_SHORT).show();
|
||||
finish();
|
||||
} else {
|
||||
Toast.makeText(con, ddb.getMsg(), Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
|
||||
CacheGroup.cacheList.remove("saveTrafficInsurance");
|
||||
}
|
||||
break;
|
||||
case ImageFileCompressUtil.COMPRESS_SUCCESS:
|
||||
customDialog = new CustomDialog(con, "加载中...");
|
||||
customDialog.show();
|
||||
path = (String) m.obj;
|
||||
new AuthRequest().upload(con, hd, new File(path));
|
||||
break;
|
||||
@@ -266,7 +233,6 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
title1 = findViewById(R.id.title1);
|
||||
title2 = findViewById(R.id.title2);
|
||||
title3 = findViewById(R.id.name1);
|
||||
value2 = findViewById(R.id.value2);
|
||||
up_img = findViewById(R.id.up_img);
|
||||
img = findViewById(R.id.img);
|
||||
zjimg_name = findViewById(R.id.zjimg_name);
|
||||
@@ -274,7 +240,6 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
tvTips = findViewById(R.id.tvTips);
|
||||
value1 = findViewById(R.id.value1);
|
||||
llInfo = findViewById(R.id.llInfo);
|
||||
llDate = findViewById(R.id.llDate);
|
||||
tvSkip = findViewById(R.id.tvSkip);
|
||||
submit = findViewById(R.id.submit);
|
||||
|
||||
@@ -282,12 +247,10 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
submit.setOnClickListener(this);
|
||||
upload_img.setOnClickListener(this);
|
||||
img.setOnClickListener(this);
|
||||
value2.setOnClickListener(this);
|
||||
|
||||
|
||||
type = getIntent().getExtras().getInt("type");
|
||||
carId = getIntent().getExtras().getString("carId", "");
|
||||
carExist = getIntent().getExtras().getBoolean("carExist", false);
|
||||
changeViewByType(type);
|
||||
|
||||
ur = new UserRequset(con, hd);
|
||||
@@ -344,14 +307,6 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
case R.id.img:
|
||||
showBigImg();
|
||||
break;
|
||||
case R.id.value2:
|
||||
DatePicker picker = new DatePicker(this);
|
||||
picker.setBodyWidth(300);
|
||||
picker.setOnDatePickedListener((year, month, day) -> value2.setText(year + "-" + month + "-" + day));
|
||||
picker.getWheelLayout().setDateMode(DateMode.YEAR_MONTH_DAY);
|
||||
picker.getWheelLayout().setDateLabel("年", "月", "日");
|
||||
picker.show();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -360,7 +315,7 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
* 展示大图片
|
||||
*/
|
||||
private void showBigImg() {
|
||||
if ((type == 0 && TextUtils.isEmpty(cdb.getData().getRoadLicensePhoto())) || (type == 4 && TextUtils.isEmpty(cdb.getData().getPolicyPhotoUrl()))) {
|
||||
if (TextUtils.isEmpty(cdb.getData().getRoadLicensePhoto())){
|
||||
choicePhoto();
|
||||
return;
|
||||
}
|
||||
@@ -403,19 +358,6 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
.show();
|
||||
// new XPopup.Builder(con)
|
||||
// .asImageViewer(img, cdb.getData().getRoadLicensePhoto(), true, -1, -1, 50, false, new CertificatesActivity.ImageLoader())
|
||||
// .show();
|
||||
|
||||
break;
|
||||
}
|
||||
|
||||
case 4:
|
||||
if (cdb.getData().getPolicyPhotoUrl() != null && !"".equals(cdb.getData().getPolicyPhotoUrl())) {
|
||||
//roadLicensePhoto
|
||||
new XPopup.Builder(con)
|
||||
.asImageViewer(img, cdb.getData().getPolicyPhotoUrl(), new SmartGlideImageLoader(R.mipmap.ic_launcher))
|
||||
.show();
|
||||
// new XPopup.Builder(con)
|
||||
// .asImageViewer(img, cdb.getData().getRoadLicensePhoto(), true, -1, -1, 50, false, new CertificatesActivity.ImageLoader())
|
||||
// .show();
|
||||
|
||||
break;
|
||||
@@ -469,15 +411,6 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
}
|
||||
new AuthRequest().saveCarRoadLicenseNo(con,hd,carId,s1);
|
||||
break;
|
||||
case 4:
|
||||
String s2 = value1.getText().toString();
|
||||
String v2 = value2.getText().toString();
|
||||
if (TextUtils.isEmpty(s2) || TextUtils.isEmpty(v2)) {
|
||||
Toast.makeText(this, "请补充证件信息", Toast.LENGTH_SHORT).show();
|
||||
return;
|
||||
}
|
||||
new AuthRequest().saveTrafficInsurance(con, hd, carId, v2, s2);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -509,17 +442,6 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
if (!TextUtils.isEmpty(cdb.getData().getRoadLicensePhoto())) {
|
||||
Glide.with(con).load(cdb.getData().getRoadLicensePhoto()).into(img);
|
||||
value1.setText(cdb.getData().getRoadLicense());
|
||||
if (!carExist) {
|
||||
submit.setBackgroundResource(R.drawable.bg_btn_grey);
|
||||
upload_img.setText("已上传");
|
||||
}
|
||||
|
||||
}
|
||||
} else if (4 == type) {
|
||||
if (!TextUtils.isEmpty(cdb.getData().getPolicyPhotoUrl())) {
|
||||
Glide.with(con).load(cdb.getData().getPolicyPhotoUrl()).into(img);
|
||||
value1.setText(cdb.getData().getInsuranceCompany());
|
||||
value2.setText(cdb.getData().getInsuranceEndDay());
|
||||
submit.setBackgroundResource(R.drawable.bg_btn_grey);
|
||||
upload_img.setText("已上传");
|
||||
}
|
||||
@@ -605,10 +527,6 @@ public class PhotoCarActivity extends BaseAppCompatActivity implements View.OnCl
|
||||
tvTips.setText(tips[type]);
|
||||
tvSkip.setVisibility(isShowSkip[type] ? View.GONE : View.VISIBLE);
|
||||
llInfo.setVisibility(isShowEdit[type] ? View.VISIBLE : View.GONE);
|
||||
if (type == 4) {
|
||||
llDate.setVisibility(View.VISIBLE);
|
||||
title3.setText("保险公司");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
+3
-28
@@ -14,10 +14,7 @@ import android.widget.Toast;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.arpa.hndahesudintocctmsdriver.event.RefreshCarListEvent;
|
||||
import com.arpa.hndahesudintocctmsdriver.event.VehicleEvent;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.alert.ToastUtil;
|
||||
import com.dahe.mylibrary.utils.ToastUtils;
|
||||
import com.google.gson.Gson;
|
||||
import com.luck.picture.lib.PictureSelector;
|
||||
import com.luck.picture.lib.config.PictureConfig;
|
||||
@@ -41,7 +38,6 @@ import com.scwang.smart.refresh.layout.SmartRefreshLayout;
|
||||
|
||||
import org.greenrobot.eventbus.EventBus;
|
||||
import org.greenrobot.eventbus.Subscribe;
|
||||
import org.greenrobot.eventbus.ThreadMode;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.ArrayList;
|
||||
@@ -69,7 +65,7 @@ public class VehicleAuthActivity extends BaseAppCompatActivity {
|
||||
CacheGroup.cacheList.remove(CAR_AUDIO);
|
||||
}
|
||||
if(CacheGroup.cacheList.get(WoDeFragment.VEHICLE_DEL)!=null){
|
||||
Log.e("--res--lijia",CacheGroup.cacheList.get(WoDeFragment.VEHICLE_DEL));
|
||||
Log.e("--res--",CacheGroup.cacheList.get(WoDeFragment.VEHICLE_DEL));
|
||||
cdb=gson.fromJson(CacheGroup.cacheList.get(WoDeFragment.VEHICLE_DEL), CarDelBean.class);
|
||||
if(cdb.getCode()==200){
|
||||
initView(null);
|
||||
@@ -83,8 +79,6 @@ public class VehicleAuthActivity extends BaseAppCompatActivity {
|
||||
bb=gson.fromJson(CacheGroup.cacheList.get(DEL_CAR),BaseBean.class);
|
||||
if (bb.getCode()==200) {
|
||||
Toast.makeText(con,"删除成功",Toast.LENGTH_SHORT).show();
|
||||
RefreshCarListEvent ve = new RefreshCarListEvent("");
|
||||
EventBus.getDefault().post(ve);
|
||||
finish();
|
||||
}else{
|
||||
Toast.makeText(con,"删除失败:"+bb.getMsg(),Toast.LENGTH_SHORT).show();
|
||||
@@ -172,13 +166,6 @@ public class VehicleAuthActivity extends BaseAppCompatActivity {
|
||||
private GetImageAlert gia=new GetImageAlert();
|
||||
private boolean key1,key2,key3=false;
|
||||
|
||||
|
||||
@Override
|
||||
protected void onDestroy() {
|
||||
super.onDestroy();
|
||||
EventBus.getDefault().unregister(this);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void initView(Object obj) {
|
||||
super.initView(obj);
|
||||
@@ -220,12 +207,11 @@ public class VehicleAuthActivity extends BaseAppCompatActivity {
|
||||
RelativeLayout r5=v.findViewById(R.id.r5);
|
||||
RelativeLayout r6=v.findViewById(R.id.r6);
|
||||
RelativeLayout r7=v.findViewById(R.id.r7);
|
||||
RelativeLayout r8=v.findViewById(R.id.r8);
|
||||
View vs1=v.findViewById(R.id.vs1);
|
||||
View vs2=v.findViewById(R.id.vs2);
|
||||
r4.setVisibility(View.GONE);
|
||||
r5.setVisibility(View.GONE);
|
||||
// vs1.setVisibility(View.GONE);
|
||||
vs1.setVisibility(View.GONE);
|
||||
vs2.setVisibility(View.GONE);
|
||||
if(!"".equals(carId) && cdb.getData().getIsTrailer()==1){
|
||||
r4.setVisibility(View.VISIBLE);
|
||||
@@ -315,17 +301,6 @@ public class VehicleAuthActivity extends BaseAppCompatActivity {
|
||||
Toast.makeText(con,"请先绑定挂车",Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
});
|
||||
|
||||
r8.setOnClickListener(v1->{
|
||||
if(!"".equals(carId)){
|
||||
Intent in = new Intent(con, PhotoCarActivity.class);
|
||||
in.putExtra("type", 4);
|
||||
in.putExtra("carId", carId);
|
||||
con.startActivity(in);
|
||||
}else{
|
||||
Toast.makeText(con,"请先绑定行驶证",Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
});
|
||||
del.setOnClickListener(v13 -> {
|
||||
new XPopup.Builder(con)
|
||||
.isDestroyOnDismiss(true) //对于只使用一次的弹窗,推荐设置这个
|
||||
@@ -409,7 +384,7 @@ public class VehicleAuthActivity extends BaseAppCompatActivity {
|
||||
super.onResume();
|
||||
}
|
||||
|
||||
@Subscribe(threadMode = ThreadMode.MAIN, sticky = true)
|
||||
@Subscribe
|
||||
public void processResult(VehicleEvent event) {
|
||||
Log.e("-msg-",event.getMessage());
|
||||
if(!"挂".equals(event.getMessage())) {
|
||||
|
||||
@@ -241,9 +241,7 @@ public class HomeFragment extends BaseFragment {
|
||||
in.putExtra("url", deb.getData().getIdCardUpdateUrl());
|
||||
}
|
||||
}
|
||||
if (!TextUtils.isEmpty(deb.getData().getDriverLicenseUpdateUrl()) || !TextUtils.isEmpty(deb.getData().getIdCardUpdateUrl())||
|
||||
!TextUtils.isEmpty(deb.getData().getQualificationUpdateUrl())||!TextUtils.isEmpty(deb.getData().getRoadLicenseUpdateUrl())||
|
||||
!TextUtils.isEmpty(deb.getData().getInsuranceUpdateUrl())) {
|
||||
if (!"".equals(deb.getData().getDriverLicenseUpdateUrl()) || !"".equals(deb.getData().getIdCardUpdateUrl())) {
|
||||
new XToast<>(act)
|
||||
.setContentView(R.layout.view_bc)
|
||||
// 设置成可拖拽的
|
||||
@@ -547,6 +545,7 @@ public class HomeFragment extends BaseFragment {
|
||||
ur.getImage(1);
|
||||
|
||||
|
||||
|
||||
if (UiAuxiliary.isLogin(con)) {
|
||||
ur.User();
|
||||
ur.getDriverExpire();
|
||||
|
||||
@@ -8,7 +8,6 @@ import android.os.Bundle;
|
||||
import android.os.Handler;
|
||||
import android.os.Message;
|
||||
import android.text.Html;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import android.widget.Button;
|
||||
import android.widget.ImageButton;
|
||||
@@ -103,18 +102,14 @@ public class HuoYunDelActivity extends BaseAppCompatActivity {
|
||||
//Toast.makeText(con,"接单成功",Toast.LENGTH_SHORT).show();
|
||||
customDialog.dismiss();
|
||||
// EsignSdk.getInstance().startH5Activity(act, (String) bb.getData());
|
||||
if (null==bb.getData()){
|
||||
UiAuxiliary.homeRequest("接单");
|
||||
Intent in = new Intent(con, StartYunDanActivity.class);
|
||||
in.putExtra("id", "0");
|
||||
startActivity(in);
|
||||
finish();
|
||||
}else{
|
||||
|
||||
|
||||
Intent intent = new Intent(this, H5Activity.class);
|
||||
intent.putExtra("url", (String) bb.getData());
|
||||
intent.putExtra("view_file", false);
|
||||
startActivity(intent);
|
||||
}
|
||||
|
||||
|
||||
//finish();
|
||||
} else {
|
||||
Toast.makeText(con, bb.getMsg(), Toast.LENGTH_SHORT).show();
|
||||
|
||||
+2
-48
@@ -19,7 +19,6 @@ import com.alct.mdp.callback.OnResultListener;
|
||||
import com.alct.mdp.model.Goods;
|
||||
import com.alct.mdp.model.Image;
|
||||
import com.alct.mdp.model.Location;
|
||||
import com.arpa.hndahesudintocctmsdriver.BuildConfig;
|
||||
import com.arpa.hndahesudintocctmsdriver.bean.CarInfoBean;
|
||||
import com.arpa.hndahesudintocctmsdriver.report.ALProcess;
|
||||
import com.arpa.hndahesudintocctmsdriver.report.JTTProcess;
|
||||
@@ -94,15 +93,11 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
switch (m.what) {
|
||||
case RequsetCodeConstants.SUCCESS:
|
||||
if (CacheGroup.cacheList.get("upload") != null) {
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
Log.e("upload", CacheGroup.cacheList.get("upload"));
|
||||
ub = gson.fromJson(CacheGroup.cacheList.remove("upload"), UploadBean.class);
|
||||
if (ub.getCode() == 200) {
|
||||
imgIds.add(ub.getData().getId());
|
||||
// Glide.with(con).load(ub.getData().getUrl()).into(res_img);
|
||||
Glide.with(con).load(path).into(res_img);
|
||||
Glide.with(con).load(ub.getData().getUrl()).into(res_img);
|
||||
res_img.setVisibility(View.VISIBLE);
|
||||
img_delete.setVisibility(View.VISIBLE);
|
||||
img_icon.setVisibility(View.GONE);
|
||||
@@ -115,9 +110,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
for (int i = 0; i < TYPE_NAME.length; i++) {
|
||||
if (CacheGroup.cacheList.get(TYPE_NAME[i]) != null) {
|
||||
BaseBean bb = gson.fromJson(CacheGroup.cacheList.get(TYPE_NAME[i]), BaseBean.class);
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
if (bb.getCode() == 200) {
|
||||
if (index == 2) {
|
||||
if (!keys){//装货回单
|
||||
@@ -156,9 +148,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
hyr.uploadFile(new File(path));
|
||||
}
|
||||
} else {//识别失败后返回code500
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
if (index == 0) {//装卸货车辆需要识别车牌号){
|
||||
Toast.makeText(con, "装货照片包含车牌号、三分之二车身或者装卸货场景。", Toast.LENGTH_SHORT).show();
|
||||
} else if (index == 1) {
|
||||
@@ -171,9 +160,7 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
break;
|
||||
case 14://定位成功
|
||||
locationKey = true;
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
tv_loaction.setText("定位成功");
|
||||
tv_loaction.setTextColor(getResources().getColor(R.color.theme_color, null));
|
||||
latLng = convertGPSToBaidu(new LatLng(lgdu.getLatitude(), lgdu.getLongitude()));
|
||||
@@ -181,9 +168,7 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
break;
|
||||
case 16://定位失败
|
||||
locationKey = false;
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
tv_loaction.setText("定位失败,点击重试");
|
||||
tv_loaction.setTextColor(getResources().getColor(R.color.loaction_no_color, null));
|
||||
Toast.makeText(con, "定位失败,请确认开启定位后重试!", Toast.LENGTH_LONG).show();
|
||||
@@ -201,7 +186,7 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
// if(index==1 || index==2){
|
||||
// new OCRRequest().OCRPlateLicense(con,hd,new File(path));
|
||||
// }
|
||||
if ((index == 0 || index == 1) && !BuildConfig.isTest) {//装卸货车辆需要识别车牌号,测试环境不校验车牌号
|
||||
if (index == 0 || index == 1) {//装卸货车辆需要识别车牌号
|
||||
new OCRRequest().OCRCarPlateLicense(con, hd, new File(path));
|
||||
} else {
|
||||
hyr.uploadFile(new File(path));
|
||||
@@ -338,12 +323,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
path = gia.getFile().getPath();
|
||||
Log.e("图片地址:", path);
|
||||
gia.dis();
|
||||
|
||||
if (customDialog!=null&&!customDialog.isShowing()){
|
||||
customDialog = new CustomDialog(con, "网络请求中...");
|
||||
customDialog.show();
|
||||
}
|
||||
|
||||
ImageFileCompressUtil.imageFileCompress(con, new File(path), hd);
|
||||
} else if (requestCode == PictureConfig.CHOOSE_REQUEST && resultCode == RESULT_OK) {
|
||||
List<LocalMedia> imgs = PictureSelector.obtainMultipleResult(data);
|
||||
@@ -357,12 +336,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
path = paths;
|
||||
Log.e("图片地址:", path);
|
||||
gia.dis();
|
||||
|
||||
if (customDialog!=null&&!customDialog.isShowing()){
|
||||
customDialog = new CustomDialog(con, "网络请求中...");
|
||||
customDialog.show();
|
||||
}
|
||||
|
||||
ImageFileCompressUtil.imageFileCompress(con, new File(path), hd);
|
||||
}
|
||||
}
|
||||
@@ -378,10 +351,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
// }
|
||||
switch (index) {
|
||||
case 0:
|
||||
if (customDialog!=null&&!customDialog.isShowing()){
|
||||
customDialog = new CustomDialog(con, "网络请求中...");
|
||||
customDialog.show();
|
||||
}
|
||||
//装货
|
||||
if (imgIds != null && imgIds.size() > 0) {
|
||||
lub.setLatitude(lgdu.getLatitude() + "");
|
||||
@@ -563,9 +532,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
|
||||
@Override
|
||||
public void onSuccess() {
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
Log.e("上报安联", "装货照片上传成功");
|
||||
Toast.makeText(con, "上传成功", Toast.LENGTH_SHORT).show();
|
||||
finish();
|
||||
@@ -598,9 +564,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
|
||||
@Override
|
||||
public void onSuccess() {
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
Log.e("上报安联", "卸货照片上传成功");
|
||||
Toast.makeText(con, "上传成功", Toast.LENGTH_SHORT).show();
|
||||
finish();
|
||||
@@ -634,9 +597,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
|
||||
@Override
|
||||
public void onSuccess() {
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
Log.e("上报安联", "回单照片上传成功");
|
||||
Toast.makeText(con, "上传成功", Toast.LENGTH_SHORT).show();
|
||||
finish();
|
||||
@@ -714,9 +674,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
@Override
|
||||
public void onFailure(String s, String s1) {
|
||||
Log.e("上报安联失败(装货):", s + s1);
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
new MessageUtils().showCenMessage(con, s1);
|
||||
}
|
||||
});
|
||||
@@ -754,9 +711,6 @@ public class ShangChuangImgActivity extends BaseAppCompatActivity {
|
||||
@Override
|
||||
public void onFailure(String s, String s1) {
|
||||
Log.e("上报安联失败(卸货):", s + s1);
|
||||
if (!isFinishing()&&customDialog!=null&&customDialog.isShowing()){
|
||||
customDialog.dismiss();
|
||||
}
|
||||
new MessageUtils().showCenMessage(con, s1);
|
||||
}
|
||||
});
|
||||
|
||||
+37
-166
@@ -7,11 +7,8 @@ import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import android.view.Gravity;
|
||||
import android.view.View;
|
||||
import android.widget.Button;
|
||||
import android.widget.EditText;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.RelativeLayout;
|
||||
import android.widget.SimpleAdapter;
|
||||
import android.widget.TextView;
|
||||
import android.widget.Toast;
|
||||
|
||||
@@ -22,17 +19,6 @@ import com.alct.mdp.callback.OnResultListener;
|
||||
import com.alct.mdp.model.Goods;
|
||||
import com.alct.mdp.model.Image;
|
||||
import com.alct.mdp.model.Location;
|
||||
import com.amap.api.maps.CameraUpdateFactory;
|
||||
import com.amap.api.services.core.AMapException;
|
||||
import com.amap.api.services.core.LatLonPoint;
|
||||
import com.amap.api.services.geocoder.GeocodeAddress;
|
||||
import com.amap.api.services.geocoder.GeocodeQuery;
|
||||
import com.amap.api.services.geocoder.GeocodeResult;
|
||||
import com.amap.api.services.geocoder.GeocodeSearch;
|
||||
import com.amap.api.services.geocoder.RegeocodeResult;
|
||||
import com.amap.api.services.help.Inputtips;
|
||||
import com.amap.api.services.help.InputtipsQuery;
|
||||
import com.amap.api.services.help.Tip;
|
||||
import com.arpa.hndahesudintocctmsdriver.R;
|
||||
import com.arpa.hndahesudintocctmsdriver.bean.BaseBean;
|
||||
import com.arpa.hndahesudintocctmsdriver.bean.CarInfoBean;
|
||||
@@ -61,35 +47,22 @@ import com.arpa.hndahesudintocctmsdriver.util.view.BaseAppCompatActivity;
|
||||
import com.baidu.mapapi.model.LatLng;
|
||||
import com.baidu.mapapi.utils.CoordinateConverter;
|
||||
import com.bumptech.glide.Glide;
|
||||
import com.dahe.mylibrary.utils.ToastUtils;
|
||||
import com.github.gzuliyujiang.wheelpicker.DatePicker;
|
||||
import com.github.gzuliyujiang.wheelpicker.DatimePicker;
|
||||
import com.github.gzuliyujiang.wheelpicker.annotation.DateMode;
|
||||
import com.github.gzuliyujiang.wheelpicker.annotation.TimeMode;
|
||||
import com.github.gzuliyujiang.wheelpicker.contract.OnDatePickedListener;
|
||||
import com.github.gzuliyujiang.wheelpicker.contract.OnDatimePickedListener;
|
||||
import com.github.gzuliyujiang.wheelpicker.entity.DateEntity;
|
||||
import com.github.gzuliyujiang.wheelpicker.entity.DatimeEntity;
|
||||
import com.google.gson.Gson;
|
||||
import com.luck.picture.lib.PictureSelector;
|
||||
import com.luck.picture.lib.config.PictureConfig;
|
||||
import com.luck.picture.lib.entity.LocalMedia;
|
||||
import com.lxj.xpopup.XPopup;
|
||||
import com.lxj.xpopup.interfaces.OnSelectListener;
|
||||
import com.lxj.xpopup.util.SmartGlideImageLoader;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.UnsupportedEncodingException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
|
||||
public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements Inputtips.InputtipsListener {
|
||||
public class ShangChuangImgActivityBC extends BaseAppCompatActivity {
|
||||
|
||||
private TextView submit, name_top, name_body, address, tips, tips_x,tvDate,tvLocation;
|
||||
private TextView submit, name_top, name_body, address, tips, tips_x;
|
||||
private RelativeLayout getImg;
|
||||
private EditText etAddress;
|
||||
private Button btnOk;
|
||||
private ImageView res_img, img_icon, img_delete;
|
||||
private String[] names = {"装货", "卸货", "回单"};
|
||||
public static String[] TYPE_NAME = {"zhuanghuo", "xiehuo", "huidan"};
|
||||
@@ -113,64 +86,7 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
private boolean locationKey = false;
|
||||
private TextView tv_loaction;
|
||||
|
||||
|
||||
private String selDate;
|
||||
private GeocodeSearch geocoderSearch;
|
||||
|
||||
private TempLoca tempLoca = new TempLoca();
|
||||
private TempLoca tempLocaBd = new TempLoca();
|
||||
|
||||
|
||||
@Override
|
||||
public void onGetInputtips(List<Tip> tipList, int rCode) {
|
||||
if (rCode == AMapException.CODE_AMAP_SUCCESS) {
|
||||
List<String> names = new ArrayList<String>();
|
||||
if(tipList != null) {
|
||||
int size = tipList.size();
|
||||
for (int i = 0; i < size; i++) {
|
||||
Tip tip = tipList.get(i);
|
||||
if(tip != null) {
|
||||
names.add(tip.getDistrict()+tip.getName());
|
||||
}
|
||||
}
|
||||
|
||||
new XPopup.Builder(this)
|
||||
.isDestroyOnDismiss(true) //对于只使用一次的弹窗,推荐设置这个
|
||||
.hasShadowBg(false) // 去掉半透明背景
|
||||
.atView(etAddress)
|
||||
.asAttachList(names.toArray(new String[0]), new int[]{}, new OnSelectListener() {
|
||||
@Override
|
||||
public void onSelect(int position, String text) {
|
||||
Tip tip = tipList.get(position);
|
||||
etAddress.setText(tip.getDistrict()+tip.getAddress()+tip.getName());
|
||||
LatLonPoint latLonPoint = tip.getPoint();
|
||||
tempLoca.setAddress(etAddress.getText().toString());
|
||||
tempLoca.setLatitude(latLonPoint.getLatitude());
|
||||
tempLoca.setLongitude(latLonPoint.getLongitude());
|
||||
tempLoca.setTime(tvDate.getText().toString());
|
||||
|
||||
LatLng latLng = convertGPSToBaidu(new LatLng(latLonPoint.getLatitude(), latLonPoint.getLongitude()));
|
||||
tempLocaBd.setLongitude(latLng.longitude);
|
||||
tempLocaBd.setLatitude(latLng.latitude);
|
||||
tempLocaBd.setAddress(etAddress.getText().toString());
|
||||
tempLocaBd.setTime(tvDate.getText().toString());
|
||||
|
||||
}
|
||||
})
|
||||
.show();
|
||||
|
||||
|
||||
|
||||
// SimpleAdapter aAdapter = new SimpleAdapter(getApplicationContext(), listString, R.layout.item_layout,
|
||||
// new String[]{"name", "address"}, new int[]{R.id.poi_field_id, R.id.poi_value_id});
|
||||
//
|
||||
// minputlist.setAdapter(aAdapter);
|
||||
// aAdapter.notifyDataSetChanged();
|
||||
}
|
||||
|
||||
} else {
|
||||
}
|
||||
}
|
||||
private TempLoca tempLoca = new TempLoca(36.11944878,120.10315118,"中国山东省青岛市黄岛区铁峰山路","2023-09-23 11:19");
|
||||
|
||||
class TempLoca{
|
||||
private double latitude;
|
||||
@@ -359,10 +275,6 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
img_icon = findViewById(R.id.img_icon);
|
||||
img_delete = findViewById(R.id.img_delete);
|
||||
tv_loaction = findViewById(R.id.tv_loaction);
|
||||
btnOk = findViewById(R.id.btnOk);
|
||||
etAddress = findViewById(R.id.etAddress);
|
||||
tvDate = findViewById(R.id.tvDate);
|
||||
tvLocation = findViewById(R.id.tvLocation);
|
||||
tips = findViewById(R.id.tips);
|
||||
tips_x = findViewById(R.id.tips_x);
|
||||
Bundle ins = getIntent().getExtras();
|
||||
@@ -385,44 +297,6 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
lgdu.onCreate();
|
||||
}
|
||||
});
|
||||
|
||||
btnOk.setOnClickListener(v -> {
|
||||
String s = etAddress.getText().toString();
|
||||
if (TextUtils.isEmpty(selDate)){
|
||||
ToastUtils.showToast(this,"请先选择时间");
|
||||
return;
|
||||
}
|
||||
if (!TextUtils.isEmpty(s)&&s.length()>=4){
|
||||
|
||||
InputtipsQuery inputquery = new InputtipsQuery(s, "");
|
||||
// inputquery.setCityLimit(true);
|
||||
Inputtips inputTips = new Inputtips(this, inputquery);
|
||||
inputTips.setInputtipsListener(this);
|
||||
inputTips.requestInputtipsAsyn();
|
||||
|
||||
|
||||
// GeocodeQuery query = new GeocodeQuery(s, "100000");// 第一个参数表示地址,第二个参数表示查询城市,中文或者中文全拼,citycode、adcode,
|
||||
// geocoderSearch.getFromLocationNameAsyn(query);// 设置同步地理编码请求
|
||||
}else{
|
||||
ToastUtils.showToast(this,"请输入地址且长度大于4");
|
||||
}
|
||||
});
|
||||
|
||||
tvDate.setOnClickListener(v -> {
|
||||
|
||||
DatimePicker datimePicker = new DatimePicker(this);
|
||||
datimePicker.setBodyWidth(300);
|
||||
datimePicker.getWheelLayout().setRange(DatimeEntity.yearOnFuture(-1),DatimeEntity.yearOnFuture(10),DatimeEntity.now());
|
||||
datimePicker.setOnDatimePickedListener((year, month, day, hour, minute, second) -> {
|
||||
selDate = year+"-"+month+"-"+day+" "+ hour+":"+minute;
|
||||
tvDate.setText(selDate);
|
||||
});
|
||||
datimePicker.getWheelLayout().setDateLabel("年", "月", "日");
|
||||
datimePicker.getWheelLayout().setTimeLabel("时","分","");
|
||||
datimePicker.getWheelLayout().setTimeMode(TimeMode.HOUR_24_NO_SECOND);
|
||||
datimePicker.show();
|
||||
});
|
||||
|
||||
hyr = new HuoYuanRequset(con, hd);
|
||||
}
|
||||
|
||||
@@ -517,9 +391,9 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
case 0:
|
||||
//装货
|
||||
if (imgIds != null && imgIds.size() > 0) {
|
||||
lub.setLatitude(tempLoca.getLatitude() + "");
|
||||
lub.setLongitude(tempLoca.getLongitude() + "");
|
||||
lub.setLocationAddress(tempLoca.getAddress());
|
||||
lub.setLatitude(lgdu.getLatitude() + "");
|
||||
lub.setLongitude(lgdu.getLongitude() + "");
|
||||
lub.setLocationAddress(lgdu.getAddress());
|
||||
lub.setImageId(imgIds);
|
||||
lub.setWaybillId(wid);
|
||||
Log.e("--装货信息", gson.toJson(lub));
|
||||
@@ -546,9 +420,8 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
lub.setLocationAddress(tempLoca.getAddress());
|
||||
lub.setImageId(imgIds);
|
||||
lub.setWaybillId(wid);
|
||||
lub.setRealLoadTime(tempLoca.getTime());
|
||||
Log.e("--卸货信息", gson.toJson(lub));
|
||||
if (locationKey&&!TextUtils.isEmpty(tempLoca.address)) {
|
||||
if (locationKey) {
|
||||
if (keys) {
|
||||
nfc();
|
||||
uploadInfo();
|
||||
@@ -577,7 +450,7 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
urib.setWaybillId(wid);
|
||||
Log.e("--回单信息", gson.toJson(urib));
|
||||
if (locationKey) {
|
||||
if (index == 2 && keys && !TextUtils.isEmpty(tempLoca.address)) {
|
||||
if (index == 2 && keys) {
|
||||
up_trafficSign();
|
||||
up_trafficReceipt();
|
||||
receipt_image();
|
||||
@@ -622,10 +495,10 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
public void up_trafficSign() {
|
||||
//安联
|
||||
Location l = new Location();
|
||||
l.setBaiduLongitude(tempLocaBd.longitude);
|
||||
l.setBaiduLatitude(tempLocaBd.latitude);
|
||||
l.setLocation(tempLocaBd.getAddress());
|
||||
l.setTime(tempLocaBd.getTime());
|
||||
l.setBaiduLongitude(tempLoca.longitude);
|
||||
l.setBaiduLatitude(tempLoca.latitude);
|
||||
l.setLocation(tempLoca.getAddress());
|
||||
l.setTime(tempLoca.getTime());
|
||||
List<Goods> gs = new ArrayList<>();
|
||||
for (StartOrderBean.DataDTO.WayChildrenDTO wayChild : sob.getData().getWayChildren()) {
|
||||
if (wid.equals(wayChild.getId() + "")) {
|
||||
@@ -662,10 +535,10 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
public void up_trafficReceipt() {
|
||||
//安联
|
||||
Location l = new Location();
|
||||
l.setBaiduLongitude(tempLocaBd.longitude);
|
||||
l.setBaiduLatitude(tempLocaBd.latitude);
|
||||
l.setLocation(tempLocaBd.getAddress());
|
||||
l.setTime(tempLocaBd.getTime());
|
||||
l.setBaiduLongitude(tempLoca.longitude);
|
||||
l.setBaiduLatitude(tempLoca.latitude);
|
||||
l.setLocation(tempLoca.getAddress());
|
||||
l.setTime(tempLoca.getTime());
|
||||
MDPLocationCollectionManager.pod(con, sob.getData().getShippingNoteNumber(), l, new OnResultListener() {
|
||||
|
||||
@Override
|
||||
@@ -690,9 +563,9 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
image.setFileExt(FileUtil.lastName(file));
|
||||
image.setFileName(FileUtil.fileName(file));
|
||||
image.setImageTakenDate(Timer.getTimerT());
|
||||
image.setBaiduLongitude(tempLocaBd.longitude);
|
||||
image.setBaiduLatitude(tempLocaBd.latitude);
|
||||
image.setLocation(tempLocaBd.getAddress());
|
||||
image.setBaiduLongitude(latLng.longitude);
|
||||
image.setBaiduLatitude(latLng.latitude);
|
||||
image.setLocation(lgdu.getAddress());
|
||||
MDPLocationCollectionManager.uploadPickupImage(con, sob.getData().getShippingNoteNumber(), image, new OnResultListener() {
|
||||
|
||||
@Override
|
||||
@@ -721,10 +594,10 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
image.setFileData("data:image/" + FileUtil.lastName(file) + ";base64," + base);
|
||||
image.setFileExt(FileUtil.lastName(file));
|
||||
image.setFileName(FileUtil.fileName(file));
|
||||
image.setImageTakenDate(tempLocaBd.getTime());
|
||||
image.setBaiduLongitude(tempLocaBd.longitude);
|
||||
image.setBaiduLatitude(tempLocaBd.latitude);
|
||||
image.setLocation(tempLocaBd.getAddress());
|
||||
image.setImageTakenDate(tempLoca.getTime());
|
||||
image.setBaiduLongitude(tempLoca.longitude);
|
||||
image.setBaiduLatitude(tempLoca.latitude);
|
||||
image.setLocation(tempLoca.getAddress());
|
||||
MDPLocationCollectionManager.uploadUnloadImage(con, sob.getData().getShippingNoteNumber(), image, new OnResultListener() {
|
||||
|
||||
@Override
|
||||
@@ -754,10 +627,10 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
image.setFileData("data:image/" + FileUtil.lastName(file) + ";base64," + base);
|
||||
image.setFileExt(FileUtil.lastName(file));
|
||||
image.setFileName(FileUtil.fileName(file));
|
||||
image.setImageTakenDate(tempLocaBd.getTime());
|
||||
image.setBaiduLongitude(tempLocaBd.longitude);
|
||||
image.setBaiduLatitude(tempLocaBd.latitude);
|
||||
image.setLocation(tempLocaBd.getAddress());
|
||||
image.setImageTakenDate(tempLoca.getTime());
|
||||
image.setBaiduLongitude(tempLoca.longitude);
|
||||
image.setBaiduLatitude(tempLoca.latitude);
|
||||
image.setLocation(tempLoca.getAddress());
|
||||
MDPLocationCollectionManager.uploadPODImage(con, sob.getData().getShippingNoteNumber(), image, new OnResultListener() {
|
||||
|
||||
@Override
|
||||
@@ -818,10 +691,10 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
//安联
|
||||
if (sob.getData().getReportAlct() == 1) {
|
||||
Location l = new Location();
|
||||
l.setBaiduLongitude(tempLocaBd.longitude);
|
||||
l.setBaiduLatitude(tempLocaBd.latitude);
|
||||
l.setLocation(tempLocaBd.getAddress());
|
||||
l.setTime(tempLocaBd.getTime());
|
||||
l.setBaiduLongitude(latLng.longitude);
|
||||
l.setBaiduLatitude(latLng.latitude);
|
||||
l.setLocation(lgdu.getAddress());
|
||||
l.setTime(Timer.getTimerT());
|
||||
MDPLocationCollectionManager.pickup(con, sob.getData().getShippingNoteNumber(), l, new OnResultListener() {
|
||||
@Override
|
||||
public void onSuccess() {
|
||||
@@ -854,10 +727,10 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
//安联
|
||||
if (sob.getData().getReportAlct() == 1) {
|
||||
Location l = new Location();
|
||||
l.setBaiduLongitude(tempLocaBd.longitude);
|
||||
l.setBaiduLatitude(tempLocaBd.latitude);
|
||||
l.setLocation(tempLocaBd.getAddress());
|
||||
l.setTime(tempLocaBd.getTime());
|
||||
l.setBaiduLongitude(tempLoca.longitude);
|
||||
l.setBaiduLatitude(tempLoca.latitude);
|
||||
l.setLocation(tempLoca.getAddress());
|
||||
l.setTime(tempLoca.getTime());
|
||||
Log.e("-安联卸货信息-", gson.toJson(l));
|
||||
MDPLocationCollectionManager.unload(con, sob.getData().getShippingNoteNumber(), l, new OnResultListener() {
|
||||
@Override
|
||||
@@ -868,7 +741,7 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
JTTProcess.stop(con, sob, "");
|
||||
}
|
||||
//卸货状态-平台
|
||||
hyr.dischargeCargo4(lub);
|
||||
hyr.dischargeCargo(lub);
|
||||
//卸货照片-安联
|
||||
up_image();
|
||||
}
|
||||
@@ -876,9 +749,7 @@ public class ShangChuangImgActivityBC extends BaseAppCompatActivity implements I
|
||||
@Override
|
||||
public void onFailure(String s, String s1) {
|
||||
Log.e("上报安联失败(卸货):", s + s1);
|
||||
// new MessageUtils().showCenMessage(con, s1);
|
||||
//运单状态不一致,平台更新状态
|
||||
hyr.dischargeCargo4(lub);
|
||||
new MessageUtils().showCenMessage(con, s1);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
@@ -1,14 +1,8 @@
|
||||
package com.arpa.hndahesudintocctmsdriver.ui.login;
|
||||
|
||||
import android.content.Context;
|
||||
import android.content.Intent;
|
||||
import android.net.wifi.WifiManager;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
import android.os.Message;
|
||||
import android.provider.Settings;
|
||||
import android.telecom.TelecomManager;
|
||||
import android.telephony.TelephonyManager;
|
||||
import android.text.SpannableStringBuilder;
|
||||
import android.text.TextPaint;
|
||||
import android.text.method.LinkMovementMethod;
|
||||
@@ -44,7 +38,6 @@ import com.arpa.hndahesudintocctmsdriver.util.http.RequsetCodeConstants;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.statusbar.StatusBarUtil;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.view.BaseActivity;
|
||||
|
||||
import java.util.Locale;
|
||||
import java.util.TimerTask;
|
||||
|
||||
import cn.jiguang.verifysdk.api.AuthPageEventListener;
|
||||
@@ -153,7 +146,7 @@ public class LoginActivity extends BaseActivity {
|
||||
ConfigBean cb = ConfigParts.getConfigParts(con);
|
||||
if (cb != null) {
|
||||
url1 = cb.getData().getUserUrl();
|
||||
url2 = "http://agreement.dahehuoyun.com/currency/#/";
|
||||
url2 = "https://agreement.dahehuoyun.com/huawei/#/private";
|
||||
}
|
||||
TextView tv_content = findViewById(R.id.tv_content);
|
||||
String str = "我已阅读并同意相关服务条款和隐私政策《用户服务协议》和《隐私政策》";
|
||||
|
||||
@@ -138,8 +138,8 @@ public class WelcomeActivity extends BaseAppCompatActivity {
|
||||
new XPopup.Builder(con)
|
||||
.dismissOnBackPressed(false)
|
||||
.dismissOnTouchOutside(false)
|
||||
.asCustom(new AgreementAlert(con, "http://agreement.dahehuoyun.com/currency/#/",
|
||||
"http://agreement.dahehuoyun.com/rule/serviceAgreement/dist/index.html#/", hd))
|
||||
.asCustom(new AgreementAlert(con, "https://agreement.dahehuoyun.com/huawei/#/private",
|
||||
"http://agreement.dahehuoyun.com/#/user", hd))
|
||||
.show();
|
||||
}
|
||||
Glide.with(con)
|
||||
|
||||
@@ -18,7 +18,6 @@ import androidx.annotation.NonNull;
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.arpa.hndahesudintocctmsdriver.event.PersonEvent;
|
||||
import com.arpa.hndahesudintocctmsdriver.event.RefreshCarListEvent;
|
||||
import com.arpa.hndahesudintocctmsdriver.event.VehicleEvent;
|
||||
import com.arpa.hndahesudintocctmsdriver.parts.ConfigParts;
|
||||
import com.arpa.hndahesudintocctmsdriver.parts.StartOrderParts;
|
||||
@@ -171,14 +170,12 @@ public class MyFragment extends BaseFragment {
|
||||
startActivity(in);
|
||||
});
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
default:break;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
class Model {
|
||||
}
|
||||
class Model{ }
|
||||
|
||||
public void getRequest(){
|
||||
sob= StartOrderParts.getStartOrder(con);
|
||||
@@ -299,13 +296,6 @@ public class MyFragment extends BaseFragment {
|
||||
ur.vehicleList("1");
|
||||
}
|
||||
}
|
||||
|
||||
@Subscribe
|
||||
public void refreshCarListEvent(RefreshCarListEvent event) {
|
||||
Log.e("-msg-", event.getMessage());
|
||||
ur.vehicleList("1");
|
||||
}
|
||||
|
||||
@Subscribe
|
||||
public void personResult(PersonEvent home) {
|
||||
Log.e("-res-", home.getMessage());
|
||||
|
||||
@@ -35,7 +35,7 @@ public class SetupActivity extends BaseActivity {
|
||||
String url2="";
|
||||
String url3="";
|
||||
String kefu="";
|
||||
private RelativeLayout r1,r2,r3,r4,r5,r6,r7,r8;
|
||||
private RelativeLayout r1,r2,r3,r4,r5,r6,r7;
|
||||
|
||||
@Override
|
||||
public void msgMethod(Message m) {
|
||||
@@ -73,9 +73,8 @@ public class SetupActivity extends BaseActivity {
|
||||
ConfigBean cb= ConfigParts.getConfigParts(con);
|
||||
if(cb!=null){
|
||||
// url1=cb.getData().getUserUrl();
|
||||
url1="http://agreement.dahehuoyun.com/rule/serviceAgreement/dist/index.html#/";
|
||||
// url2=cb.getData().getPrivateUrl();
|
||||
url2="http://agreement.dahehuoyun.com/currency/#/";
|
||||
url1="https://agreement.dahehuoyun.com/huawei/#/private";
|
||||
url2=cb.getData().getPrivateUrl();
|
||||
kefu=cb.getData().getServiceMobile();
|
||||
url3=cb.getData().getSecurityUrl();
|
||||
}
|
||||
@@ -86,7 +85,6 @@ public class SetupActivity extends BaseActivity {
|
||||
r5=findViewById(R.id.r5);
|
||||
r6=findViewById(R.id.r6);
|
||||
r7=findViewById(R.id.r7);
|
||||
r8=findViewById(R.id.r8);
|
||||
ur=new UserRequset(con,hd);
|
||||
initView(null);
|
||||
}
|
||||
@@ -120,12 +118,6 @@ public class SetupActivity extends BaseActivity {
|
||||
in.putExtra("url","https://smlt.esign.cn/hmfbZoeeGQqv");
|
||||
startActivity(in);
|
||||
});
|
||||
r8.setOnClickListener(v12 -> {
|
||||
Intent in=new Intent(con,WebActivity.class);
|
||||
in.putExtra("title","交易规则");
|
||||
in.putExtra("url","http://agreement.dahehuoyun.com/rule/transactionRules/dist/index.html#/");
|
||||
startActivity(in);
|
||||
});
|
||||
r6.setOnClickListener(v12 -> {
|
||||
String[] title={"平台客服:"+kefu,"银行客服:95528","技术咨询:13460042961"};
|
||||
String[] value={kefu,"95528","13460042961"};
|
||||
|
||||
@@ -1,14 +1,21 @@
|
||||
package com.arpa.hndahesudintocctmsdriver.ui.news;
|
||||
|
||||
import android.content.Intent;
|
||||
import android.net.Uri;
|
||||
import android.os.Build;
|
||||
import android.os.Bundle;
|
||||
import android.os.Environment;
|
||||
import android.provider.Settings;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
import androidx.fragment.app.Fragment;
|
||||
|
||||
import com.arpa.hndahesudintocctmsdriver.R;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.alert.ToastUtil;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.statusbar.StateStyleUtil;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.view.BaseAppCompatActivity;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.view.BottomTabUtil;
|
||||
import com.dahe.mylibrary.utils.ToastUtils;
|
||||
|
||||
/**
|
||||
* @author hlh
|
||||
@@ -27,6 +34,33 @@ public class NewActivity extends BaseAppCompatActivity {
|
||||
fs[0] =new NewsFragment();
|
||||
BottomTabUtil bt =new BottomTabUtil(this,R.id.body, fs);
|
||||
bt.selectItem(fs[0]);
|
||||
|
||||
|
||||
|
||||
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) {
|
||||
if (!Environment.isExternalStorageManager()) {
|
||||
Intent intent = new Intent(Settings.ACTION_MANAGE_APP_ALL_FILES_ACCESS_PERMISSION);
|
||||
intent.setData(Uri.parse("package:" + getPackageName()));
|
||||
this.startActivityForResult(intent, 1024);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
private boolean isRefuse = false;
|
||||
@Override
|
||||
protected void onActivityResult(int requestCode, int resultCode, @Nullable Intent data) {
|
||||
super.onActivityResult(requestCode, resultCode, data);
|
||||
if (requestCode == 1024 && Build.VERSION.SDK_INT >= Build.VERSION_CODES.R) {
|
||||
// 检查是否有权限
|
||||
if (Environment.isExternalStorageManager()) {
|
||||
isRefuse = false;
|
||||
ToastUtils.showToast(this,"授权成功");
|
||||
// 授权成功
|
||||
} else {
|
||||
isRefuse = true;
|
||||
ToastUtils.showToast(this,"授权失败");
|
||||
// 授权失败
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,7 +5,6 @@ import android.os.Bundle;
|
||||
import android.os.Message;
|
||||
import android.text.TextUtils;
|
||||
import android.util.Log;
|
||||
import android.view.View;
|
||||
import android.widget.EditText;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
@@ -13,8 +12,6 @@ import android.widget.Toast;
|
||||
|
||||
import androidx.annotation.Nullable;
|
||||
|
||||
import com.arpa.hndahesudintocctmsdriver.weight.OnLimitClickHelper;
|
||||
import com.arpa.hndahesudintocctmsdriver.weight.OnLimitClickListener;
|
||||
import com.bumptech.glide.Glide;
|
||||
import com.google.gson.Gson;
|
||||
import com.arpa.hndahesudintocctmsdriver.R;
|
||||
@@ -43,7 +40,7 @@ import java.util.List;
|
||||
* @date 2021/8/26 19:06
|
||||
* @description:
|
||||
*/
|
||||
public class UpBankActivity extends BaseAppCompatActivity implements OnLimitClickListener {
|
||||
public class UpBankActivity extends BaseAppCompatActivity {
|
||||
|
||||
private ImageView up_bank_img;
|
||||
private EditText bank_name,bank_number;
|
||||
@@ -74,7 +71,6 @@ public class UpBankActivity extends BaseAppCompatActivity implements OnLimitClic
|
||||
if(CacheGroup.cacheList.get("insBank")!=null){
|
||||
BaseBean bb=new Gson().fromJson(CacheGroup.cacheList.get("insBank"),BaseBean.class);
|
||||
if(bb.getCode()==200){
|
||||
customDialog.dismiss();
|
||||
Toast.makeText(con,"绑定成功",Toast.LENGTH_SHORT).show();
|
||||
finish();
|
||||
}else{
|
||||
@@ -110,7 +106,13 @@ public class UpBankActivity extends BaseAppCompatActivity implements OnLimitClic
|
||||
up_bank_img.setOnClickListener(v -> {
|
||||
gia.showPopueWindow(this);
|
||||
});
|
||||
submit.setOnClickListener(new OnLimitClickHelper(this));
|
||||
submit.setOnClickListener(v -> {
|
||||
if(ib!=null){
|
||||
submit();
|
||||
}else{
|
||||
Toast.makeText(con,"请先上传图片",Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
});
|
||||
return_btn.setOnClickListener(v -> {
|
||||
finish();
|
||||
});
|
||||
@@ -150,8 +152,6 @@ public class UpBankActivity extends BaseAppCompatActivity implements OnLimitClic
|
||||
}
|
||||
|
||||
public void submit(){
|
||||
customDialog = new CustomDialog(con, "上传中,请稍后...");
|
||||
customDialog.show();
|
||||
String bankName=bank_name.getText().toString().trim();
|
||||
String bankNumber=bank_number.getText().toString().trim();
|
||||
if("".equals(bankName) || "".equals(bankNumber)){
|
||||
@@ -168,16 +168,4 @@ public class UpBankActivity extends BaseAppCompatActivity implements OnLimitClic
|
||||
qr.insBankCard(ibib);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onClick(View view) {
|
||||
switch (view.getId()) {
|
||||
case R.id.submit:
|
||||
if (ib != null) {
|
||||
submit();
|
||||
} else {
|
||||
Toast.makeText(con, "请先上传图片", Toast.LENGTH_SHORT).show();
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,240 +0,0 @@
|
||||
package com.arpa.hndahesudintocctmsdriver.util;
|
||||
|
||||
import com.arpa.hndahesudintocctmsdriver.FileUtils;
|
||||
|
||||
import java.io.BufferedOutputStream;
|
||||
import java.io.BufferedReader;
|
||||
import java.io.BufferedWriter;
|
||||
import java.io.File;
|
||||
import java.io.FileInputStream;
|
||||
import java.io.FileOutputStream;
|
||||
import java.io.FileWriter;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.io.InputStreamReader;
|
||||
import java.io.OutputStream;
|
||||
|
||||
/**
|
||||
* @ClassName FileIOUtils
|
||||
* @Author john
|
||||
* @Date 2024/3/29 09:50
|
||||
* @Description TODO
|
||||
*/
|
||||
public class FileIOUtils {
|
||||
|
||||
private FileIOUtils() {
|
||||
throw new UnsupportedOperationException("u can't instantiate me...");
|
||||
}
|
||||
|
||||
private static final String LINE_SEP = System.getProperty("line.separator");
|
||||
|
||||
/**
|
||||
* 将输入流写入文件
|
||||
*
|
||||
* @param filePath 路径
|
||||
* @param is 输入流
|
||||
* @return {@code true}: 写入成功<br>{@code false}: 写入失败
|
||||
*/
|
||||
public static boolean writeFileFromIS(String filePath, final InputStream is) {
|
||||
return writeFileFromIS(FileUtils.getFileByPath(filePath), is, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将输入流写入文件
|
||||
*
|
||||
* @param filePath 路径
|
||||
* @param is 输入流
|
||||
* @param append 是否追加在文件末
|
||||
* @return {@code true}: 写入成功<br>{@code false}: 写入失败
|
||||
*/
|
||||
public static boolean writeFileFromIS(String filePath, final InputStream is, boolean append) {
|
||||
return writeFileFromIS(FileUtils.getFileByPath(filePath), is, append);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将输入流写入文件
|
||||
*
|
||||
* @param file 文件
|
||||
* @param is 输入流
|
||||
* @return {@code true}: 写入成功<br>{@code false}: 写入失败
|
||||
*/
|
||||
public static boolean writeFileFromIS(File file, final InputStream is) {
|
||||
return writeFileFromIS(file, is, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将输入流写入文件
|
||||
*
|
||||
* @param file 文件
|
||||
* @param is 输入流
|
||||
* @param append 是否追加在文件末
|
||||
* @return {@code true}: 写入成功<br>{@code false}: 写入失败
|
||||
*/
|
||||
public static boolean writeFileFromIS(File file, final InputStream is, boolean append) {
|
||||
if (!FileUtils.createOrExistsFile(file) || is == null) return false;
|
||||
OutputStream os = null;
|
||||
try {
|
||||
os = new BufferedOutputStream(new FileOutputStream(file, append));
|
||||
byte data[] = new byte[1024];
|
||||
int len;
|
||||
while ((len = is.read(data, 0, 1024)) != -1) {
|
||||
os.write(data, 0, len);
|
||||
}
|
||||
return true;
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
return false;
|
||||
} finally {
|
||||
try {
|
||||
is.close();
|
||||
os.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 将字符串写入文件
|
||||
*
|
||||
* @param filePath 文件路径
|
||||
* @param content 写入内容
|
||||
* @return {@code true}: 写入成功<br>{@code false}: 写入失败
|
||||
*/
|
||||
public static boolean writeFileFromString(String filePath, String content) {
|
||||
return writeFileFromString(FileUtils.getFileByPath(filePath), content, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将字符串写入文件
|
||||
*
|
||||
* @param filePath 文件路径
|
||||
* @param content 写入内容
|
||||
* @param append 是否追加在文件末
|
||||
* @return {@code true}: 写入成功<br>{@code false}: 写入失败
|
||||
*/
|
||||
public static boolean writeFileFromString(String filePath, String content, boolean append) {
|
||||
return writeFileFromString(FileUtils.getFileByPath(filePath), content, append);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将字符串写入文件
|
||||
*
|
||||
* @param file 文件
|
||||
* @param content 写入内容
|
||||
* @return {@code true}: 写入成功<br>{@code false}: 写入失败
|
||||
*/
|
||||
public static boolean writeFileFromString(File file, String content) {
|
||||
return writeFileFromString(file, content, false);
|
||||
}
|
||||
|
||||
/**
|
||||
* 将字符串写入文件
|
||||
*
|
||||
* @param file 文件
|
||||
* @param content 写入内容
|
||||
* @param append 是否追加在文件末
|
||||
* @return {@code true}: 写入成功<br>{@code false}: 写入失败
|
||||
*/
|
||||
public static boolean writeFileFromString(File file, String content, boolean append) {
|
||||
if (file == null || content == null) return false;
|
||||
if (!FileUtils.createOrExistsFile(file)) return false;
|
||||
BufferedWriter bw = null;
|
||||
try {
|
||||
bw = new BufferedWriter(new FileWriter(file, append));
|
||||
bw.write(content);
|
||||
bw.newLine();
|
||||
return true;
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
return false;
|
||||
} finally {
|
||||
try {
|
||||
bw.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 读取文件到字符串中
|
||||
*
|
||||
* @param filePath 文件路径
|
||||
* @return 字符串
|
||||
*/
|
||||
public static String readFile2String(String filePath) {
|
||||
return readFile2String(FileUtils.getFileByPath(filePath), null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 读取文件到字符串中
|
||||
*
|
||||
* @param filePath 文件路径
|
||||
* @param charsetName 编码格式
|
||||
* @return 字符串
|
||||
*/
|
||||
public static String readFile2String(String filePath, String charsetName) {
|
||||
return readFile2String(FileUtils.getFileByPath(filePath), charsetName);
|
||||
}
|
||||
|
||||
/**
|
||||
* 读取文件到字符串中
|
||||
*
|
||||
* @param file 文件
|
||||
* @return 字符串
|
||||
*/
|
||||
public static String readFile2String(File file) {
|
||||
return readFile2String(file, null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 读取文件到字符串中
|
||||
*
|
||||
* @param file 文件
|
||||
* @param charsetName 编码格式
|
||||
* @return 字符串
|
||||
*/
|
||||
public static String readFile2String(File file, String charsetName) {
|
||||
if (!FileUtils.isFileExists(file)) return null;
|
||||
BufferedReader reader = null;
|
||||
try {
|
||||
StringBuilder sb = new StringBuilder();
|
||||
if (isSpace(charsetName)) {
|
||||
reader = new BufferedReader(new InputStreamReader(new FileInputStream(file)));
|
||||
} else {
|
||||
reader = new BufferedReader(new InputStreamReader(new FileInputStream(file), charsetName));
|
||||
}
|
||||
String line;
|
||||
while ((line = reader.readLine()) != null) {
|
||||
sb.append(line).append(LINE_SEP);
|
||||
}
|
||||
// delete the last line separator
|
||||
return sb.delete(sb.length() - LINE_SEP.length(), sb.length()).toString();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
return null;
|
||||
} finally {
|
||||
try {
|
||||
reader.close();
|
||||
} catch (IOException e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private static boolean isSpace(String s) {
|
||||
if (s == null) return true;
|
||||
for (int i = 0, len = s.length(); i < len; ++i) {
|
||||
if (!Character.isWhitespace(s.charAt(i))) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -3,7 +3,6 @@ package com.arpa.hndahesudintocctmsdriver.util.http;
|
||||
import android.content.Context;
|
||||
|
||||
import com.arpa.hndahesudintocctmsdriver.util.app.VersionUtil;
|
||||
import com.dahe.mylibrary.utils.AppUtils;
|
||||
|
||||
import java.io.File;
|
||||
|
||||
@@ -42,7 +41,6 @@ public class OkHttpUtil {
|
||||
.post(body)
|
||||
.headers(hb.build())
|
||||
.addHeader("Version", VersionUtil.getVersion(con))
|
||||
.addHeader("VersionCode",String.valueOf(AppUtils.getAppVersionCode()))
|
||||
//.addHeader("sign",sign)
|
||||
.removeHeader("User-Agent")
|
||||
.addHeader("User-Agent",GetUtil.getUserAgent(con))
|
||||
@@ -73,7 +71,6 @@ public class OkHttpUtil {
|
||||
.addHeader("Authorization", token)
|
||||
.addHeader("Content-Type", "application/json")
|
||||
.addHeader("Version", VersionUtil.getVersion(con))
|
||||
.addHeader("VersionCode",String.valueOf(AppUtils.getAppVersionCode()))
|
||||
//.addHeader("sign",sign)
|
||||
.removeHeader("User-Agent")
|
||||
.addHeader("User-Agent",GetUtil.getUserAgent(con))
|
||||
@@ -89,7 +86,6 @@ public class OkHttpUtil {
|
||||
.url(od.getUrl())
|
||||
.get()
|
||||
.headers(hb.build())
|
||||
.addHeader("VersionCode",String.valueOf(AppUtils.getAppVersionCode()))
|
||||
.build();
|
||||
return request;
|
||||
}
|
||||
@@ -103,7 +99,6 @@ public class OkHttpUtil {
|
||||
Request request = new Request.Builder()
|
||||
.url(od.getUrl())
|
||||
.addHeader("Authorization", token)
|
||||
.addHeader("VersionCode",String.valueOf(AppUtils.getAppVersionCode()))
|
||||
.get()
|
||||
.headers(hb.build())
|
||||
.build();
|
||||
@@ -134,7 +129,6 @@ public class OkHttpUtil {
|
||||
.url(od.getUrl())
|
||||
.method("POST", body)
|
||||
.addHeader("Authorization", token)
|
||||
.addHeader("VersionCode",String.valueOf(AppUtils.getAppVersionCode()))
|
||||
.addHeader("Cookie", "JSESSIONID=NqpqKQstwceQurcNK5hjl4GnTgiF4eSzZSo5a1rz")
|
||||
.build();
|
||||
return request;
|
||||
@@ -151,26 +145,23 @@ public class OkHttpUtil {
|
||||
.url(od.getUrl())
|
||||
.method("POST", body)
|
||||
.addHeader("Authorization", token)
|
||||
.addHeader("VersionCode",String.valueOf(AppUtils.getAppVersionCode()))
|
||||
.addHeader("Cookie", "JSESSIONID=NqpqKQstwceQurcNK5hjl4GnTgiF4eSzZSo5a1rz")
|
||||
.build();
|
||||
return request;
|
||||
}
|
||||
|
||||
public static Request postFiles(OkDate od,File file,String token,String carId,String carNum,boolean isSave) {
|
||||
public static Request postFiles(OkDate od,File file,String token,String carId,String carNum) {
|
||||
MediaType mediaType = MediaType.parse("text/plain");
|
||||
RequestBody body = new MultipartBody.Builder()
|
||||
.setType(MultipartBody.FORM)
|
||||
.addFormDataPart("file",file.getPath(),RequestBody.create(MediaType.parse("application/octet-stream"), file))
|
||||
.addFormDataPart("carId",carId)
|
||||
.addFormDataPart("carNum",carNum)
|
||||
.addFormDataPart("isSave",isSave?"0":"1")
|
||||
.build();
|
||||
Request request = new Request.Builder()
|
||||
.url(od.getUrl())
|
||||
.method("POST", body)
|
||||
.addHeader("Authorization", token)
|
||||
.addHeader("VersionCode",String.valueOf(AppUtils.getAppVersionCode()))
|
||||
.addHeader("Cookie", "JSESSIONID=NqpqKQstwceQurcNK5hjl4GnTgiF4eSzZSo5a1rz")
|
||||
.build();
|
||||
return request;
|
||||
|
||||
@@ -9,8 +9,6 @@ import android.provider.MediaStore;
|
||||
|
||||
import androidx.core.content.FileProvider;
|
||||
|
||||
import com.dahe.mylibrary.utils.AppUtils;
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.text.SimpleDateFormat;
|
||||
@@ -41,7 +39,7 @@ public class ImageGetUtil {
|
||||
if(imageFile!=null){
|
||||
if(Build.VERSION.SDK_INT>= Build.VERSION_CODES.N){
|
||||
/*7.0以上要通过FileProvider将File转化为Uri*/
|
||||
uri = FileProvider.getUriForFile(act.getApplicationContext(), AppUtils.getAppPackageName()+".fileprovider",imageFile);
|
||||
uri = FileProvider.getUriForFile(act.getApplicationContext(),"com.arpa.hndahesudintocctmsdriver.fileprovider",imageFile);
|
||||
}else {
|
||||
/*7.0以下则直接使用Uri的fromFile方法将File转化为Uri*/
|
||||
uri = Uri.fromFile(imageFile);
|
||||
|
||||
@@ -8,9 +8,7 @@ import com.amap.api.location.AMapLocation;
|
||||
import com.amap.api.location.AMapLocationClient;
|
||||
import com.amap.api.location.AMapLocationClientOption;
|
||||
import com.amap.api.location.AMapLocationListener;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.cache.CacheGroup;
|
||||
import com.arpa.hndahesudintocctmsdriver.util.msg.MsgUtil;
|
||||
import com.google.gson.Gson;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Date;
|
||||
@@ -76,7 +74,6 @@ public class LocationGDUtil {
|
||||
SimpleDateFormat df = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||
Date date = new Date(aMapLocation.getTime());
|
||||
df.format(date);
|
||||
CacheGroup.cacheList.put("getLocation",new Gson().toJson(aMapLocation));
|
||||
MsgUtil.addHdMsgWat(hd,RES);
|
||||
if (mLocationClient!=null) {
|
||||
mLocationClient.onDestroy();
|
||||
|
||||
@@ -1,38 +0,0 @@
|
||||
package com.arpa.hndahesudintocctmsdriver.weight;
|
||||
|
||||
import android.view.View;
|
||||
import android.widget.Toast;
|
||||
|
||||
import com.arpa.hndahesudintocctmsdriver.util.alert.ToastUtil;
|
||||
import com.dahe.mylibrary.utils.ToastUtils;
|
||||
|
||||
import java.util.Calendar;
|
||||
|
||||
/**
|
||||
* @ClassName OnLimitClickHelper
|
||||
* @Author john
|
||||
* @Date 2024/4/22 14:28
|
||||
* @Description TODO
|
||||
*/
|
||||
public class OnLimitClickHelper implements View.OnClickListener {
|
||||
public static final int LIMIT_TIME = 2000;
|
||||
private long lastClickTime = 0;
|
||||
private OnLimitClickListener onLimitClickListener = null;
|
||||
|
||||
public OnLimitClickHelper(OnLimitClickListener onLimitClickListener){
|
||||
this.onLimitClickListener = onLimitClickListener;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onClick(View v) {
|
||||
long curTime = Calendar.getInstance().getTimeInMillis();
|
||||
if (curTime - lastClickTime > LIMIT_TIME) {
|
||||
lastClickTime = curTime;
|
||||
if(onLimitClickListener != null){
|
||||
onLimitClickListener.onClick(v);
|
||||
}
|
||||
}else{
|
||||
ToastUtils.showToast(v.getContext(),"点击速度过快,请稍后重试");
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,17 +0,0 @@
|
||||
package com.arpa.hndahesudintocctmsdriver.weight;
|
||||
|
||||
import android.view.View;
|
||||
|
||||
/**
|
||||
* @ClassName OnLimitClickListener
|
||||
* @Author john
|
||||
* @Date 2024/4/22 14:28
|
||||
* @Description TODO
|
||||
*/
|
||||
public interface OnLimitClickListener {
|
||||
/**
|
||||
* 按钮点击事件
|
||||
* @param view
|
||||
*/
|
||||
void onClick(View view);
|
||||
}
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 432 KiB |
@@ -163,20 +163,20 @@
|
||||
android:textColor="#ffc4c4ce"
|
||||
android:textSize="@dimen/sp_13"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/value2"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_marginLeft="@dimen/dp_30"
|
||||
android:background="@null"
|
||||
android:textColor="#ff999999"
|
||||
android:textSize="@dimen/sp_13"
|
||||
android:maxLines="1"
|
||||
android:hint="点击进行手动输入"
|
||||
android:ellipsize="end"
|
||||
android:gravity="right"
|
||||
android:hint="点击进行手动输入"
|
||||
android:maxLines="1"
|
||||
android:textColor="#ff999999"
|
||||
android:textSize="@dimen/sp_13" />
|
||||
android:layout_marginLeft="@dimen/dp_30"
|
||||
android:background="@null"
|
||||
/>
|
||||
</RelativeLayout>
|
||||
</LinearLayout>
|
||||
<TextView
|
||||
|
||||
@@ -382,38 +382,5 @@
|
||||
/>
|
||||
</LinearLayout>
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/r8"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
<LinearLayout
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
android:layout_marginBottom="@dimen/dp_20"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="交强险保单"
|
||||
android:textColor="#ff000000"
|
||||
android:textSize="@dimen/sp_15"
|
||||
/>
|
||||
</LinearLayout>
|
||||
<ImageView
|
||||
android:layout_width="@dimen/dp_6"
|
||||
android:layout_height="@dimen/dp_10"
|
||||
android:src="@mipmap/chevron"
|
||||
android:scaleType="fitXY"
|
||||
android:background="@null"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"/>
|
||||
</RelativeLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_2"
|
||||
android:background="#F6F6F9"/>
|
||||
|
||||
</LinearLayout>
|
||||
</RelativeLayout>
|
||||
@@ -81,7 +81,7 @@
|
||||
android:id="@+id/zjimg_name"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
android:layout_marginTop="@dimen/dp_19"
|
||||
android:text="从业资格证照片"
|
||||
android:textColor="#ff333333"
|
||||
android:textSize="@dimen/sp_15" />
|
||||
@@ -91,7 +91,7 @@
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_marginBottom="@dimen/dp_16"
|
||||
android:layout_marginBottom="@dimen/dp_19"
|
||||
android:text="点击上传图片"
|
||||
android:textColor="@color/theme_color"
|
||||
android:textSize="@dimen/sp_15" />
|
||||
@@ -100,7 +100,7 @@
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
<LinearLayout
|
||||
|
||||
android:visibility="gone"
|
||||
android:id="@+id/llInfo"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
@@ -137,8 +137,6 @@
|
||||
android:orientation="vertical"
|
||||
android:padding="@dimen/dp_14">
|
||||
|
||||
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/cow1"
|
||||
|
||||
@@ -164,55 +162,10 @@
|
||||
android:gravity="right"
|
||||
android:hint="点击进行手动输入"
|
||||
android:maxLines="1"
|
||||
android:singleLine="true"
|
||||
android:textColor="#ff999999"
|
||||
android:textSize="@dimen/sp_13" />
|
||||
</RelativeLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:id="@+id/llDate"
|
||||
android:visibility="gone"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="vertical"
|
||||
>
|
||||
<View
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_1"
|
||||
android:background="@drawable/bottom_xu"/>
|
||||
<RelativeLayout
|
||||
android:id="@+id/rlDate"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content">
|
||||
<TextView
|
||||
android:id="@+id/name2"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="截止日期"
|
||||
android:textColor="#ffc4c4ce"
|
||||
android:textSize="@dimen/sp_13"
|
||||
/>
|
||||
<TextView
|
||||
android:layout_toRightOf="@+id/name2"
|
||||
android:id="@+id/value2"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="#ff999999"
|
||||
android:textSize="@dimen/sp_13"
|
||||
android:maxLines="1"
|
||||
android:hint="请选择截止日期"
|
||||
android:gravity="right"
|
||||
android:ellipsize="end"
|
||||
android:layout_marginLeft="@dimen/dp_10"
|
||||
/>
|
||||
</RelativeLayout>
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
@@ -1,190 +1,142 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:id="@+id/activity_shangchuan"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:background="@drawable/bg_theme">
|
||||
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:background="@drawable/bg_theme"
|
||||
android:id="@+id/activity_shangchuan">
|
||||
<ImageView
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
android:layout_width="@dimen/dp_300"
|
||||
android:layout_height="@dimen/dp_207"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_marginTop="@dimen/dp_16"
|
||||
android:src="@mipmap/top_creativity" />
|
||||
|
||||
android:src="@mipmap/top_creativity"
|
||||
android:layout_centerHorizontal="true"/>
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:orientation="vertical">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_marginTop="@dimen/dp_58"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_58">
|
||||
android:layout_height="wrap_content">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/return_btn"
|
||||
android:layout_marginLeft="@dimen/dp_30"
|
||||
android:layout_width="@dimen/dp_40"
|
||||
android:layout_height="@dimen/dp_31"
|
||||
android:layout_marginLeft="@dimen/dp_30"
|
||||
android:src="@mipmap/return_lefts"
|
||||
android:padding="@dimen/dp_10"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@mipmap/return_lefts" />
|
||||
android:scaleType="fitXY"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tv_loaction"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_marginRight="@dimen/dp_30"
|
||||
android:padding="@dimen/dp_5"
|
||||
android:textSize="@dimen/sp_14"
|
||||
android:text="定位成功"
|
||||
android:textColor="@color/theme_color"
|
||||
android:textSize="@dimen/sp_14" />
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_marginRight="@dimen/dp_30"
|
||||
android:layout_centerVertical="true"
|
||||
android:padding="@dimen/dp_5"
|
||||
android:textColor="@color/theme_color"/>
|
||||
|
||||
</RelativeLayout>
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_38"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
android:text="补传"
|
||||
android:textColor="#ff000000"
|
||||
android:textSize="@dimen/sp_23" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvDate"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_50"
|
||||
android:gravity="center_vertical"
|
||||
android:hint="请选择时间"></TextView>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal"
|
||||
>
|
||||
<EditText
|
||||
android:layout_weight="1"
|
||||
android:id="@+id/etAddress"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_50"
|
||||
android:hint="请输入地址"></EditText>
|
||||
<Button
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:textColor="@color/red"
|
||||
android:text="确定"
|
||||
android:id="@+id/btnOk"
|
||||
></Button>
|
||||
</LinearLayout>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvLocation"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center_vertical"
|
||||
></TextView>
|
||||
android:text="补传"
|
||||
android:textColor="#ff000000"
|
||||
android:textSize="@dimen/sp_23"
|
||||
/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/name_top"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_38"
|
||||
android:layout_marginTop="@dimen/dp_8"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="上传卸货照片"
|
||||
android:textColor="#ff000000"
|
||||
android:textSize="@dimen/sp_23" />
|
||||
|
||||
android:textSize="@dimen/sp_23"
|
||||
/>
|
||||
<androidx.cardview.widget.CardView
|
||||
android:id="@+id/getImg1"
|
||||
android:layout_marginTop="@dimen/dp_33"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_38"
|
||||
android:layout_marginTop="@dimen/dp_33"
|
||||
android:layout_marginRight="@dimen/dp_38"
|
||||
app:cardCornerRadius="@dimen/dp_8">
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:orientation="horizontal">
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/getImg"
|
||||
android:layout_width="@dimen/dp_90"
|
||||
android:layout_height="@dimen/dp_90"
|
||||
android:layout_marginLeft="@dimen/dp_11"
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
android:layout_marginBottom="@dimen/dp_13"
|
||||
android:layout_width="@dimen/dp_90"
|
||||
android:layout_height="@dimen/dp_90"
|
||||
android:background="#EEEEEE">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/res_img"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/img_icon"
|
||||
android:layout_width="@dimen/dp_23"
|
||||
android:layout_height="@dimen/dp_23"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:layout_centerHorizontal="true"
|
||||
android:src="@mipmap/up_img"/>
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/img_delete"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_width="@dimen/dp_25"
|
||||
android:layout_height="@dimen/dp_25"
|
||||
android:layout_alignParentRight="true"
|
||||
android:padding="@dimen/dp_3"
|
||||
android:src="@mipmap/icon_delete"
|
||||
android:padding="@dimen/dp_3"
|
||||
android:visibility="gone"/>
|
||||
</RelativeLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
android:layout_marginLeft="@dimen/dp_8"
|
||||
android:layout_marginRight="@dimen/dp_10"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_8"
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
android:layout_marginRight="@dimen/dp_10"
|
||||
android:orientation="vertical">
|
||||
|
||||
<TextView
|
||||
android:layout_marginTop="@dimen/dp_7"
|
||||
android:id="@+id/name_body"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_7"
|
||||
android:text="卸货照片"
|
||||
android:textColor="#ff000000"
|
||||
android:textSize="@dimen/sp_13" />
|
||||
|
||||
android:textSize="@dimen/sp_13"
|
||||
/>
|
||||
<TextView
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
android:id="@+id/address"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_13"
|
||||
android:text=""
|
||||
android:textColor="#ff999999"
|
||||
android:text=""
|
||||
android:textSize="@dimen/sp_13" />
|
||||
</LinearLayout>
|
||||
</LinearLayout>
|
||||
</androidx.cardview.widget.CardView>
|
||||
|
||||
<LinearLayout
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_38"
|
||||
android:layout_marginTop="@dimen/dp_10"
|
||||
android:layout_marginRight="@dimen/dp_38">
|
||||
|
||||
android:layout_marginLeft="@dimen/dp_38"
|
||||
android:layout_marginRight="@dimen/dp_38"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content">
|
||||
<TextView
|
||||
android:id="@+id/tips_x"
|
||||
android:layout_width="wrap_content"
|
||||
@@ -192,7 +144,6 @@
|
||||
android:text="*"
|
||||
android:textColor="#E61829"
|
||||
android:visibility="gone"/>
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tips"
|
||||
android:layout_width="wrap_content"
|
||||
@@ -201,25 +152,24 @@
|
||||
android:textColor="#E61829"
|
||||
android:visibility="gone"/>
|
||||
</LinearLayout>
|
||||
|
||||
<androidx.cardview.widget.CardView
|
||||
android:layout_marginTop="@dimen/dp_33"
|
||||
android:layout_marginLeft="@dimen/dp_38"
|
||||
android:layout_marginRight="@dimen/dp_38"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_42"
|
||||
android:layout_marginLeft="@dimen/dp_38"
|
||||
android:layout_marginTop="@dimen/dp_33"
|
||||
android:layout_marginRight="@dimen/dp_38"
|
||||
app:cardBackgroundColor="@color/red"
|
||||
app:cardCornerRadius="@dimen/dp_21">
|
||||
|
||||
app:cardCornerRadius="@dimen/dp_21"
|
||||
app:cardBackgroundColor="@color/red">
|
||||
<TextView
|
||||
android:id="@+id/submit"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_alignParentRight="true"
|
||||
android:gravity="center"
|
||||
android:text="提交"
|
||||
android:textColor="#fff"
|
||||
android:textSize="@dimen/sp_15" />
|
||||
android:textSize="@dimen/sp_15"
|
||||
android:gravity="center"
|
||||
/>
|
||||
</androidx.cardview.widget.CardView>
|
||||
</LinearLayout>
|
||||
</RelativeLayout>
|
||||
@@ -103,7 +103,6 @@
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:visibility="gone"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_30"
|
||||
@@ -132,7 +131,6 @@
|
||||
</LinearLayout>
|
||||
|
||||
<LinearLayout
|
||||
android:visibility="gone"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginLeft="@dimen/dp_30"
|
||||
|
||||
@@ -146,35 +146,6 @@
|
||||
android:src="@mipmap/chevron" />
|
||||
</RelativeLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_2"
|
||||
android:background="#F6F6F9" />
|
||||
|
||||
<RelativeLayout
|
||||
android:id="@+id/r8"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:paddingTop="@dimen/dp_20"
|
||||
android:paddingBottom="@dimen/dp_20">
|
||||
|
||||
<TextView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="交易规则"
|
||||
android:textColor="#ff000000"
|
||||
android:textSize="@dimen/sp_15" />
|
||||
|
||||
<ImageView
|
||||
android:layout_width="@dimen/dp_4"
|
||||
android:layout_height="@dimen/dp_8"
|
||||
android:layout_alignParentRight="true"
|
||||
android:layout_centerVertical="true"
|
||||
android:background="@null"
|
||||
android:scaleType="fitXY"
|
||||
android:src="@mipmap/chevron" />
|
||||
</RelativeLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_2"
|
||||
@@ -304,19 +275,11 @@
|
||||
android:scaleType="fitXY"
|
||||
android:src="@mipmap/chevron" />
|
||||
</RelativeLayout>
|
||||
|
||||
<View
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_2"
|
||||
android:background="#F6F6F9" />
|
||||
<TextView
|
||||
android:layout_marginTop="@dimen/dp_20"
|
||||
android:gravity="center"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"
|
||||
android:text="ICP备案号:豫ICP备09025418号-24A"
|
||||
/>
|
||||
|
||||
|
||||
</LinearLayout>
|
||||
|
||||
</androidx.core.widget.NestedScrollView>
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 606 KiB |
+1
-1
@@ -1,6 +1,6 @@
|
||||
#Mon Jul 12 10:16:49 CST 2021
|
||||
distributionBase=GRADLE_USER_HOME
|
||||
distributionUrl=https\://mirrors.cloud.tencent.com/gradle/gradle-6.7.1-bin.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip
|
||||
distributionPath=wrapper/dists
|
||||
zipStorePath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
|
||||
@@ -176,7 +176,7 @@ public final class TimeUtil {
|
||||
* 注意:SimpleDateFormat不是线程安全的,线程安全需用{@code ThreadLocal<SimpleDateFormat>}
|
||||
*/
|
||||
|
||||
private static final DateFormat DEFAULT_FORMAT = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss", Locale.getDefault());
|
||||
public static final DateFormat DEFAULT_FORMAT = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss", Locale.getDefault());
|
||||
private static final DateFormat DEFAULT_FORMAT2 = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZSS:SS", Locale.getDefault());
|
||||
private static final DateFormat DEFAULT_FORMAT3 = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss.SSSZ", Locale.getDefault());
|
||||
public static final DateFormat DEFAULT_FORMAT4 = new SimpleDateFormat("yyyy-MM-dd'T'HH:mm:ss", Locale.getDefault());
|
||||
|
||||
@@ -29,24 +29,6 @@ public class ToastUtils {
|
||||
}
|
||||
}
|
||||
|
||||
public static void showLongToast(Context mContext, String message) {
|
||||
if (!TextUtils.isEmpty(message)) {
|
||||
|
||||
// if ( mToast != null) {
|
||||
// mToast.cancel();
|
||||
// }
|
||||
// mToast = Toast.makeText(mContext, message, Toast.LENGTH_SHORT);
|
||||
// mToast.show();
|
||||
|
||||
if (mToast == null) {
|
||||
mToast = Toast.makeText(mContext, message, Toast.LENGTH_LONG);
|
||||
} else {
|
||||
mToast.setText(message);
|
||||
}
|
||||
mToast.show();
|
||||
}
|
||||
}
|
||||
|
||||
public static void cancelToast(){
|
||||
if (mToast!=null)
|
||||
mToast.cancel();
|
||||
|
||||
Reference in New Issue
Block a user