From 7610ead03b4802a9548e4ad7db5cf223e097a508 Mon Sep 17 00:00:00 2001
From: hongxilin <17663930442@163.com>
Date: Thu, 28 Nov 2024 20:58:01 +0800
Subject: [PATCH] =?UTF-8?q?=E6=B4=BB=E5=8A=A8=E7=AE=A1=E7=90=86=E8=A1=A8?=
=?UTF-8?q?=E6=90=9C=E7=B4=A2=E6=8E=A5=E5=8F=A3=20=E6=9F=A5=E8=AF=A2?=
=?UTF-8?q?=E6=B2=A1=E6=9C=89=E4=BA=BA=E5=90=8D=EF=BC=8C=E8=80=8C=E6=98=AF?=
=?UTF-8?q?id=EF=BC=8C=E5=BA=94=E8=AF=A5=E8=81=94=E6=9F=A5=E5=87=BA?=
=?UTF-8?q?=E4=BA=BA=E5=90=8D=EF=BC=8C=E7=AC=AC=E4=BA=8C=E6=B2=A1=E6=9C=89?=
=?UTF-8?q?=E6=B4=BB=E5=8A=A8=E7=9A=84=E7=8A=B6=E6=80=81=E3=80=82?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.../src/views/managerecharge/activity.vue | 40 ++++++++++++++++------
1 file changed, 30 insertions(+), 10 deletions(-)
diff --git a/vue/gold-system/src/views/managerecharge/activity.vue b/vue/gold-system/src/views/managerecharge/activity.vue
index 790b7a3..e89fb31 100644
--- a/vue/gold-system/src/views/managerecharge/activity.vue
+++ b/vue/gold-system/src/views/managerecharge/activity.vue
@@ -4,12 +4,12 @@ import ElementPlus from "element-plus";
import axios from 'axios';
//变量
//活动表格数据
-const tableData = ref[{}];
+const tableData = ref([]);
//搜索对象
const getObj = ref({
- page: 1,
- size: 10,
+ pageNum: 1,
+ pageSize: 5,
})
//分页总条目
const total = ref(100)
@@ -17,7 +17,23 @@ const total = ref(100)
//方法
//搜索方法
-
+const get = async function () {
+ try {
+ console.log('搜索参数', getObj.value);
+ // 发送POST请求
+ const result = await axios.post('http://192.168.8.93:10010/recharge/activity/select', getObj.value);
+
+ // 将响应结果存储到响应式数据中
+ console.log('请求成功', result);
+ // 存储表格数据
+ tableData.value = result.data.data.list;
+ console.log('tableData', tableData.value);
+ // 在这里可以根据需求进一步处理成功后的逻辑,比如更新UI显示成功消息等
+ } catch (error) {
+ console.log('请求失败', error);
+ // 在这里可以处理错误逻辑,比如显示错误提示等
+ }
+}
//新增活动弹出框
const addActivityVisible = ref(false)
//打开新增活动弹出框
@@ -48,6 +64,12 @@ const Delete = function (index, row) {
console.log(index, row)
}
+
+// 挂载
+onMounted(async function(){
+ get();
+})
+
@@ -125,8 +147,8 @@ const Delete = function (index, row) {
-
+
@@ -138,7 +160,7 @@ const Delete = function (index, row) {
-
+
@@ -162,7 +184,7 @@ const Delete = function (index, row) {
-
+
@@ -178,8 +200,6 @@ const Delete = function (index, row) {