From 3febfd29ec9c3873b8ab286684248320e6634217 Mon Sep 17 00:00:00 2001 From: jjLv <1981429112@qq.com> Date: Sat, 12 Oct 2024 18:21:27 +0800 Subject: [PATCH] =?UTF-8?q?=E6=97=A5=E6=9C=9F=E9=80=89=E6=8B=A9=E5=99=A8?= =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/exceptionHandle/errorForm/index.vue | 35 ++++++++++++-- src/views/report/monthlyError/index.vue | 47 ++++++++++++++++++- 2 files changed, 76 insertions(+), 6 deletions(-) diff --git a/src/views/exceptionHandle/errorForm/index.vue b/src/views/exceptionHandle/errorForm/index.vue index c90ec42..0ac65bf 100644 --- a/src/views/exceptionHandle/errorForm/index.vue +++ b/src/views/exceptionHandle/errorForm/index.vue @@ -78,8 +78,8 @@ - - + + + + 查询 @@ -235,6 +247,9 @@ { required: true, message: "补充内容不能为空", trigger: "blur" } ], }, + pickerOptions: { + disabledDate: this.disabledDate, + }, }; }, computed: { @@ -281,6 +296,18 @@ // }, methods: { + + disabledDate(time) { + const str=this.queryRecord.attCurrentMonth+'-01'; + // 获取当前日期 + var currentDate = new Date(str); + // 获取当前月份的第一天 + var firstDayOfMonth = new Date(currentDate.getFullYear(), currentDate.getMonth(), 1); + // 获取当前月份的最后一天 + var lastDayOfMonth = new Date(currentDate.getFullYear(), currentDate.getMonth() + 1, 0); + return time < firstDayOfMonth || time > lastDayOfMonth; + }, + handleChange(newValue) { // 如果选择的值为空,重置为之前的值 if (!newValue) { @@ -385,13 +412,13 @@ getListRecord() { this.loadingTwo = true; if(this.title=='轮休未审批记录'){ - getDetailExceptionRest(this.queryRecord).then(response => { + getDetailExceptionRest(this.addDateRange(this.queryRecord, this.dateRange)).then(response => { this.tableDataRecord = response.rows; this.totalTwo = response.total; this.loadingTwo = false; }); }else if(this.title=='外出办事未审批记录'){ - getDetailExceptionOut(this.queryRecord).then(response => { + getDetailExceptionOut(this.addDateRange(this.queryRecord, this.dateRange)).then(response => { this.tableDataRecord = response.rows; this.totalTwo = response.total; this.loadingTwo = false; diff --git a/src/views/report/monthlyError/index.vue b/src/views/report/monthlyError/index.vue index 7d21d72..6ebc7b5 100644 --- a/src/views/report/monthlyError/index.vue +++ b/src/views/report/monthlyError/index.vue @@ -45,6 +45,7 @@ +