From ceb802af0b9630b30c7f973f05da8d2ed9e9c16f Mon Sep 17 00:00:00 2001 From: maven <2163098428@qq.com> Date: 星期四, 14 八月 2025 15:52:12 +0800 Subject: [PATCH] yys 新增劳保统计 --- src/views/lavorissue/ledger/index.vue | 62 ++++++++++++++++++++++++++++-- 1 files changed, 57 insertions(+), 5 deletions(-) diff --git a/src/views/lavorissue/ledger/index.vue b/src/views/lavorissue/ledger/index.vue index 27cd948..6441247 100644 --- a/src/views/lavorissue/ledger/index.vue +++ b/src/views/lavorissue/ledger/index.vue @@ -3,7 +3,7 @@ <el-form :model="filters" :inline="true"> <el-form-item label="鍛樺伐鍚嶇О:"> <el-input - v-model="filters.supplierName" + v-model="filters.staffName" style="width: 240px" placeholder="璇疯緭鍏�" @change="handleQuery" @@ -49,6 +49,9 @@ <el-button type="primary" text @click="edit(row)" icon="editPen"> 缂栬緫 </el-button> + <el-button type="primary" :disabled="row.adoptedDate ? true : false" text @click="adopted(row)"> + 棰嗙敤 + </el-button> </template> </PIMTable> </div> @@ -59,7 +62,7 @@ <script setup> import { usePaginationApi } from "@/hooks/usePaginationApi"; -import { listPage,deleteLedger } from "@/api/lavorissce/ledger"; +import { listPage,deleteLedger,update } from "@/api/lavorissce/ledger"; import { onMounted, getCurrentInstance } from "vue"; import Modal from "./Modal.vue"; import { ElMessageBox, ElMessage } from "element-plus"; @@ -85,9 +88,14 @@ } = usePaginationApi( listPage, { - incomeMethod: undefined, + staffName: '', }, [ + { + label: "鍔充繚鍗曞彿", + align: "center", + prop: "orderNo", + }, { label: "鍛樺伐鍚嶇О", align: "center", @@ -98,6 +106,13 @@ align: "center", prop: "staffNo" }, + + { + label: "鍔充繚绫诲瀷", + align: "center", + prop: "dictTypeName", + + }, { label: "鍔充繚闃插叿", align: "center", @@ -105,9 +120,21 @@ }, { - label: "棰嗙敤鏁伴噺", + label: "鍙戞斁鏁伴噺", align: "center", prop: "num", + + }, + { + label: "杩涘巶鏃ユ湡", + align: "center", + prop: "factoryDate", + + }, + { + label: "鍙戞斁鏃ユ湡", + align: "center", + prop: "issueDate", }, { @@ -132,11 +159,37 @@ multipleList.value = selectionList; }; +const adopted = (row) => { + ElMessageBox.confirm("鏄惁纭棰嗙敤?", "鎻愮ず", { + confirmButtonText: "纭畾", + cancelButtonText: "鍙栨秷", + type: "warning", + }).then(async () => { + const params = { + id: row.id, + adoptedDate: dayjs().format("YYYY-MM-DD") + } + const { code } = await update(params); + if (code == 200) { + ElMessage({ + type: "success", + message: "棰嗙敤鎴愬姛", + }); + getTableData(); + } + }) +} + const add = () => { modalRef.value.openModal(); }; const edit = (row) => { modalRef.value.loadForm(row); +}; + +/** 鎼滅储鎸夐挳鎿嶄綔 */ +const handleQuery = () => { + getTableData(); }; const changePage = ({ page, limit }) => { pagination.currentPage = page; @@ -192,7 +245,6 @@ }; onMounted(() => { - console.log(12331) filters.entryDate = [ dayjs().format("YYYY-MM-DD"), dayjs().add(1, "day").format("YYYY-MM-DD"), -- Gitblit v1.9.3