代码优化

This commit is contained in:
GaoHao
2025-03-26 13:34:19 +08:00
parent e928fdfa2a
commit 413222a5f0
42 changed files with 166 additions and 531 deletions

View File

@@ -69,11 +69,12 @@
import { onLoad, onReady, onShow, } from '@dcloudio/uni-app';
import { ref, reactive, computed, watch } from 'vue';
import { $status } from '@/commons/table-status.js'
import tableItem from './components/table-item'
import go from '@/commons/utils/go.js';
import myActionSheet from '@/components/my-components/my-action-sheet';
import tableItem from './components/table-item'
import { hasPermission } from '@/commons/utils/hasPermission.js'
import { getShopTable, shopTableBind, shopTableClear } from '@/http/api/table.js'
import { getShopArea } from '@/http/api/area.js'
import { printOrder } from '@/http/api/order.js'
@@ -94,7 +95,7 @@
statusList: [[{
key: '',
label: '全部'
},...uni.$utils.objToArrary($status)]],
},...uni.$utils.objToArrary(uni.$dict.tableStatus)]],
statusName: '全部',
tabList: [],
area: {
@@ -138,7 +139,7 @@
* 获取区域
*/
async function getArea() {
const res = await getShopArea({ name: '', page: 0, size: 300 })
const res = await getShopArea({ name: '', page: 1, size: 300 })
pageData.area.list = res.records
pageData.areaMap = res.records.reduce((prve, cur) => {
prve[cur.id] = cur.name