[#397 bis] added participation management on event from thunderbird (#432)

Co-authored-by: Camille Moussu <cmoussu@linagora.com>
This commit is contained in:
Camille Moussu
2026-01-07 11:45:17 +01:00
committed by GitHub
parent e59d878e6c
commit 9ff75056c7
47 changed files with 550 additions and 366 deletions
+14 -17
View File
@@ -24,10 +24,11 @@ import { useI18n } from "twake-i18n";
import { useAppDispatch, useAppSelector } from "../../app/hooks";
import { searchEventsAsync } from "../../features/Search/SearchSlice";
import { setView } from "../../features/Settings/SettingsSlice";
import { userAttendee } from "../../features/User/userDataTypes";
import { userAttendee } from "../../features/User/models/attendee";
import UserSearch from "../Attendees/AttendeeSearch";
import { CalendarItemList } from "../Calendar/CalendarItemList";
import { PeopleSearch, User } from "../Attendees/PeopleSearch";
import { createAttendee } from "../../features/User/models/attendee.mapper";
export default function SearchBar() {
const { t } = useI18n();
@@ -151,14 +152,12 @@ export default function SearchBar() {
if (contacts.length > 0) {
handleSearch("", {
...filters,
organizers: contacts.map((c) => ({
cal_address: c.email || c.displayName || "",
cutype: "INDIVIDUAL",
cn: c.displayName || c.email,
role: "Participant",
rsvp: "TRUE",
partstat: "",
})),
organizers: contacts.map((contact) =>
createAttendee({
cal_address: contact.email,
cn: contact.displayName,
})
),
});
}
};
@@ -334,14 +333,12 @@ export default function SearchBar() {
handleFilterChange("keywords", query);
handleFilterChange(
"organizers",
selectedContacts.map((a: User) => ({
cn: a.displayName,
cal_address: a.email || "",
partstat: "NEEDS-ACTION",
rsvp: "FALSE",
role: "REQ-PARTICIPANT",
cutype: "INDIVIDUAL",
}))
selectedContacts.map((attendee: User) =>
createAttendee({
cal_address: attendee.email,
cn: attendee.displayName,
})
)
);
}}
>