From 5eb145f6ab64a130aab5519b3da3f536c23b4f8c Mon Sep 17 00:00:00 2001 From: gaoluyang <2820782392@qq.com> Date: 星期一, 14 七月 2025 13:25:04 +0800 Subject: [PATCH] 1.协同审批报错 --- src/views/salesManagement/receiptPayment/index.vue | 40 +++++++++++++++++++++++++++------------- 1 files changed, 27 insertions(+), 13 deletions(-) diff --git a/src/views/salesManagement/receiptPayment/index.vue b/src/views/salesManagement/receiptPayment/index.vue index d9048a0..a46b667 100644 --- a/src/views/salesManagement/receiptPayment/index.vue +++ b/src/views/salesManagement/receiptPayment/index.vue @@ -49,7 +49,7 @@ <div class="actions"> <div></div> <div> - <el-button type="primary" icon="Plus" @click="openForm('add')"> + <el-button type="primary" @click="openForm('add')"> 鏂板鍥炴 </el-button> <el-button icon="Download" @click="handleOut"> 瀵煎嚭 </el-button> @@ -66,7 +66,7 @@ :expand-row-keys="expandedRowKeys" @expand-change="expandChange" - height="calc(100vh - 18.5em)" + height="calc(100vh - 21.5em)" > <el-table-column align="center" type="selection" width="55" /> <el-table-column type="expand"> @@ -86,10 +86,13 @@ <el-table-column label="鍥炴鏃ユ湡" prop="receiptPaymentDate" /> <el-table-column label="鍥炴閲戦" prop="receiptPaymentAmount"> <template #default="scope"> - <el-input - v-model="scope.row.receiptPaymentAmount" - :disabled="!scope.row.editType" - ></el-input> + <el-input-number :step="0.01" :min="0" style="width: 100%" + v-model="scope.row.receiptPaymentAmount" + :disabled="!scope.row.editType" + :precision="2" + placeholder="璇疯緭鍏�" + clearable + /> </template> </el-table-column> <el-table-column label="鍥炴鏂瑰紡" prop="receiptPaymentType"> @@ -119,6 +122,7 @@ size="small" @click="changeEditType(scope.row)" v-if="!scope.row.editType" + :disabled="scope.row.registrant !== userStore.nickName" >缂栬緫</el-button > <el-button @@ -127,6 +131,7 @@ size="small" @click="saveReceiptPayment(scope.row)" v-if="scope.row.editType" + :disabled="scope.row.registrant !== userStore.nickName" >淇濆瓨</el-button > <el-button @@ -134,6 +139,7 @@ type="primary" size="small" @click="delReceiptRecord(scope.row)" + :disabled="scope.row.registrant !== userStore.nickName" >鍒犻櫎</el-button > </template> @@ -165,7 +171,7 @@ label="椤圭洰鍚嶇О" prop="projectName" show-overflow-tooltip - width="200" + width="340" /> <el-table-column label="浜у搧澶х被" @@ -285,7 +291,8 @@ </el-col> <el-col :span="12"> <el-form-item label="鏈鍥炴閲戦锛�" prop="receiptPaymentAmount"> - <el-input-number :step="0.01" :min="0" style="width: 100%" + <el-input-number :step="0.01" :min="0" style="width: 100%" + :precision="2" v-model="form.receiptPaymentAmount" placeholder="璇疯緭鍏�" clearable @@ -431,13 +438,20 @@ getList(); }; const getList = () => { - expandedRowKeys.value = []; tableLoading.value = true; bindInvoiceNoRegPage({ ...searchForm, ...page }) .then((res) => { tableLoading.value = false; tableData.value = res.data.records; total.value = res.data.total; + if (expandedRowKeys.value.length > 0) { + const arr = [] + const index = tableData.value.findIndex(item => item.id === expandedRowKeys.value[0]); + if (index > -1) { + arr.push(tableData.value[index]); + expandChange(tableData.value[index], arr) + } + } }) .catch(() => { tableLoading.value = false; @@ -499,10 +513,8 @@ proxy.$modal.msgError("璇烽�夋嫨涓�鏉℃暟鎹�"); return; } - // - console.log("(selectedRows.value", selectedRows.value); - if (selectedRows.value[0].noReceiptAmount === 0) { - proxy.$modal.msgError("寰呭洖娆鹃噾棰濅负0鍏�"); + if (selectedRows.value[0].noReceiptAmount == 0) { + proxy.$modal.warning("鏃犻渶鍐嶅洖娆�"); return; } invoiceInfo({ id: selectedRows.value[0].id }).then((res) => { @@ -570,6 +582,8 @@ }; receiptPaymentSaveOrUpdate(updateData).then((res) => { row.editType = !row.editType; + getList(); + proxy.$modal.msgSuccess("鎻愪氦鎴愬姛"); }); }; -- Gitblit v1.9.3