| 1234567891011121314151617181920212223242526272829303132333435363738 |
- <template>
- <div>
- <el-row>
- <el-col :span="4"></el-col>
- <el-col :span="16">
- <el-table :data="SellItems" border stripe>
- <el-table-column prop="Name" label="Name"></el-table-column>
- <el-table-column prop="data.Description" label="Description"></el-table-column>
- <el-table-column prop="data.Price" label="Price"></el-table-column>
- </el-table>
- </el-col>
- </el-row>
- </div>
- </template>
- <script setup lang="ts">
- import {BaseData, GetSellItems, SellItem} from "../../api/ConfigFile";
- import {ref} from "vue";
- let SellItems = ref<BaseData<SellItem>[]>([]);
- replay()
- function replay() {
- GetSellItems().then((res) => {
- if (res.code == 200) {
- for (let key in res.data) {
- SellItems.value.push(new BaseData(key, res.data[key]))
- }
- }
- });
- }
- </script>
- <style scoped lang="scss">
- </style>
|