接口联调
This commit is contained in:
@@ -65,9 +65,7 @@ class PayActivity : BaseActivity<ActivityPayBinding>() {
|
||||
if (binding.btnPayCash.isChecked) {
|
||||
return@setOnClickListener
|
||||
}
|
||||
if (cashPayFragment == null) {
|
||||
cashPayFragment = CashPayFragment()
|
||||
}
|
||||
cashPayFragment = CashPayFragment()
|
||||
showFragment(cashPayFragment!!, TAG_PAY_CASH)
|
||||
switchButton(false, true, false, false)
|
||||
}
|
||||
@@ -75,9 +73,7 @@ class PayActivity : BaseActivity<ActivityPayBinding>() {
|
||||
if (binding.btnPayNumber.isChecked) {
|
||||
return@setOnClickListener
|
||||
}
|
||||
if (numberPayFragment == null) {
|
||||
numberPayFragment = NumberPayFragment()
|
||||
}
|
||||
numberPayFragment = NumberPayFragment()
|
||||
showFragment(numberPayFragment!!, TAG_PAY_NUMBER)
|
||||
switchButton(false, false, true, false)
|
||||
}
|
||||
@@ -92,9 +88,7 @@ class PayActivity : BaseActivity<ActivityPayBinding>() {
|
||||
}
|
||||
|
||||
private fun showScanQrCodePay() {
|
||||
if (qrCodePayFragment == null) {
|
||||
qrCodePayFragment = ScanQrCodePayFragment()
|
||||
}
|
||||
qrCodePayFragment = ScanQrCodePayFragment()
|
||||
showFragment(qrCodePayFragment!!, TAG_PAY_QR_CODE)
|
||||
switchButton(true, false, false, false)
|
||||
}
|
||||
@@ -107,9 +101,7 @@ class PayActivity : BaseActivity<ActivityPayBinding>() {
|
||||
}
|
||||
|
||||
fun showFacePay() {
|
||||
if (facePayFragment == null) {
|
||||
facePayFragment = FacePayFragment()
|
||||
}
|
||||
facePayFragment = FacePayFragment()
|
||||
showFragment(facePayFragment!!, TAG_PAY_FACE)
|
||||
switchButton(false, false, false, true)
|
||||
}
|
||||
@@ -149,9 +141,7 @@ class PayActivity : BaseActivity<ActivityPayBinding>() {
|
||||
// }
|
||||
|
||||
fun showPayResult() {
|
||||
if (payResultFragment == null) {
|
||||
payResultFragment = PayResultFragment()
|
||||
}
|
||||
payResultFragment = PayResultFragment()
|
||||
showFragment(payResultFragment!!, TAG_PAY_RESULT)
|
||||
}
|
||||
|
||||
@@ -162,9 +152,10 @@ class PayActivity : BaseActivity<ActivityPayBinding>() {
|
||||
facePayFragment?.presentation?.dismiss()
|
||||
super.onDestroy()
|
||||
}
|
||||
private var scanQrCodePayPresentation: ScanQrCodePayPresentation?=null
|
||||
|
||||
private var scanQrCodePayPresentation: ScanQrCodePayPresentation? = null
|
||||
fun paySuccess() {
|
||||
showFragment(PayResultFragment(),"")
|
||||
showFragment(PayResultFragment(), "")
|
||||
if (displays.size > 1) {
|
||||
scanQrCodePayPresentation = ScanQrCodePayPresentation(
|
||||
activity = this,
|
||||
|
||||
Reference in New Issue
Block a user