| | |
| | | <template> |
| | | <div class="app-container"> |
| | | <el-form :model="filters"> |
| | | <el-form :model="filters" :inline="true"> |
| | | <el-form-item label="搜索"> |
| | | <el-input |
| | | v-model="filters.searchText" |
| | |
| | | @change="getTableData" |
| | | /> |
| | | </el-form-item> |
| | | <el-form-item> |
| | | <el-button type="primary" @click="getTableData">搜索</el-button> |
| | | <el-button @click="resetFilters">重置</el-button> |
| | | </el-form-item> |
| | | </el-form> |
| | | <PIMTable :column="columns" /> |
| | | <PIMTable |
| | | :column="columns" |
| | | :tableData="dataList" |
| | | :page="{ |
| | | current: pagination.currentPage, |
| | | size: pagination.pageSize, |
| | | total: pagination.total, |
| | | }" |
| | | > |
| | | <template #operation> |
| | | <el-button type="primary" text>编辑</el-button> |
| | | <el-button type="danger" text>删除</el-button> |
| | | </template> |
| | | </PIMTable> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | name: "设备台账", |
| | | }); |
| | | |
| | | const { filters, columns, getTableData } = usePaginationApi( |
| | | () => {}, |
| | | { |
| | | searchText: undefined, |
| | | }, |
| | | [ |
| | | const { filters, columns, dataList, pagination, getTableData, resetFilters } = |
| | | usePaginationApi( |
| | | () => {}, |
| | | { |
| | | label: "设备名称", |
| | | searchText: undefined, |
| | | }, |
| | | ] |
| | | ); |
| | | [ |
| | | { |
| | | label: "设备名称", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "规格型号", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "供应商", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "单位", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "数量", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "含税单价", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "含税总价", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "税率", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "不含税总价", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "录入人", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "录入日期", |
| | | align: "center", |
| | | }, |
| | | { |
| | | label: "操作", |
| | | dataType: "slot", |
| | | slot: "operation", |
| | | align: "center", |
| | | width: "150px", |
| | | }, |
| | | ] |
| | | ); |
| | | </script> |