资料修改1

This commit is contained in:
lijia 2024-03-21 15:28:59 +08:00
parent e9b9834a5c
commit ce822d0845
27 changed files with 1510 additions and 174 deletions

View File

@ -2,3 +2,9 @@
友盟+上的appkey用来唤醒与阿里云购买appkey同样可以唤醒前端sdk?)不同(后台需配置友盟+上的appkey来获取token
# 无法获取sha1失败
可通过gradle-app-android-signingReport获取
# gradle无法下载或者下载慢问题-替换阿里云或腾讯云镜像
添加maven { url 'https://maven.aliyun.com/repository/central' }
maven { url 'https://maven.aliyun.com/nexus/content/repositories/google' }
distributionUrl=https\://mirrors.cloud.tencent.com/gradle/gradle-8.2-bin.zip
distributionUrl=https\://emas-devops-cdn.aliyuncs.com/distributions/gradle-7.2-bin.zip

View File

@ -34,7 +34,8 @@ android {
ndk {
//SO库架构so
abiFilters "armeabi", "armeabi-v7a", "arm64-v8a", "x86","x86_64"
abiFilters "armeabi", "arm64-v8a"
// abiFilters "armeabi", "armeabi-v7a", "arm64-v8a", "x86","x86_64"
}
}
@ -159,4 +160,6 @@ dependencies {
implementation 'com.umeng.umsdk:uverify-main:2.1.4'//
implementation 'com.umeng.umsdk:uverify-logger:2.1.4'//
implementation 'com.umeng.umsdk:uverify-crashshield:2.1.4'//
//
implementation 'com.umeng.umsdk:push:6.6.3'//
}

View File

@ -292,6 +292,11 @@
android:configChanges="keyboardHidden|orientation|locale"
android:screenOrientation="portrait"
android:windowSoftInputMode="adjustPan|stateHidden" />
<activity
android:name=".ui.mine.activity.CarDetailActivity"
android:configChanges="keyboardHidden|orientation|locale"
android:screenOrientation="portrait"
android:windowSoftInputMode="adjustPan|stateHidden" />
<!-- 我的相关end -->

View File

@ -6,11 +6,13 @@ import android.util.Log
import com.dahe.gldriver.BuildConfig
import com.dahe.gldriver.net.Api
import com.dahe.gldriver.oss.OssServiceUtil
import com.dahe.gldriver.push.PushHelper
import com.dahe.mylibrary.CommonBaseLibrary
import com.esign.esignsdk.EsignSdk
import com.github.gzuliyujiang.dialog.DialogConfig
import com.github.gzuliyujiang.dialog.DialogStyle
import com.umeng.commonsdk.UMConfigure
import com.umeng.message.PushAgent
import com.umeng.umverify.UMVerifyHelper
import com.umeng.umverify.listener.UMTokenResultListener
import java.security.SecureRandom
@ -19,6 +21,7 @@ import javax.net.ssl.HttpsURLConnection
import javax.net.ssl.SSLContext
import javax.net.ssl.TrustManager
import javax.net.ssl.X509TrustManager
import kotlin.concurrent.thread
class App : Application() {
override fun onCreate() {
@ -93,20 +96,29 @@ class App : Application() {
}
private fun initUmeng(){
//友盟
UMConfigure.preInit(this,"65f10b873ace4f7d7198fa75","Umeng");
UMConfigure.init(this,"65f10b873ace4f7d7198fa75","Umeng",UMConfigure.DEVICE_TYPE_PHONE,"")
val authHelper = UMVerifyHelper.getInstance(this, object : UMTokenResultListener {
override fun onTokenSuccess(ret: String) {
Log.e("Umenginit", "onTokenSuccess: $ret")
}
// thread {
//友盟
UMConfigure.preInit(this,AppConfig.APP_KEY,"Umeng");
override fun onTokenFailed(ret: String) {
Log.e("Umenginit", "onTokenFailed: $ret")
}
})
authHelper.setLoggerEnable(true)
authHelper.setAuthSDKInfo("iiBVGHSKbUML/NTbj187eM1N1KMvRzh1sJbM+2FMbV7FNOnmngDlPr2reqlvouhK/8dXcaNGJuI9B+Kv7C6IlBMoGE0PMVWvwY754T8zxSgSfLUM6s7e0dVxmtMFRrCDawKBiv6g/5+X1mSK5OXNG+H//8rtDDf0vePyUUPCAU26tIX/7BCJ4wvUjobAHBDtSbMMhzqWR5MC7jTCnR0k1OwwvEYxIH6jZuRqT4QgBBO4AMKvFjboqj3rsrr5uE6Gn28fWQrBBrOkPS830GnZFU8ND/0LedGgTlMllBAXLy0gbZZ/8LKJOQ==")
// 推送注册
val api = PushAgent.getInstance(this)
PushHelper.setting(api)
UMConfigure.init(this,AppConfig.APP_KEY,"Umeng",UMConfigure.DEVICE_TYPE_PHONE,AppConfig.MESSAGE_SECRET)
//实名认证
val authHelper = UMVerifyHelper.getInstance(this, object : UMTokenResultListener {
override fun onTokenSuccess(ret: String) {
Log.e("Umenginit", "onTokenSuccess: $ret")
}
override fun onTokenFailed(ret: String) {
Log.e("Umenginit", "onTokenFailed: $ret")
}
})
authHelper.setLoggerEnable(true)
authHelper.setAuthSDKInfo("iiBVGHSKbUML/NTbj187eM1N1KMvRzh1sJbM+2FMbV7FNOnmngDlPr2reqlvouhK/8dXcaNGJuI9B+Kv7C6IlBMoGE0PMVWvwY754T8zxSgSfLUM6s7e0dVxmtMFRrCDawKBiv6g/5+X1mSK5OXNG+H//8rtDDf0vePyUUPCAU26tIX/7BCJ4wvUjobAHBDtSbMMhzqWR5MC7jTCnR0k1OwwvEYxIH6jZuRqT4QgBBO4AMKvFjboqj3rsrr5uE6Gn28fWQrBBrOkPS830GnZFU8ND/0LedGgTlMllBAXLy0gbZZ/8LKJOQ==")
// }.start()
}

View File

@ -19,9 +19,14 @@ object AppConfig {
const val CHILDRE_ID = "DA_HE_CHILDRE_ID"
const val RATE_TYPE = "DA_HE_RATE_TYPE"//0:收到的评价 1:发表的评价
const val CODE = "DA_HE_PHONE"
const val USER_DETAIL = "DA_HE_USER_DETAIL"
const val IS_ONLY_SHOW = "DA_HE_IS_ONLY_SHOW"
const val REFRSH = "DA_HE_REFRSH"
const val SUCCESS_TYPE = "DA_HE_SUCCESS_TYPE"
const val E_KEY = "19ac0aa74338e487e45057faf7212401"
const val E_LICENSE = "HF41uGxM/1i3CtW98DimoA97BlNTAnQ+DiEAihYmZ2jR1jqC4be253joEJbOJgFDIzp5aIoeuXSWWHFaDVfaHL2Pksbq5f8M8EqsVhP9q/i1xGYSYf6MJVlHdMAVLWgR0Kra+n8dVzkSDuZeyJuDsskAmZaGFQN1CqnWYCI1tmV1Tk4A57e9LQMed0U11QWjdshdU2DGqBXKmGE419PdW3NmIxOR2u9iB1OKBmvzCUT8RAYyBzSn/yhU++YJ25g5a8Pb5kOvi+eOh+PEFEcQL6oOp/CF4Iw5nadlsLhc+XEnVJpwL2myZBoSlVcKxrJKbRn1/DIgXBueKKnqhyHKdJlpqI9eghAlRF0p2Q4f23m89mWRZf4nhKzTeXGIjCTFO4TNVucrlGU7tyJcrRCDVdfV24fziH+hB3QGckpuYzzjefr7hZalLRJ/w8dPw/8dCY1wnWq3AJ3zw2g1PzMxl51q7AgdKvwc1ERcGBns0zb8PK6vGKCnJq3uHiJEnslbTI0MEosje+h+OPO7hf2QofErewjI19wHEOv4dTvuFLh3VmGFMObAmov5kI47705fjSxCvAPGATBrfUSwim+5EQ1hanc5IcXe0/nOTiRUNEpZ+x65zVydqAs7490yqQiIUQvPazEwcal7vH2OD54lCcgpxKxqdmGc5/bp5UnqB45+n+iuInV/Q9DMOQVk15uaVZmhS8VaCqH21CmfH/ZGLb9wiEpaRLrPZLKX3bK7MT9Z0/OlDnb2QUKU8LMMIhLuQQntzsf0Wn4kA/0e9QAJJQ=="
//友盟
const val MESSAGE_SECRET = "9d3338d1d3797cf1c765c3aa7700f145"
const val APP_KEY = "65f10b873ace4f7d7198fa75"
}

View File

@ -11,6 +11,7 @@ import retrofit2.http.GET
data class UserBean(
var access_token :String,
var token :String,
var userid :String,
var id :String,
var roleId :String,
var contactPhone :String,
@ -33,9 +34,47 @@ data class UserBean(
var isCarCaptain :String,//是否是车队长0=否,1=是,9=未选择)
var contactName :String,
var idcardName :String,
var isRealName :String,
var avatar :String,
var approvedType :String,//准驾类型
var partyMemberCertification :String,//党员认证(0=未认证,1=已认证)
var captainId :String
)
data class UserDetail(
val createBy: String,
val createTime: String,
val driverBankcardAddress: String,
val driverBankcardNumber: String,
val driverBankcardPhotoUrl: String,
val driverId: Int,
val idcardAddress: String,
val idcardBackUrl: String,
val idcardEffectiveEnd: String,
val idcardEffectiveStart: String,
val idcardEthnicity: String,
val idcardFrontUrl: String,
val idcardIsEndless: String,
val idcardName: String,
val idcardNo: String,
val idcardSex: String,
val licenseApproveOrganization: String,
val licenseEffectiveEnd: String,
val licenseEffectiveStart: String,
val licenseFirstGetDate: String,
val licenseName: String,
val licenseNo: String,
val licensePhotoBackUrl: String,
val licensePhotoFaceUrl: String,
val licenseRecordNumber: String,
val licenseType: String,
val qualificationCertificateEffectiveEnd: String,
val qualificationCertificateExamineDate: String,
val qualificationCertificateNo: String,
val qualificationCertificatePhotoUrl: String,
val remark: String,
val taxpayerCaptainId: String,
val updateBy: String,
val updateTime: String
)

View File

@ -137,39 +137,39 @@ interface Api {
* 司机上传身份证
* */
@POST(BASE_URL + "driver/driver/setUpDriverIdCard")
fun setUpDriverIdCard(@Body carBean: UpPersonInfoBean): Observable<CommonResponseBean<String>>
fun setUpDriverIdCard(@Body carBean: UpPersonInfoBean): Observable<CommonResponseBean<Any>>
/**
* 司机上传驾驶证
* */
@POST(BASE_URL + "driver/driver/setUpDriverLicense")
fun setUpDriverLicense(@Body driverBean: UpDriverInfoBean): Observable<CommonResponseBean<String>>
fun setUpDriverLicense(@Body driverBean: UpDriverInfoBean): Observable<CommonResponseBean<Any>>
/**
* 司机上传从业资格证
* */
@POST(BASE_URL + "driver/driver/setUpDriverQualificationCertificate")
fun setUpDriverQualificationCertificate(@Body qualiBean: UpQualiInfoBean): Observable<CommonResponseBean<String>>
fun setUpDriverQualificationCertificate(@Body qualiBean: UpQualiInfoBean): Observable<CommonResponseBean<Any>>
/**
* 上传车辆的道路运输证
* */
@POST(BASE_URL + "driver/car/setUpRoadLicense")
fun setUpRoadLicense(@Body roadBean: UpRoadInfoBean): Observable<CommonResponseBean<String>>
fun setUpRoadLicense(@Body roadBean: UpRoadInfoBean): Observable<CommonResponseBean<Any>>
/**
* 司机上传银行卡
* */
@POST(BASE_URL + "driver/driver/setUpDriverBankCard")
fun setUpDriverBankCard(@Body bankBean: UpBankInfoBean): Observable<CommonResponseBean<String>>
fun setUpDriverBankCard(@Body bankBean: UpBankInfoBean): Observable<CommonResponseBean<Any>>
/**
* 司机认证成为车队长
* */
@POST(BASE_URL + "driver/driver/authenticationCaptain")
fun authenticationCaptain(@Body bankBean: AuthTeamBean): Observable<CommonResponseBean<String>>
fun authenticationCaptain(@Body bankBean: AuthTeamBean): Observable<CommonResponseBean<Any>>
/**
@ -307,6 +307,15 @@ interface Api {
@GET(BASE_URL + "driver/captain/selectDriverList")
fun selectDriverList(@Query("phone") phone: String): Observable<CommonResponseBean<MutableList<DriverBean>>>
/**
* 获取司机详细信息
* @return Observable<CommonResponseBean<UserDetail>>
*/
@GET(BASE_URL + "driver/driver/getUserDetail")
fun getUserDetail(): Observable<CommonResponseBean<UserDetail>>
/**
*
*查询司机所在车队信息

View File

@ -0,0 +1,136 @@
package com.dahe.gldriver.push
import android.app.Notification
import android.content.Context
import android.util.Log
import com.dahe.gldriver.utils.SPUtils
import com.dahe.glex.bean.UserBean
import com.umeng.message.PushAgent
import com.umeng.message.UmengMessageHandler
import com.umeng.message.UmengNotificationClickHandler
import com.umeng.message.entity.UMessage
/**
* PushSDK集成帮助类
*/
object PushHelper {
const val TAG = "UPushDemo"
/**
* 推送设置
*/
fun setting(api: PushAgent) {
//修改为您app/src/main/AndroidManifest.xml中package值
api.resourcePackageName = "com.dahe.gldriver"
//设置通知栏显示通知的最大个数0100不限制个数
api.displayNotificationNumber = 0
//推送消息处理
val msgHandler: UmengMessageHandler = object : UmengMessageHandler() {
//处理通知栏消息
override fun dealWithNotificationMessage(context: Context, msg: UMessage) {
super.dealWithNotificationMessage(context, msg)
Log.i(TAG, """notification receiver:${msg.raw}""".trimIndent())
}
//自定义通知样式,此方法可以修改通知样式等
override fun getNotification(context: Context, msg: UMessage): Notification {
return super.getNotification(context, msg)
}
//处理透传消息
override fun dealWithCustomMessage(context: Context, msg: UMessage) {
super.dealWithCustomMessage(context, msg)
Log.i(
TAG, """custom receiver:${msg.raw}""".trimIndent()
)
}
}
api.messageHandler = msgHandler
//推送消息点击处理
val notificationClickHandler: UmengNotificationClickHandler =
object : UmengNotificationClickHandler() {
override fun openActivity(context: Context, msg: UMessage) {
super.openActivity(context, msg)
Log.i(TAG, """click open activity:${msg.raw}""".trimIndent())
}
override fun launchApp(context: Context, msg: UMessage) {
super.launchApp(context, msg)
Log.i(TAG, """click launch app:${msg.raw}""".trimIndent())
}
override fun openUrl(context: Context, msg: UMessage) {
super.openUrl(context, msg)
Log.i(TAG, """click open deeplink:${msg.raw}""".trimIndent())
}
override fun dismissNotification(context: Context, msg: UMessage) {
super.dismissNotification(context, msg)
Log.i(TAG, """dismissNotification:${msg.raw}""".trimIndent())
}
}
api.notificationClickHandler = notificationClickHandler
//通过Service自定义接收并处理消息
// api.setPushIntentServiceClass(MyCustomMessageService.class);
//设置厂商Token回调
api.setThirdTokenCallback { type, token -> Log.i(TAG, "push type:$type token:$token") }
}
/**
* 注册设备推送通道小米华为等设备的推送
*/
fun registerDevicePush(context: Context?) {
//小米推送填写您在小米后台APP对应的xiaomi id和key
// MiPushRegistar.register(context, PushConstants.MI_ID, PushConstants.MI_KEY);
// //华为推送注意华为推送的初始化参数在AndroidManifest.xml中配置
// HuaWeiRegister.register(context.getApplicationContext());
// //魅族推送填写您在魅族后台APP对应的app id和key
// MeizuRegister.register(context, PushConstants.MEI_ZU_ID, PushConstants.MEI_ZU_KEY);
// //OPPO推送填写您在OPPO后台APP对应的app key和secret
// OppoRegister.register(context, PushConstants.OPPO_KEY, PushConstants.OPPO_SECRET);
// //vivo推送注意vivo推送的初始化参数在AndroidManifest.xml中配置
// VivoRegister.register(context);
// //荣耀推送注意荣耀推送的初始化参数在AndroidManifest.xml中配置
// HonorRegister.register(context);
// //谷歌fcm推送
// FCMRegister.register(context);
}
/**
* 绑定别名绑定成功后可通过别名推送消息
*/
fun setAlias(context: Context, userBean: UserBean) {
val alias = userBean.userid
val type = "uid"
PushAgent.getInstance(context).setAlias(alias, type) { success, message ->
val msg: String
msg = if (success) {
"set alias success! type:$type alias:$alias"
} else {
"set alias failure! msg:$message"
}
}
}
/**
* 删除别名
*/
fun delete(context: Context) {
val alias = SPUtils.instance.getUserInfo(context)?.userid
val type = "uid"
PushAgent.getInstance(context).deleteAlias(alias, type) { success, message ->
val msg: String
msg = if (success) {
"delete alias success! type:$type alias:$alias"
} else {
"delete alias failure! msg:$message"
}
}
}
}

View File

@ -0,0 +1,91 @@
package com.dahe.gldriver.temp;
import android.app.Activity;
import android.content.Intent;
import android.content.pm.ActivityInfo;
import android.graphics.Color;
import android.os.Build;
import android.view.View;
import android.widget.ImageView;
import android.widget.Toast;
import com.bumptech.glide.Glide;
import com.bumptech.glide.load.engine.DiskCacheStrategy;
import com.dahe.gldriver.R;
import com.umeng.umverify.UMVerifyHelper;
import com.umeng.umverify.view.UMAbstractPnsViewDelegate;
import com.umeng.umverify.view.UMAuthRegisterXmlConfig;
import com.umeng.umverify.view.UMAuthUIConfig;
/**
* xml文件方便预览
* 可以通过addAuthRegisterXmlConfig一次性统一添加授权页的所有自定义view
*/
public class CustomXmlConfig extends BaseUIConfig {
public CustomXmlConfig(Activity activity, UMVerifyHelper authHelper) {
super(activity, authHelper);
}
@Override
public void configAuthPage() {
mAuthHelper.removeAuthRegisterXmlConfig();
mAuthHelper.removeAuthRegisterViewConfig();
int authPageOrientation = ActivityInfo.SCREEN_ORIENTATION_SENSOR_PORTRAIT;
if (Build.VERSION.SDK_INT == 26) {
authPageOrientation = ActivityInfo.SCREEN_ORIENTATION_BEHIND;
}
mAuthHelper.addAuthRegisterXmlConfig(new UMAuthRegisterXmlConfig.Builder()
.setLayout(R.layout.custom_full_port, new UMAbstractPnsViewDelegate() {
@Override
public void onViewCreated(View view) {
findViewById(R.id.btn_back).setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
mAuthHelper.quitLoginPage();
}
});
ImageView pImageView = (ImageView) findViewById(R.id.iv_background);
Glide.with(mContext).load(R.drawable.head_defaut).diskCacheStrategy(DiskCacheStrategy.RESOURCE).into(pImageView);
findViewById(R.id.tv_switch).setOnClickListener(new View.OnClickListener() {
@Override
public void onClick(View v) {
Toast.makeText(mContext, "切换到短信登录方式", Toast.LENGTH_SHORT).show();
// Intent pIntent = new Intent(mActivity, MessageActivity.class);
// mActivity.startActivityForResult(pIntent, 1002);
mAuthHelper.quitLoginPage();
}
});
}
})
.build());
mAuthHelper.setAuthUIConfig(new UMAuthUIConfig.Builder()
.setAppPrivacyOne("《自定义隐私协议》", "https://test.h5.app.tbmao.com/user")
.setAppPrivacyTwo("《百度》", "https://www.baidu.com")
.setAppPrivacyColor(Color.GRAY, Color.parseColor("#002E00"))
.setNavHidden(true)
.setLogoHidden(true)
.setSloganHidden(true)
.setSwitchAccHidden(true)
.setPrivacyState(false)
.setCheckboxHidden(true)
.setLightColor(true)
.setStatusBarColor(Color.TRANSPARENT)
.setStatusBarUIFlag(View.SYSTEM_UI_FLAG_LAYOUT_FULLSCREEN)
.setWebNavTextSizeDp(20)
.setNumberSizeDp(20)
.setNumberColor(Color.BLACK)
.setAuthPageActIn("in_activity", "out_activity")
.setAuthPageActOut("in_activity", "out_activity")
.setVendorPrivacyPrefix("")
.setVendorPrivacySuffix("")
.setPageBackgroundPath("page_background_color")
.setLogoImgPath("mytel_app_launcher")
.setLogBtnBackgroundPath("login_btn_bg")
.setScreenOrientation(authPageOrientation)
.create());
}
}

View File

@ -0,0 +1,183 @@
package com.dahe.gldriver.temp;
import android.app.Activity;
import android.content.Context;
import android.content.Intent;
import android.content.pm.ActivityInfo;
import android.graphics.Color;
import android.os.Build;
import android.util.DisplayMetrics;
import android.view.Surface;
import android.view.View;
import android.view.WindowManager;
import android.widget.Toast;
import com.dahe.gldriver.R;
import com.dahe.mylibrary.utils.BaseUtils;
import com.nirvana.tools.core.AppUtils;
import com.umeng.umverify.UMVerifyHelper;
import com.umeng.umverify.listener.UMCustomInterface;
import com.umeng.umverify.view.UMAbstractPnsViewDelegate;
import com.umeng.umverify.view.UMAuthRegisterViewConfig;
import com.umeng.umverify.view.UMAuthRegisterXmlConfig;
import com.umeng.umverify.view.UMAuthUIConfig;
public class DialogPortConfig extends BaseUIConfig {
/**
* 应用包名
*/
private String mPackageName;
public DialogPortConfig(Activity activity, UMVerifyHelper authHelper) {
super(activity, authHelper);
mPackageName = AppUtils.getPackageName(activity);
}
public int mScreenWidthDp;
public int mScreenHeightDp;
@Override
public void configAuthPage() {
mAuthHelper.removeAuthRegisterXmlConfig();
mAuthHelper.removeAuthRegisterViewConfig();
int authPageOrientation = ActivityInfo.SCREEN_ORIENTATION_SENSOR_PORTRAIT;
if (Build.VERSION.SDK_INT == 26) {
authPageOrientation = ActivityInfo.SCREEN_ORIENTATION_BEHIND;
}
updateScreenSize(authPageOrientation);
int dialogWidth = (int) (mScreenWidthDp * 0.8f);
int dialogHeight = (int) (mScreenHeightDp * 0.65f);
int designHeight = dialogHeight - 50;
int unit = designHeight / 10;
int logBtnHeight = (int) (unit * 1.2);
// mAuthHelper.addAuthRegistViewConfig("switch_msg", new UMAuthRegisterViewConfig.Builder()
// .setView(initSwitchView(unit * 6))
// .setRootViewId(UMAuthRegisterViewConfig.RootViewId.ROOT_VIEW_ID_BODY)
// .setCustomInterface(new UMCustomInterface() {
// @Override
// public void onClick(Context context) {
// Toast.makeText(mContext, "切换到短信登录方式", Toast.LENGTH_SHORT).show();
//// Intent pIntent = new Intent(mActivity, MessageActivity.class);
//// mActivity.startActivityForResult(pIntent, 1002);
// mAuthHelper.quitLoginPage();
// }
// })
// .build());
// mAuthHelper.addAuthRegisterXmlConfig(new UMAuthRegisterXmlConfig.Builder()
// .setLayout(R.layout.custom_port_dialog_action_bar, new UMAbstractPnsViewDelegate() {
// @Override
// public void onViewCreated(View view) {
// findViewById(R.id.btn_close).setOnClickListener(new View.OnClickListener() {
// @Override
// public void onClick(View v) {
// mAuthHelper.quitLoginPage();
// }
// });
// }
// })
// .build());
mAuthHelper.setAuthUIConfig(new UMAuthUIConfig.Builder()
.setAppPrivacyOne("《自定义隐私协议》232", "https://www.baidu.com")
.setAppPrivacyTwo("《自定义隐私协议》2", "https://baijiahao.baidu.com/s?id=1693920988135022454&wfr=spider&for=pc")
.setAppPrivacyThree("《自定义隐私协议》3", "http://www.npc.gov.cn/zgrdw/npc/cwhhy/13jcwh/node_35014.htm")
.setAppPrivacyColor(Color.GRAY, Color.parseColor("#002E00"))
.setPrivacyConectTexts(new String[]{",", "", ""})
.setPrivacyOperatorIndex(2)
.setPrivacyState(false)
.setCheckboxHidden(true)
.setNavHidden(true)
.setSwitchAccHidden(true)
.setNavReturnHidden(false)
.setDialogBottom(false)
.setProtocolAction("com.aliqin.mytel.protocolWeb")
.setPackageName(mPackageName)
.setNavColor(Color.TRANSPARENT)
.setWebNavColor(Color.BLUE)
.setLogBtnBackgroundDrawable(mContext.getDrawable(R.drawable.bg_btn))
.setLogoOffsetY(0)
.setLogoWidth(42)
.setLogoHeight(42)
.setLogoImgPath("mytel_app_launcher")
.setNumFieldOffsetY(unit + 10)
.setNumberSizeDp(17)
.setLogBtnWidth(dialogWidth - 30)
.setLogBtnMarginLeftAndRight(15)
.setLogBtnHeight(logBtnHeight)
.setLogBtnTextSizeDp(16)
.setLogBtnBackgroundPath("login_btn_bg")
.setLogBtnOffsetY(unit * 4)
.setSloganText("为了您的账号安全,请先绑定手机号")
.setSloganOffsetY(unit * 3)
.setSloganTextSizeDp(11)
.setPageBackgroundPath("dialog_page_background")
.setAuthPageActIn("in_activity", "out_activity")
.setAuthPageActOut("in_activity", "out_activity")
.setVendorPrivacyPrefix("")
.setVendorPrivacySuffix("")
.setDialogWidth(dialogWidth)
.setDialogHeight(dialogHeight)
.setScreenOrientation(authPageOrientation)
.setLogoImgDrawable(mContext.getDrawable(R.drawable.diver_logo))
.create());
}
protected void updateScreenSize(int authPageScreenOrientation) {
int screenHeightDp = BaseUtils.px2dip(mContext, getPhoneHeightPixels(mContext));
int screenWidthDp = BaseUtils.px2dip(mContext, getPhoneWidthPixels(mContext));
int rotation = mActivity.getWindowManager().getDefaultDisplay().getRotation();
if (authPageScreenOrientation == ActivityInfo.SCREEN_ORIENTATION_BEHIND) {
authPageScreenOrientation = mActivity.getRequestedOrientation();
}
if (authPageScreenOrientation == ActivityInfo.SCREEN_ORIENTATION_LANDSCAPE
|| authPageScreenOrientation == ActivityInfo.SCREEN_ORIENTATION_SENSOR_LANDSCAPE
|| authPageScreenOrientation == ActivityInfo.SCREEN_ORIENTATION_USER_LANDSCAPE) {
rotation = Surface.ROTATION_90;
} else if (authPageScreenOrientation == ActivityInfo.SCREEN_ORIENTATION_PORTRAIT
|| authPageScreenOrientation == ActivityInfo.SCREEN_ORIENTATION_SENSOR_PORTRAIT
|| authPageScreenOrientation == ActivityInfo.SCREEN_ORIENTATION_USER_PORTRAIT) {
rotation = Surface.ROTATION_180;
}
switch (rotation) {
case Surface.ROTATION_0:
case Surface.ROTATION_180:
mScreenWidthDp = screenWidthDp;
mScreenHeightDp = screenHeightDp;
break;
case Surface.ROTATION_90:
case Surface.ROTATION_270:
mScreenWidthDp = screenHeightDp;
mScreenHeightDp = screenWidthDp;
break;
default:
break;
}
}
public static int getPhoneWidthPixels(Context context) {
WindowManager wm = (WindowManager) context.getSystemService(Context.WINDOW_SERVICE);
DisplayMetrics var2 = new DisplayMetrics();
if (wm != null) {
wm.getDefaultDisplay().getMetrics(var2);
}
return var2.widthPixels;
}
public static int getPhoneHeightPixels(Context context) {
WindowManager wm = (WindowManager) context.getSystemService(Context.WINDOW_SERVICE);
DisplayMetrics var2 = new DisplayMetrics();
if (wm != null) {
wm.getDefaultDisplay().getMetrics(var2);
}
return var2.heightPixels;
}
}

View File

@ -10,6 +10,7 @@ import com.dahe.gldriver.net.DataManager
import com.dahe.gldriver.net.RxHttpCallBack
import com.dahe.gldriver.ui.HomeActivity
import com.dahe.gldriver.utils.SPUtils
import com.dahe.gldriver.utils.UserUtils
import com.dahe.glex.bean.UserBean
import com.dahe.mylibrary.base.BaseActivity
import com.dahe.mylibrary.net.CommonResponseBean
@ -73,21 +74,7 @@ class CodeLoginActivity : BaseActivity<ActivityCodeBinding>(), View.OnClickListe
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<UserBean>(this) {
override fun onSuccess(t: CommonResponseBean<UserBean>) {
super.onSuccess(t)
SPUtils.instance.setUserInfo(mContext, Gson().toJson(t.data))
if (t.data.isCarCaptain == "9") {//是否是车队长0=否,1=是,9=未选择)
ActivityUtils.startActivity(
mContext,
SelectRoleActivity::class.java
)
} else {
ActivityUtils.startActivity(
mContext,
HomeActivity::class.java
)
}
ActivityUtils.finishToActivity(LoginActivity::class.java, true)
UserUtils.instance.loginIn(mContext, t.data)
}
}))

