Implement full-day events #3
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "agroudiev/fullday"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #1
Implements events where participants need to select the full day instead of specific hours.
Backend:
is_fulldayfield forEvent, etcFrontend:
fullday-DDMMYYYYformat for serialized cell namesis_fulldayproperty fc0950edf0is_fulldayin payload event response f405c91671En y repensant, il faudrait peut-être désactiver le choix de la timezone sur la page de sélection de disponibilité pour éviter la confusion
Edit: done
Il faut penser à bien rentrer dans le shell nix pour avoir les hooks de pre-push qui tournent quand tu pousses ton code, le formatage n'est pas bon en particulier
@ -220,6 +221,7 @@ impl From<event::Model> for Event {visited_at: value.visited_at.and_utc(),times: serde_json::from_value(value.times).unwrap_or(vec![]),timezone: value.timezone,is_fullday: value.is_fullday,Il va y avoir une migration à créer avec
sea-orm-cli migrate generate add_fullday_eventlancé danssrc/api/adaptors/sql/src@ -38,3 +38,2 @@const expandedTimes = useMemo(() => expandTimes(event?.times ?? []),[event?.times],() => expandTimes(event?.times ?? [], event?.is_fullday ?? false),!!event?.is_fulldayplutôt@ -207,6 +208,7 @@ const EventAvailabilities = ({ event }: EventAvailabilitiesProps) => {times={expandedTimes}people={people}table={table}isFullday={event?.is_fullday ?? false}Bof, il vaut mieux déclarer
isFullDayenboolean | undefineddans le composant@ -1,3 +1,5 @@import { is } from "zod/v4/locales";C'est inutilisé ?
@ -15,6 +15,7 @@ interface AvailabilityEditorProps {eventId?: string;times: string[];timezone: string;isFullday: boolean;isFullDay?: boolean@ -116,0 +108,4 @@<divclassName={makeClass(viewerStyles.timeLabels,isFullday && viewerStyles.timeLabelsFullday,Cette classe n'existe pas, y'a une typo maybe ?
Ah oui, c’est une ancienne classe que j’ai refactor
@ -29,32 +32,41 @@ export const calculateTable = ({const isSpecificDates = times[0]?.length === 13;À modifier, les dates ne s'affichent pas sur la vue journée entière
La migration sql va pas marcher actuellement, je te fais un fix demain
@ -15,6 +15,7 @@ interface AvailabilityEditorProps {eventId?: string;times: string[];timezone: string;isFullday?: boolean | undefined;Avec le
?y'a pas besoin de mettre le| undefined@ -23,12 +23,14 @@ import { useLocale, useTranslations } from "next-intl";interface AvailabilityViewerProps {times: string[];isFullday: boolean | undefined;nit:
isFullday?: boolean@ -0,0 +33,4 @@}: TimeFieldProps<TValues>) => {const t = useTranslations("Home");const [type, setType] = useState<"timeRange" | "fullday">("timeRange");nit: Je mettrais
kindplutôt quetypevu qu'en typescript c'est un keywordView command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.