[#25] changed loading order + added condition to keep loading screen while loading calendar list

This commit is contained in:
Camille Moussu
2025-07-04 15:27:25 +02:00
parent 1b55f82e45
commit aae4d729f6
11 changed files with 216 additions and 86 deletions
+3 -3
View File
@@ -28,7 +28,7 @@ function EventPopover({
const dispatch = useAppDispatch();
const organizer = useAppSelector((state) => state.user.organiserData);
const calendars = useAppSelector((state) => state.calendars);
const calendars = useAppSelector((state) => state.calendars.list);
const [title, setTitle] = useState("");
const [description, setDescription] = useState("");
const [location, setLocation] = useState("");
@@ -46,8 +46,8 @@ function EventPopover({
const handleSave = () => {
const newEvent: CalendarEvent = {
title,
start: new Date(start || ""),
end: new Date(end || ""),
start: new Date(start ?? ""),
end: new Date(end ?? ""),
uid: Date.now().toString(36),
description,
location,
+7 -7
View File
@@ -40,22 +40,22 @@ export function parseCalendarEvent(
break;
case "organizer":
event.organizer = {
cn: params?.cn || "",
cn: params?.cn ?? "",
cal_address: value.replace(/^mailto:/, ""),
};
break;
case "attendee":
(event.attendee as userAttendee[]).push({
cn: params?.cn || "",
cn: params?.cn ?? "",
cal_address: value.replace(/^mailto:/, ""),
partstat: params?.partstat || "",
rsvp: params?.rsvp || "",
role: params?.role || "",
cutype: params?.cutype || "",
partstat: params?.partstat ?? "",
rsvp: params?.rsvp ?? "",
role: params?.role ?? "",
cutype: params?.cutype ?? "",
});
break;
case "dtstamp":
event.stamp = new Date(value);
event.stamp = value;
break;
case "sequence":
event.sequence = Number(value);