View File

@ -87,8 +87,8 @@ class AuthBankCardActivity : BaseActivity<ActivityAuthBankcardBinding>() {
DataManager.getInstance().setUpDriverBankCard(this)
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<String>() {
override fun onSuccess(t: CommonResponseBean<String>) {
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<Any>() {
override fun onSuccess(t: CommonResponseBean<Any>) {
super.onSuccess(t)
ActivityUtils.startActivity(mContext, AuthFaceActivity::class.java)
}

View File

@ -98,8 +98,8 @@ class AuthDriverActivity : BaseActivity<ActivityAuthDriverBinding>() {
DataManager.getInstance().setUpDriverLicense(driverInfoBean)
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<String>() {
override fun onSuccess(t: CommonResponseBean<String>) {
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<Any>() {
override fun onSuccess(t: CommonResponseBean<Any>) {
super.onSuccess(t)
ActivityUtils.startActivity(
mContext,

View File

@ -1,7 +1,10 @@
package com.dahe.gldriver.ui.account.authperson
import android.os.Bundle
import android.view.View
import com.dahe.gldriver.R
import com.dahe.gldriver.base.AppConfig
import com.dahe.gldriver.base.AppConfig.USER_DETAIL
import com.dahe.gldriver.bean.OcrPersonBean
import com.dahe.gldriver.bean.UpPersonInfoBean
import com.dahe.gldriver.databinding.ActivityAuthPersonBinding
@ -10,6 +13,7 @@ import com.dahe.gldriver.net.DataManager
import com.dahe.gldriver.net.RxHttpCallBack
import com.dahe.gldriver.oss.OssServiceUtil
import com.dahe.gldriver.utils.OcrUtils
import com.dahe.glex.bean.UserDetail
import com.dahe.mylibrary.base.BaseActivity
import com.dahe.mylibrary.net.CommonResponseBean
import com.dahe.mylibrary.utils.ActivityUtils
@ -17,6 +21,7 @@ import com.dahe.mylibrary.utils.ImageLoader
import com.dahe.mylibrary.utils.PickerUtils
import com.dahe.mylibrary.utils.PopsUtils
import com.dahe.mylibrary.utils.TimeUtil
import com.google.gson.Gson
import io.reactivex.rxjava3.android.schedulers.AndroidSchedulers
import io.reactivex.rxjava3.schedulers.Schedulers
import okhttp3.MediaType.Companion.toMediaTypeOrNull
@ -34,11 +39,13 @@ class AuthPersonActivity : BaseActivity<ActivityAuthPersonBinding>() {
lateinit var ossServiceUtil: OssServiceUtil
var isOnlyShow = false
var perInfoBean: UpPersonInfoBean = UpPersonInfoBean()
override fun initView(savedInstanceState: Bundle?) {
setStatusBarColor(R.color.white)
setTitleBar("实名认证", true)
isOnlyShow = intent.extras?.getBoolean(AppConfig.IS_ONLY_SHOW, false) == true
ossServiceUtil = OssServiceUtil.getInstance()
binding.run {
@ -54,8 +61,8 @@ class AuthPersonActivity : BaseActivity<ActivityAuthPersonBinding>() {
DataManager.getInstance().setUpDriverIdCard(perInfoBean)
.subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread())
.subscribe(BaseObserver(mContext,object : RxHttpCallBack<String>(){
override fun onSuccess(t: CommonResponseBean<String>) {
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<Any>() {
override fun onSuccess(t: CommonResponseBean<Any>) {
super.onSuccess(t)
ActivityUtils.startActivity(mContext, AuthDriverActivity::class.java)
}
@ -81,31 +88,31 @@ class AuthPersonActivity : BaseActivity<ActivityAuthPersonBinding>() {
}
ivFront.setOnClickListener {
OcrUtils.getInstance().ocrPerson(mContext,this@AuthPersonActivity){picPath,result->
ImageLoader.getInstance().loadRoundImage(mContext, picPath.locPic, 12, ivFront)
perInfoBean.idcardFrontUrl = picPath.picPath
result?.data?.face?.data.let {
it?.run {
perInfoBean.run {
idcardNo = idNumber
idcardName = name
idcardEthnicity = ethnicity
idcardSex = if (sex == "") "0" else "1"
OcrUtils.getInstance()
.ocrPerson(mContext, this@AuthPersonActivity) { picPath, result ->
ImageLoader.getInstance()
.loadRoundImage(mContext, picPath.locPic, 12, ivFront)
perInfoBean.idcardFrontUrl = picPath.picPath
result?.data?.face?.data.let {
it?.run {
perInfoBean.run {
idcardNo = idNumber
idcardName = name
idcardEthnicity = ethnicity
idcardSex = if (sex == "") "0" else "1"
}
}
binding.run {
etName.setText(it?.name)
etId.setText(it?.idNumber)
}
}
binding.run {
etName.setText(it?.name)
etId.setText(it?.idNumber)
}
}
}
}
ivBack.setOnClickListener {
PopsUtils.getInstance().showSimSelPic(mContext) {
var data = it[0]
val path: String
if (data.isCut && !data.isCompressed) {
// 裁剪过
@ -140,9 +147,12 @@ class AuthPersonActivity : BaseActivity<ActivityAuthPersonBinding>() {
if (it.data.validPeriod?.contains("-") == true) {
val split = it.data.validPeriod.split("-")
binding.run {
tvStart.text = TimeUtil.changeDateFormat(split[0])
tvStart.text =
TimeUtil.changeDateFormat(split[0])
tvEnd.text =
if (split.size == 2) TimeUtil.changeDateFormat(split[1]) else ""
if (split.size == 2) TimeUtil.changeDateFormat(
split[1]
) else ""
}
}
}
@ -157,5 +167,41 @@ class AuthPersonActivity : BaseActivity<ActivityAuthPersonBinding>() {
}
override fun initDate() {
val data =
Gson().fromJson(intent.extras?.getString(USER_DETAIL), UserDetail::class.java)
if (isOnlyShow) {
binding.run {
llBtn.visibility = View.GONE
etName.isEnabled = false
etId.isEnabled = false
tvStart.isEnabled = false
tvEnd.isEnabled = false
ivFront.isEnabled = false
ivBack.isEnabled = false
etName.setText(data.idcardName)
etId.setText(data.idcardNo)
tvStart.text = data.idcardEffectiveStart
tvEnd.text = data.idcardEffectiveEnd
ImageLoader.getInstance()
.loadRoundImage(mContext, data.idcardFrontUrl, 12, ivFront)
ImageLoader.getInstance()
.loadRoundImage(mContext, data.idcardBackUrl, 12, ivBack)
}
} else {
if (data != null) {
binding.run {
etName.setText(data.idcardName)
etId.setText(data.idcardNo)
tvStart.text = data.idcardEffectiveStart
tvEnd.text = data.idcardEffectiveEnd
ImageLoader.getInstance()
.loadRoundImage(mContext, data.idcardFrontUrl, 12, ivFront)
ImageLoader.getInstance()
.loadRoundImage(mContext, data.idcardBackUrl, 12, ivBack)
}
}
}
}
}

View File

@ -76,8 +76,8 @@ class AuthQualificationActivity : BaseActivity<ActivityAuthQualificationBinding>
DataManager.getInstance().setUpDriverQualificationCertificate(upQuaInfo)
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<String>() {
override fun onSuccess(t: CommonResponseBean<String>) {
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<Any>() {
override fun onSuccess(t: CommonResponseBean<Any>) {
super.onSuccess(t)
ActivityUtils.startActivity(mContext, AuthBankCardActivity::class.java)
}

View File

@ -64,8 +64,8 @@ class AuthRoadActivity : BaseActivity<ActivityAuthRoadBinding>() {
DataManager.getInstance().setUpRoadLicense(upRoad)
.subscribeOn(Schedulers.io())
.observeOn(AndroidSchedulers.mainThread())
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<String>() {
override fun onSuccess(t: CommonResponseBean<String>) {
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<Any>() {
override fun onSuccess(t: CommonResponseBean<Any>) {
super.onSuccess(t)
ActivityUtils.startActivity(mContext, AuthSuccActivity::class.java)
}

View File

@ -225,8 +225,8 @@ class AuthTeamActivity : BaseActivity<ActivityAuthTeamBinding>(), View.OnClickLi
DataManager.getInstance()
.authenticationCaptain(if (checkTeamType == 1) upComInfoBean else upPerInfoBean)
.subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread())
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<String>(this) {
override fun onSuccess(t: CommonResponseBean<String>) {
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<Any>(this) {
override fun onSuccess(t: CommonResponseBean<Any>) {
super.onSuccess(t)
}
}))

View File

@ -0,0 +1,89 @@
package com.dahe.gldriver.ui.mine.activity
import android.os.Bundle
import android.view.View
import com.dahe.gldriver.databinding.ActivityCarDetailBinding
import com.dahe.gldriver.databinding.ActivityDriverTeamDetailBinding
import com.dahe.gldriver.net.BaseObserver
import com.dahe.gldriver.net.DataManager
import com.dahe.gldriver.net.RxHttpCallBack
import com.dahe.gldriver.utils.SPUtils
import com.dahe.glex.bean.UserDetail
import com.dahe.mylibrary.base.BaseActivity
import com.dahe.mylibrary.net.CommonResponseBean
import io.reactivex.rxjava3.android.schedulers.AndroidSchedulers
import io.reactivex.rxjava3.schedulers.Schedulers
/**
* @ClassName CarDetailActivity
* @Author john
* @Date 2024/3/21 11:24
* @Description TODO
*/
class CarDetailActivity : BaseActivity<ActivityCarDetailBinding>() {
var doneInfoCount = 0
override fun initView(savedInstanceState: Bundle?) {
setStatusHeightParams(binding.rlTop)
setTitleBar("车辆详情", true)
}
override fun initDate() {
DataManager.getInstance().getUserDetail()
.subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread())
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<UserDetail>() {
override fun onSuccess(t: CommonResponseBean<UserDetail>) {
super.onSuccess(t)
initViewByData(t.data)
}
}))
}
private fun initViewByData(data: UserDetail) {
// userDetail = data
binding.run {
val userInfo = SPUtils.instance.getUserInfo(mContext)
var missInfo = ""
if (data.idcardNo.isNullOrEmpty()) {
tvInfo.text = "证件缺失将无法进行接单"
missInfo.plus("行驶证、")
} else {
doneInfoCount++
tvInfo.text = """${data.idcardName} ${data.idcardNo}"""
}
if (data.licenseNo.isNullOrEmpty()) {
tvDriverInfo.text = "证件缺失将无法进行接单"
missInfo.plus("挂车行驶证、")
} else {
doneInfoCount++
tvDriverInfo.text = """${data.licenseName} ${data.licenseNo}"""
}
if (data.qualificationCertificateNo.isNullOrEmpty()) {
tvQualiInfo.text = "证件缺失将无法进行接单"
missInfo.plus("道路运输许可证、")
} else {
doneInfoCount++
tvQualiInfo.text = """${data.qualificationCertificateNo}"""
}
btnNext.text = if (doneInfoCount == 3) "已完成" else "继续认证"
tvContent.text = if (missInfo.isNullOrEmpty()) "认证成功,请接单把!!!" else missInfo
llId.visibility = if (data.idcardNo.isNullOrEmpty()) View.GONE else View.VISIBLE
btnId.visibility = if (data.idcardNo.isNullOrEmpty()) View.VISIBLE else View.GONE
llDriver.visibility = if (data.licenseNo.isNullOrEmpty()) View.GONE else View.VISIBLE
btnDriver.visibility = if (data.licenseNo.isNullOrEmpty()) View.VISIBLE else View.GONE
llQua.visibility =
if (data.qualificationCertificateNo.isNullOrEmpty()) View.GONE else View.VISIBLE
btnQua.visibility =
if (data.qualificationCertificateNo.isNullOrEmpty()) View.VISIBLE else View.GONE
circleBarView2.progress = doneInfoCount * 100 / 3
}
}
}

View File

@ -50,6 +50,9 @@ class CarsManActivity : BaseActivity<ActivityCarsManBinding>() {
adapter as CarsAdapter
}.apply {
isStateViewEnable = true
setOnItemClickListener{_,_,position->
ActivityUtils.startActivity(mContext,CarDetailActivity::class.java)
}
addOnItemChildClickListener(R.id.tvUnbind) { adapter, view, position ->
CommonPopUtils.getInstance()
.showCommCenterPop(

View File

@ -1,9 +1,23 @@
package com.dahe.gldriver.ui.mine.activity
import android.os.Bundle
import android.view.View
import com.dahe.gldriver.R
import com.dahe.gldriver.base.AppConfig
import com.dahe.gldriver.databinding.ActivityPersonInfoBinding
import com.dahe.gldriver.net.BaseObserver
import com.dahe.gldriver.net.DataManager
import com.dahe.gldriver.net.RxHttpCallBack
import com.dahe.gldriver.ui.account.authperson.AuthPersonActivity
import com.dahe.gldriver.utils.OrderUtils
import com.dahe.gldriver.utils.SPUtils
import com.dahe.glex.bean.UserDetail
import com.dahe.mylibrary.base.BaseActivity
import com.dahe.mylibrary.net.CommonResponseBean
import com.dahe.mylibrary.utils.ActivityUtils
import com.google.gson.Gson
import io.reactivex.rxjava3.android.schedulers.AndroidSchedulers
import io.reactivex.rxjava3.schedulers.Schedulers
/**
* @ClassName PersonInfoActivity
@ -11,19 +25,133 @@ import com.dahe.mylibrary.base.BaseActivity
* @Date 2024/2/18 08:47
* @Description TODO
*/
class PersonInfoActivity : BaseActivity<ActivityPersonInfoBinding>() {
class PersonInfoActivity : BaseActivity<ActivityPersonInfoBinding>(), View.OnClickListener {
var doneInfoCount = 0
var userDetail: UserDetail? = null
override fun initView(savedInstanceState: Bundle?) {
setStatusHeightParams(binding.rlTop)
setTitleBar("实名认证",true)
setTitleBar("实名认证", true)
binding.circleBarView2.run {
text = "完成度"
valueText = "10"
unitText= "%"
progress = 20
binding.run {
circleBarView2.run {
text = "完成度"
unitText = "%"
progress = 0
}
btnId.setOnClickListener(this@PersonInfoActivity)
llAgainId.setOnClickListener(this@PersonInfoActivity)
llSeeId.setOnClickListener(this@PersonInfoActivity)
btnDriver.setOnClickListener(this@PersonInfoActivity)
llAgainDriver.setOnClickListener(this@PersonInfoActivity)
llSeeDriver.setOnClickListener(this@PersonInfoActivity)
btnQua.setOnClickListener(this@PersonInfoActivity)
llAgainQua.setOnClickListener(this@PersonInfoActivity)
llSeeQua.setOnClickListener(this@PersonInfoActivity)
btnFace.setOnClickListener(this@PersonInfoActivity)
}
}
override fun initDate() {
DataManager.getInstance().getUserDetail()
.subscribeOn(Schedulers.io()).observeOn(AndroidSchedulers.mainThread())
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<UserDetail>() {
override fun onSuccess(t: CommonResponseBean<UserDetail>) {
super.onSuccess(t)
initViewByData(t.data)
}
}))
}
override fun onClick(view: View?) {
super.onClick(view)
binding.run {
when (view?.id) {
btnId.id, llAgainId.id -> ActivityUtils.startActivity(
mContext,
AuthPersonActivity::class.java,
Bundle().apply {
putBoolean(AppConfig.IS_ONLY_SHOW, false)
putString(AppConfig.USER_DETAIL, Gson().toJson(userDetail))
})
llSeeId.id -> ActivityUtils.startActivity(
mContext,
AuthPersonActivity::class.java,
Bundle().apply {
putBoolean(AppConfig.IS_ONLY_SHOW, true)
putString(AppConfig.USER_DETAIL, Gson().toJson(userDetail))
})
btnDriver.id, llAgainDriver.id -> {}
llSeeDriver.id -> {}
btnQua.id, llAgainQua.id -> {}
llSeeQua.id -> {}
btnFace.id -> {}
}
}
}
private fun initViewByData(data: UserDetail) {
userDetail = data
binding.run {
val userInfo = SPUtils.instance.getUserInfo(mContext)
var missInfo = ""
if (data.idcardNo.isNullOrEmpty()) {
tvInfo.text = "证件缺失将无法进行接单"
missInfo.plus("身份证、")
} else {
doneInfoCount++
tvInfo.text = """${data.idcardName} ${data.idcardNo}"""
}
if (data.licenseNo.isNullOrEmpty()) {
tvDriverInfo.text = "证件缺失将无法进行接单"
missInfo.plus("驾驶证、")
} else {
doneInfoCount++
tvDriverInfo.text = """${data.licenseName} ${data.licenseNo}"""
}
if (data.qualificationCertificateNo.isNullOrEmpty()) {
tvQualiInfo.text = "证件缺失将无法进行接单"
missInfo.plus("从业资格证、")
} else {
doneInfoCount++
tvQualiInfo.text = """${data.qualificationCertificateNo}"""
}
if (userInfo?.isRealName == "0") {
btnFace.text = "未实名认证将无法进行接单"
missInfo.plus("实名认证缺失")
} else {
doneInfoCount++
tvFaceInfo.text = "实名认证成功"
}
btnNext.text = if (doneInfoCount == 4) "已完成" else "继续认证"
tvContent.text = if (missInfo.isNullOrEmpty()) "认证成功,请接单把!!!" else missInfo
llId.visibility = if (data.idcardNo.isNullOrEmpty()) View.GONE else View.VISIBLE
btnId.visibility = if (data.idcardNo.isNullOrEmpty()) View.VISIBLE else View.GONE
llDriver.visibility = if (data.licenseNo.isNullOrEmpty()) View.GONE else View.VISIBLE
btnDriver.visibility = if (data.licenseNo.isNullOrEmpty()) View.VISIBLE else View.GONE
llQua.visibility =
if (data.qualificationCertificateNo.isNullOrEmpty()) View.GONE else View.VISIBLE
btnQua.visibility =
if (data.qualificationCertificateNo.isNullOrEmpty()) View.VISIBLE else View.GONE
btnFace.visibility = if (userInfo?.isRealName == "0") View.VISIBLE else View.GONE
circleBarView2.progress = doneInfoCount * 100 / 4
}
}
}

View File

@ -8,6 +8,8 @@ import com.dahe.gldriver.net.BaseObserver
import com.dahe.gldriver.net.DataManager
import com.dahe.gldriver.net.RxHttpCallBack
import com.dahe.gldriver.temp.AuthPageConfig
import com.dahe.gldriver.temp.CustomXmlConfig
import com.dahe.gldriver.temp.DialogPortConfig
import com.dahe.gldriver.temp.FullPortConfig
import com.dahe.gldriver.ui.HomeActivity
import com.dahe.gldriver.ui.account.LoginActivity
@ -63,20 +65,9 @@ class OneKeyLoginUtils private constructor() {
override fun onSuccess(t: CommonResponseBean<UserBean>) {
super.onSuccess(t)
mPhoneNumberAuthHelper.quitLoginPage()
SPUtils.instance.setUserInfo(context, Gson().toJson(t.data))
if (t.data.isCarCaptain == "9") {//是否是车队长0=否,1=是,9=未选择)
ActivityUtils.startActivity(
context,
SelectRoleActivity::class.java
)
} else {
ActivityUtils.startActivity(
context,
HomeActivity::class.java
)
}
ActivityUtils.finishToActivity(LoginActivity::class.java,true)
UserUtils.instance.loginIn(context,t.data)
}
}))
}
@ -134,6 +125,7 @@ class OneKeyLoginUtils private constructor() {
}
mUIConfig = FullPortConfig(activity, mPhoneNumberAuthHelper)
// mUIConfig = DialogPortConfig(activity, mPhoneNumberAuthHelper)
}
private open class CheckListener(context: Context) : UMTokenResultListener {

View File

@ -1,7 +1,17 @@
package com.dahe.gldriver.utils
import android.content.Context
import android.content.Intent
import com.dahe.gldriver.push.PushHelper
import com.dahe.gldriver.ui.HomeActivity
import com.dahe.gldriver.ui.LauncherActivity
import com.dahe.gldriver.ui.account.LoginActivity
import com.dahe.gldriver.ui.account.SelectRoleActivity
import com.dahe.glex.bean.UserBean
import com.dahe.mylibrary.utils.ActivityUtils
import com.dahe.mylibrary.utils.BaseSPUtils
import com.dahe.mylibrary.utils.ToastUtils
import com.google.gson.Gson
class UserUtils private constructor(){
@ -16,11 +26,31 @@ class UserUtils private constructor(){
fun loginOut(context : Context){
if (null== SPUtils.instance.getUserInfo(context))
return
// PushAgent.getInstance(context).deleteAlias(SPUtils.getUserInfo(context).userInfo.userId,"uid"){ b, s -> }
// BaseSPUtils.cleanUserInfo(context)
// val intent = Intent(context, LauncherActivity::class.java)
// intent.flags = Intent.FLAG_ACTIVITY_CLEAR_TASK or Intent.FLAG_ACTIVITY_NEW_TASK
// context.startActivity(intent)
// ToastUtils.showToast(context, "您的账号再异地登录,请重新登录")
//删除推送别名
PushHelper.delete(context)
BaseSPUtils.cleanUserInfo(context)
val intent = Intent(context, LauncherActivity::class.java)
intent.flags = Intent.FLAG_ACTIVITY_CLEAR_TASK or Intent.FLAG_ACTIVITY_NEW_TASK
context.startActivity(intent)
ToastUtils.showToast(context, "您的账号再异地登录,请重新登录")
}
fun loginIn(context: Context,userBean: UserBean){
SPUtils.instance.setUserInfo(context, Gson().toJson(userBean))
//设置推送别名
PushHelper.setAlias(context,userBean)
if (userBean.isCarCaptain == "9") {//是否是车队长0=否,1=是,9=未选择)
ActivityUtils.startActivity(
context,
SelectRoleActivity::class.java
)
} else {
ActivityUtils.startActivity(
context,
HomeActivity::class.java
)
}
ActivityUtils.finishToActivity(LoginActivity::class.java,true)
}
}

View File

@ -9,6 +9,7 @@
<include layout="@layout/common_toolbar"></include>
<TextView
android:layout_width="match_parent"
android:layout_height="wrap_content"
@ -121,8 +122,8 @@
android:layout_marginLeft="@dimen/dp_10"
android:layout_weight="1"
android:background="@drawable/shape_phone_bg"
android:paddingLeft="@dimen/dp_10"
android:gravity="right|center_vertical"
android:paddingLeft="@dimen/dp_10"
android:paddingRight="@dimen/dp_10"
android:textColor="@color/black"
android:textSize="@dimen/sp_15"
@ -151,10 +152,10 @@
android:layout_marginLeft="@dimen/dp_10"
android:layout_weight="1"
android:background="@drawable/shape_phone_bg"
android:paddingLeft="@dimen/dp_10"
android:textColor="@color/black"
android:gravity="right|center_vertical"
android:paddingLeft="@dimen/dp_10"
android:paddingRight="@dimen/dp_10"
android:textColor="@color/black"
android:textSize="@dimen/sp_15"
tools:text="412826196205220056"></EditText>
</LinearLayout>
@ -182,18 +183,21 @@
android:layout_marginLeft="@dimen/dp_10"
android:layout_weight="1"
android:background="@drawable/shape_phone_bg"
android:gravity="right|center_vertical"
android:hint="请选择开始日期"
android:maxLines="1"
android:paddingLeft="@dimen/dp_10"
android:paddingRight="@dimen/dp_10"
android:singleLine="true"
android:textColor="@color/black"
android:textSize="@dimen/sp_15"
android:gravity="right|center_vertical"
android:paddingRight="@dimen/dp_10"
android:hint="请选择开始日期"
tools:text="1990-05-24"></TextView>
</LinearLayout>
<LinearLayout
android:layout_below="@+id/llStart"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/llStart"
android:layout_marginTop="@dimen/dp_14"
android:orientation="horizontal">
@ -213,12 +217,14 @@
android:layout_marginLeft="@dimen/dp_10"
android:layout_weight="1"
android:background="@drawable/shape_phone_bg"
android:gravity="right|center_vertical"
android:hint="请选择结束日期"
android:maxLines="1"
android:paddingLeft="@dimen/dp_10"
android:paddingRight="@dimen/dp_10"
android:singleLine="true"
android:textColor="@color/black"
android:textSize="@dimen/sp_15"
android:gravity="right|center_vertical"
android:paddingRight="@dimen/dp_10"
android:hint="请选择结束日期"
tools:text="1990-05-24"></TextView>
</LinearLayout>
@ -233,6 +239,7 @@
android:background="@color/white"></View>
<LinearLayout
android:id="@+id/llBtn"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_70"
android:background="@color/white"

View File

@ -0,0 +1,503 @@
<?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"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:background="@color/white"
android:orientation="vertical">
<RelativeLayout
android:id="@+id/rlTop"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_242"
android:background="@drawable/person_bg">
<include layout="@layout/common_toolbar"></include>
</RelativeLayout>
<androidx.core.widget.NestedScrollView
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="@dimen/dp_96"
android:fillViewport="true">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<androidx.cardview.widget.CardView
android:id="@+id/cdPerson"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginRight="@dimen/dp_15"
app:cardBackgroundColor="@color/white"
app:cardCornerRadius="@dimen/dp_8">
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center_horizontal"
android:paddingBottom="@dimen/dp_20"
android:orientation="vertical">
<com.dahe.mylibrary.weight.CircleBarView2
android:id="@+id/circleBarView2"
android:layout_width="@dimen/dp_260"
android:layout_height="@dimen/dp_110"
android:layout_marginTop="@dimen/dp_16" />
<Button
android:id="@+id/btnNext"
android:layout_width="@dimen/dp_100"
android:layout_height="@dimen/dp_28"
android:background="@drawable/shape_btn_14"
android:text="继续认证"
android:textColor="@color/white"
android:textSize="@dimen/sp_12" />
<LinearLayout
android:id="@+id/llContent"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_36"
android:layout_marginLeft="@dimen/dp_10"
android:layout_marginTop="@dimen/dp_20"
android:layout_marginRight="@dimen/dp_10"
android:background="@drawable/shape_code_bg5"
android:gravity="center_vertical"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/dp_12"
android:layout_height="@dimen/dp_12"
android:layout_marginLeft="@dimen/dp_10"
android:background="@drawable/icon_warn" />
<TextView
android:id="@+id/tvContent"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
android:text="行驶证和从业资格证照片缺失"
android:textColor="@color/black"
android:textSize="@dimen/sp_12" />
</LinearLayout>
</LinearLayout>
</androidx.cardview.widget.CardView>
<androidx.cardview.widget.CardView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_10"
android:layout_marginRight="@dimen/dp_15"
app:cardBackgroundColor="@color/white"
app:cardCornerRadius="@dimen/dp_8">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<ImageView
android:id="@+id/ivIcon"
android:layout_width="@dimen/dp_21"
android:layout_height="@dimen/dp_21"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_18"
android:background="@drawable/icon_person" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBottom="@+id/ivIcon"
android:layout_marginLeft="@dimen/dp_10"
android:layout_toRightOf="@+id/ivIcon"
android:text="行驶证"
android:textColor="@color/black"
android:textSize="@dimen/sp_16" />
<TextView
android:id="@+id/tvInfo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/ivIcon"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_8"
android:layout_marginBottom="@dimen/dp_15"
android:text="王师傅 412************062"
android:textColor="@color/color_c"
android:textSize="@dimen/sp_12" />
<Button
android:id="@+id/btnId"
android:layout_width="@dimen/dp_55"
android:layout_height="@dimen/dp_22"
android:layout_alignParentRight="true"
android:layout_marginTop="@dimen/dp_24"
android:layout_marginRight="@dimen/dp_14"
android:background="@drawable/shape_btn_11"
android:text="去上传"
android:textColor="@color/white"
android:textSize="@dimen/sp_12" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tvInfo"
android:orientation="vertical">
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginRight="@dimen/dp_15"
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llId"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_46"
android:gravity="center"
android:orientation="horizontal">
<LinearLayout
android:id="@+id/llAgainId"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/dp_14"
android:layout_height="@dimen/dp_14"
android:background="@drawable/icon_refre" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
android:text="重新上传"
android:textColor="#917349"
android:textSize="@dimen/sp_12" />
</LinearLayout>
<View
android:layout_width="@dimen/dp_1"
android:layout_height="@dimen/dp_16"
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llSeeId"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/dp_14"
android:layout_height="@dimen/dp_14"
android:background="@drawable/icon_check" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
android:text="查看证件"
android:textColor="#917349"
android:textSize="@dimen/sp_12" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
</RelativeLayout>
</androidx.cardview.widget.CardView>
<androidx.cardview.widget.CardView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_10"
android:layout_marginRight="@dimen/dp_15"
app:cardBackgroundColor="@color/white"
app:cardCornerRadius="@dimen/dp_8">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<ImageView
android:id="@+id/ivIcon2"
android:layout_width="@dimen/dp_21"
android:layout_height="@dimen/dp_21"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_18"
android:background="@drawable/icon_driver" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBottom="@+id/ivIcon2"
android:layout_marginLeft="@dimen/dp_10"
android:layout_toRightOf="@+id/ivIcon2"
android:text="挂车驾驶证"
android:textColor="@color/black"
android:textSize="@dimen/sp_16" />
<TextView
android:id="@+id/tvDriverInfo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/ivIcon2"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_8"
android:layout_marginBottom="@dimen/dp_15"
android:text="王师傅 412************062"
android:textColor="@color/color_c"
android:textSize="@dimen/sp_12" />
<Button
android:id="@+id/btnDriver"
android:layout_width="@dimen/dp_55"
android:layout_height="@dimen/dp_22"
android:layout_alignParentRight="true"
android:layout_marginTop="@dimen/dp_24"
android:layout_marginRight="@dimen/dp_14"
android:background="@drawable/shape_btn_11"
android:text="去上传"
android:textColor="@color/white"
android:textSize="@dimen/sp_12" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tvDriverInfo"
android:orientation="vertical">
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginRight="@dimen/dp_15"
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llDriver"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_46"
android:gravity="center"
android:orientation="horizontal">
<LinearLayout
android:id="@+id/llAgainDriver"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/dp_14"
android:layout_height="@dimen/dp_14"
android:background="@drawable/icon_refre" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
android:text="重新上传"
android:textColor="#917349"
android:textSize="@dimen/sp_12" />
</LinearLayout>
<View
android:layout_width="@dimen/dp_1"
android:layout_height="@dimen/dp_16"
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llSeeDriver"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/dp_14"
android:layout_height="@dimen/dp_14"
android:background="@drawable/icon_check" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
android:text="查看证件"
android:textColor="#917349"
android:textSize="@dimen/sp_12" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
</RelativeLayout>
</androidx.cardview.widget.CardView>
<androidx.cardview.widget.CardView
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_10"
android:layout_marginRight="@dimen/dp_15"
app:cardBackgroundColor="@color/white"
app:cardCornerRadius="@dimen/dp_8">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<ImageView
android:id="@+id/ivIcon3"
android:layout_width="@dimen/dp_21"
android:layout_height="@dimen/dp_21"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_18"
android:background="@drawable/icon_quali" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignBottom="@+id/ivIcon3"
android:layout_marginLeft="@dimen/dp_10"
android:layout_toRightOf="@+id/ivIcon3"
android:text="道路运输许可证"
android:textColor="@color/black"
android:textSize="@dimen/sp_16" />
<TextView
android:id="@+id/tvQualiInfo"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_below="@+id/ivIcon3"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_8"
android:layout_marginBottom="@dimen/dp_15"
android:text="王师傅 412************062"
android:textColor="@color/color_c"
android:textSize="@dimen/sp_12" />
<Button
android:id="@+id/btnQua"
android:layout_width="@dimen/dp_55"
android:layout_height="@dimen/dp_22"
android:layout_alignParentRight="true"
android:layout_marginTop="@dimen/dp_24"
android:layout_marginRight="@dimen/dp_14"
android:background="@drawable/shape_btn_11"
android:text="去上传"
android:textColor="@color/white"
android:textSize="@dimen/sp_12" />
<LinearLayout
android:id="@+id/llQua"
android:visibility="gone"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tvQualiInfo"
android:orientation="vertical">
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginRight="@dimen/dp_15"
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llAgainQua"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_46"
android:gravity="center"
android:orientation="horizontal">
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/dp_14"
android:layout_height="@dimen/dp_14"
android:background="@drawable/icon_refre" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
android:text="重新上传"
android:textColor="#917349"
android:textSize="@dimen/sp_12" />
</LinearLayout>
<View
android:layout_width="@dimen/dp_1"
android:layout_height="@dimen/dp_16"
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llSeeQua"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/dp_14"
android:layout_height="@dimen/dp_14"
android:background="@drawable/icon_check" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
android:text="查看证件"
android:textColor="#917349"
android:textSize="@dimen/sp_12" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
</RelativeLayout>
</androidx.cardview.widget.CardView>
<View
android:layout_width="@dimen/dp_0"
android:layout_height="@dimen/dp_10"/>
</LinearLayout>
</androidx.core.widget.NestedScrollView>
</RelativeLayout>

View File

@ -32,7 +32,7 @@
<androidx.cardview.widget.CardView
android:id="@+id/cdPerson"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_225"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginRight="@dimen/dp_15"
@ -43,6 +43,7 @@
android:layout_width="match_parent"
android:layout_height="match_parent"
android:gravity="center_horizontal"
android:paddingBottom="@dimen/dp_20"
android:orientation="vertical">
<com.dahe.mylibrary.weight.CircleBarView2
@ -52,6 +53,7 @@
android:layout_marginTop="@dimen/dp_16" />
<Button
android:id="@+id/btnNext"
android:layout_width="@dimen/dp_100"
android:layout_height="@dimen/dp_28"
android:background="@drawable/shape_btn_14"
@ -60,6 +62,7 @@
android:textSize="@dimen/sp_12" />
<LinearLayout
android:id="@+id/llContent"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_36"
android:layout_marginLeft="@dimen/dp_10"
@ -76,6 +79,7 @@
android:background="@drawable/icon_warn" />
<TextView
android:id="@+id/tvContent"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
@ -136,6 +140,7 @@
android:textSize="@dimen/sp_12" />
<Button
android:id="@+id/btnId"
android:layout_width="@dimen/dp_55"
android:layout_height="@dimen/dp_22"
android:layout_alignParentRight="true"
@ -161,12 +166,14 @@
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llId"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_46"
android:gravity="center"
android:orientation="horizontal">
<LinearLayout
android:id="@+id/llAgainId"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
@ -193,6 +200,7 @@
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llSeeId"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
@ -265,6 +273,7 @@
android:textSize="@dimen/sp_12" />
<Button
android:id="@+id/btnDriver"
android:layout_width="@dimen/dp_55"
android:layout_height="@dimen/dp_22"
android:layout_alignParentRight="true"
@ -290,12 +299,14 @@
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llDriver"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_46"
android:gravity="center"
android:orientation="horizontal">
<LinearLayout
android:id="@+id/llAgainDriver"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
@ -322,6 +333,7 @@
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llSeeDriver"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
@ -394,6 +406,7 @@
android:textSize="@dimen/sp_12" />
<Button
android:id="@+id/btnQua"
android:layout_width="@dimen/dp_55"
android:layout_height="@dimen/dp_22"
android:layout_alignParentRight="true"
@ -406,6 +419,7 @@
<LinearLayout
android:id="@+id/llQua"
android:visibility="gone"
android:layout_width="match_parent"
android:layout_height="wrap_content"
@ -420,6 +434,7 @@
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llAgainQua"
android:layout_width="match_parent"
android:layout_height="@dimen/dp_46"
android:gravity="center"
@ -452,6 +467,7 @@
android:background="@color/color_c" />
<LinearLayout
android:id="@+id/llSeeQua"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
@ -518,91 +534,23 @@
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginTop="@dimen/dp_8"
android:layout_marginBottom="@dimen/dp_15"
android:text="王师傅 412************062"
android:text="人脸缺失将无法完成实名认证"
android:textColor="@color/color_c"
android:textSize="@dimen/sp_12" />
<Button
android:id="@+id/btnFace"
android:layout_width="@dimen/dp_55"
android:layout_height="@dimen/dp_22"
android:layout_alignParentRight="true"
android:layout_marginTop="@dimen/dp_24"
android:layout_marginRight="@dimen/dp_14"
android:background="@drawable/shape_btn_11"
android:text="去上传"
android:text="去认证"
android:textColor="@color/white"
android:textSize="@dimen/sp_12" />
<LinearLayout
android:visibility="gone"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_below="@+id/tvFaceInfo"
android:orientation="vertical">
<View
android:layout_width="match_parent"
android:layout_height="@dimen/dp_1"
android:layout_marginLeft="@dimen/dp_15"
android:layout_marginRight="@dimen/dp_15"
android:background="@color/color_c" />
<LinearLayout
android:layout_width="match_parent"
android:layout_height="@dimen/dp_46"
android:gravity="center"
android:orientation="horizontal">
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/dp_14"
android:layout_height="@dimen/dp_14"
android:background="@drawable/icon_refre" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
android:text="重新上传"
android:textColor="#917349"
android:textSize="@dimen/sp_12" />
</LinearLayout>
<View
android:layout_width="@dimen/dp_1"
android:layout_height="@dimen/dp_16"
android:background="@color/color_c" />
<LinearLayout
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:gravity="center"
android:orientation="horizontal">
<ImageView
android:layout_width="@dimen/dp_14"
android:layout_height="@dimen/dp_14"
android:background="@drawable/icon_check" />
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_marginLeft="@dimen/dp_4"
android:text="查看证件"
android:textColor="#917349"
android:textSize="@dimen/sp_12" />
</LinearLayout>
</LinearLayout>
</LinearLayout>
</RelativeLayout>
</androidx.cardview.widget.CardView>

View File

@ -0,0 +1,81 @@
<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
>
<ImageView
android:id="@+id/iv_background"
android:layout_width="match_parent"
android:layout_height="match_parent"/>
<LinearLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical">
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="50dp"
android:background="@color/main_red">
<ImageView
android:id="@+id/btn_back"
android:layout_width="20dp"
android:layout_height="20dp"
android:background="@drawable/black_back"
android:scaleType="center"
android:layout_centerVertical="true"
android:cropToPadding="true"
android:layout_marginLeft="12dp"/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerInParent="true"
android:textSize="18sp"
android:textColor="@color/white"
android:text="hahha"/>
</RelativeLayout>
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_marginTop="50dp"
android:orientation="vertical">
<ImageView
android:layout_width="50dp"
android:layout_height="50dp"
android:layout_centerHorizontal="true"
android:background="@drawable/head_defaut"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_marginTop="70dp"
android:text="nizhenshuai"
android:textColor="@color/black"
android:textSize="20sp" />
<TextView
android:id="@+id/tv_switch"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerHorizontal="true"
android:layout_marginTop="350dp"
android:text="duanxindenglu"
android:textSize="18sp" />
</RelativeLayout>
</LinearLayout>
</RelativeLayout>

View File

@ -0,0 +1,33 @@
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="38.5dp"
android:background="@android:color/transparent">
<TextView
android:id="@+id/tv_title"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="免密登陆"
android:textColor="@android:color/black"
android:textSize="12sp"
android:gravity="center"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<ImageView
android:id="@+id/btn_close"
android:layout_width="50dp"
android:layout_height="50dp"
android:scaleType="fitCenter"
android:src="@drawable/black_back"
android:padding="20dp"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
/>
</LinearLayout>