From 00228dfd593c06119c6815dbd1afe7edcd6b5dec Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期三, 20 八月 2025 10:47:11 +0800
Subject: [PATCH] 劳保台账修改
---
src/api/lavorissce/ledger.js | 4 ++--
src/views/lavorissue/ledger/index.vue | 37 +++++++++++++++++++++----------------
2 files changed, 23 insertions(+), 18 deletions(-)
diff --git a/src/api/lavorissce/ledger.js b/src/api/lavorissce/ledger.js
index 2d81bd9..90730c1 100644
--- a/src/api/lavorissce/ledger.js
+++ b/src/api/lavorissce/ledger.js
@@ -1,11 +1,11 @@
import request from '@/utils/request'
// 鍒嗛〉鏌ヨ
-export function lavorIssueListPage(params) {
+export function lavorIssueListPage(query) {
return request({
url: '/lavorIssue/listPage',
method: 'get',
- params
+ params: query
})
}
diff --git a/src/views/lavorissue/ledger/index.vue b/src/views/lavorissue/ledger/index.vue
index b23bffe..33a1461 100644
--- a/src/views/lavorissue/ledger/index.vue
+++ b/src/views/lavorissue/ledger/index.vue
@@ -143,13 +143,15 @@
</template>
<script setup>
-import { ref, onMounted } from 'vue'
+import { ref, onMounted, reactive, toRefs, nextTick, getCurrentInstance } from 'vue'
import dayjs from "dayjs";
import Modal from "./Modal.vue";
import FilesDia from "./filesDia.vue";
-import {lavorIssueListPage} from "@/api/lavorissce/ledger.js";
-import {ElMessageBox} from "element-plus";
+import Pagination from "@/components/Pagination/index.vue";
+import {lavorIssueListPage, deleteLedger, update} from "@/api/lavorissce/ledger.js";
+import {ElMessageBox, ElMessage} from "element-plus";
const { proxy } = getCurrentInstance();
+import { getCurrentMonth } from "@/utils/util"
const page = ref({
current: 1,
@@ -163,13 +165,14 @@
const { sys_lavor_issue } = proxy.useDict("sys_lavor_issue")
const data = reactive({
searchForm: {
- feedbackDate: "",
- disDate: "",
+ season: "",
+ staffName: "",
},
});
+const { searchForm } = toRefs(data);
+
const modalRef = ref();
const filesDia = ref();
-const { searchForm } = toRefs(data);
const multipleList = ref([]);
const jidu = ref([
{
@@ -192,16 +195,17 @@
/** 鎼滅储鎸夐挳鎿嶄綔 */
const handleQuery = () => {
- page.current = 1;
+ page.value.current = 1;
getList();
};
// 鑾峰彇瀛楀吀鏁版嵁
const getList = async () => {
tableLoading.value = true;
- lavorIssueListPage().then(res => {
+ const params = { ...searchForm.value, ...page.value };
+ lavorIssueListPage(params).then(res => {
tableLoading.value = false;
tableData.value = res.data.records;
- page.total = res.data.total;
+ total.value = res.data.total;
}).catch(err => {
tableLoading.value = false;
})
@@ -224,7 +228,7 @@
type: "success",
message: "鍒犻櫎鎴愬姛",
});
- getTableData();
+ getList();
}
});
};
@@ -235,10 +239,10 @@
type: "warning",
})
.then(() => {
- proxy.download(`/lavorIssue/exportCopy`, {season: filters.season}, "鍔充繚鍙拌处.xlsx");
+ proxy.download(`/lavorIssue/exportCopy`, {season: searchForm.value.season}, "鍔充繚鍙拌处.xlsx");
})
.catch(() => {
- proxy.$modal.msg("宸插彇娑�");
+ ElMessage.info("宸插彇娑�");
});
};
const adopted = (row) => {
@@ -257,7 +261,7 @@
type: "success",
message: "棰嗙敤鎴愬姛",
});
- getTableData();
+ getList();
}
})
}
@@ -272,9 +276,10 @@
multipleList.value = selection;
}
-const paginationChange = (size) => {
- console.log(size)
-
+const paginationChange = (pagination) => {
+ page.value.current = pagination.page;
+ page.value.size = pagination.limit;
+ getList();
}
// 缁勪欢鎸傝浇鏃跺姞杞藉瓧鍏告暟鎹�
--
Gitblit v1.9.3