Browse Source

Merge branch 'v20' of http://192.168.31.240:3000/MTP2.0_New/MTP20_WEB_GLOBAL into v20

li.shaoyi 1 year ago
parent
commit
c76c5d8f03

+ 14 - 4
src/packages/tss/views/bank/wallet/components/deposit/Index.vue

@@ -77,23 +77,24 @@
                 <Button round block type="danger" @click="formRef?.submit()">{{ $t('operation.confirm') }}</Button>
             </div>
         </template>
+        <component ref="componentRef" :is="componentMap.get(componentId)" @closed="closeComponent"
+        v-if="componentId" />
     </app-view>
 </template>
 
 <script lang="ts" setup>
-import { shallowRef, ref } from 'vue'
+import { shallowRef, ref, defineAsyncComponent, onMounted } from 'vue'
 import { Form, Field, Cell, CellGroup, Button, FieldRule, FormInstance, RadioGroup, Radio, showToast, showFailToast } from 'vant'
 import { fullloading, dialog } from '@/utils/vant'
-import { useNavigation } from '@mobile/router/navigation'
 import { useDoDeposit, useDoCusBankExtendConfigs } from '@/business/bank'
 import { getServerTime } from '@/services/api/common'
 import { useUserStore, useAccountStore, i18n } from '@/stores'
+import { useComponent } from '@/hooks/component'
 import Stepper from '@mobile/components/base/stepper/index.vue'
 import moment from 'moment'
 
 const formRef = shallowRef<FormInstance>()
 const { formData, onSubmit, sign } = useDoDeposit()
-const { router } = useNavigation()
 const { getSystemParamValue } = useUserStore()
 const { configs, cusBank, startTime, endTime } = useDoCusBankExtendConfigs(2)
 const certificate_photo_url = ref('')
@@ -109,6 +110,11 @@ const msg_322 = getSystemParamValue('322')
 const msg_323 = getSystemParamValue('323')
 const msg_324 = getSystemParamValue('324')
 
+const componentMap = new Map<string, unknown>([
+    ['inoutapply', defineAsyncComponent(() => import('../inoutapply/Index.vue'))], // 申请流水
+])
+const { componentRef, componentId, openComponent, closeComponent } = useComponent()
+
 // 数量步长列表
 const qtyStepList = [100, 500, 1000, 5000, 10000, 50000] 
 // 数量步长
@@ -184,7 +190,7 @@ const formSubmit = () => {
             dialog({
                 message: i18n.global.t('banksign.tips13')
             }).then(() => {
-                router.back()
+                openComponent('inoutapply')
             })
         }
 
@@ -207,6 +213,10 @@ const formSubmit = () => {
         })
     })
 }
+
+onMounted(() => {
+    formData.Amount = qtyStepList[0]
+})
 </script>
 
 <style lang="less">

+ 2 - 2
src/packages/tss/views/bank/wallet/components/withdraw/Index.vue

@@ -134,7 +134,7 @@ const formSubmit = () => {
         let isComplete = false // 请求是否结束
         const complete = () => {
             isComplete = true
-            dialog('提交成功,请勿重复提交,稍后确认结果').then(() => {
+            dialog(i18n.global.t('banksign.wallet.withdraw.submitsuccess')).then(() => {
                 router.back()
             })
         }
@@ -148,7 +148,7 @@ const formSubmit = () => {
             }
         }).catch((err) => {
             if (!isComplete) {
-                dialog(t('common.submitfailure') + err).then(() => {
+                dialog(i18n.global.t('common.submitfailure') + err).then(() => {
                     formData.Amount = undefined
                 })
             }