From c39792a0f67861602b0c430e32b88fa9d1667008 Mon Sep 17 00:00:00 2001 From: GYJ <1157756119@qq.com> Date: Tue, 20 Aug 2024 10:24:14 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B4=BB=E5=8A=A8=E9=A1=B5=E9=9D=A2=E5=A2=9E?= =?UTF-8?q?=E5=8A=A0=E8=87=AA=E5=AE=9A=E4=B9=89=E5=85=85=E5=80=BC=E9=87=91?= =?UTF-8?q?=E9=A2=9D=E5=BC=80=E5=85=B3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/user_manage/active_list.vue | 34 +++++++++++++++++++++++++-- 1 file changed, 32 insertions(+), 2 deletions(-) diff --git a/src/views/user_manage/active_list.vue b/src/views/user_manage/active_list.vue index 2df7e2f..2d0dc88 100644 --- a/src/views/user_manage/active_list.vue +++ b/src/views/user_manage/active_list.vue @@ -18,6 +18,9 @@ 下载会员充值二维码 +
+ 允许充值自定义金额: +
@@ -63,10 +66,11 @@ import handselTypes from './handselTypes' import addActive from './components/addActive' import QR from './components/downloadQR.vue' import { findActivate, modityActivate } from '@/api/shop' +import { tbShopInfo, tbShopInfoPut } from "@/api/user"; import dayjs from 'dayjs' export default { components: { - addActive,QR + addActive, QR }, data() { return { @@ -79,6 +83,9 @@ export default { size: 10, loading: false, total: 0 + }, + shopInfo: { + isCustom: '0', } } }, @@ -92,6 +99,7 @@ export default { }, mounted() { this.getTableData() + this.getShopInfo() }, methods: { // 切换状态 @@ -131,7 +139,29 @@ export default { } catch (error) { console.log(error) } + }, + // 请求店铺信息 + async getShopInfo() { + try { + const res = await tbShopInfo(localStorage.getItem('shopId')) + this.shopInfo = res + + if (this.shopInfo.isCustom == null) { + this.shopInfo.isCustom = '0' + } + + console.log(this.shopInfo); + + } catch (error) { + console.log(error) + } + }, + customStatusChange() { + this.updateShopInfo() + }, + async updateShopInfo() { + await tbShopInfoPut(this.shopInfo) } } } - \ No newline at end of file +