From 1c0f01cc462d37e146c34127d2883ca51e26d508 Mon Sep 17 00:00:00 2001 From: 曹睿 <360930172@qq.com> Date: 星期二, 24 六月 2025 17:12:32 +0800 Subject: [PATCH] fix: 修复PIMTable不支持懒加载问题。修复【来票登记】金额格式化显示NaN问题。 style: 重构来票登记页面。 feat: 完善文件上传组件功能。【来票台账】底部添加合计。【来票登记】添加上传附件 --- src/views/procurementManagement/thePaymentLedger/index.vue | 109 ++++++++++++++++++++++++++++-------------------------- 1 files changed, 57 insertions(+), 52 deletions(-) diff --git a/src/views/procurementManagement/thePaymentLedger/index.vue b/src/views/procurementManagement/thePaymentLedger/index.vue index 38fac3a..5fa9e6f 100644 --- a/src/views/procurementManagement/thePaymentLedger/index.vue +++ b/src/views/procurementManagement/thePaymentLedger/index.vue @@ -4,93 +4,98 @@ <div> <span class="search_title">渚涘簲鍟嗗悕绉�/鍚堝悓鍙凤細</span> <el-input - v-model="searchForm.supplierNameOrContractNo" - style="width: 240px" - placeholder="杈撳叆渚涘簲鍟嗗悕绉�/鍚堝悓鍙锋悳绱�" - @change="handleQuery" - clearable - :prefix-icon="Search" + v-model="searchForm.supplierNameOrContractNo" + style="width: 240px" + placeholder="杈撳叆渚涘簲鍟嗗悕绉�/鍚堝悓鍙锋悳绱�" + @change="handleQuery" + clearable + :prefix-icon="Search" /> - <el-button type="primary" @click="handleQuery" style="margin-left: 10px">鎼滅储</el-button> + <el-button type="primary" @click="handleQuery" style="margin-left: 10px" + >鎼滅储</el-button + > </div> </div> <div class="table_list"> - <PIMTable :column="tableColumn" :tableData="tableData" :page="page" - :tableLoading="tableLoading" @pagination="pagination" :total="total"></PIMTable> + <PIMTable + rowKey="id" + :column="tableColumn" + :tableData="tableData" + :page="page" + :tableLoading="tableLoading" + @pagination="pagination" + :total="total" + ></PIMTable> </div> </div> </template> <script setup> -import { ref } from 'vue' -import {Search} from "@element-plus/icons-vue"; -import { - registrationList, -} from "@/api/procurementManagement/paymentEntry.js"; +import { ref } from "vue"; +import { Search } from "@element-plus/icons-vue"; +import { registrationList } from "@/api/procurementManagement/paymentEntry.js"; const tableColumn = ref([ { - label: '浠樻鏃ユ湡', - prop: 'paymentDate', + label: "浠樻鏃ユ湡", + prop: "paymentDate", }, { - label: '渚涘簲鍟嗗悕绉�', - prop: 'supplierName', + label: "渚涘簲鍟嗗悕绉�", + prop: "supplierName", }, { - label: '浠樻閲戦', - prop: 'currentPaymentAmount', + label: "浠樻閲戦", + prop: "currentPaymentAmount", }, { - label: '鐧昏浜�', - prop: 'registrant' + label: "鐧昏浜�", + prop: "registrant", }, { - label: '鐧昏鏃ユ湡', - prop: 'registrationtDate' + label: "鐧昏鏃ユ湡", + prop: "registrationtDate", }, -]) -const tableData = ref([]) -const tableLoading = ref(false) -const purchaseLedgerList = ref([]) -const invoiceNumberList = ref([]) +]); +const tableData = ref([]); +const tableLoading = ref(false); +const purchaseLedgerList = ref([]); +const invoiceNumberList = ref([]); const page = reactive({ current: 1, size: 10, -}) -const total = ref(0) +}); +const total = ref(0); // 鐢ㄦ埛淇℃伅琛ㄥ崟寮规鏁版嵁 -const operationType = ref('') -const dialogFormVisible = ref(false) +const operationType = ref(""); +const dialogFormVisible = ref(false); const data = reactive({ searchForm: { - supplierNameOrContractNo: '', + supplierNameOrContractNo: "", }, -}) -const { searchForm, form, rules } = toRefs(data) +}); +const { searchForm, form, rules } = toRefs(data); // 鏌ヨ鍒楄〃 /** 鎼滅储鎸夐挳鎿嶄綔 */ const handleQuery = () => { - page.current = 1 - getList() -} + page.current = 1; + getList(); +}; const pagination = ({ current, limit }) => { page.current = current; page.size = limit; - getList() -} + getList(); +}; const getList = () => { - tableLoading.value = true - registrationList({...searchForm.value, ...page}).then(res => { - tableLoading.value = false - tableData.value = res.rows - total.value = res.total - }) -} -getList() + tableLoading.value = true; + registrationList({ ...searchForm.value, ...page }).then((res) => { + tableLoading.value = false; + tableData.value = res.rows; + total.value = res.total; + }); +}; +getList(); </script> -<style scoped lang="scss"> - -</style> +<style scoped lang="scss"></style> -- Gitblit v1.9.3