From 28972c351ea79b4721750f6970e88263b64c64aa Mon Sep 17 00:00:00 2001
From: gaoluyang <2820782392@qq.com>
Date: 星期四, 13 三月 2025 16:03:36 +0800
Subject: [PATCH] 表格样式整体修改
---
src/views/performance/manHour/workTimeManagement.vue | 27 +++++++++++++--------------
1 files changed, 13 insertions(+), 14 deletions(-)
diff --git a/src/views/performance/manHour/workTimeManagement.vue b/src/views/performance/manHour/workTimeManagement.vue
index 2f10f73..6d3bc23 100644
--- a/src/views/performance/manHour/workTimeManagement.vue
+++ b/src/views/performance/manHour/workTimeManagement.vue
@@ -42,7 +42,7 @@
</div>
</div>
<div style="display: flex; align-items: center; justify-content: space-between">
- <el-radio-group :key="'111'" v-model="currentTable" size="small">
+ <el-radio-group :key="'111'" v-model="currentTable" size="small" @change="searchList">
<el-radio-button label="ValueTable0"> 杈呭姪宸ユ椂 </el-radio-button>
<el-radio-button label="ValueTable1"> 浜ч噺宸ユ椂 </el-radio-button>
</el-radio-group>
@@ -220,7 +220,6 @@
</template>
<script>
-import ValueTable from "@/components/Table/value-table.vue";
import { getYearAndMonthAndDays } from "@/utils/date";
import {
selectAuxiliaryWorkingHoursDay,
@@ -238,7 +237,6 @@
import limsTable from "@/components/Table/lims-table.vue";
export default {
components: {
- ValueTable,
limsTable,
},
dicts: ["sys_class_type"],
@@ -507,10 +505,17 @@
this.getCurrentWeekNumber();
this.collectWorkingHours();
this.selectshiftByUser();
- this.getList();
- this.getList0();
+ this.searchList()
},
methods: {
+ searchList() {
+ if (this.currentTable == 'ValueTable0') {
+ this.getList();
+ } else {
+ this.getList0();
+ }
+ },
+ // 鏌ヨ杈呭姪宸ユ椂鍒楄〃
getList(entity) {
this.tableLoading = true;
let param = {};
@@ -518,7 +523,7 @@
param = { ...entity, ...this.page };
} else {
param = { ...this.entity, ...this.page };
- param.dateTime = JSON.stringify(param.dateTime);
+ param.dateTime = param.dateTime?.length > 0 ? JSON.stringify(param.dateTime) : null;
}
delete param.total;
selectAuxiliaryWorkingHoursDay({ ...param })
@@ -533,6 +538,7 @@
this.tableLoading = false;
});
},
+ // 鏌ヨ浜ч噺宸ユ椂鍒楄〃
getList0(entity) {
this.tableLoading = true;
let param = {};
@@ -540,7 +546,7 @@
param = { ...entity, ...this.page0 };
} else {
param = { ...this.entity, ...this.page0 };
- param.dateTime = JSON.stringify(param.dateTime);
+ param.dateTime = param.dateTime?.length > 0 ? JSON.stringify(param.dateTime) : null
}
delete param.total;
selectAuxiliaryOutputWorkingHours({ ...param })
@@ -637,7 +643,6 @@
})
.then(() => {
deleteAuxiliaryWorkingHoursDay({ id: row.id }).then((res) => {
- if (res.code == 201) return;
this.$message.success("鍒犻櫎鎴愬姛");
this.refreshTable("page");
});
@@ -660,7 +665,6 @@
if (!this.formData.id) {
insertAuxiliaryWorkingHoursDay(this.formData).then((res) => {
this.addLoad = false;
- if (res.code == 201) return;
this.$message.success("宸叉彁浜�");
this.formData.number = "";
this.formData.amount = "";
@@ -675,7 +679,6 @@
} else {
updateAuxiliaryWorkingHoursDay(this.formData).then((res) => {
this.addLoad = false;
- if (res.code == 201) return;
this.$message.success("鎿嶄綔鎴愬姛");
this.formData.number = "";
this.formData.amount = "";
@@ -728,9 +731,6 @@
});
approve({ auxiliaryWorkingHoursDays: auxiliaryWorkingHoursDays }).then(
(res) => {
- if (res.code === 201) {
- return;
- }
this.submitBatchCheckDialog();
this.$message.success("鎿嶄綔鎴愬姛");
}
@@ -767,7 +767,6 @@
} else {
this.checkLoadY = false;
}
- if (res.code == 201) return;
this.$message.success("鎿嶄綔鎴愬姛");
this.checkVisible = false;
this.refreshTable("page");
--
Gitblit v1.9.3