From 0b6fe459e5a0cac9563b3b58d67de846e5867d35 Mon Sep 17 00:00:00 2001 From: iriska-gri <79623434+iriska-gri@users.noreply.github.com> Date: Thu, 6 Jun 2024 14:53:16 +0300 Subject: [PATCH] P-55 --- .../calendar_of_events/BigCalendar.vue | 27 ++- .../calendar_of_events/calendar-create.vue | 36 ++-- .../calendar_of_events/calendar-my.vue | 162 ++++++++++++------ 3 files changed, 147 insertions(+), 78 deletions(-) diff --git a/src/front/src/components/calendar_of_events/BigCalendar.vue b/src/front/src/components/calendar_of_events/BigCalendar.vue index f358503af..1ccb73e4a 100644 --- a/src/front/src/components/calendar_of_events/BigCalendar.vue +++ b/src/front/src/components/calendar_of_events/BigCalendar.vue @@ -44,7 +44,11 @@ - + + + + - + @@ -97,7 +107,6 @@ import CalendarMy from "@/components/calendar_of_events/calendar-my.vue"; import { axiosApiInstance } from "@/utils/axios-api"; import { useAccountStore } from "@/store/AccountStore"; - export default { components: { EventCreate, CalendarMy }, @@ -119,16 +128,16 @@ export default { MyYear.value = year; }; - console.log(accountStore, 'store') - axiosApiInstance .get("api/calendar_of_events/get_calendars/") .then((res) => { - console.log(accountStore.calendar,"lo\d"); - res.data.forEach(e => e.visible = accountStore.calendar.includes(e.id)?false: true) + res.data.forEach( + (e) => + (e.visible = accountStore.calendar.includes(e.id) ? false : true + ) + ); calendarForMy.value = res.data; - - console.log(calendarForMy.value, 'calendarForMy.valuecalendarForMy.value'); + console.log(calendarForMy.value, 'calendarForMy.valuecalendarForMy.valuecalendarForMy.value'); }); const weekendsData = () => { diff --git a/src/front/src/components/calendar_of_events/calendar-create.vue b/src/front/src/components/calendar_of_events/calendar-create.vue index cc16d7bd5..fde59846f 100644 --- a/src/front/src/components/calendar_of_events/calendar-create.vue +++ b/src/front/src/components/calendar_of_events/calendar-create.vue @@ -182,25 +182,23 @@ export default { // confirmation() -// СМЫСЛ ДЕЛАТЬ РЕАКТИВНОСТЬ? - const color = ref([ - "#F44336", - "#E91E63", - "#FF5722", - "#FFC107", - "#FFEB3B", - "#CDDC39", - "#8BC34A", - "#4CAF50", - "#00BCD4", - "#03A9F4", - "#2196F3", - "#3F51B5", - "#673AB7", - "#9C27B0", - "#607D8B", - "#795548", - ]); + const color = [ + "red", + "pink", + "deep-orange", + "amber", + "yellow", + "lime", + "light-green", + "green", + "light-blue", + "blue", + "indigo", + "deep-purple", + "purple", + "blue-grey", + "brown", + ]; const colorPik = (col) => { if (newcalendar.value.cl_color === col) { diff --git a/src/front/src/components/calendar_of_events/calendar-my.vue b/src/front/src/components/calendar_of_events/calendar-my.vue index 9a8af8656..0614b7362 100644 --- a/src/front/src/components/calendar_of_events/calendar-my.vue +++ b/src/front/src/components/calendar_of_events/calendar-my.vue @@ -1,54 +1,74 @@