优化从业资格证判断逻辑
This commit is contained in:
parent
55ae6f863f
commit
c9b561537f
@ -122,18 +122,18 @@ class AuthDriverActivity : BaseActivity<ActivityAuthDriverBinding>() {
|
|||||||
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<Any>() {
|
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<Any>() {
|
||||||
override fun onSuccess(t: CommonResponseBean<Any>) {
|
override fun onSuccess(t: CommonResponseBean<Any>) {
|
||||||
super.onSuccess(t)
|
super.onSuccess(t)
|
||||||
if (driverInfoBean.licenseType.contains("C")) {//C证
|
//驾驶证类型包含A B类需要上传从业资格证
|
||||||
ActivityUtils.startActivity(
|
if (driverInfoBean.licenseType.contains("A")||driverInfoBean.licenseType.contains("B")) {
|
||||||
mContext,
|
|
||||||
AuthBankCardActivity::class.java
|
|
||||||
)
|
|
||||||
} else {
|
|
||||||
ActivityUtils.startActivity(
|
ActivityUtils.startActivity(
|
||||||
mContext,
|
mContext,
|
||||||
AuthQualificationActivity::class.java
|
AuthQualificationActivity::class.java
|
||||||
)
|
)
|
||||||
|
}else{
|
||||||
|
ActivityUtils.startActivity(
|
||||||
|
mContext,
|
||||||
|
AuthBankCardActivity::class.java
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}))
|
}))
|
||||||
}
|
}
|
||||||
|
@ -70,7 +70,6 @@ class EditDriverActivity : BaseActivity<ActivityAuthDriverBinding>() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ivFront.setOnClickListener {
|
ivFront.setOnClickListener {
|
||||||
|
|
||||||
if (driverInfoBean.licensePhotoFaceUrl.isNullOrEmpty()){
|
if (driverInfoBean.licensePhotoFaceUrl.isNullOrEmpty()){
|
||||||
selFrontPic()
|
selFrontPic()
|
||||||
}else{
|
}else{
|
||||||
|
@ -206,7 +206,7 @@ class HomeFragment : BaseFragment<FragmentHomeBinding>(), RefreshCallBack {
|
|||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
getLocation()
|
// getLocation()
|
||||||
ALProcess.verification(mContext)
|
ALProcess.verification(mContext)
|
||||||
//证件过期判断+轨迹上传判断
|
//证件过期判断+轨迹上传判断
|
||||||
DataManager.getInstance().getUserInfo()
|
DataManager.getInstance().getUserInfo()
|
||||||
|
@ -323,19 +323,19 @@ class MineFragment : BaseFragment<FragmentMineBinding>(), View.OnClickListener,
|
|||||||
}
|
}
|
||||||
}))
|
}))
|
||||||
|
|
||||||
DataManager.getInstance().getDriverBalance()
|
// DataManager.getInstance().getDriverBalance()
|
||||||
.subscribeOn(Schedulers.io())
|
// .subscribeOn(Schedulers.io())
|
||||||
.observeOn(AndroidSchedulers.mainThread())
|
// .observeOn(AndroidSchedulers.mainThread())
|
||||||
.subscribe(BaseObserver(mContext, object : RxHttpCallBack<WalletInfo>() {
|
// .subscribe(BaseObserver(mContext, object : RxHttpCallBack<WalletInfo>() {
|
||||||
override fun onSuccess(t: CommonResponseBean<WalletInfo>) {
|
// override fun onSuccess(t: CommonResponseBean<WalletInfo>) {
|
||||||
super.onSuccess(t)
|
// super.onSuccess(t)
|
||||||
binding.run {
|
// binding.run {
|
||||||
tvWalletBa.text = t.data.acctBal
|
// tvWalletBa.text = t.data.acctBal
|
||||||
tvBankNum.text = t.data.bankCountNum
|
// tvBankNum.text = t.data.bankCountNum
|
||||||
tvIncome.text = t.data.accumulatedRevenue
|
// tvIncome.text = t.data.accumulatedRevenue
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
}))
|
// }))
|
||||||
|
|
||||||
//司机证件缺失过期提醒
|
//司机证件缺失过期提醒
|
||||||
val userInfo = SPUtils.instance.getUserInfo(mContext)
|
val userInfo = SPUtils.instance.getUserInfo(mContext)
|
||||||
|
@ -222,7 +222,7 @@ class PersonInfoActivity : BaseActivity<ActivityPersonInfoBinding>(), View.OnCli
|
|||||||
tvDriverInfo.text = """${data.licenseName} ${data.licenseNo}"""
|
tvDriverInfo.text = """${data.licenseName} ${data.licenseNo}"""
|
||||||
}
|
}
|
||||||
|
|
||||||
if (data.licenseType.contains("C")) {
|
if (!data.licenseType.contains("A")&&!data.licenseType.contains("B")) {
|
||||||
cvQua.visibility = View.GONE
|
cvQua.visibility = View.GONE
|
||||||
allInfoCount = 4
|
allInfoCount = 4
|
||||||
} else {
|
} else {
|
||||||
@ -239,7 +239,7 @@ class PersonInfoActivity : BaseActivity<ActivityPersonInfoBinding>(), View.OnCli
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
doneInfoCount++
|
doneInfoCount++
|
||||||
tvQualiInfo.text = """${data.qualificationCertificateNo}"""
|
tvQualiInfo.text = data.qualificationCertificateNo
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -253,7 +253,7 @@ class PersonInfoActivity : BaseActivity<ActivityPersonInfoBinding>(), View.OnCli
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
doneInfoCount++
|
doneInfoCount++
|
||||||
tvBankInfo.text = """${data.driverBankcardNumber}"""
|
tvBankInfo.text = data.driverBankcardNumber
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -294,7 +294,7 @@ class PersonInfoActivity : BaseActivity<ActivityPersonInfoBinding>(), View.OnCli
|
|||||||
if (data.driverBankcardNumber.isNullOrEmpty()) View.VISIBLE else View.GONE
|
if (data.driverBankcardNumber.isNullOrEmpty()) View.VISIBLE else View.GONE
|
||||||
|
|
||||||
|
|
||||||
btnFace.visibility = if (data?.isRealName == "0") View.VISIBLE else View.GONE
|
btnFace.visibility = if (data.isRealName == "0") View.VISIBLE else View.GONE
|
||||||
|
|
||||||
circleBarView2.progress = doneInfoCount * 100 / allInfoCount
|
circleBarView2.progress = doneInfoCount * 100 / allInfoCount
|
||||||
}
|
}
|
||||||
|
@ -88,7 +88,7 @@
|
|||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:text="郑州"
|
android:text="郑州"
|
||||||
android:textColor="@color/white"
|
android:textColor="@color/white"
|
||||||
android:textSize="@dimen/sp_16"></TextView>
|
android:textSize="@dimen/sp_16" />
|
||||||
|
|
||||||
<EditText
|
<EditText
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
Loading…
Reference in New Issue
Block a user