From eecb7aa9d4707f83a811563488b1fea4c0ffefdf Mon Sep 17 00:00:00 2001 From: lzyyj Date: Mon, 14 Oct 2024 11:49:08 +0800 Subject: [PATCH] =?UTF-8?q?=E8=AE=A2=E5=8D=95=E5=88=97=E8=A1=A8=E7=AE=A1?= =?UTF-8?q?=E7=90=86=E6=8E=A5=E5=8F=A3=E5=AF=B9=E6=8E=A5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/order/index.vue | 22 ++++++++++++---------- 1 file changed, 12 insertions(+), 10 deletions(-) diff --git a/src/views/order/index.vue b/src/views/order/index.vue index 4c23945..62d9069 100644 --- a/src/views/order/index.vue +++ b/src/views/order/index.vue @@ -309,15 +309,17 @@ import { } from '@element-plus/icons-vue' import {nextTick, onMounted, reactive, ref} from 'vue' -import {options} from './options.js' -import {getUserList} from "../../api/modules/user"; +// 示例数据 +// import {options} from './options.js' +import {getOrderList} from "../../api/modules/order"; const tableData = ref([]) const dataList = ref([]) const table = ref() const tabclickIndex = ref() const isExpand = ref(false) -const columnData = ref(JSON.parse(JSON.stringify(options))) +// 示例数据加载 +// const exampleData = ref(JSON.parse(JSON.stringify(options))) const disabled = ref(false) const dialogVisible = ref(false) const total = ref(0) @@ -332,14 +334,14 @@ const queryData = ref({ }) const initData = () => { + // 示例数据加载 + // tableData.value = exampleData.value; - tableData.value = columnData.value; - - // orderLists(queryData.value).then((res) => { - // console.log(res.data.data) - // // total.value = res.data.data.total - // tableData.value = res.data.data - // }) + getOrderList(queryData.value).then((res) => { + console.log(res.data) + total.value = res.data.total + tableData.value = res.data + }) } const itemEditHanld = (item) => { item.itemEdit = !item.itemEdit