fix: nạp tiền
This commit is contained in:
parent
e8ee371974
commit
63e5969515
@ -20,9 +20,9 @@ const type = ref("");
|
|||||||
const amount = Number(route.query.money);
|
const amount = Number(route.query.money);
|
||||||
|
|
||||||
const bankInfo = reactive({
|
const bankInfo = reactive({
|
||||||
bankName: "bank",
|
bankName: "",
|
||||||
accountNumber: "123456",
|
accountNumber: "",
|
||||||
holder: "NGUYEN VAN A"
|
holder: ""
|
||||||
})
|
})
|
||||||
|
|
||||||
if (isNaN(amount) || amount <= 0) {
|
if (isNaN(amount) || amount <= 0) {
|
||||||
@ -30,10 +30,11 @@ if (isNaN(amount) || amount <= 0) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const submit = () => {
|
const submit = () => {
|
||||||
|
|
||||||
handleRequest(axios.post(API.TRANSACTION_DEPOSIT, { amount, note: "ok" })).then(res => {
|
handleRequest(axios.post(API.TRANSACTION_DEPOSIT, { amount, note: "ok" })).then(res => {
|
||||||
if(res.success) {
|
if(res.success) {
|
||||||
type.value = 'bank';
|
type.value = 'bank';
|
||||||
|
console.log(res.data.bank)
|
||||||
|
Object.assign(bankInfo, res.data.bank)
|
||||||
} else {
|
} else {
|
||||||
showFailToast(res.message ?? "Lỗi nạp tiền")
|
showFailToast(res.message ?? "Lỗi nạp tiền")
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user