From be7c4fd8b6d5e38dfd85d640213e33f643cf4526 Mon Sep 17 00:00:00 2001 From: Daria Golova Date: Fri, 14 Oct 2022 13:44:55 +0300 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=BE=D0=B1=D0=B0=D0=B2=D0=B8=D0=BB?= =?UTF-8?q?=D0=B0=20CalendarSchedule,=20=D0=BF=D1=80=D0=BE=D0=BA=D0=B8?= =?UTF-8?q?=D0=BD=D1=83=D0=BB=D0=B0=20=D0=BF=D1=80=D0=BE=D0=BF=D1=81=D1=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/calendar/TheCalendar.vue | 22 +++----- .../calendar/components/CalendarColumn.vue | 35 ++++++++++++- .../calendar/components/CalendarHeader.vue | 10 ++-- .../calendar/components/CalendarSchedule.vue | 51 +++++++++++++++++++ 4 files changed, 97 insertions(+), 21 deletions(-) create mode 100644 src/pages/calendar/components/CalendarSchedule.vue diff --git a/src/pages/calendar/TheCalendar.vue b/src/pages/calendar/TheCalendar.vue index a08e224..e8b57ec 100644 --- a/src/pages/calendar/TheCalendar.vue +++ b/src/pages/calendar/TheCalendar.vue @@ -1,29 +1,23 @@ @@ -50,6 +79,8 @@ export default { .line border-bottom: 1px solid var(--border-light-grey-color) height: 62px + &:last-child + display: none .middle-line border-top: 1px dashed var(--border-light-grey-color) diff --git a/src/pages/calendar/components/CalendarHeader.vue b/src/pages/calendar/components/CalendarHeader.vue index 930fc1a..7b6b7b7 100644 --- a/src/pages/calendar/components/CalendarHeader.vue +++ b/src/pages/calendar/components/CalendarHeader.vue @@ -17,7 +17,7 @@ export default { name: "CalendarHeader", components: { BaseArrowButton, CalendarLayoutSwitch }, props: { - currentDay: Object, + currentDate: Object, }, data() { return { @@ -26,7 +26,7 @@ export default { }, computed: { dateString() { - let newStr = this.currentDay.format("D MMMM YYYY"); + let newStr = this.currentDate.format("D MMMM YYYY"); return newStr .split(" ") .map((elem, index) => { @@ -38,7 +38,7 @@ export default { }, methods: { changeSelectedLayout(option) { - this.$emit("selectedLayout", option); + this.$emit("selected-layout", option); }, previousHandler() { this.$emit("previous-date"); @@ -48,9 +48,9 @@ export default { }, }, watch: { - currentDay: function () { + currentDate: function () { this.isToday = - this.currentDay.format("DD.MM.YYYY") === moment().format("DD.MM.YYYY"); + this.currentDate.format("DD.MM.YYYY") === moment().format("DD.MM.YYYY"); }, }, }; diff --git a/src/pages/calendar/components/CalendarSchedule.vue b/src/pages/calendar/components/CalendarSchedule.vue new file mode 100644 index 0000000..5c799c1 --- /dev/null +++ b/src/pages/calendar/components/CalendarSchedule.vue @@ -0,0 +1,51 @@ + + + + +