1.修复防篡改误报的问题并优化没有网络和服务器挂了的体验
2.支付管理编辑信用卡页面增加删除支付信息 3.优化添加信用卡页面点击空白处可隐藏键盘
This commit is contained in:
@@ -28,10 +28,10 @@ android {
|
|||||||
applicationId "com.abbidot.tracker"
|
applicationId "com.abbidot.tracker"
|
||||||
minSdkVersion 24
|
minSdkVersion 24
|
||||||
targetSdkVersion 35
|
targetSdkVersion 35
|
||||||
versionCode 2501
|
versionCode 2502
|
||||||
// versionName "2.5.1"
|
// versionName "2.5.2"
|
||||||
versionName "2.5.1-Beta1"
|
versionName "2.5.2-Beta1"
|
||||||
|
4
|
||||||
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
|
||||||
|
|
||||||
ndk {
|
ndk {
|
||||||
|
|||||||
@@ -338,11 +338,13 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
/**
|
/**
|
||||||
* 按钮开启/禁用点击
|
* 按钮开启/禁用点击
|
||||||
*/
|
*/
|
||||||
fun setButtonEnabled(v: View, enabled: Int = ConstantInt.SpecialType) {
|
fun setButtonEnabled(v: View?, enabled: Int = ConstantInt.SpecialType) {
|
||||||
when (enabled) {
|
v?.let {
|
||||||
ConstantInt.SpecialType -> v.isEnabled = !v.isEnabled
|
when (enabled) {
|
||||||
ConstantInt.Type0 -> v.isEnabled = false
|
ConstantInt.SpecialType -> v.isEnabled = !v.isEnabled
|
||||||
ConstantInt.Type1 -> v.isEnabled = true
|
ConstantInt.Type0 -> v.isEnabled = false
|
||||||
|
ConstantInt.Type1 -> v.isEnabled = true
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -422,7 +424,10 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
else {
|
else {
|
||||||
mTopBar!!.setTitle(title)
|
mTopBar!!.setTitle(title)
|
||||||
val tf =
|
val tf =
|
||||||
ViewUtil.instance.setTypeface(mContext, getString(R.string.roboto_bold_font))
|
ViewUtil.instance.setTypeface(
|
||||||
|
mContext,
|
||||||
|
getString(R.string.roboto_bold_font)
|
||||||
|
)
|
||||||
mTopBar!!.titleView!!.setTypeface(tf)
|
mTopBar!!.titleView!!.setTypeface(tf)
|
||||||
}
|
}
|
||||||
mTopBar!!.addLeftBackImageButton().setOnClickListener { leftBackOnClick() }
|
mTopBar!!.addLeftBackImageButton().setOnClickListener { leftBackOnClick() }
|
||||||
@@ -460,7 +465,10 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
// }
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
fun showNoCancelableLoading(show: Boolean, message: String = getString(R.string.txt_loading)) {
|
fun showNoCancelableLoading(
|
||||||
|
show: Boolean,
|
||||||
|
message: String = getString(R.string.txt_loading)
|
||||||
|
) {
|
||||||
if (!isFrontRunning && show) {
|
if (!isFrontRunning && show) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@@ -472,7 +480,8 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
// if (TextUtils.isEmpty(tip)) {
|
// if (TextUtils.isEmpty(tip)) {
|
||||||
// }
|
// }
|
||||||
mLoadingDialog =
|
mLoadingDialog =
|
||||||
QMUITipDialog.Builder(mContext).setIconType(QMUITipDialog.Builder.ICON_TYPE_LOADING)
|
QMUITipDialog.Builder(mContext)
|
||||||
|
.setIconType(QMUITipDialog.Builder.ICON_TYPE_LOADING)
|
||||||
.setTipWord(message).create(false).apply {
|
.setTipWord(message).create(false).apply {
|
||||||
setCanceledOnTouchOutside(false)
|
setCanceledOnTouchOutside(false)
|
||||||
show()
|
show()
|
||||||
@@ -585,7 +594,7 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
isShowNoDataTip: Boolean = true,//是否显示无数据提示
|
isShowNoDataTip: Boolean = true,//是否显示无数据提示
|
||||||
isShowRequestErrorTip: Boolean = true,//是否显示请求错误提示
|
isShowRequestErrorTip: Boolean = true,//是否显示请求错误提示
|
||||||
isShowCodeError: Boolean = true,//是否显示错误码提示
|
isShowCodeError: Boolean = true,//是否显示错误码提示
|
||||||
isShowNetCodeMsg: Boolean = false,//是否显示服务器返回message提示
|
isShowNetErrorMsg: Boolean = false,//是否显示服务器返回message提示
|
||||||
errorTip: String = getString(R.string.txt_net_error)
|
errorTip: String = getString(R.string.txt_net_error)
|
||||||
) {
|
) {
|
||||||
try {
|
try {
|
||||||
@@ -625,7 +634,7 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
|
|
||||||
val data = it.getOrNull()
|
val data = it.getOrNull()
|
||||||
if (null == data) {
|
if (null == data) {
|
||||||
if (isShowNetCodeMsg && exceptionCode == ErrorCode.ERROR.toString()) {
|
if (isShowNetErrorMsg && exceptionCode == ErrorCode.ERROR.toString()) {
|
||||||
showToast(exceptionMessage ?: errorTip)
|
showToast(exceptionMessage ?: errorTip)
|
||||||
} else if (isShowRequestErrorTip) {
|
} else if (isShowRequestErrorTip) {
|
||||||
if (NetworkUtil.isNetworkAvailable(mContext)) {
|
if (NetworkUtil.isNetworkAvailable(mContext)) {
|
||||||
@@ -658,7 +667,10 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
/**
|
/**
|
||||||
* 网络请求错误code提示
|
* 网络请求错误code提示
|
||||||
*/
|
*/
|
||||||
private fun netErrorCodeTips(exceptionCode: String, isShowCodeError: Boolean = true): Boolean {
|
private fun netErrorCodeTips(
|
||||||
|
exceptionCode: String,
|
||||||
|
isShowCodeError: Boolean = true
|
||||||
|
): Boolean {
|
||||||
//设备已过期,请续费
|
//设备已过期,请续费
|
||||||
when (exceptionCode) {
|
when (exceptionCode) {
|
||||||
ErrorCode.DEVICE_RENEWAL.toString() -> {
|
ErrorCode.DEVICE_RENEWAL.toString() -> {
|
||||||
@@ -693,12 +705,18 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
}
|
}
|
||||||
//注册失败
|
//注册失败
|
||||||
ErrorCode.REGISTER_FAIL.toString() -> {
|
ErrorCode.REGISTER_FAIL.toString() -> {
|
||||||
if (isShowCodeError) showToast(R.string.txt_register_fail, gravity = Gravity.CENTER)
|
if (isShowCodeError) showToast(
|
||||||
|
R.string.txt_register_fail,
|
||||||
|
gravity = Gravity.CENTER
|
||||||
|
)
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
//用户不存在
|
//用户不存在
|
||||||
ErrorCode.USER_NO_EXIST.toString() -> {
|
ErrorCode.USER_NO_EXIST.toString() -> {
|
||||||
if (isShowCodeError) showToast(R.string.txt_user_no_exist, gravity = Gravity.CENTER)
|
if (isShowCodeError) showToast(
|
||||||
|
R.string.txt_user_no_exist,
|
||||||
|
gravity = Gravity.CENTER
|
||||||
|
)
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
//用户已存在
|
//用户已存在
|
||||||
@@ -737,17 +755,26 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
}
|
}
|
||||||
//系统异常
|
//系统异常
|
||||||
"1001" -> {
|
"1001" -> {
|
||||||
if (isShowCodeError) showToast(R.string.txt_system_error, gravity = Gravity.CENTER)
|
if (isShowCodeError) showToast(
|
||||||
|
R.string.txt_system_error,
|
||||||
|
gravity = Gravity.CENTER
|
||||||
|
)
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
"1002" -> {
|
"1002" -> {
|
||||||
if (isShowCodeError) showToast(R.string.txt_missing_param, gravity = Gravity.CENTER)
|
if (isShowCodeError) showToast(
|
||||||
|
R.string.txt_missing_param,
|
||||||
|
gravity = Gravity.CENTER
|
||||||
|
)
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
"1003" -> {
|
"1003" -> {
|
||||||
if (isShowCodeError) showToast(R.string.txt_tracker_busy, gravity = Gravity.CENTER)
|
if (isShowCodeError) showToast(
|
||||||
|
R.string.txt_tracker_busy,
|
||||||
|
gravity = Gravity.CENTER
|
||||||
|
)
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -759,7 +786,10 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
}
|
}
|
||||||
|
|
||||||
"1005" -> {
|
"1005" -> {
|
||||||
if (isShowCodeError) showToast(R.string.txt_tracker_live, gravity = Gravity.CENTER)
|
if (isShowCodeError) showToast(
|
||||||
|
R.string.txt_tracker_live,
|
||||||
|
gravity = Gravity.CENTER
|
||||||
|
)
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -782,7 +812,7 @@ abstract class BaseActivity<T : ViewBinding>(val inflater: (inflater: LayoutInfl
|
|||||||
/**
|
/**
|
||||||
* 监听软键盘隐藏
|
* 监听软键盘隐藏
|
||||||
*/
|
*/
|
||||||
open fun listenHideKeyboard() {}
|
// open fun listenHideKeyboard() {}
|
||||||
|
|
||||||
/******************************点击屏幕页面隐藏软键盘start**************************************/
|
/******************************点击屏幕页面隐藏软键盘start**************************************/
|
||||||
// override fun dispatchTouchEvent(ev: MotionEvent): Boolean {
|
// override fun dispatchTouchEvent(ev: MotionEvent): Boolean {
|
||||||
|
|||||||
@@ -21,6 +21,7 @@ import com.abbidot.baselibrary.constant.ConState
|
|||||||
import com.abbidot.baselibrary.constant.EventName
|
import com.abbidot.baselibrary.constant.EventName
|
||||||
import com.abbidot.baselibrary.constant.MMKVKey
|
import com.abbidot.baselibrary.constant.MMKVKey
|
||||||
import com.abbidot.baselibrary.eventbus.XEventBus
|
import com.abbidot.baselibrary.eventbus.XEventBus
|
||||||
|
import com.abbidot.baselibrary.network.exception.ErrorCode
|
||||||
import com.abbidot.baselibrary.util.AppUtils
|
import com.abbidot.baselibrary.util.AppUtils
|
||||||
import com.abbidot.baselibrary.util.LogUtil
|
import com.abbidot.baselibrary.util.LogUtil
|
||||||
import com.abbidot.baselibrary.util.MMKVUtil
|
import com.abbidot.baselibrary.util.MMKVUtil
|
||||||
@@ -58,6 +59,7 @@ import com.abbidot.tracker.vm.CountDownTimerViewModel
|
|||||||
import com.abbidot.tracker.vm.DataViewModel
|
import com.abbidot.tracker.vm.DataViewModel
|
||||||
import com.abbidot.tracker.vm.FamilyViewModel
|
import com.abbidot.tracker.vm.FamilyViewModel
|
||||||
import com.abbidot.tracker.vm.LogBleReportViewModel
|
import com.abbidot.tracker.vm.LogBleReportViewModel
|
||||||
|
import com.baidu.platform.comapi.util.NetworkUtil
|
||||||
import com.clj.fastble.BleManager
|
import com.clj.fastble.BleManager
|
||||||
import com.google.android.material.navigation.NavigationBarView
|
import com.google.android.material.navigation.NavigationBarView
|
||||||
import dagger.hilt.android.AndroidEntryPoint
|
import dagger.hilt.android.AndroidEntryPoint
|
||||||
@@ -169,8 +171,7 @@ class HomeV2Activity : BaseActivity<ActivityHomeV2Binding>(ActivityHomeV2Binding
|
|||||||
setLineShow(2)
|
setLineShow(2)
|
||||||
|
|
||||||
//判断是否登录失效
|
//判断是否登录失效
|
||||||
if (loginInfoInvalid())
|
if (loginInfoInvalid()) return
|
||||||
return
|
|
||||||
|
|
||||||
//出现闪退,5秒退出APP
|
//出现闪退,5秒退出APP
|
||||||
val isCrash = MMKVUtil.getBoolean(MMKVKey.isCrash, false)
|
val isCrash = MMKVUtil.getBoolean(MMKVKey.isCrash, false)
|
||||||
@@ -216,7 +217,12 @@ class HomeV2Activity : BaseActivity<ActivityHomeV2Binding>(ActivityHomeV2Binding
|
|||||||
|
|
||||||
checkPermissions()
|
checkPermissions()
|
||||||
|
|
||||||
mDataViewModel.getHomeBindPetList(this@HomeV2Activity)
|
//首次启动APP,没有网络去检验APP合法性,就在网络可用时去检验
|
||||||
|
if (MMKVUtil.getInt(MMKVKey.isCheckLegalApp) == ConstantInt.Type2) {
|
||||||
|
mAppSetViewModel.checkPackageStatus(applicationContext)
|
||||||
|
} else {
|
||||||
|
mDataViewModel.getHomeBindPetList(this@HomeV2Activity)
|
||||||
|
}
|
||||||
|
|
||||||
//设置bugly的用户id
|
//设置bugly的用户id
|
||||||
// CrashReport.setUserId(MMKVUtil.getString(MMKVKey.Email))
|
// CrashReport.setUserId(MMKVUtil.getString(MMKVKey.Email))
|
||||||
@@ -249,8 +255,7 @@ class HomeV2Activity : BaseActivity<ActivityHomeV2Binding>(ActivityHomeV2Binding
|
|||||||
|
|
||||||
override fun onResume() {
|
override fun onResume() {
|
||||||
super.onResume()
|
super.onResume()
|
||||||
if (loginInfoInvalid())
|
if (loginInfoInvalid()) return
|
||||||
return
|
|
||||||
if (isCountdownAutoConnBle && mCountdownType == ConstantInt.Type1) {
|
if (isCountdownAutoConnBle && mCountdownType == ConstantInt.Type1) {
|
||||||
LogUtil.e("onResume,自动连接设备20秒计时开始")
|
LogUtil.e("onResume,自动连接设备20秒计时开始")
|
||||||
mCountDownTimerViewModel.startCountDown(20)
|
mCountDownTimerViewModel.startCountDown(20)
|
||||||
@@ -303,17 +308,26 @@ class HomeV2Activity : BaseActivity<ActivityHomeV2Binding>(ActivityHomeV2Binding
|
|||||||
}
|
}
|
||||||
mAppSetViewModel.mCheckPackageStatusLiveData.observe(this) {
|
mAppSetViewModel.mCheckPackageStatusLiveData.observe(this) {
|
||||||
if (null == it) {
|
if (null == it) {
|
||||||
showToast(R.string.txt_no_legal_app, true)
|
showToast(R.string.txt_no_legal_app, false, Gravity.CENTER)
|
||||||
} else {
|
} else {
|
||||||
if (null == it.getOrNull()) {
|
if (it.isSuccess) {
|
||||||
showToast(R.string.txt_no_legal_app, true, Gravity.CENTER)
|
|
||||||
} else {
|
|
||||||
MMKVUtil.putInt(MMKVKey.isCheckLegalApp, ConstantInt.Type1)
|
MMKVUtil.putInt(MMKVKey.isCheckLegalApp, ConstantInt.Type1)
|
||||||
if (mNetworkRequestsFailRetryCount == mNetworkRequestsFailMaxCount && mPetList.isEmpty()) {
|
if (mPetList.isEmpty()) {
|
||||||
mNetworkRequestsFailRetryCount = 0
|
mNetworkRequestsFailRetryCount = 0
|
||||||
isFirst = false
|
|
||||||
mDataViewModel.getHomeBindPetList(this@HomeV2Activity)
|
mDataViewModel.getHomeBindPetList(this@HomeV2Activity)
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
if (null == it.exceptionOrNull()) {
|
||||||
|
showToast(R.string.txt_no_legal_app, false, Gravity.CENTER)
|
||||||
|
} else {
|
||||||
|
//服务器返回错误code
|
||||||
|
val exceptionCode = it.exceptionOrNull().toString()
|
||||||
|
if (exceptionCode == ErrorCode.ILLEGAL_APP_PACKAGE.toString()) {
|
||||||
|
showToast(R.string.txt_no_legal_app, true, Gravity.CENTER)
|
||||||
|
} else if (NetworkUtil.isNetworkAvailable(mContext)) {
|
||||||
|
showToast(R.string.txt_system_error, false, Gravity.CENTER)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ import androidx.core.view.ViewCompat
|
|||||||
import androidx.core.view.WindowInsetsCompat
|
import androidx.core.view.WindowInsetsCompat
|
||||||
import cn.jpush.android.api.JPushInterface
|
import cn.jpush.android.api.JPushInterface
|
||||||
import com.abbidot.baselibrary.constant.MMKVKey
|
import com.abbidot.baselibrary.constant.MMKVKey
|
||||||
|
import com.abbidot.baselibrary.network.exception.ErrorCode
|
||||||
import com.abbidot.baselibrary.util.AppUtils
|
import com.abbidot.baselibrary.util.AppUtils
|
||||||
import com.abbidot.baselibrary.util.LogUtil
|
import com.abbidot.baselibrary.util.LogUtil
|
||||||
import com.abbidot.baselibrary.util.MMKVUtil
|
import com.abbidot.baselibrary.util.MMKVUtil
|
||||||
@@ -122,24 +123,33 @@ class SplashActivity : QMUIActivity() {
|
|||||||
mAppSetViewModel.apply {
|
mAppSetViewModel.apply {
|
||||||
mCheckPackageStatusLiveData.observe(this@SplashActivity) {
|
mCheckPackageStatusLiveData.observe(this@SplashActivity) {
|
||||||
if (null == it) {
|
if (null == it) {
|
||||||
showToastAndFinish()
|
checkLegal(ConstantInt.Type2)
|
||||||
} else {
|
} else {
|
||||||
if (null == it.getOrNull()) {
|
if (it.isSuccess) {
|
||||||
showToastAndFinish()
|
checkLegal(ConstantInt.Type1)
|
||||||
} else {
|
} else {
|
||||||
MMKVUtil.putInt(MMKVKey.isCheckLegalApp, ConstantInt.Type1)
|
if (null == it.exceptionOrNull()) {
|
||||||
legalApp()
|
checkLegal(ConstantInt.Type2)
|
||||||
|
} else {
|
||||||
|
//服务器返回错误code
|
||||||
|
val exceptionCode = it.exceptionOrNull().toString()
|
||||||
|
if (exceptionCode == ErrorCode.ILLEGAL_APP_PACKAGE.toString()) {
|
||||||
|
showToastAndFinish()
|
||||||
|
} else checkLegal(ConstantInt.Type2)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
mAppSetViewModel.checkPackageStatus(applicationContext)
|
mAppSetViewModel.checkPackageStatus(applicationContext)
|
||||||
} else {
|
} else {
|
||||||
MMKVUtil.putInt(MMKVKey.isCheckLegalApp, ConstantInt.Type2)
|
checkLegal(ConstantInt.Type2)
|
||||||
legalApp()
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 显示非法APP包提示窗并finish
|
||||||
|
*/
|
||||||
private fun showToastAndFinish() {
|
private fun showToastAndFinish() {
|
||||||
Toaster.show(getString(R.string.txt_no_legal_app))
|
Toaster.show(getString(R.string.txt_no_legal_app))
|
||||||
mViewBinding.root.postDelayed({
|
mViewBinding.root.postDelayed({
|
||||||
@@ -147,6 +157,12 @@ class SplashActivity : QMUIActivity() {
|
|||||||
}, 2000)
|
}, 2000)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private fun checkLegal(checkType: Int) {
|
||||||
|
MMKVUtil.putInt(MMKVKey.isCheckLegalApp, checkType)
|
||||||
|
legalApp()
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
private fun legalApp() {
|
private fun legalApp() {
|
||||||
mCountDownTimerViewModel.mCountDownEndLiveData.observe(this) {
|
mCountDownTimerViewModel.mCountDownEndLiveData.observe(this) {
|
||||||
mViewBinding.splashLottieAnimationView.cancelAnimation()
|
mViewBinding.splashLottieAnimationView.cancelAnimation()
|
||||||
|
|||||||
@@ -5,6 +5,7 @@ import android.text.InputFilter
|
|||||||
import android.text.InputFilter.LengthFilter
|
import android.text.InputFilter.LengthFilter
|
||||||
import android.text.InputType
|
import android.text.InputType
|
||||||
import android.text.TextUtils
|
import android.text.TextUtils
|
||||||
|
import android.view.Gravity
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import android.view.View.OnFocusChangeListener
|
import android.view.View.OnFocusChangeListener
|
||||||
import androidx.activity.viewModels
|
import androidx.activity.viewModels
|
||||||
@@ -44,6 +45,9 @@ class AddCreditCardPaymentActivity :
|
|||||||
private var mOldCard: CreditCardBean? = null
|
private var mOldCard: CreditCardBean? = null
|
||||||
private var isEdit = false
|
private var isEdit = false
|
||||||
|
|
||||||
|
//是否显示删除按钮
|
||||||
|
private var isShowDeleteBtn = false
|
||||||
|
|
||||||
//是否存在PaymentMethodID
|
//是否存在PaymentMethodID
|
||||||
private var isHavePaymentMethodID = false
|
private var isHavePaymentMethodID = false
|
||||||
|
|
||||||
@@ -56,6 +60,7 @@ class AddCreditCardPaymentActivity :
|
|||||||
intent, ConstantString.Card, CreditCardBean::class.java
|
intent, ConstantString.Card, CreditCardBean::class.java
|
||||||
)
|
)
|
||||||
isEdit = getBoolean(ConstantString.Edit)
|
isEdit = getBoolean(ConstantString.Edit)
|
||||||
|
isShowDeleteBtn = getBoolean(ConstantString.PartnerCode)
|
||||||
isHavePaymentMethodID = getBoolean(ConstantString.isCheck)
|
isHavePaymentMethodID = getBoolean(ConstantString.isCheck)
|
||||||
}
|
}
|
||||||
if (null == mCreditCard) mCreditCard = CreditCardBean()
|
if (null == mCreditCard) mCreditCard = CreditCardBean()
|
||||||
@@ -63,7 +68,9 @@ class AddCreditCardPaymentActivity :
|
|||||||
if (isEdit) {
|
if (isEdit) {
|
||||||
mOldCard = mCreditCard
|
mOldCard = mCreditCard
|
||||||
setTopBarTitle(R.string.txt_edit_pay_method)
|
setTopBarTitle(R.string.txt_edit_pay_method)
|
||||||
// mRightImageButton = addRightImageButton(R.drawable.icon_delete_svg)
|
if (isShowDeleteBtn) {
|
||||||
|
mRightImageButton = addRightImageButton(R.drawable.icon_delete_svg)
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
setTopBarTitle(R.string.txt_add_payment)
|
setTopBarTitle(R.string.txt_add_payment)
|
||||||
}
|
}
|
||||||
@@ -73,7 +80,7 @@ class AddCreditCardPaymentActivity :
|
|||||||
|
|
||||||
ilAddCardNameOnCard.let {
|
ilAddCardNameOnCard.let {
|
||||||
it.tvInputView2NameTitle.setText(R.string.txt_name_card)
|
it.tvInputView2NameTitle.setText(R.string.txt_name_card)
|
||||||
it.etInputView2Content.setFilters(arrayOf<InputFilter>(InputFilter.AllCaps()))
|
it.etInputView2Content.filters = arrayOf<InputFilter>(InputFilter.AllCaps())
|
||||||
it.etInputView2Content.onFocusChangeListener = this@AddCreditCardPaymentActivity
|
it.etInputView2Content.onFocusChangeListener = this@AddCreditCardPaymentActivity
|
||||||
showEditViewContent(it.etInputView2Content, mCreditCard!!.cardName)
|
showEditViewContent(it.etInputView2Content, mCreditCard!!.cardName)
|
||||||
}
|
}
|
||||||
@@ -127,23 +134,52 @@ class AddCreditCardPaymentActivity :
|
|||||||
ilAddCardNameOnCard.root,
|
ilAddCardNameOnCard.root,
|
||||||
ilAddCardNumber.root,
|
ilAddCardNumber.root,
|
||||||
llAddCardCvcLayout,
|
llAddCardCvcLayout,
|
||||||
llAddCardMmDdLayout
|
llAddCardMmDdLayout, tvAddCardExperienceBtn
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun liveDataObserve() {
|
override fun liveDataObserve() {
|
||||||
mSubscriptionPayViewModel.mSavePaymentMethodIDLiveData.observe(this) {
|
mSubscriptionPayViewModel.apply {
|
||||||
dealRequestResult(it, object : GetResultCallback {
|
mSavePaymentMethodIDLiveData.observe(this@AddCreditCardPaymentActivity) {
|
||||||
override fun onResult(any: Any) {
|
dealRequestResult(it, object : GetResultCallback {
|
||||||
setResult(ResultCode.ResultCode_1, null)
|
override fun onResult(any: Any) {
|
||||||
showToast(R.string.txt_save_successful, isFinish = true)
|
setResult(ResultCode.ResultCode_1, null)
|
||||||
}
|
showToast(R.string.txt_save_successful, isFinish = true)
|
||||||
|
}
|
||||||
|
|
||||||
override fun onRequestError(exceptionCode: String?) {
|
override fun onRequestError(exceptionCode: String?) {
|
||||||
setButtonEnabled(mViewBinding.btnSaveNewCreditCard, ConstantInt.Type1)
|
setButtonEnabled(mViewBinding.btnSaveNewCreditCard, ConstantInt.Type1)
|
||||||
}
|
}
|
||||||
}, isShowNetCodeMsg = true)
|
}, isShowNetErrorMsg = true)
|
||||||
|
}
|
||||||
|
mOrderAutoRenewalStatusLiveData.observe(this@AddCreditCardPaymentActivity) {
|
||||||
|
dealRequestResult(it, object : GetResultCallback {
|
||||||
|
override fun onResult(any: Any) {
|
||||||
|
it.getOrNull()?.let { d ->
|
||||||
|
showRemoveDialog(d.isNeedCancel)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onRequestError(exceptionCode: String?) {
|
||||||
|
setButtonEnabled(mRightImageButton, ConstantInt.Type1)
|
||||||
|
setButtonEnabled(mViewBinding.btnSaveNewCreditCard, ConstantInt.Type1)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
mRemovePaymentMethodLiveData.observe(this@AddCreditCardPaymentActivity) {
|
||||||
|
dealRequestResult(it, object : GetResultCallback {
|
||||||
|
override fun onResult(any: Any) {
|
||||||
|
setResult(ResultCode.ResultCode_1, null)
|
||||||
|
showToast(R.string.txt_delete_succe, true, Gravity.CENTER)
|
||||||
|
}
|
||||||
|
|
||||||
|
override fun onRequestError(exceptionCode: String?) {
|
||||||
|
setButtonEnabled(mRightImageButton, ConstantInt.Type1)
|
||||||
|
setButtonEnabled(mViewBinding.btnSaveNewCreditCard, ConstantInt.Type1)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -201,7 +237,7 @@ class AddCreditCardPaymentActivity :
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun listenHideKeyboard() {
|
private fun setHideKeyboard() {
|
||||||
mViewBinding.apply {
|
mViewBinding.apply {
|
||||||
setEditViewNoFocusHide(etAddCardCvcContent, false)
|
setEditViewNoFocusHide(etAddCardCvcContent, false)
|
||||||
setEditViewNoFocusHide(etAddCardMmDdContent, false)
|
setEditViewNoFocusHide(etAddCardMmDdContent, false)
|
||||||
@@ -211,7 +247,6 @@ class AddCreditCardPaymentActivity :
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
private fun confirmSaveCardV2() {
|
private fun confirmSaveCardV2() {
|
||||||
mViewBinding.apply {
|
mViewBinding.apply {
|
||||||
val cardNumber = ilAddCardNumber.etInputView2Content.text.toString().replace(" ", "")
|
val cardNumber = ilAddCardNumber.etInputView2Content.text.toString().replace(" ", "")
|
||||||
@@ -295,32 +330,59 @@ class AddCreditCardPaymentActivity :
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun deleteCard() {
|
/**
|
||||||
ViewUtil.instance.showDialog(
|
* 显示删除支付方式弹窗
|
||||||
mContext, R.string.txt_sure_delete_card, object : BaseDialog.OnDialogOkListener {
|
* @param haveAutoRenewal 是否有自动续费 1为有 0为无
|
||||||
override fun onOkClick(dialog: BaseDialog<*>) {
|
*/
|
||||||
lifecycleScope.launch(Dispatchers.IO) {
|
private fun showRemoveDialog(haveAutoRenewal: Int) {
|
||||||
mCreditCard?.apply {
|
if (haveAutoRenewal == ConstantInt.Type1) {
|
||||||
// MyDatabase.creditCardDao().delete(this)
|
ViewUtil.instance.showDialog(
|
||||||
}
|
this@AddCreditCardPaymentActivity,
|
||||||
|
R.string.txt_remove_pay_method_tips2,
|
||||||
|
object : BaseDialog.OnDialogOkListener {
|
||||||
|
override fun onOkClick(dialog: BaseDialog<*>) {
|
||||||
|
dialog.dismiss()
|
||||||
|
mSubscriptionPayViewModel.removePaymentMethodID(1)
|
||||||
}
|
}
|
||||||
dialog.dismiss()
|
},
|
||||||
setResult(ResultCode.ResultCode_1, null)
|
getString(R.string.txt_auto_renewal_on),
|
||||||
showToast(R.string.txt_delete_succe, isFinish = true)
|
R.string.txt_turn_off_remove, R.string.txt_cancel
|
||||||
}
|
)
|
||||||
}, okTextResId = R.string.start_txt_yes
|
} else {
|
||||||
)
|
ViewUtil.instance.showDialog(
|
||||||
|
this@AddCreditCardPaymentActivity,
|
||||||
|
R.string.txt_remove_pay_method_tips1,
|
||||||
|
object : BaseDialog.OnDialogOkListener {
|
||||||
|
override fun onOkClick(dialog: BaseDialog<*>) {
|
||||||
|
dialog.dismiss()
|
||||||
|
mSubscriptionPayViewModel.removePaymentMethodID(1)
|
||||||
|
}
|
||||||
|
},
|
||||||
|
getString(R.string.txt_remove_pay_method) + if (AppUtils.isChina()) "?" else "?",
|
||||||
|
R.string.txt_remove, R.string.txt_cancel
|
||||||
|
)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
override fun onClick(v: View?) {
|
override fun onClick(v: View?) {
|
||||||
mViewBinding.apply {
|
mViewBinding.apply {
|
||||||
|
if (v != tvAddCardExperienceBtn && isLimitClick()) return
|
||||||
when (v!!) {
|
when (v!!) {
|
||||||
|
tvAddCardExperienceBtn -> {
|
||||||
|
setHideKeyboard()
|
||||||
|
hideInputMethod(v)
|
||||||
|
}
|
||||||
|
|
||||||
btnSaveNewCreditCard -> confirmSaveCardV2()
|
btnSaveNewCreditCard -> confirmSaveCardV2()
|
||||||
llAddCardMmDdLayout -> setClickEditViewVisible(etAddCardMmDdContent)
|
llAddCardMmDdLayout -> setClickEditViewVisible(etAddCardMmDdContent)
|
||||||
llAddCardCvcLayout -> setClickEditViewVisible(etAddCardCvcContent)
|
llAddCardCvcLayout -> setClickEditViewVisible(etAddCardCvcContent)
|
||||||
ilAddCardNameOnCard.root -> setClickEditViewVisible(ilAddCardNameOnCard.etInputView2Content)
|
ilAddCardNameOnCard.root -> setClickEditViewVisible(ilAddCardNameOnCard.etInputView2Content)
|
||||||
ilAddCardNumber.root -> setClickEditViewVisible(ilAddCardNumber.etInputView2Content)
|
ilAddCardNumber.root -> setClickEditViewVisible(ilAddCardNumber.etInputView2Content)
|
||||||
mRightImageButton -> deleteCard()
|
mRightImageButton -> {
|
||||||
|
setButtonEnabled(btnSaveNewCreditCard, ConstantInt.Type0)
|
||||||
|
setButtonEnabled(mRightImageButton, ConstantInt.Type0)
|
||||||
|
mSubscriptionPayViewModel.getOrderAutoRenewalStatus()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -328,21 +390,17 @@ class AddCreditCardPaymentActivity :
|
|||||||
override fun onFocusChange(v: View?, hasFocus: Boolean) {
|
override fun onFocusChange(v: View?, hasFocus: Boolean) {
|
||||||
mViewBinding.apply {
|
mViewBinding.apply {
|
||||||
when (v!!) {
|
when (v!!) {
|
||||||
ilAddCardNameOnCard.etInputView2Content -> {
|
ilAddCardNameOnCard.etInputView2Content ->
|
||||||
setEditViewNoFocusHide(ilAddCardNameOnCard.etInputView2Content, hasFocus)
|
setEditViewNoFocusHide(ilAddCardNameOnCard.etInputView2Content, hasFocus)
|
||||||
}
|
|
||||||
|
|
||||||
ilAddCardNumber.etInputView2Content -> {
|
ilAddCardNumber.etInputView2Content -> setEditViewNoFocusHide(
|
||||||
setEditViewNoFocusHide(ilAddCardNumber.etInputView2Content, hasFocus)
|
ilAddCardNumber.etInputView2Content,
|
||||||
}
|
hasFocus
|
||||||
|
)
|
||||||
|
|
||||||
etAddCardMmDdContent -> {
|
etAddCardMmDdContent -> setEditViewNoFocusHide(etAddCardMmDdContent, hasFocus)
|
||||||
setEditViewNoFocusHide(etAddCardMmDdContent, hasFocus)
|
|
||||||
}
|
|
||||||
|
|
||||||
etAddCardCvcContent -> {
|
etAddCardCvcContent -> setEditViewNoFocusHide(etAddCardCvcContent, hasFocus)
|
||||||
setEditViewNoFocusHide(etAddCardCvcContent, hasFocus)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -41,6 +41,9 @@ class CreditCardPaymentFragment : BaseFragment<FragmentCreditCardPaymentBinding>
|
|||||||
private val mSubscriptionPayViewModel: SubscriptionPayViewModel by viewModels()
|
private val mSubscriptionPayViewModel: SubscriptionPayViewModel by viewModels()
|
||||||
private lateinit var mCreditCardAdapter: CreditCardAdapter
|
private lateinit var mCreditCardAdapter: CreditCardAdapter
|
||||||
|
|
||||||
|
//是否显示编辑里删除按钮
|
||||||
|
private var isShowDeleteBtn = false
|
||||||
|
|
||||||
companion object {
|
companion object {
|
||||||
@JvmStatic
|
@JvmStatic
|
||||||
fun newInstance(context: Context) = CreditCardPaymentFragment().apply {
|
fun newInstance(context: Context) = CreditCardPaymentFragment().apply {
|
||||||
@@ -54,8 +57,7 @@ class CreditCardPaymentFragment : BaseFragment<FragmentCreditCardPaymentBinding>
|
|||||||
mCreditCardAdapter = CreditCardAdapter(mContext!!, null).apply {
|
mCreditCardAdapter = CreditCardAdapter(mContext!!, null).apply {
|
||||||
setOnAgainClickListener(object : BaseRecyclerAdapter.OnAgainClickListener {
|
setOnAgainClickListener(object : BaseRecyclerAdapter.OnAgainClickListener {
|
||||||
override fun onAgainListener() {
|
override fun onAgainListener() {
|
||||||
val intent = Intent(mContext, AddCreditCardPaymentActivity::class.java)
|
goAddCard()
|
||||||
launchActivity(mActivity!!, mActivityResultLauncher, intent)
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
@@ -110,6 +112,8 @@ class CreditCardPaymentFragment : BaseFragment<FragmentCreditCardPaymentBinding>
|
|||||||
// }
|
// }
|
||||||
//没有卡,显示无卡提示 不用去添加卡
|
//没有卡,显示无卡提示 不用去添加卡
|
||||||
mViewBinding.apply {
|
mViewBinding.apply {
|
||||||
|
btnCreditCardPaymentRemove.visibility = View.GONE
|
||||||
|
isShowDeleteBtn = false
|
||||||
if (null == getHostActivity(PaymentMethodActivity::class.java)?.mOrderBean) {
|
if (null == getHostActivity(PaymentMethodActivity::class.java)?.mOrderBean) {
|
||||||
ilCreditCardPaymentNoData.root.visibility = View.VISIBLE
|
ilCreditCardPaymentNoData.root.visibility = View.VISIBLE
|
||||||
rvCreditCardPaymentList.visibility = View.GONE
|
rvCreditCardPaymentList.visibility = View.GONE
|
||||||
@@ -132,10 +136,12 @@ class CreditCardPaymentFragment : BaseFragment<FragmentCreditCardPaymentBinding>
|
|||||||
//卡管理 不需要点击效果
|
//卡管理 不需要点击效果
|
||||||
if (null == getHostActivity(PaymentMethodActivity::class.java)?.mOrderBean) {
|
if (null == getHostActivity(PaymentMethodActivity::class.java)?.mOrderBean) {
|
||||||
btnCreditCardPaymentRemove.visibility = View.VISIBLE
|
btnCreditCardPaymentRemove.visibility = View.VISIBLE
|
||||||
|
isShowDeleteBtn = true
|
||||||
btnMakePaymentCreditCard.visibility = View.GONE
|
btnMakePaymentCreditCard.visibility = View.GONE
|
||||||
} else {
|
} else {
|
||||||
stripeMethodInfo.checked = true
|
stripeMethodInfo.checked = true
|
||||||
btnCreditCardPaymentRemove.visibility = View.GONE
|
btnCreditCardPaymentRemove.visibility = View.GONE
|
||||||
|
isShowDeleteBtn = false
|
||||||
btnMakePaymentCreditCard.visibility = View.VISIBLE
|
btnMakePaymentCreditCard.visibility = View.VISIBLE
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -152,6 +158,7 @@ class CreditCardPaymentFragment : BaseFragment<FragmentCreditCardPaymentBinding>
|
|||||||
Intent(mContext, AddCreditCardPaymentActivity::class.java).let {
|
Intent(mContext, AddCreditCardPaymentActivity::class.java).let {
|
||||||
it.putExtra(ConstantString.Card, cardBean)
|
it.putExtra(ConstantString.Card, cardBean)
|
||||||
it.putExtra(ConstantString.Edit, true)
|
it.putExtra(ConstantString.Edit, true)
|
||||||
|
it.putExtra(ConstantString.PartnerCode, isShowDeleteBtn)
|
||||||
//是否存在PaymentMethodID
|
//是否存在PaymentMethodID
|
||||||
var isHavePaymentMethodID = false
|
var isHavePaymentMethodID = false
|
||||||
getHostActivity(PaymentMethodActivity::class.java)?.let { h ->
|
getHostActivity(PaymentMethodActivity::class.java)?.let { h ->
|
||||||
@@ -163,6 +170,14 @@ class CreditCardPaymentFragment : BaseFragment<FragmentCreditCardPaymentBinding>
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 添加卡
|
||||||
|
*/
|
||||||
|
private fun goAddCard() {
|
||||||
|
val intent = Intent(mContext, AddCreditCardPaymentActivity::class.java)
|
||||||
|
launchActivity(mActivity!!, mActivityResultLauncher, intent)
|
||||||
|
}
|
||||||
|
|
||||||
override fun liveDataObserve() {
|
override fun liveDataObserve() {
|
||||||
mSubscriptionPayViewModel.apply {
|
mSubscriptionPayViewModel.apply {
|
||||||
mSubscriptionCustomerLiveData.observe(viewLifecycleOwner) {
|
mSubscriptionCustomerLiveData.observe(viewLifecycleOwner) {
|
||||||
@@ -215,6 +230,7 @@ class CreditCardPaymentFragment : BaseFragment<FragmentCreditCardPaymentBinding>
|
|||||||
//卡管理 不需要点击效果
|
//卡管理 不需要点击效果
|
||||||
if (null == getHostActivity(PaymentMethodActivity::class.java)?.mOrderBean) {
|
if (null == getHostActivity(PaymentMethodActivity::class.java)?.mOrderBean) {
|
||||||
mViewBinding.btnCreditCardPaymentRemove.visibility = View.VISIBLE
|
mViewBinding.btnCreditCardPaymentRemove.visibility = View.VISIBLE
|
||||||
|
isShowDeleteBtn = true
|
||||||
mViewBinding.btnMakePaymentCreditCard.visibility = View.GONE
|
mViewBinding.btnMakePaymentCreditCard.visibility = View.GONE
|
||||||
} else {
|
} else {
|
||||||
var haveCheck = false
|
var haveCheck = false
|
||||||
@@ -228,6 +244,7 @@ class CreditCardPaymentFragment : BaseFragment<FragmentCreditCardPaymentBinding>
|
|||||||
list[0].checked = true
|
list[0].checked = true
|
||||||
}
|
}
|
||||||
mViewBinding.btnCreditCardPaymentRemove.visibility = View.GONE
|
mViewBinding.btnCreditCardPaymentRemove.visibility = View.GONE
|
||||||
|
isShowDeleteBtn = false
|
||||||
mViewBinding.btnMakePaymentCreditCard.visibility = View.VISIBLE
|
mViewBinding.btnMakePaymentCreditCard.visibility = View.VISIBLE
|
||||||
}
|
}
|
||||||
mViewBinding.apply {
|
mViewBinding.apply {
|
||||||
@@ -341,10 +358,7 @@ class CreditCardPaymentFragment : BaseFragment<FragmentCreditCardPaymentBinding>
|
|||||||
|
|
||||||
mViewBinding.apply {
|
mViewBinding.apply {
|
||||||
when (v!!) {
|
when (v!!) {
|
||||||
btnCreditCardPaymentAdd -> {
|
btnCreditCardPaymentAdd -> goAddCard()
|
||||||
val intent = Intent(mContext, AddCreditCardPaymentActivity::class.java)
|
|
||||||
launchActivity(mActivity!!, mActivityResultLauncher, intent)
|
|
||||||
}
|
|
||||||
|
|
||||||
btnCreditCardPaymentRemove -> getHostActivity(PaymentMethodActivity::class.java)?.removePaymentMethodID(
|
btnCreditCardPaymentRemove -> getHostActivity(PaymentMethodActivity::class.java)?.removePaymentMethodID(
|
||||||
ConstantInt.Type1
|
ConstantInt.Type1
|
||||||
|
|||||||
@@ -9,6 +9,7 @@ import com.abbidot.baselibrary.util.AppUtils
|
|||||||
import com.abbidot.baselibrary.util.MMKVUtil
|
import com.abbidot.baselibrary.util.MMKVUtil
|
||||||
import com.abbidot.tracker.bean.NotificationBean
|
import com.abbidot.tracker.bean.NotificationBean
|
||||||
import com.abbidot.tracker.retrofit2.NetworkApi
|
import com.abbidot.tracker.retrofit2.NetworkApi
|
||||||
|
import com.hjq.toast.Toaster
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
import java.util.UUID
|
import java.util.UUID
|
||||||
|
|
||||||
|
|||||||
@@ -14,6 +14,7 @@
|
|||||||
<androidx.core.widget.NestedScrollView
|
<androidx.core.widget.NestedScrollView
|
||||||
style="@style/my_ScrollView_style"
|
style="@style/my_ScrollView_style"
|
||||||
android:layout_weight="1"
|
android:layout_weight="1"
|
||||||
|
android:fillViewport="true"
|
||||||
android:padding="@dimen/dp_16">
|
android:padding="@dimen/dp_16">
|
||||||
|
|
||||||
<RelativeLayout
|
<RelativeLayout
|
||||||
@@ -179,6 +180,13 @@
|
|||||||
android:textSize="@dimen/textSize14"
|
android:textSize="@dimen/textSize14"
|
||||||
android:visibility="gone"
|
android:visibility="gone"
|
||||||
app:typeface="@string/roboto_regular_font" />
|
app:typeface="@string/roboto_regular_font" />
|
||||||
|
|
||||||
|
<androidx.appcompat.widget.AppCompatTextView
|
||||||
|
android:id="@+id/tv_add_card_experience_btn"
|
||||||
|
android:layout_width="match_parent"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_below="@id/ll_add_card_accepted_cards"
|
||||||
|
android:layout_alignParentBottom="true" />
|
||||||
</RelativeLayout>
|
</RelativeLayout>
|
||||||
</androidx.core.widget.NestedScrollView>
|
</androidx.core.widget.NestedScrollView>
|
||||||
|
|
||||||
|
|||||||
@@ -899,11 +899,11 @@
|
|||||||
<string name="txt_subscription_terms_conditions_html">subscription_terms_conditions_de.html</string>
|
<string name="txt_subscription_terms_conditions_html">subscription_terms_conditions_de.html</string>
|
||||||
<string name="system_txt_copyright">Copyright © %d ABBIDOT. Alle Rechte vorbehalten</string>
|
<string name="system_txt_copyright">Copyright © %d ABBIDOT. Alle Rechte vorbehalten</string>
|
||||||
<string name="txt_login_info_invalid">Sitzung abgelaufen. Bitte erneut anmelden</string>
|
<string name="txt_login_info_invalid">Sitzung abgelaufen. Bitte erneut anmelden</string>
|
||||||
|
|
||||||
<string name="txt_remove_pay_method">Zahlungsmethode entfernen</string>
|
<string name="txt_remove_pay_method">Zahlungsmethode entfernen</string>
|
||||||
<string name="txt_remove_pay_method_tips1">Möchten Sie diese Zahlungsmethode wirklich entfernen?</string>
|
<string name="txt_remove_pay_method_tips1">Möchten Sie diese Zahlungsmethode wirklich entfernen?</string>
|
||||||
<string name="txt_remove_pay_method_tips2">Bitte deaktivieren Sie die automatische Verlängerung, bevor Sie Ihre Zahlungsmethode entfernen.</string>
|
<string name="txt_remove_pay_method_tips2">Bitte deaktivieren Sie die automatische Verlängerung, bevor Sie Ihre Zahlungsmethode entfernen.</string>
|
||||||
<string name="txt_auto_renewal_on">Automatische Verlängerung ist aktiviert</string>
|
<string name="txt_auto_renewal_on">Automatische Verlängerung ist aktiviert</string>
|
||||||
<string name="txt_remove">Entfernen</string>
|
<string name="txt_remove">Entfernen</string>
|
||||||
<string name="txt_turn_off_remove">Deaktivieren & entfernen</string>
|
<string name="txt_turn_off_remove">Deaktivieren & entfernen</string>
|
||||||
|
<string name="txt_no_legal_app">Nicht autorisierte App. Von offizieller Quelle laden</string>
|
||||||
</resources>
|
</resources>
|
||||||
@@ -906,4 +906,5 @@
|
|||||||
<string name="txt_auto_renewal_on">Renouvellement automatique activé</string>
|
<string name="txt_auto_renewal_on">Renouvellement automatique activé</string>
|
||||||
<string name="txt_remove">Supprimer</string>
|
<string name="txt_remove">Supprimer</string>
|
||||||
<string name="txt_turn_off_remove">Désactiver et supprimer</string>
|
<string name="txt_turn_off_remove">Désactiver et supprimer</string>
|
||||||
|
<string name="txt_no_legal_app">App non autorisée. Téléchargez depuis une source officielle</string>
|
||||||
</resources>
|
</resources>
|
||||||
@@ -895,4 +895,5 @@
|
|||||||
<string name="txt_renewal_years">Rinnovo: $%s/%s anni su %s</string>
|
<string name="txt_renewal_years">Rinnovo: $%s/%s anni su %s</string>
|
||||||
<string name="txt_renewal_months">Rinnovo: $%s/%s mesi su %s</string>
|
<string name="txt_renewal_months">Rinnovo: $%s/%s mesi su %s</string>
|
||||||
<string name="txt_login_info_invalid">La sessione di accesso è scaduta. Accedi di nuovo</string>
|
<string name="txt_login_info_invalid">La sessione di accesso è scaduta. Accedi di nuovo</string>
|
||||||
|
<string name="txt_no_legal_app">App non autorizzata. Scarica da una fonte ufficiale</string>
|
||||||
</resources>
|
</resources>
|
||||||
@@ -999,5 +999,5 @@
|
|||||||
<string name="txt_auto_renewal_on">Auto-Renewal Is On</string>
|
<string name="txt_auto_renewal_on">Auto-Renewal Is On</string>
|
||||||
<string name="txt_remove">Remove</string>
|
<string name="txt_remove">Remove</string>
|
||||||
<string name="txt_turn_off_remove">Turn Off & Remove</string>
|
<string name="txt_turn_off_remove">Turn Off & Remove</string>
|
||||||
<string name="txt_no_legal_app">非法APP,请从正规渠道下载安装</string>
|
<string name="txt_no_legal_app">Unauthorized app. Download from official sources</string>
|
||||||
</resources>
|
</resources>
|
||||||
@@ -19,6 +19,7 @@ import androidx.annotation.IntDef
|
|||||||
ErrorCode.NO_SHARE_MYSELF,
|
ErrorCode.NO_SHARE_MYSELF,
|
||||||
ErrorCode.DEVICE_HAS_BOUND,
|
ErrorCode.DEVICE_HAS_BOUND,
|
||||||
ErrorCode.WX_NO_EXIST,
|
ErrorCode.WX_NO_EXIST,
|
||||||
|
ErrorCode.ILLEGAL_APP_PACKAGE,
|
||||||
ErrorCode.PHONE_NO_REGISTER,
|
ErrorCode.PHONE_NO_REGISTER,
|
||||||
ErrorCode.PHONE_HAS_BIND,
|
ErrorCode.PHONE_HAS_BIND,
|
||||||
ErrorCode.DEVICE_HAS_BIND,
|
ErrorCode.DEVICE_HAS_BIND,
|
||||||
@@ -72,13 +73,19 @@ annotation class ErrorCode {
|
|||||||
|
|
||||||
//515 设备未存在
|
//515 设备未存在
|
||||||
const val DEVICE_NOT_EXIST = 515
|
const val DEVICE_NOT_EXIST = 515
|
||||||
|
|
||||||
//519 手机号未注册
|
//519 手机号未注册
|
||||||
const val PHONE_NO_REGISTER = 519
|
const val PHONE_NO_REGISTER = 519
|
||||||
|
|
||||||
//520 手机号已绑定
|
//520 手机号已绑定
|
||||||
const val PHONE_HAS_BIND = 520
|
const val PHONE_HAS_BIND = 520
|
||||||
|
|
||||||
//微信绑定不存在
|
//微信绑定不存在
|
||||||
const val WX_NO_EXIST = 521
|
const val WX_NO_EXIST = 521
|
||||||
|
|
||||||
|
//非法APP包,检验签名失败
|
||||||
|
const val ILLEGAL_APP_PACKAGE = 524
|
||||||
|
|
||||||
//信用卡支付成功
|
//信用卡支付成功
|
||||||
const val CREDIT_CARD_PAY_SUCCESS = 1
|
const val CREDIT_CARD_PAY_SUCCESS = 1
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user