diff --git a/src/api/calendar/DateClass.ts b/src/api/calendar/DateClass.ts index 847ad05..a755360 100644 --- a/src/api/calendar/DateClass.ts +++ b/src/api/calendar/DateClass.ts @@ -29,6 +29,7 @@ class DateClass { : date.getFullYear() + '-' + (date.getMonth() + 1) + '-' + date.getDate(); } getHolidays(date: number[]) { + console.log(`${date[0]}${clockFactory(date[1])}${clockFactory(date[2])}`,"<==>",config.Holidays.indexOf(`${date[0]}${clockFactory(date[1])}${clockFactory(date[2])}`)) return ( config.Holidays.indexOf(`${date[0]}${clockFactory(date[1])}${clockFactory(date[2])}`) > -1 diff --git a/src/api/calendar/config.ts b/src/api/calendar/config.ts index 81e7b6e..67a63ca 100644 --- a/src/api/calendar/config.ts +++ b/src/api/calendar/config.ts @@ -164,6 +164,36 @@ export default { '20241005', '20241006', '20241007', + '20250101', + '20250128', + '20250129', + '20250130', + '20250131', + '20250201', + '20250202', + '20250203', + '20250204', + '20250404', + '20250405', + '20250406', + '20250501', + '20250502', + '20250503', + '20250504', + '20250505', + '20250531', + '20250601', + '20250602', + '20251001', + '20251002', + '20251002', + '20251003', + '20251004', + '20251005', + '20251006', + '20251007', + '20251008', + '20260101', ], /** * 补休日期 diff --git a/src/components/DesignForm/app/calendar/calendar1/calendarPage.vue b/src/components/DesignForm/app/calendar/calendar1/calendarPage.vue index 957658e..87ddb90 100644 --- a/src/components/DesignForm/app/calendar/calendar1/calendarPage.vue +++ b/src/components/DesignForm/app/calendar/calendar1/calendarPage.vue @@ -3,228 +3,308 @@ @ 时间: 2024-07-12 09:27:42 @ 备注: 日历 --> - - diff --git a/src/views/hr/teams/scheduling.vue b/src/views/hr/teams/scheduling.vue index ae5b6e5..7825081 100644 --- a/src/views/hr/teams/scheduling.vue +++ b/src/views/hr/teams/scheduling.vue @@ -236,6 +236,45 @@ const forwardTime = () => { const goTady = () => { taday.value = DateClass.getCurrent(); + + if (taday.value.length <= 0) { + taday.value = DateClass.getCurrent(); + } + if (curtteDayType.value != 2) { + taday.value = DateClass.moveTime( + taday.value[0], + taday.value[1], + taday.value[2], + curtteDayType.value + ); + } else { + let weekObject = DateClass.moveTime( + taday.value.start[0], + taday.value.start[1], + taday.value.start[2], + curtteDayType.value + ); + taday.value = weekObject; + } + console.log("curtteDayType.value--------->", curtteDayType.value); + nextTick(() => { + switch (curtteDayType.value) { + case 1: + console.log("curtteDayType.value-----1---->", curtteDayType.value); + monthPageRef.value.analyban(); + break; + case 2: + console.log("curtteDayType.value---2------>", curtteDayType.value); + weekPageRef.value.analysisWeek(); + break; + case 3: + console.log("curtteDayType.value---3------>", curtteDayType.value); + dayPageRef.value.analysisDays(); + break; + default: + console.log("curtteDayType.value---4------>", curtteDayType.value); + } + }); }; /** @ 作者: 秦东