修复了在`store_finance_flow`视图中,`el-table`组件缺少`tree-props`属性的问题。

This commit is contained in:
zmj 2024-06-21 15:44:23 +08:00
parent a29f4c27e7
commit a4eafad385
2 changed files with 97 additions and 1 deletions

View File

@ -0,0 +1,95 @@
<template>
<div>
<el-card class="!border-none mb-4" shadow="never">
<el-form class="mb-[-16px]" :model="queryParams" label-width="80px">
<el-row>
<el-col :span="6">
<el-form-item label="商品状态">
<el-select class="flex-1" v-model="queryParams.status" clearable placeholder="请选择商品状态">
<el-option label="销售中" :value="0" />
<el-option label="仓库中" :value="0" />
<el-option label="已售罄" :value="0" />
<el-option label="库存预警" :value="0" />
</el-select>
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item label="商品搜索" prop="nature">
<el-input v-model="queryParams.status" clearable placeholder="请输入商品名称" />
</el-form-item>
</el-col>
<el-col :span="6">
<el-form-item>
<el-button type="primary" @click="resetPage">查询</el-button>
<el-button @click="resetParams">重置</el-button>
</el-form-item>
</el-col>
</el-row>
</el-form>
</el-card>
<el-card class="!border-none" v-loading="pager.loading" shadow="never">
<div class="mt-4">
<el-table :data="pager.lists" @selection-change="handleSelectionChange">
<el-table-column label="入账门店" prop="progress" show-overflow-tooltip />
<el-table-column label="入账时间" prop="progress" show-overflow-tooltip />
<el-table-column label="应入帐金额" prop="progress" show-overflow-tooltip />
<el-table-column label="已入账金额" prop="progress" show-overflow-tooltip />
<el-table-column label="未入账金额" prop="progress" show-overflow-tooltip />
<el-table-column label="操作" width="170" fixed="right">
<template #default="{ row }">
<el-button type="primary" link @click="handleEdit(row)">
编辑
</el-button>
<el-button type="primary" link @click="handleEdit(row)">
起码子
</el-button>
</template>
</el-table-column>
</el-table>
</div>
<div class="flex mt-4 justify-end">
<pagination v-model="pager" @change="getLists" />
</div>
</el-card>
<!-- <detailPopup ref="editRef" /> -->
</div>
</template>
<script lang="ts" setup name="manageProjectLists">
import { ref, reactive } from "vue"
import { usePaging } from '@/hooks/usePaging'
// import { apiGoodsListLists, apiStatus, apiGoodsTypeLists } from '@/api/goodsList'
// import detailPopup from './detail.vue'
// const editRef = shallowRef<InstanceType<typeof EditPopup>>()
//
// const showDetail = ref(false)
//
const queryParams = reactive({
status: ""
})
//
const selectData = ref<any[]>([])
//
const handleSelectionChange = (val: any[]) => {
selectData.value = val.map(({ id }) => id)
}
//
const { pager, getLists, resetParams, resetPage } = usePaging({
// fetchFun: apiGoodsListLists,
params: queryParams
})
//
const handleEdit = async (data: any) => {
// editRef.value?.open()
}
// getLists()
</script>

View File

@ -39,7 +39,8 @@
删除 删除
</el-button> --> </el-button> -->
<div> <div>
<el-table :data="pager.lists" @selection-change="handleSelectionChange" row-key="id" :tree-props="{ children: 'list' }"> <el-table :data="pager.lists" @selection-change="handleSelectionChange" row-key="id"
:tree-props="{ children: 'list' }">
<el-table-column label="ID" prop="id" min-width="100" show-overflow-tooltip /> <el-table-column label="ID" prop="id" min-width="100" show-overflow-tooltip />
<el-table-column label="交易单号" prop="order_sn" min-width="120" show-overflow-tooltip /> <el-table-column label="交易单号" prop="order_sn" min-width="120" show-overflow-tooltip />
<el-table-column label="交易时间" prop="create_time" min-width="120" show-overflow-tooltip /> <el-table-column label="交易时间" prop="create_time" min-width="120" show-overflow-tooltip />