|
@@ -1,11 +1,12 @@
|
|
|
import { reactive, shallowRef, computed } from 'vue'
|
|
import { reactive, shallowRef, computed } from 'vue'
|
|
|
-import { useAccountStore, useUserStore } from '@/stores'
|
|
|
|
|
|
|
+import { useAccountStore, useUserStore, useLoginStore } from '@/stores'
|
|
|
import { t2bBankWithdraw, queryBankAccountSign, t2bBankDeposit, queryCusBankSignBank, t2bBankSign, t2bBankCancelSign, accountFundInfoReq } from '@/services/api/bank'
|
|
import { t2bBankWithdraw, queryBankAccountSign, t2bBankDeposit, queryCusBankSignBank, t2bBankSign, t2bBankCancelSign, accountFundInfoReq } from '@/services/api/bank'
|
|
|
import { SignStatus } from '@/constants/bank'
|
|
import { SignStatus } from '@/constants/bank'
|
|
|
import { decryptAES } from '@/services/websocket/package/crypto'
|
|
import { decryptAES } from '@/services/websocket/package/crypto'
|
|
|
import moment from "moment"
|
|
import moment from "moment"
|
|
|
|
|
|
|
|
const accountStore = useAccountStore()
|
|
const accountStore = useAccountStore()
|
|
|
|
|
+const loginStore = useLoginStore()
|
|
|
|
|
|
|
|
// 提现请求
|
|
// 提现请求
|
|
|
export function useDoWithdraw() {
|
|
export function useDoWithdraw() {
|
|
@@ -210,18 +211,23 @@ export function useDoCancelBankSign() {
|
|
|
/// 获取当前是否已签约
|
|
/// 获取当前是否已签约
|
|
|
const sign = shallowRef<Model.BankAccountSignRsp[]>([])
|
|
const sign = shallowRef<Model.BankAccountSignRsp[]>([])
|
|
|
|
|
|
|
|
- const formRefresh = () => {
|
|
|
|
|
- queryBankAccountSign().then((res) => {
|
|
|
|
|
|
|
+ const request = queryBankAccountSign({
|
|
|
|
|
+ data: {
|
|
|
|
|
+ userid: loginStore.userId
|
|
|
|
|
+ }
|
|
|
|
|
+ }).then((res) => {
|
|
|
|
|
+ if (res.data.length) {
|
|
|
bankInfo.value = res.data[0];
|
|
bankInfo.value = res.data[0];
|
|
|
({
|
|
({
|
|
|
currency: formData.Currency,
|
|
currency: formData.Currency,
|
|
|
cusbankid: formData.CusBankID,
|
|
cusbankid: formData.CusBankID,
|
|
|
accountcode: formData.AccountCode,
|
|
accountcode: formData.AccountCode,
|
|
|
} = bankInfo.value ?? {})
|
|
} = bankInfo.value ?? {})
|
|
|
- })
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ }
|
|
|
|
|
+ })
|
|
|
|
|
|
|
|
const cancelSubmit = async () => {
|
|
const cancelSubmit = async () => {
|
|
|
|
|
+ await request
|
|
|
// await request
|
|
// await request
|
|
|
loading.value = true
|
|
loading.value = true
|
|
|
/// 发起请求
|
|
/// 发起请求
|
|
@@ -240,8 +246,7 @@ export function useDoCancelBankSign() {
|
|
|
cancelSubmit,
|
|
cancelSubmit,
|
|
|
formData,
|
|
formData,
|
|
|
sign,
|
|
sign,
|
|
|
- bankInfo,
|
|
|
|
|
- formRefresh
|
|
|
|
|
|
|
+ bankInfo
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|