diff --git a/src/views/attendance/editSpecialDay.vue b/src/views/attendance/editSpecialDay.vue index 2365864..1a3b5ea 100644 --- a/src/views/attendance/editSpecialDay.vue +++ b/src/views/attendance/editSpecialDay.vue @@ -13,6 +13,7 @@ @@ -24,6 +25,7 @@ @@ -53,6 +55,12 @@ name: 'EditSpecialDay', data() { return { + beginDateOptions: { + disabledDate: this.disabledBeginDate + }, + endDateOptions: { + disabledDate: this.disabledEndDate + }, dialogFormVisible: false, // 对话框是否显示 dialogStatus: '', // 对话框类型:create,update specialDayForm: { @@ -102,6 +110,16 @@ this.isEditMode = true } }, + disabledBeginDate(time) { + if (this.specialDayForm.endDate !== '') { + return time.getTime() > new Date(this.specialDayForm.endDate) + } + }, + disabledEndDate(time) { + if (this.specialDayForm.beginDate !== '') { + return time.getTime() < new Date(this.specialDayForm.beginDate + ' 00:00:00') + } + }, // 重置表单 resetForm() { this.specialDayForm = { diff --git a/src/views/attendance/editSpecialDay.vue b/src/views/attendance/editSpecialDay.vue index 2365864..1a3b5ea 100644 --- a/src/views/attendance/editSpecialDay.vue +++ b/src/views/attendance/editSpecialDay.vue @@ -13,6 +13,7 @@ @@ -24,6 +25,7 @@ @@ -53,6 +55,12 @@ name: 'EditSpecialDay', data() { return { + beginDateOptions: { + disabledDate: this.disabledBeginDate + }, + endDateOptions: { + disabledDate: this.disabledEndDate + }, dialogFormVisible: false, // 对话框是否显示 dialogStatus: '', // 对话框类型:create,update specialDayForm: { @@ -102,6 +110,16 @@ this.isEditMode = true } }, + disabledBeginDate(time) { + if (this.specialDayForm.endDate !== '') { + return time.getTime() > new Date(this.specialDayForm.endDate) + } + }, + disabledEndDate(time) { + if (this.specialDayForm.beginDate !== '') { + return time.getTime() < new Date(this.specialDayForm.beginDate + ' 00:00:00') + } + }, // 重置表单 resetForm() { this.specialDayForm = { diff --git a/src/views/attendance/makeReport.vue b/src/views/attendance/makeReport.vue index 5f423d1..7a0baae 100644 --- a/src/views/attendance/makeReport.vue +++ b/src/views/attendance/makeReport.vue @@ -63,6 +63,7 @@ makeReport(this.form).then(response => { loading.close() downloadFile(response.data, '考勤报表') + this.$message.success('生成报表成功') }).catch((res) => { loading.close() }) diff --git a/src/views/attendance/editSpecialDay.vue b/src/views/attendance/editSpecialDay.vue index 2365864..1a3b5ea 100644 --- a/src/views/attendance/editSpecialDay.vue +++ b/src/views/attendance/editSpecialDay.vue @@ -13,6 +13,7 @@ @@ -24,6 +25,7 @@ @@ -53,6 +55,12 @@ name: 'EditSpecialDay', data() { return { + beginDateOptions: { + disabledDate: this.disabledBeginDate + }, + endDateOptions: { + disabledDate: this.disabledEndDate + }, dialogFormVisible: false, // 对话框是否显示 dialogStatus: '', // 对话框类型:create,update specialDayForm: { @@ -102,6 +110,16 @@ this.isEditMode = true } }, + disabledBeginDate(time) { + if (this.specialDayForm.endDate !== '') { + return time.getTime() > new Date(this.specialDayForm.endDate) + } + }, + disabledEndDate(time) { + if (this.specialDayForm.beginDate !== '') { + return time.getTime() < new Date(this.specialDayForm.beginDate + ' 00:00:00') + } + }, // 重置表单 resetForm() { this.specialDayForm = { diff --git a/src/views/attendance/makeReport.vue b/src/views/attendance/makeReport.vue index 5f423d1..7a0baae 100644 --- a/src/views/attendance/makeReport.vue +++ b/src/views/attendance/makeReport.vue @@ -63,6 +63,7 @@ makeReport(this.form).then(response => { loading.close() downloadFile(response.data, '考勤报表') + this.$message.success('生成报表成功') }).catch((res) => { loading.close() }) diff --git a/src/views/query/listRecord.vue b/src/views/query/listRecord.vue index 6f9220e..9e731c6 100644 --- a/src/views/query/listRecord.vue +++ b/src/views/query/listRecord.vue @@ -19,7 +19,7 @@ - + import selectTree from '@/components/SelectTree/singleSelect' -import { getRecordList, getDoorSourceList, getDeviceSourceList, getDeviceLabelList ,exportRecords } from '@/api/query' +import { getRecordList, getDoorSourceList, getDeviceLabelList, exportRecords } from '@/api/query' import DownloadTemplate from '@/components/DownloadTemplate' import DeptSelect from '@/components/DeptSelect/index' import { downloadFile } from '@/utils/downloadUtils'