From de87091b5883efdb952416d40d63c79373e9f727 Mon Sep 17 00:00:00 2001 From: Frank Bille-Stauner Date: Sat, 16 Nov 2024 20:49:40 +0100 Subject: [PATCH] Add create event (#26) --- src/admin/event/new/AdminCreateEvent.tsx | 53 ++++++++++++++++ src/admin/event/new/CreateEvent.graphql | 5 ++ src/admin/event/new/adminCreateEventAction.ts | 34 +++++++++++ src/admin/event/new/index.ts | 2 + src/admin/location/AdminLocation.tsx | 39 ++++++++---- .../location/AdminLocationEventTable.tsx | 5 +- src/admin/location/AdminLocationTable.tsx | 2 +- src/components/JidCodeInput.tsx | 18 +++++- src/event/AuthenticatedButtons.tsx | 2 +- src/event/GetEvent.graphql | 1 + src/gql/__autogenerated/gql.ts | 9 ++- src/gql/__autogenerated/graphql.ts | 12 +++- src/gql/serverErrors.ts | 3 + src/i18n/locales/da.po | 60 ++++++++++++++----- src/i18n/locales/da.ts | 2 +- src/i18n/locales/en.po | 56 +++++++++++++---- src/i18n/locales/en.ts | 2 +- src/router.tsx | 8 ++- 18 files changed, 261 insertions(+), 52 deletions(-) create mode 100644 src/admin/event/new/AdminCreateEvent.tsx create mode 100644 src/admin/event/new/CreateEvent.graphql create mode 100644 src/admin/event/new/adminCreateEventAction.ts create mode 100644 src/admin/event/new/index.ts diff --git a/src/admin/event/new/AdminCreateEvent.tsx b/src/admin/event/new/AdminCreateEvent.tsx new file mode 100644 index 0000000..d163fc1 --- /dev/null +++ b/src/admin/event/new/AdminCreateEvent.tsx @@ -0,0 +1,53 @@ +import {RouterDialog, RouterDialogAction} from "../../../components/RouterDialog.tsx"; +import {t, Trans} from "@lingui/macro"; +import {useActionData} from "react-router-dom"; +import {OptionalErrorResponseBody} from "../../../utils/responses.ts"; +import {translateErrorCode} from "../../../gql"; +import {JidCodeInput} from "../../../components/JidCodeInput.tsx"; +import {useState} from "react"; + +export const AdminCreateEvent = () => { + const [jidCode, setJidCode] = useState(""); + + const actionData = useActionData() as OptionalErrorResponseBody; + + const error = actionData?.errorCode + ? translateErrorCode(actionData.errorCode) + : actionData?.error; + + const dialogActions: RouterDialogAction[] = [{ + label: Cancel, + type: "button", + callback: callback => callback.cancel(), + }, { + label: Create, + type: "submit", + name: "createButton", + classNames: "btn-primary", + }]; + + return ( + Add event} actions={dialogActions}> + + + {error &&
+ {error} +
} +
+ ) +} \ No newline at end of file diff --git a/src/admin/event/new/CreateEvent.graphql b/src/admin/event/new/CreateEvent.graphql new file mode 100644 index 0000000..9ebe7d3 --- /dev/null +++ b/src/admin/event/new/CreateEvent.graphql @@ -0,0 +1,5 @@ +mutation CreateEvent($input: CreateEventInput!) { + createEvent(input: $input) { + id + } +} diff --git a/src/admin/event/new/adminCreateEventAction.ts b/src/admin/event/new/adminCreateEventAction.ts new file mode 100644 index 0000000..5ce4f27 --- /dev/null +++ b/src/admin/event/new/adminCreateEventAction.ts @@ -0,0 +1,34 @@ +import {ActionFunctionArgs, replace} from "react-router-dom"; +import {client, CreateEventDocument, hasErrorCode, ServerErrorCode} from "../../../gql"; +import {badRequest} from "../../../utils/responses.ts"; + +export const adminCreateEventAction = async ({params, request}: ActionFunctionArgs) => { + const formData = await request.formData(); + + if (formData.has("createButton") && formData.get("code") && formData.get("year")) { + const locationId = params.locationId as string; + const code = formData.get("code") as string; + const year = +(formData.get("year") as string); + + const result = await client.mutation(CreateEventDocument, { + input: { + locationId, + code, + year, + active: false, + } + }); + + if (result.error) { + if (hasErrorCode(result.error, ServerErrorCode.EVENT_CODE_AND_YEAR_NOT_AVAILABLE)) { + return badRequest({errorCode: ServerErrorCode.EVENT_CODE_AND_YEAR_NOT_AVAILABLE}); + } else { + return badRequest({error: result.error.message}); + } + } + + return replace(`/admin/locations/$\{params.locationId}/events/${result.data?.createEvent?.id}`); + } + + return replace(`/admin/locations/${params.locationId}`); +} diff --git a/src/admin/event/new/index.ts b/src/admin/event/new/index.ts new file mode 100644 index 0000000..eec322c --- /dev/null +++ b/src/admin/event/new/index.ts @@ -0,0 +1,2 @@ +export * from "./adminCreateEventAction.ts"; +export * from "./AdminCreateEvent.tsx"; \ No newline at end of file diff --git a/src/admin/location/AdminLocation.tsx b/src/admin/location/AdminLocation.tsx index 93561f2..b1b8600 100644 --- a/src/admin/location/AdminLocation.tsx +++ b/src/admin/location/AdminLocation.tsx @@ -1,6 +1,7 @@ import {useEffect} from "react"; -import {Trans} from "@lingui/macro"; -import {useLoaderData} from "react-router-dom"; +import {t, Trans} from "@lingui/macro"; +import {Link, Outlet, useLoaderData} from "react-router-dom"; +import {PlusIcon} from "@heroicons/react/24/solid"; import {Dashboard} from "../../components/Dashboard.tsx"; import {GetAdminLocationQuery} from "../../gql"; @@ -19,15 +20,29 @@ export const AdminLocation = () => { }, [setNavigationCenter, setNavigationButtons, loaderData]); return ( - Events, - content: , - span: 2, - }, { - key: "owners", - title: Owners, - content: , - }]}/> + <> + Events, + content: , + span: 2, + }, { + key: "owners", + title: Owners, + content: , + }]}/> + +
+
+ + + +
+
+ + + ) } \ No newline at end of file diff --git a/src/admin/location/AdminLocationEventTable.tsx b/src/admin/location/AdminLocationEventTable.tsx index 04ae0d3..62600eb 100644 --- a/src/admin/location/AdminLocationEventTable.tsx +++ b/src/admin/location/AdminLocationEventTable.tsx @@ -7,10 +7,11 @@ import {Link} from "react-router-dom"; import {RocketLaunchIcon, StopIcon} from "@heroicons/react/16/solid"; type AdminLocationEventTableProps = { + locationId: string getAdminLocationEventsFragment: FragmentType } -export const AdminLocationEventTable = ({getAdminLocationEventsFragment}: AdminLocationEventTableProps) => { +export const AdminLocationEventTable = ({locationId, getAdminLocationEventsFragment}: AdminLocationEventTableProps) => { const getAdminLocationEvents = useFragment(GetAdminLocationEventsFragmentDoc, getAdminLocationEventsFragment); const events = getAdminLocationEvents.events!; @@ -21,7 +22,7 @@ export const AdminLocationEventTable = ({getAdminLocationEventsFragment}: AdminL key: "year", header: Year, getValue: event => ( - {event.year} + {event.year} ), sort: numberSort(event => event.year), sortAscendingDefault: false, diff --git a/src/admin/location/AdminLocationTable.tsx b/src/admin/location/AdminLocationTable.tsx index e600103..1017aef 100644 --- a/src/admin/location/AdminLocationTable.tsx +++ b/src/admin/location/AdminLocationTable.tsx @@ -35,7 +35,7 @@ export const AdminLocationTable = ({getAdminLocationsFragment}: AdminLocationTab header: Latest Event, getValue: location => ( location.latestEvent && - {location.latestEvent.year} + {location.latestEvent.year} ), sort: numberSort(location => location.latestEvent ? location.latestEvent.year : 0), sortAscendingDefault: false, diff --git a/src/components/JidCodeInput.tsx b/src/components/JidCodeInput.tsx index 0f380b7..781b8d3 100644 --- a/src/components/JidCodeInput.tsx +++ b/src/components/JidCodeInput.tsx @@ -7,6 +7,8 @@ type JidCodeInputProps = { onValidJidCode: (validJidCode: string | null) => void jidCode: string setJidCode: (jidCode: string) => void + style?: "form" | "large" + name?: string } export const jidCodeRegex = /[1-7]([A-Z]{2})[0-9]{2}[A-Z]/ @@ -28,7 +30,7 @@ const maskitoOptions: MaskitoOptions = { ], } -export const JidCodeInput = ({onValidJidCode, jidCode, setJidCode}: JidCodeInputProps) => { +export const JidCodeInput = ({onValidJidCode, jidCode, setJidCode, style, name}: JidCodeInputProps) => { const inputRef = useMaskito({ options: maskitoOptions, @@ -48,6 +50,17 @@ export const JidCodeInput = ({onValidJidCode, jidCode, setJidCode}: JidCodeInput } } + const styleClasses = () => { + switch (style) { + case "form": + return ""; + case "large": + return `input-lg tracking-widest font-mono text-center${validJidCode ? ' input-success' : ''}`; + default: + return ""; + } + } + return ( ); } diff --git a/src/event/AuthenticatedButtons.tsx b/src/event/AuthenticatedButtons.tsx index d38a3e7..ba7f557 100644 --- a/src/event/AuthenticatedButtons.tsx +++ b/src/event/AuthenticatedButtons.tsx @@ -17,7 +17,7 @@ export const AuthenticatedButtons = ({data, reloadEvent}: AuthenticatedButtonsPr if (isAdminAuthenticated(data)) { dropdownLinks.push( - + Admin ); diff --git a/src/event/GetEvent.graphql b/src/event/GetEvent.graphql index 7000fa1..26c1c7d 100644 --- a/src/event/GetEvent.graphql +++ b/src/event/GetEvent.graphql @@ -12,6 +12,7 @@ query GetEvent($code: String!) { event(code: $code) { id location { + id name owners { id diff --git a/src/gql/__autogenerated/gql.ts b/src/gql/__autogenerated/gql.ts index 6e1bdca..b2a7492 100644 --- a/src/gql/__autogenerated/gql.ts +++ b/src/gql/__autogenerated/gql.ts @@ -16,6 +16,7 @@ import { TypedDocumentNode as DocumentNode } from '@graphql-typed-document-node/ const documents = { "query Admin {\n authenticatedAdmin {\n id\n name\n }\n ...GetFooter\n}": types.AdminDocument, "query GetAdminEvent($eventId: ID!) {\n eventById(eventId: $eventId) {\n id\n code {\n value\n }\n year\n jidCodeStats {\n count\n uniqueCount\n uniqueCountries\n }\n location {\n id\n name\n }\n }\n}": types.GetAdminEventDocument, + "mutation CreateEvent($input: CreateEventInput!) {\n createEvent(input: $input) {\n id\n }\n}": types.CreateEventDocument, "query GetAdminLocation($locationId: ID!) {\n location(locationId: $locationId) {\n id\n name\n ...GetAdminLocationEvents\n ...GetAdminLocationOwners\n }\n}": types.GetAdminLocationDocument, "fragment GetAdminLocationEvents on Location {\n events {\n id\n code {\n value\n }\n year\n active\n jidCodeStats {\n count\n uniqueCount\n uniqueCountryCount\n }\n participants {\n id\n }\n }\n}": types.GetAdminLocationEventsFragmentDoc, "fragment GetAdminLocationOwners on Location {\n owners {\n id\n name\n }\n}": types.GetAdminLocationOwnersFragmentDoc, @@ -28,7 +29,7 @@ const documents = { "mutation CreateAdmin($input: CreateAdmin!) {\n createAdmin(input: $input) {\n id\n }\n}": types.CreateAdminDocument, "fragment GetFooter on Query {\n serverVersion\n}": types.GetFooterFragmentDoc, "subscription EventSubscription($eventId: ID!) {\n eventUpdated(eventId: $eventId)\n}": types.EventSubscriptionDocument, - "query GetEvent($code: String!) {\n authenticatedParticipant {\n id\n name\n event {\n id\n }\n }\n authenticatedAdmin {\n id\n }\n event(code: $code) {\n id\n location {\n name\n owners {\n id\n }\n }\n code {\n value\n }\n year\n jidCodeStats {\n count\n uniqueCount\n uniqueCountryCount\n }\n ...Countries\n ...Participants\n ...StatBar\n }\n ...GetFooter\n}": types.GetEventDocument, + "query GetEvent($code: String!) {\n authenticatedParticipant {\n id\n name\n event {\n id\n }\n }\n authenticatedAdmin {\n id\n }\n event(code: $code) {\n id\n location {\n id\n name\n owners {\n id\n }\n }\n code {\n value\n }\n year\n jidCodeStats {\n count\n uniqueCount\n uniqueCountryCount\n }\n ...Countries\n ...Participants\n ...StatBar\n }\n ...GetFooter\n}": types.GetEventDocument, "mutation RegisterJidCode($input: RegisterFoundJidCode!) {\n registerFoundJidCode(input: $input) {\n id\n }\n}": types.RegisterJidCodeDocument, "fragment Countries on Event {\n jidCodeStats {\n countryStats {\n country\n uniqueCount\n }\n }\n}": types.CountriesFragmentDoc, "mutation AuthenticateParticipant($eventId: ID!, $name: String!, $pinCode: String!) {\n authenticateParticipant(eventId: $eventId, name: $name, pinCode: $pinCode)\n}": types.AuthenticateParticipantDocument, @@ -61,6 +62,10 @@ export function graphql(source: "query Admin {\n authenticatedAdmin {\n id\n * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. */ export function graphql(source: "query GetAdminEvent($eventId: ID!) {\n eventById(eventId: $eventId) {\n id\n code {\n value\n }\n year\n jidCodeStats {\n count\n uniqueCount\n uniqueCountries\n }\n location {\n id\n name\n }\n }\n}"): (typeof documents)["query GetAdminEvent($eventId: ID!) {\n eventById(eventId: $eventId) {\n id\n code {\n value\n }\n year\n jidCodeStats {\n count\n uniqueCount\n uniqueCountries\n }\n location {\n id\n name\n }\n }\n}"]; +/** + * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. + */ +export function graphql(source: "mutation CreateEvent($input: CreateEventInput!) {\n createEvent(input: $input) {\n id\n }\n}"): (typeof documents)["mutation CreateEvent($input: CreateEventInput!) {\n createEvent(input: $input) {\n id\n }\n}"]; /** * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. */ @@ -112,7 +117,7 @@ export function graphql(source: "subscription EventSubscription($eventId: ID!) { /** * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. */ -export function graphql(source: "query GetEvent($code: String!) {\n authenticatedParticipant {\n id\n name\n event {\n id\n }\n }\n authenticatedAdmin {\n id\n }\n event(code: $code) {\n id\n location {\n name\n owners {\n id\n }\n }\n code {\n value\n }\n year\n jidCodeStats {\n count\n uniqueCount\n uniqueCountryCount\n }\n ...Countries\n ...Participants\n ...StatBar\n }\n ...GetFooter\n}"): (typeof documents)["query GetEvent($code: String!) {\n authenticatedParticipant {\n id\n name\n event {\n id\n }\n }\n authenticatedAdmin {\n id\n }\n event(code: $code) {\n id\n location {\n name\n owners {\n id\n }\n }\n code {\n value\n }\n year\n jidCodeStats {\n count\n uniqueCount\n uniqueCountryCount\n }\n ...Countries\n ...Participants\n ...StatBar\n }\n ...GetFooter\n}"]; +export function graphql(source: "query GetEvent($code: String!) {\n authenticatedParticipant {\n id\n name\n event {\n id\n }\n }\n authenticatedAdmin {\n id\n }\n event(code: $code) {\n id\n location {\n id\n name\n owners {\n id\n }\n }\n code {\n value\n }\n year\n jidCodeStats {\n count\n uniqueCount\n uniqueCountryCount\n }\n ...Countries\n ...Participants\n ...StatBar\n }\n ...GetFooter\n}"): (typeof documents)["query GetEvent($code: String!) {\n authenticatedParticipant {\n id\n name\n event {\n id\n }\n }\n authenticatedAdmin {\n id\n }\n event(code: $code) {\n id\n location {\n id\n name\n owners {\n id\n }\n }\n code {\n value\n }\n year\n jidCodeStats {\n count\n uniqueCount\n uniqueCountryCount\n }\n ...Countries\n ...Participants\n ...StatBar\n }\n ...GetFooter\n}"]; /** * The graphql function is used to parse GraphQL queries into a document that can be used by GraphQL clients. */ diff --git a/src/gql/__autogenerated/graphql.ts b/src/gql/__autogenerated/graphql.ts index f3282fc..89963f8 100644 --- a/src/gql/__autogenerated/graphql.ts +++ b/src/gql/__autogenerated/graphql.ts @@ -77,6 +77,13 @@ export type GetAdminEventQueryVariables = Exact<{ export type GetAdminEventQuery = { __typename?: 'Query', eventById?: { __typename?: 'Event', id: string, year: number, code: { __typename?: 'JidCode', value: string }, jidCodeStats: { __typename?: 'JidCodeStats', count: number, uniqueCount: number, uniqueCountries: Array }, location: { __typename?: 'Location', id: string, name: string } } | null }; +export type CreateEventMutationVariables = Exact<{ + input: CreateEventInput; +}>; + + +export type CreateEventMutation = { __typename?: 'Mutation', createEvent?: { __typename?: 'Event', id: string } | null }; + export type GetAdminLocationQueryVariables = Exact<{ locationId: Scalars['ID']['input']; }>; @@ -155,7 +162,7 @@ export type GetEventQueryVariables = Exact<{ export type GetEventQuery = ( { __typename?: 'Query', authenticatedParticipant?: { __typename?: 'Participant', id: string, name: string, event: { __typename?: 'Event', id: string } } | null, authenticatedAdmin?: { __typename?: 'Admin', id: string } | null, event?: ( - { __typename?: 'Event', id: string, year: number, location: { __typename?: 'Location', name: string, owners?: Array<{ __typename?: 'Admin', id: string }> | null }, code: { __typename?: 'JidCode', value: string }, jidCodeStats: { __typename?: 'JidCodeStats', count: number, uniqueCount: number, uniqueCountryCount: number } } + { __typename?: 'Event', id: string, year: number, location: { __typename?: 'Location', id: string, name: string, owners?: Array<{ __typename?: 'Admin', id: string }> | null }, code: { __typename?: 'JidCode', value: string }, jidCodeStats: { __typename?: 'JidCodeStats', count: number, uniqueCount: number, uniqueCountryCount: number } } & { ' $fragmentRefs'?: { 'CountriesFragment': CountriesFragment;'ParticipantsFragment': ParticipantsFragment;'StatBarFragment': StatBarFragment } } ) | null } & { ' $fragmentRefs'?: { 'GetFooterFragment': GetFooterFragment } } @@ -214,6 +221,7 @@ export const ParticipantsFragmentDoc = {"kind":"Document","definitions":[{"kind" export const StatBarFragmentDoc = {"kind":"Document","definitions":[{"kind":"FragmentDefinition","name":{"kind":"Name","value":"StatBar"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Event"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"participants"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"count"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCountryCount"}}]}}]}}]} as unknown as DocumentNode; export const AdminDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"Admin"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"authenticatedAdmin"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}}]}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"GetFooter"}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"GetFooter"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Query"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"serverVersion"}}]}}]} as unknown as DocumentNode; export const GetAdminEventDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"GetAdminEvent"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"eventId"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"ID"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"eventById"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"eventId"},"value":{"kind":"Variable","name":{"kind":"Name","value":"eventId"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"code"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"value"}}]}},{"kind":"Field","name":{"kind":"Name","value":"year"}},{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"count"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCount"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCountries"}}]}},{"kind":"Field","name":{"kind":"Name","value":"location"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}}]}}]}}]}}]} as unknown as DocumentNode; +export const CreateEventDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"mutation","name":{"kind":"Name","value":"CreateEvent"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"input"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"CreateEventInput"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"createEvent"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"input"},"value":{"kind":"Variable","name":{"kind":"Name","value":"input"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]} as unknown as DocumentNode; export const GetAdminLocationDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"GetAdminLocation"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"locationId"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"ID"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"location"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"locationId"},"value":{"kind":"Variable","name":{"kind":"Name","value":"locationId"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"GetAdminLocationEvents"}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"GetAdminLocationOwners"}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"GetAdminLocationEvents"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Location"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"events"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"code"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"value"}}]}},{"kind":"Field","name":{"kind":"Name","value":"year"}},{"kind":"Field","name":{"kind":"Name","value":"active"}},{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"count"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCount"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCountryCount"}}]}},{"kind":"Field","name":{"kind":"Name","value":"participants"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"GetAdminLocationOwners"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Location"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"owners"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}}]}}]}}]} as unknown as DocumentNode; export const CreateLocationDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"mutation","name":{"kind":"Name","value":"CreateLocation"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"input"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"CreateLocationInput"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"createLocation"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"input"},"value":{"kind":"Variable","name":{"kind":"Name","value":"input"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]} as unknown as DocumentNode; export const GetAdminLoginDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"GetAdminLogin"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"authenticatedAdmin"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"GetFooter"}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"GetFooter"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Query"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"serverVersion"}}]}}]} as unknown as DocumentNode; @@ -222,7 +230,7 @@ export const AdminOverviewDocument = {"kind":"Document","definitions":[{"kind":" export const GetAdminRegisterDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"GetAdminRegister"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"authenticatedAdmin"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"GetFooter"}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"GetFooter"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Query"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"serverVersion"}}]}}]} as unknown as DocumentNode; export const CreateAdminDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"mutation","name":{"kind":"Name","value":"CreateAdmin"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"input"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"CreateAdmin"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"createAdmin"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"input"},"value":{"kind":"Variable","name":{"kind":"Name","value":"input"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]} as unknown as DocumentNode; export const EventSubscriptionDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"subscription","name":{"kind":"Name","value":"EventSubscription"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"eventId"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"ID"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"eventUpdated"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"eventId"},"value":{"kind":"Variable","name":{"kind":"Name","value":"eventId"}}}]}]}}]} as unknown as DocumentNode; -export const GetEventDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"GetEvent"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"code"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"authenticatedParticipant"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"event"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"authenticatedAdmin"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"event"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"code"},"value":{"kind":"Variable","name":{"kind":"Name","value":"code"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"location"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"owners"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"code"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"value"}}]}},{"kind":"Field","name":{"kind":"Name","value":"year"}},{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"count"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCount"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCountryCount"}}]}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"Countries"}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"Participants"}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"StatBar"}}]}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"GetFooter"}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"Countries"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Event"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"countryStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"country"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCount"}}]}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"Participants"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Event"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"participants"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"uniqueCount"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCountryCount"}}]}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"StatBar"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Event"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"participants"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"count"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCountryCount"}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"GetFooter"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Query"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"serverVersion"}}]}}]} as unknown as DocumentNode; +export const GetEventDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"query","name":{"kind":"Name","value":"GetEvent"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"code"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"authenticatedParticipant"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"event"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"authenticatedAdmin"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"event"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"code"},"value":{"kind":"Variable","name":{"kind":"Name","value":"code"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"location"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"owners"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}},{"kind":"Field","name":{"kind":"Name","value":"code"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"value"}}]}},{"kind":"Field","name":{"kind":"Name","value":"year"}},{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"count"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCount"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCountryCount"}}]}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"Countries"}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"Participants"}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"StatBar"}}]}},{"kind":"FragmentSpread","name":{"kind":"Name","value":"GetFooter"}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"Countries"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Event"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"countryStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"country"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCount"}}]}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"Participants"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Event"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"participants"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"uniqueCount"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCountryCount"}}]}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"StatBar"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Event"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"participants"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}},{"kind":"Field","name":{"kind":"Name","value":"jidCodeStats"},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"count"}},{"kind":"Field","name":{"kind":"Name","value":"uniqueCountryCount"}}]}}]}},{"kind":"FragmentDefinition","name":{"kind":"Name","value":"GetFooter"},"typeCondition":{"kind":"NamedType","name":{"kind":"Name","value":"Query"}},"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"serverVersion"}}]}}]} as unknown as DocumentNode; export const RegisterJidCodeDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"mutation","name":{"kind":"Name","value":"RegisterJidCode"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"input"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"RegisterFoundJidCode"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"registerFoundJidCode"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"input"},"value":{"kind":"Variable","name":{"kind":"Name","value":"input"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}}]}}]}}]} as unknown as DocumentNode; export const AuthenticateParticipantDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"mutation","name":{"kind":"Name","value":"AuthenticateParticipant"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"eventId"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"ID"}}}},{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"name"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}},{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"pinCode"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"String"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"authenticateParticipant"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"eventId"},"value":{"kind":"Variable","name":{"kind":"Name","value":"eventId"}}},{"kind":"Argument","name":{"kind":"Name","value":"name"},"value":{"kind":"Variable","name":{"kind":"Name","value":"name"}}},{"kind":"Argument","name":{"kind":"Name","value":"pinCode"},"value":{"kind":"Variable","name":{"kind":"Name","value":"pinCode"}}}]}]}}]} as unknown as DocumentNode; export const CreateParticipantDocument = {"kind":"Document","definitions":[{"kind":"OperationDefinition","operation":"mutation","name":{"kind":"Name","value":"CreateParticipant"},"variableDefinitions":[{"kind":"VariableDefinition","variable":{"kind":"Variable","name":{"kind":"Name","value":"input"}},"type":{"kind":"NonNullType","type":{"kind":"NamedType","name":{"kind":"Name","value":"CreateParticipantInput"}}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"createParticipant"},"arguments":[{"kind":"Argument","name":{"kind":"Name","value":"input"},"value":{"kind":"Variable","name":{"kind":"Name","value":"input"}}}],"selectionSet":{"kind":"SelectionSet","selections":[{"kind":"Field","name":{"kind":"Name","value":"id"}},{"kind":"Field","name":{"kind":"Name","value":"name"}},{"kind":"Field","name":{"kind":"Name","value":"pinCode"}}]}}]}}]} as unknown as DocumentNode; diff --git a/src/gql/serverErrors.ts b/src/gql/serverErrors.ts index 73200ce..04e6fd0 100644 --- a/src/gql/serverErrors.ts +++ b/src/gql/serverErrors.ts @@ -3,6 +3,7 @@ import {t} from "@lingui/macro"; export enum ServerErrorCode { PARTICIPANT_NAME_NOT_AVAILABLE = 1, + EVENT_CODE_AND_YEAR_NOT_AVAILABLE = 7, ADMIN_AUTHENTICATION_FAILED = 8, EMAIL_NOT_AVAILABLE = 10, } @@ -37,6 +38,8 @@ export const translateErrorCode = (errorCode: ServerErrorCode) => { switch (errorCode) { case ServerErrorCode.PARTICIPANT_NAME_NOT_AVAILABLE: return t`Participant name already taken`; + case ServerErrorCode.EVENT_CODE_AND_YEAR_NOT_AVAILABLE: + return t`An event is already created with the JID code and year`; case ServerErrorCode.ADMIN_AUTHENTICATION_FAILED: return t`Authentication failed`; case ServerErrorCode.EMAIL_NOT_AVAILABLE: diff --git a/src/i18n/locales/da.po b/src/i18n/locales/da.po index 4822809..5319838 100644 --- a/src/i18n/locales/da.po +++ b/src/i18n/locales/da.po @@ -1,23 +1,23 @@ msgid "" msgstr "" -"POT-Creation-Date: 2024-11-13 23:35+0100\n" +"POT-Creation-Date: 2024-11-16 20:43+0100\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=utf-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Generator: @lingui/cli\n" "Language: da\n" -#: src/admin/location/AdminLocationEventTable.tsx:59 +#: src/admin/location/AdminLocationEventTable.tsx:60 msgid "# JID codes" msgstr "# JID koder" -#: src/admin/location/AdminLocationEventTable.tsx:36 -#: src/admin/location/AdminLocationEventTable.tsx:40 +#: src/admin/location/AdminLocationEventTable.tsx:37 #: src/admin/location/AdminLocationEventTable.tsx:41 +#: src/admin/location/AdminLocationEventTable.tsx:42 msgid "Active" msgstr "Aktiv" -#: src/components/JidCodeInput.tsx:58 +#: src/components/JidCodeInput.tsx:72 msgid "Add Code" msgstr "Tilføj kode" @@ -26,6 +26,18 @@ msgstr "Tilføj kode" msgid "Add JID Code" msgstr "Tilføj JID kode" +#: src/admin/event/new/AdminCreateEvent.tsx:30 +#: src/admin/location/AdminLocation.tsx:37 +msgid "Add event" +msgstr "" +"Tilføj arrangement\n" +"" + +#: src/admin/location/new/AdminCreateLocation.tsx:27 +#: src/admin/overview/AdminOverview.tsx:30 +msgid "Add location" +msgstr "Tilføj sted" + #: src/event/AuthenticatedButtons.tsx:21 #: src/landing/Landing.tsx:15 msgid "Admin" @@ -51,6 +63,10 @@ msgstr "Har du allerede en konto? <0>Log ind" msgid "American Samoa" msgstr "Amerikansk Samoa" +#: src/gql/serverErrors.ts:42 +msgid "An event is already created with the JID code and year" +msgstr "Der er allerede oprettet et arrangement for det givne år og JID kode" + #: src/utils/countries.tsx:7 msgid "Andorra" msgstr "Andorra" @@ -87,7 +103,7 @@ msgstr "Australien" msgid "Austria" msgstr "Østrig" -#: src/gql/serverErrors.ts:40 +#: src/gql/serverErrors.ts:44 msgid "Authentication failed" msgstr "Login mislykkedes" @@ -195,6 +211,8 @@ msgstr "Canada" msgid "Canary Islands" msgstr "De Kanariske Øer" +#: src/admin/event/new/AdminCreateEvent.tsx:19 +#: src/admin/location/new/AdminCreateLocation.tsx:16 #: src/event/AddJidCode.tsx:55 #: src/event/join/JoinEvent.tsx:20 msgid "Cancel" @@ -282,6 +300,11 @@ msgstr "Lande" msgid "Country" msgstr "Land" +#: src/admin/event/new/AdminCreateEvent.tsx:23 +#: src/admin/location/new/AdminCreateLocation.tsx:20 +msgid "Create" +msgstr "Opret" + #: src/utils/countries.tsx:199 msgid "Croatia" msgstr "Kroatien" @@ -351,6 +374,10 @@ msgstr "El Salvador" msgid "Email" msgstr "E-mail" +#: src/gql/serverErrors.ts:46 +msgid "Email already associated with account" +msgstr "E-mail er allerede knyttet til en anden konto" + #: src/utils/languages.tsx:8 msgid "English" msgstr "Engelsk" @@ -379,7 +406,7 @@ msgstr "Etiopien" msgid "Event #" msgstr "Arrangement #" -#: src/admin/location/AdminLocation.tsx:24 +#: src/admin/location/AdminLocation.tsx:26 msgid "Events" msgstr "Arrangementer" @@ -536,7 +563,7 @@ msgstr "Italien" msgid "JID Codes" msgstr "JID koder" -#: src/admin/location/AdminLocationEventTable.tsx:30 +#: src/admin/location/AdminLocationEventTable.tsx:31 msgid "JID code" msgstr "JID kode" @@ -630,7 +657,12 @@ msgstr "Liechtenstein" msgid "Lithuania" msgstr "Litauen" -#: src/admin/overview/AdminOverview.tsx:24 +#: src/admin/event/new/AdminCreateEvent.tsx:41 +#: src/admin/location/new/AdminCreateLocation.tsx:30 +msgid "Location name" +msgstr "Stedets navn" + +#: src/admin/overview/AdminOverview.tsx:25 msgid "Locations" msgstr "Steder" @@ -807,8 +839,8 @@ msgstr "Nordmarianerne" msgid "Norway" msgstr "Norge" -#: src/admin/location/AdminLocationEventTable.tsx:44 #: src/admin/location/AdminLocationEventTable.tsx:45 +#: src/admin/location/AdminLocationEventTable.tsx:46 msgid "Not active" msgstr "Ikke aktiv" @@ -816,7 +848,7 @@ msgstr "Ikke aktiv" msgid "Oman" msgstr "Oman" -#: src/admin/location/AdminLocation.tsx:29 +#: src/admin/location/AdminLocation.tsx:32 msgid "Owners" msgstr "Ejere" @@ -844,11 +876,11 @@ msgstr "Papua Ny Guinea" msgid "Paraguay" msgstr "Paraguay" -#: src/gql/serverErrors.ts:38 +#: src/gql/serverErrors.ts:40 msgid "Participant name already taken" msgstr "Deltagerens navn er allerede taget" -#: src/admin/location/AdminLocationEventTable.tsx:53 +#: src/admin/location/AdminLocationEventTable.tsx:54 #: src/event/Event.tsx:60 #: src/event/statbar/EventStatBar.tsx:16 msgid "Participants" @@ -1175,7 +1207,7 @@ msgstr "Vestsahara" msgid "What is your name?" msgstr "Hvad er dit navn?" -#: src/admin/location/AdminLocationEventTable.tsx:22 +#: src/admin/location/AdminLocationEventTable.tsx:23 msgid "Year" msgstr "År" diff --git a/src/i18n/locales/da.ts b/src/i18n/locales/da.ts index 0954f23..4fcc601 100644 --- a/src/i18n/locales/da.ts +++ b/src/i18n/locales/da.ts @@ -1 +1 @@ -/*eslint-disable*/import type{Messages}from"@lingui/core";export const messages=JSON.parse("{\"T6OzMq\":[[\"locationName\"],\" \",[\"eventYear\"]],\"1eHppt\":\"# JID koder\",\"F6pfE9\":\"Aktiv\",\"VbT1oK\":\"Tilføj kode\",\"IYYyC4\":\"Tilføj JID kode\",\"U3pytU\":\"Admin\",\"VFCG/o\":\"Afghanistan\",\"/9JruU\":\"Ålandsøerne\",\"fl/qbv\":\"Albanien\",\"HgfQva\":\"Algeriet\",\"HIsSWr\":\"Har du allerede en konto? <0>Log ind\",\"Xp8e0M\":\"Amerikansk Samoa\",\"i7j+rI\":\"Andorra\",\"fFWMB8\":\"Angola\",\"kRkTOo\":\"Anguilla\",\"hBTNUd\":\"Antigua og Barbuda\",\"n25nMV\":\"Argentina\",\"uImFCC\":\"Armenien\",\"rauLEz\":\"Aruba\",\"QeKGx6\":\"Australien\",\"SNQEUJ\":\"Østrig\",\"htuqBH\":\"Login mislykkedes\",\"R9Khdg\":\"Auto\",\"ntRxPY\":\"Aserbajdsjan\",\"WdBTIc\":\"Bahamas\",\"4zHav4\":\"Bahrain\",\"N6kXss\":\"Bangladesh\",\"56Z8bT\":\"Barbados\",\"Fax4U2\":\"Hviderusland\",\"C9G7k0\":\"Belgien\",\"6cyLjb\":\"Belize\",\"nkEPgb\":\"Benin\",\"V+Y2mD\":\"Bermuda\",\"GTOXKV\":\"Bhutan\",\"J3V4yP\":\"Bolivia\",\"/LJfnD\":\"Bosnien-Hercegovina\",\"qgi2wZ\":\"Botswana\",\"P7k2N+\":\"Brasilien\",\"ioIIOw\":\"Britisk territorium i Det Indiske Ocean\",\"chqr93\":\"De Britiske Jomfruøer\",\"2rxD4o\":\"Brunei\",\"umGaDy\":\"Bulgarien\",\"0wg9EY\":\"Burkina Faso\",\"2bZVF9\":\"Burundi\",\"w6uMH2\":\"Cambodja\",\"0jQ4za\":\"Cameroun\",\"RtHGDr\":\"Canada\",\"1rsa2i\":\"De Kanariske Øer\",\"dEgA5A\":\"Annuller\",\"SRy70x\":\"Kap Verde\",\"CBLSFB\":\"Caribien Holland\",\"t1RF/q\":\"Caymanøerne\",\"6yca6H\":\"Den Centralafrikanske Republik\",\"uHw40v\":\"Ceuta og Melilla\",\"skKTDB\":\"Chad\",\"VAAqbc\":\"Chile\",\"Rhcdj/\":\"Kina\",\"JcJnn+\":\"Juleøen\",\"Tndr67\":[\"Klientversion: \",[\"uiVersion\"]],\"gcFBCv\":\"Cocos (Keeling) øerne\",\"MhCc7B\":\"Colombia\",\"n/rrHm\":\"Comorerne\",\"zm7XGe\":\"Congo - Brazzaville\",\"0iyydL\":\"Congo - Kinshasa\",\"HKZDAB\":\"Cook-øerne\",\"blW8gp\":\"Costa Rica\",\"eoehPl\":\"Elfenbenskysten\",\"wBMjJ2\":\"Antal\",\"NW9vMU\":\"Lande\",\"JNCzPW\":\"Land\",\"eT0pTr\":\"Kroatien\",\"fYHG5A\":\"Cuba\",\"P7bAUC\":\"Curaçao\",\"xVtOyQ\":\"Cypern\",\"2SQ/G3\":\"Tjekkiet\",\"Fo2vDn\":\"Dansk\",\"E/CKn7\":\"Danmark\",\"OFow6z\":\"Diego Garcia\",\"CBjjAj\":\"Djibouti\",\"9uxqj8\":\"Dominica\",\"FrBQGv\":\"Den Dominikanske Republik\",\"kBYV5Z\":\"Har du ikke en konto? <0>Registrer\",\"MtZ4ZX\":\"Ecuador\",\"NGditG\":\"Egypten\",\"08cLBp\":\"El Salvador\",\"O3oNi5\":\"E-mail\",\"lYGfRP\":\"Engelsk\",\"BnWtS2\":\"Ækvatorialguinea\",\"jIhOia\":\"Eritrea\",\"Ija6SC\":\"Estland\",\"ReEyML\":\"Eswatini\",\"SjhaXQ\":\"Etiopien\",\"uEfPLo\":\"Arrangement #\",\"tst44n\":\"Arrangementer\",\"nZaXmP\":\"Falklandsøerne\",\"7LrL7q\":\"Færøerne\",\"rx1loD\":\"Fiji\",\"n/d3zN\":\"Finland\",\"+gY+iO\":\"Frankrig\",\"Pls7ft\":\"Fransk Guyana\",\"X9yAes\":\"Fransk Polynesien\",\"PE5vOp\":\"Gabon\",\"0ttL3c\":\"Gambia\",\"26mZIT\":\"Georgien\",\"XTtR6a\":\"Tyskland\",\"ja3lDX\":\"Ghana\",\"NCBDr7\":\"Gibraltar\",\"fpB1B/\":\"Gå til begivenhed\",\"suigXz\":\"Grækenland\",\"67xH8L\":\"Grønland\",\"XPW0U9\":\"Grenada\",\"sLECWi\":\"Guadeloupe\",\"sG8Ixz\":\"Guam\",\"OVrih8\":\"Guatemala\",\"qN9XXd\":\"Guernsey\",\"0FI1uz\":\"Guinea\",\"x76C/t\":\"Guinea-Bissau\",\"YH2SkJ\":\"Guyana\",\"hcqzcm\":\"Haiti\",\"G7r4Oi\":\"Honduras\",\"m+5WGh\":\"SAR Hongkong\",\"tHPrTV\":\"Ungarn\",\"2AB3u7\":\"Island\",\"7GbHlU\":\"Indien\",\"y4CtQD\":\"Indonesien\",\"AF+of8\":\"Iran\",\"w9k801\":\"Irak\",\"krAJef\":\"Irland\",\"OCfl1n\":\"Isle of Man\",\"rQFCoH\":\"Israel\",\"MFljzs\":\"Italien\",\"7dOxiL\":\"Jamaica\",\"A1ET6E\":\"Japan\",\"aMTfRY\":\"Jersey\",\"D4a5SN\":\"JID kode\",\"5Hjl1F\":\"JID koder\",\"0wdd7X\":\"Deltag\",\"/4MiV6\":[\"Deltag i \",[\"locationName\"],\" \",[\"eventYear\"]],\"uqun6A\":\"Jordan\",\"s9irlx\":\"Kasakhstan\",\"QSZYwx\":\"Kenya\",\"yn1Jhl\":\"Kiribati\",\"pky2s/\":\"Kosovo\",\"UYw39m\":\"Kuwait\",\"rQdXWy\":\"Kirgisistan\",\"vXIe7J\":\"Sprog\",\"KGMGzH\":\"Laos\",\"i/OeVc\":\"Seneste arrangement\",\"6/RHJc\":\"Letland\",\"ss3YZQ\":\"Libanon\",\"0MAc+x\":\"Lesotho\",\"A49wve\":\"Liberia\",\"pi7ujn\":\"Libyen\",\"LZFxxH\":\"Liechtenstein\",\"tPeAHE\":\"Litauen\",\"VppBoU\":\"Steder\",\"z0t9bb\":\"Log ind\",\"nOhz3x\":\"Log ud\",\"X46cnc\":\"Luxembourg\",\"nO9N5q\":\"SAR Macao\",\"0zfPc5\":\"Madagaskar\",\"mpAmDi\":\"Malawi\",\"3CWdKb\":\"Malaysia\",\"LToFQm\":\"Maldiverne\",\"myyHLb\":\"Mali\",\"XMC+ix\":\"Malta\",\"4HBFYh\":\"Kort\",\"/W1CY2\":\"Marshalløerne\",\"z7ht1P\":\"Martinique\",\"0J/oR9\":\"Mauretanien\",\"fDPr0Q\":\"Mauritius\",\"qAeqhI\":\"Mayotte\",\"J6PdvT\":\"Mexico\",\"4KhXAq\":\"Mikronesien\",\"ZFfy9b\":\"Moldova\",\"qYYZGC\":\"Monaco\",\"tZtPRG\":\"Mongoliet\",\"7SJIDV\":\"Montenegro\",\"IwXxWT\":\"Montserrat\",\"C/IDOH\":\"Marokko\",\"sBQFjV\":\"Mozambique\",\"Qf17XN\":\"Myanmar (Burma)\",\"6YtxFj\":\"Navn\",\"lQa3W0\":\"Namibia\",\"HTFZeF\":\"Nauru\",\"zrhWlq\":\"Nepal\",\"lTo/3/\":\"Holland\",\"c7mAvD\":\"Ny Kaledonien\",\"ADasb3\":\"New Zealand\",\"cpNoc4\":\"Nicaragua\",\"1cvWEV\":\"Niger\",\"2FumKI\":\"Nigeria\",\"0WI/SI\":\"Niue\",\"OKOh/2\":\"Norfolk-øen\",\"0MeemP\":\"Nordkorea\",\"AtHcAV\":\"Nordmakedonien\",\"bqlZhX\":\"Nordmarianerne\",\"YPOHAm\":\"Norge\",\"mGDLTg\":\"Ikke aktiv\",\"TDAbIp\":\"Oman\",\"CYRJEX\":\"Ejere\",\"GBGf6U\":\"Pakistan\",\"tPTbCz\":\"Palau\",\"BUcdXX\":\"Palæstinensiske områder\",\"OUUlO8\":\"Panama\",\"pn2ogq\":\"Papua Ny Guinea\",\"fr2N9b\":\"Paraguay\",\"Sb5/xx\":\"Deltagerens navn er allerede taget\",\"MZHPuB\":\"Deltagere\",\"8ZsakT\":\"Kodeord\",\"RsRRw3\":\"Peru\",\"xR7k0Y\":\"Filippinerne\",\"I78DIm\":\"Pitcairn-øerne\",\"sfwBnA\":\"Polen\",\"htCPf9\":\"Portugal\",\"vERlcd\":\"Profil\",\"eVk4WJ\":\"Puerto Rico\",\"9jKy+T\":\"Qatar\",\"fgLNSM\":\"Registrer\",\"sarsmw\":\"Réunion\",\"mWoNJT\":\"Rumænien\",\"X2/NjG\":\"Rusland\",\"IAwvQM\":\"Rwanda\",\"zJfCcx\":\"Samoa\",\"bh3WAH\":\"San Marino\",\"pLg5we\":\"São Tomé og Príncipe\",\"Iw7UoY\":\"Saudi-Arabien\",\"tfDRzk\":\"Gem\",\"ARtLGZ\":\"Senegal\",\"0pXCr4\":\"Serbien\",\"gsy6gb\":\"Serbien og Montenegro\",\"f0iSQt\":[\"Serverversion: \",[\"serverVersion\"]],\"7YiXQN\":\"Seychellerne\",\"YCzKAA\":\"Sierra Leone\",\"8+ImgH\":\"Singapore\",\"lphsuP\":\"Sint Maarten\",\"Chveds\":\"Slovakiet\",\"hXSTLN\":\"Slovenien\",\"1vVROZ\":\"Salomonøerne\",\"tMq1xU\":\"Somalia\",\"JJ+vfH\":\"Sydafrika\",\"jmuzeU\":\"Sydkorea\",\"VbVDak\":\"Sydsudan\",\"OigxPq\":\"Spanien\",\"vQPCWm\":\"Sri Lanka\",\"I6mHed\":\"St Barthélemy\",\"tbvf8b\":\"St Helena\",\"5FPgwo\":\"St Kitts & Nevis\",\"y0XxAA\":\"Saint Lucia\",\"WCD11v\":\"Saint Martin\",\"myNc6K\":\"St Pierre og Miquelon\",\"YGpK3c\":\"Vincent og Grenadinerne\",\"9umCb1\":\"Sudan\",\"AEd2Vh\":\"Surinam\",\"1vUs6h\":\"Svalbard og Jan Mayen\",\"nnIui6\":\"Sverige\",\"c7yvtA\":\"Schweiz\",\"XmNDeb\":\"Syrien\",\"if5Kxg\":\"Taiwan\",\"9Iqild\":\"Tadsjikistan\",\"Pw3pGz\":\"Tanzania\",\"+tyx++\":\"Thailand\",\"FEr96N\":\"Tema\",\"XDJRcs\":\"Timor-Leste\",\"trNmBM\":\"Togo\",\"hLBqO+\":\"Tokelau\",\"vGzZWo\":\"Tonga\",\"lGJp1X\":\"Trinidad & Tobago\",\"MsTUgs\":\"Tunesien\",\"BQ11x2\":\"Tyrkiet\",\"9kEOKZ\":\"Turkmenistan\",\"MvzSG0\":\"Turks- og Caicosøerne\",\"VHdaJt\":\"Tuvalu\",\"KevOdr\":\"Uganda\",\"Gyc/04\":\"Ukraine\",\"rwCsyF\":\"De Forenede Arabiske Emirater\",\"Eh7Dql\":\"Storbritannien\",\"Mqy/Zy\":\"USA\",\"8HB/Mv\":\"Uruguay\",\"tVVqHY\":\"Amerikanske oversøiske øer\",\"IdGMXK\":\"De Amerikanske Jomfruøer\",\"1iGIjH\":\"Usbekistan\",\"iWOlMs\":\"Vanuatu\",\"6w2wqV\":\"Vatikanstaten\",\"5YLAE6\":\"Venezuela\",\"qjyHpe\":\"Vietnam\",\"ePt/mZ\":\"Wallis og Futuna\",\"qP2+4s\":\"Vestsahara\",\"+Mob4T\":\"Hvad er dit navn?\",\"3PAU4M\":\"År\",\"ZpORBp\":\"Yemen\",\"2sNADv\":\"Du har oprettet en konto. Gå til <0>login\",\"kpgmML\":\"Zambia\",\"AmGIGd\":\"Zimbabwe\"}")as Messages; \ No newline at end of file +/*eslint-disable*/import type{Messages}from"@lingui/core";export const messages=JSON.parse("{\"T6OzMq\":[[\"locationName\"],\" \",[\"eventYear\"]],\"1eHppt\":\"# JID koder\",\"F6pfE9\":\"Aktiv\",\"VbT1oK\":\"Tilføj kode\",\"e2ygq+\":\"Tilføj arrangement\\n\",\"IYYyC4\":\"Tilføj JID kode\",\"zfXn+r\":\"Tilføj sted\",\"U3pytU\":\"Admin\",\"VFCG/o\":\"Afghanistan\",\"/9JruU\":\"Ålandsøerne\",\"fl/qbv\":\"Albanien\",\"HgfQva\":\"Algeriet\",\"HIsSWr\":\"Har du allerede en konto? <0>Log ind\",\"Xp8e0M\":\"Amerikansk Samoa\",\"3q/cvu\":\"Der er allerede oprettet et arrangement for det givne år og JID kode\",\"i7j+rI\":\"Andorra\",\"fFWMB8\":\"Angola\",\"kRkTOo\":\"Anguilla\",\"hBTNUd\":\"Antigua og Barbuda\",\"n25nMV\":\"Argentina\",\"uImFCC\":\"Armenien\",\"rauLEz\":\"Aruba\",\"QeKGx6\":\"Australien\",\"SNQEUJ\":\"Østrig\",\"htuqBH\":\"Login mislykkedes\",\"R9Khdg\":\"Auto\",\"ntRxPY\":\"Aserbajdsjan\",\"WdBTIc\":\"Bahamas\",\"4zHav4\":\"Bahrain\",\"N6kXss\":\"Bangladesh\",\"56Z8bT\":\"Barbados\",\"Fax4U2\":\"Hviderusland\",\"C9G7k0\":\"Belgien\",\"6cyLjb\":\"Belize\",\"nkEPgb\":\"Benin\",\"V+Y2mD\":\"Bermuda\",\"GTOXKV\":\"Bhutan\",\"J3V4yP\":\"Bolivia\",\"/LJfnD\":\"Bosnien-Hercegovina\",\"qgi2wZ\":\"Botswana\",\"P7k2N+\":\"Brasilien\",\"ioIIOw\":\"Britisk territorium i Det Indiske Ocean\",\"chqr93\":\"De Britiske Jomfruøer\",\"2rxD4o\":\"Brunei\",\"umGaDy\":\"Bulgarien\",\"0wg9EY\":\"Burkina Faso\",\"2bZVF9\":\"Burundi\",\"w6uMH2\":\"Cambodja\",\"0jQ4za\":\"Cameroun\",\"RtHGDr\":\"Canada\",\"1rsa2i\":\"De Kanariske Øer\",\"dEgA5A\":\"Annuller\",\"SRy70x\":\"Kap Verde\",\"CBLSFB\":\"Caribien Holland\",\"t1RF/q\":\"Caymanøerne\",\"6yca6H\":\"Den Centralafrikanske Republik\",\"uHw40v\":\"Ceuta og Melilla\",\"skKTDB\":\"Chad\",\"VAAqbc\":\"Chile\",\"Rhcdj/\":\"Kina\",\"JcJnn+\":\"Juleøen\",\"Tndr67\":[\"Klientversion: \",[\"uiVersion\"]],\"gcFBCv\":\"Cocos (Keeling) øerne\",\"MhCc7B\":\"Colombia\",\"n/rrHm\":\"Comorerne\",\"zm7XGe\":\"Congo - Brazzaville\",\"0iyydL\":\"Congo - Kinshasa\",\"HKZDAB\":\"Cook-øerne\",\"blW8gp\":\"Costa Rica\",\"eoehPl\":\"Elfenbenskysten\",\"wBMjJ2\":\"Antal\",\"NW9vMU\":\"Lande\",\"JNCzPW\":\"Land\",\"hYgDIe\":\"Opret\",\"eT0pTr\":\"Kroatien\",\"fYHG5A\":\"Cuba\",\"P7bAUC\":\"Curaçao\",\"xVtOyQ\":\"Cypern\",\"2SQ/G3\":\"Tjekkiet\",\"Fo2vDn\":\"Dansk\",\"E/CKn7\":\"Danmark\",\"OFow6z\":\"Diego Garcia\",\"CBjjAj\":\"Djibouti\",\"9uxqj8\":\"Dominica\",\"FrBQGv\":\"Den Dominikanske Republik\",\"kBYV5Z\":\"Har du ikke en konto? <0>Registrer\",\"MtZ4ZX\":\"Ecuador\",\"NGditG\":\"Egypten\",\"08cLBp\":\"El Salvador\",\"O3oNi5\":\"E-mail\",\"UID/DW\":\"E-mail er allerede knyttet til en anden konto\",\"lYGfRP\":\"Engelsk\",\"BnWtS2\":\"Ækvatorialguinea\",\"jIhOia\":\"Eritrea\",\"Ija6SC\":\"Estland\",\"ReEyML\":\"Eswatini\",\"SjhaXQ\":\"Etiopien\",\"uEfPLo\":\"Arrangement #\",\"tst44n\":\"Arrangementer\",\"nZaXmP\":\"Falklandsøerne\",\"7LrL7q\":\"Færøerne\",\"rx1loD\":\"Fiji\",\"n/d3zN\":\"Finland\",\"+gY+iO\":\"Frankrig\",\"Pls7ft\":\"Fransk Guyana\",\"X9yAes\":\"Fransk Polynesien\",\"PE5vOp\":\"Gabon\",\"0ttL3c\":\"Gambia\",\"26mZIT\":\"Georgien\",\"XTtR6a\":\"Tyskland\",\"ja3lDX\":\"Ghana\",\"NCBDr7\":\"Gibraltar\",\"fpB1B/\":\"Gå til begivenhed\",\"suigXz\":\"Grækenland\",\"67xH8L\":\"Grønland\",\"XPW0U9\":\"Grenada\",\"sLECWi\":\"Guadeloupe\",\"sG8Ixz\":\"Guam\",\"OVrih8\":\"Guatemala\",\"qN9XXd\":\"Guernsey\",\"0FI1uz\":\"Guinea\",\"x76C/t\":\"Guinea-Bissau\",\"YH2SkJ\":\"Guyana\",\"hcqzcm\":\"Haiti\",\"G7r4Oi\":\"Honduras\",\"m+5WGh\":\"SAR Hongkong\",\"tHPrTV\":\"Ungarn\",\"2AB3u7\":\"Island\",\"7GbHlU\":\"Indien\",\"y4CtQD\":\"Indonesien\",\"AF+of8\":\"Iran\",\"w9k801\":\"Irak\",\"krAJef\":\"Irland\",\"OCfl1n\":\"Isle of Man\",\"rQFCoH\":\"Israel\",\"MFljzs\":\"Italien\",\"7dOxiL\":\"Jamaica\",\"A1ET6E\":\"Japan\",\"aMTfRY\":\"Jersey\",\"D4a5SN\":\"JID kode\",\"5Hjl1F\":\"JID koder\",\"0wdd7X\":\"Deltag\",\"/4MiV6\":[\"Deltag i \",[\"locationName\"],\" \",[\"eventYear\"]],\"uqun6A\":\"Jordan\",\"s9irlx\":\"Kasakhstan\",\"QSZYwx\":\"Kenya\",\"yn1Jhl\":\"Kiribati\",\"pky2s/\":\"Kosovo\",\"UYw39m\":\"Kuwait\",\"rQdXWy\":\"Kirgisistan\",\"vXIe7J\":\"Sprog\",\"KGMGzH\":\"Laos\",\"i/OeVc\":\"Seneste arrangement\",\"6/RHJc\":\"Letland\",\"ss3YZQ\":\"Libanon\",\"0MAc+x\":\"Lesotho\",\"A49wve\":\"Liberia\",\"pi7ujn\":\"Libyen\",\"LZFxxH\":\"Liechtenstein\",\"tPeAHE\":\"Litauen\",\"eRzAA6\":\"Stedets navn\",\"VppBoU\":\"Steder\",\"z0t9bb\":\"Log ind\",\"nOhz3x\":\"Log ud\",\"X46cnc\":\"Luxembourg\",\"nO9N5q\":\"SAR Macao\",\"0zfPc5\":\"Madagaskar\",\"mpAmDi\":\"Malawi\",\"3CWdKb\":\"Malaysia\",\"LToFQm\":\"Maldiverne\",\"myyHLb\":\"Mali\",\"XMC+ix\":\"Malta\",\"4HBFYh\":\"Kort\",\"/W1CY2\":\"Marshalløerne\",\"z7ht1P\":\"Martinique\",\"0J/oR9\":\"Mauretanien\",\"fDPr0Q\":\"Mauritius\",\"qAeqhI\":\"Mayotte\",\"J6PdvT\":\"Mexico\",\"4KhXAq\":\"Mikronesien\",\"ZFfy9b\":\"Moldova\",\"qYYZGC\":\"Monaco\",\"tZtPRG\":\"Mongoliet\",\"7SJIDV\":\"Montenegro\",\"IwXxWT\":\"Montserrat\",\"C/IDOH\":\"Marokko\",\"sBQFjV\":\"Mozambique\",\"Qf17XN\":\"Myanmar (Burma)\",\"6YtxFj\":\"Navn\",\"lQa3W0\":\"Namibia\",\"HTFZeF\":\"Nauru\",\"zrhWlq\":\"Nepal\",\"lTo/3/\":\"Holland\",\"c7mAvD\":\"Ny Kaledonien\",\"ADasb3\":\"New Zealand\",\"cpNoc4\":\"Nicaragua\",\"1cvWEV\":\"Niger\",\"2FumKI\":\"Nigeria\",\"0WI/SI\":\"Niue\",\"OKOh/2\":\"Norfolk-øen\",\"0MeemP\":\"Nordkorea\",\"AtHcAV\":\"Nordmakedonien\",\"bqlZhX\":\"Nordmarianerne\",\"YPOHAm\":\"Norge\",\"mGDLTg\":\"Ikke aktiv\",\"TDAbIp\":\"Oman\",\"CYRJEX\":\"Ejere\",\"GBGf6U\":\"Pakistan\",\"tPTbCz\":\"Palau\",\"BUcdXX\":\"Palæstinensiske områder\",\"OUUlO8\":\"Panama\",\"pn2ogq\":\"Papua Ny Guinea\",\"fr2N9b\":\"Paraguay\",\"Sb5/xx\":\"Deltagerens navn er allerede taget\",\"MZHPuB\":\"Deltagere\",\"8ZsakT\":\"Kodeord\",\"RsRRw3\":\"Peru\",\"xR7k0Y\":\"Filippinerne\",\"I78DIm\":\"Pitcairn-øerne\",\"sfwBnA\":\"Polen\",\"htCPf9\":\"Portugal\",\"vERlcd\":\"Profil\",\"eVk4WJ\":\"Puerto Rico\",\"9jKy+T\":\"Qatar\",\"fgLNSM\":\"Registrer\",\"sarsmw\":\"Réunion\",\"mWoNJT\":\"Rumænien\",\"X2/NjG\":\"Rusland\",\"IAwvQM\":\"Rwanda\",\"zJfCcx\":\"Samoa\",\"bh3WAH\":\"San Marino\",\"pLg5we\":\"São Tomé og Príncipe\",\"Iw7UoY\":\"Saudi-Arabien\",\"tfDRzk\":\"Gem\",\"ARtLGZ\":\"Senegal\",\"0pXCr4\":\"Serbien\",\"gsy6gb\":\"Serbien og Montenegro\",\"f0iSQt\":[\"Serverversion: \",[\"serverVersion\"]],\"7YiXQN\":\"Seychellerne\",\"YCzKAA\":\"Sierra Leone\",\"8+ImgH\":\"Singapore\",\"lphsuP\":\"Sint Maarten\",\"Chveds\":\"Slovakiet\",\"hXSTLN\":\"Slovenien\",\"1vVROZ\":\"Salomonøerne\",\"tMq1xU\":\"Somalia\",\"JJ+vfH\":\"Sydafrika\",\"jmuzeU\":\"Sydkorea\",\"VbVDak\":\"Sydsudan\",\"OigxPq\":\"Spanien\",\"vQPCWm\":\"Sri Lanka\",\"I6mHed\":\"St Barthélemy\",\"tbvf8b\":\"St Helena\",\"5FPgwo\":\"St Kitts & Nevis\",\"y0XxAA\":\"Saint Lucia\",\"WCD11v\":\"Saint Martin\",\"myNc6K\":\"St Pierre og Miquelon\",\"YGpK3c\":\"Vincent og Grenadinerne\",\"9umCb1\":\"Sudan\",\"AEd2Vh\":\"Surinam\",\"1vUs6h\":\"Svalbard og Jan Mayen\",\"nnIui6\":\"Sverige\",\"c7yvtA\":\"Schweiz\",\"XmNDeb\":\"Syrien\",\"if5Kxg\":\"Taiwan\",\"9Iqild\":\"Tadsjikistan\",\"Pw3pGz\":\"Tanzania\",\"+tyx++\":\"Thailand\",\"FEr96N\":\"Tema\",\"XDJRcs\":\"Timor-Leste\",\"trNmBM\":\"Togo\",\"hLBqO+\":\"Tokelau\",\"vGzZWo\":\"Tonga\",\"lGJp1X\":\"Trinidad & Tobago\",\"MsTUgs\":\"Tunesien\",\"BQ11x2\":\"Tyrkiet\",\"9kEOKZ\":\"Turkmenistan\",\"MvzSG0\":\"Turks- og Caicosøerne\",\"VHdaJt\":\"Tuvalu\",\"KevOdr\":\"Uganda\",\"Gyc/04\":\"Ukraine\",\"rwCsyF\":\"De Forenede Arabiske Emirater\",\"Eh7Dql\":\"Storbritannien\",\"Mqy/Zy\":\"USA\",\"8HB/Mv\":\"Uruguay\",\"tVVqHY\":\"Amerikanske oversøiske øer\",\"IdGMXK\":\"De Amerikanske Jomfruøer\",\"1iGIjH\":\"Usbekistan\",\"iWOlMs\":\"Vanuatu\",\"6w2wqV\":\"Vatikanstaten\",\"5YLAE6\":\"Venezuela\",\"qjyHpe\":\"Vietnam\",\"ePt/mZ\":\"Wallis og Futuna\",\"qP2+4s\":\"Vestsahara\",\"+Mob4T\":\"Hvad er dit navn?\",\"3PAU4M\":\"År\",\"ZpORBp\":\"Yemen\",\"2sNADv\":\"Du har oprettet en konto. Gå til <0>login\",\"kpgmML\":\"Zambia\",\"AmGIGd\":\"Zimbabwe\"}")as Messages; \ No newline at end of file diff --git a/src/i18n/locales/en.po b/src/i18n/locales/en.po index e4f8f4c..39d535d 100644 --- a/src/i18n/locales/en.po +++ b/src/i18n/locales/en.po @@ -20,25 +20,35 @@ msgstr "" msgid "{locationName} {eventYear}" msgstr "{locationName} {eventYear}" -#: src/admin/location/AdminLocationEventTable.tsx:59 +#: src/admin/location/AdminLocationEventTable.tsx:60 msgid "# JID codes" msgstr "# JID codes" -#: src/admin/location/AdminLocationEventTable.tsx:36 -#: src/admin/location/AdminLocationEventTable.tsx:40 +#: src/admin/location/AdminLocationEventTable.tsx:37 #: src/admin/location/AdminLocationEventTable.tsx:41 +#: src/admin/location/AdminLocationEventTable.tsx:42 msgid "Active" msgstr "Active" -#: src/components/JidCodeInput.tsx:58 +#: src/components/JidCodeInput.tsx:72 msgid "Add Code" msgstr "Add Code" +#: src/admin/event/new/AdminCreateEvent.tsx:30 +#: src/admin/location/AdminLocation.tsx:37 +msgid "Add event" +msgstr "Add event" + #: src/event/AddJidCode.tsx:65 #: src/event/AddJidCode.tsx:84 msgid "Add JID Code" msgstr "Add JID Code" +#: src/admin/location/new/AdminCreateLocation.tsx:27 +#: src/admin/overview/AdminOverview.tsx:30 +msgid "Add location" +msgstr "Add location" + #: src/event/AuthenticatedButtons.tsx:21 #: src/landing/Landing.tsx:15 msgid "Admin" @@ -68,6 +78,10 @@ msgstr "Already have an account? <0>Login" msgid "American Samoa" msgstr "American Samoa" +#: src/gql/serverErrors.ts:42 +msgid "An event is already created with the JID code and year" +msgstr "An event is already created with the JID code and year" + #: src/utils/countries.tsx:7 msgid "Andorra" msgstr "Andorra" @@ -104,7 +118,7 @@ msgstr "Australia" msgid "Austria" msgstr "Austria" -#: src/gql/serverErrors.ts:40 +#: src/gql/serverErrors.ts:44 msgid "Authentication failed" msgstr "Authentication failed" @@ -212,6 +226,8 @@ msgstr "Canada" msgid "Canary Islands" msgstr "Canary Islands" +#: src/admin/event/new/AdminCreateEvent.tsx:19 +#: src/admin/location/new/AdminCreateLocation.tsx:16 #: src/event/AddJidCode.tsx:55 #: src/event/join/JoinEvent.tsx:20 msgid "Cancel" @@ -303,6 +319,11 @@ msgstr "Countries" msgid "Country" msgstr "Country" +#: src/admin/event/new/AdminCreateEvent.tsx:23 +#: src/admin/location/new/AdminCreateLocation.tsx:20 +msgid "Create" +msgstr "Create" + #: src/utils/countries.tsx:199 msgid "Croatia" msgstr "Croatia" @@ -368,6 +389,10 @@ msgstr "El Salvador" msgid "Email" msgstr "Email" +#: src/gql/serverErrors.ts:46 +msgid "Email already associated with account" +msgstr "Email already associated with account" + #: src/utils/languages.tsx:8 msgid "English" msgstr "English" @@ -396,7 +421,7 @@ msgstr "Ethiopia" msgid "Event #" msgstr "Event #" -#: src/admin/location/AdminLocation.tsx:24 +#: src/admin/location/AdminLocation.tsx:26 msgid "Events" msgstr "Events" @@ -560,7 +585,7 @@ msgstr "Japan" msgid "Jersey" msgstr "Jersey" -#: src/admin/location/AdminLocationEventTable.tsx:30 +#: src/admin/location/AdminLocationEventTable.tsx:31 msgid "JID code" msgstr "JID code" @@ -647,7 +672,12 @@ msgstr "Liechtenstein" msgid "Lithuania" msgstr "Lithuania" -#: src/admin/overview/AdminOverview.tsx:24 +#: src/admin/event/new/AdminCreateEvent.tsx:41 +#: src/admin/location/new/AdminCreateLocation.tsx:30 +msgid "Location name" +msgstr "Location name" + +#: src/admin/overview/AdminOverview.tsx:25 msgid "Locations" msgstr "Locations" @@ -824,8 +854,8 @@ msgstr "Northern Mariana Islands" msgid "Norway" msgstr "Norway" -#: src/admin/location/AdminLocationEventTable.tsx:44 #: src/admin/location/AdminLocationEventTable.tsx:45 +#: src/admin/location/AdminLocationEventTable.tsx:46 msgid "Not active" msgstr "Not active" @@ -833,7 +863,7 @@ msgstr "Not active" msgid "Oman" msgstr "Oman" -#: src/admin/location/AdminLocation.tsx:29 +#: src/admin/location/AdminLocation.tsx:32 msgid "Owners" msgstr "Owners" @@ -861,11 +891,11 @@ msgstr "Papua New Guinea" msgid "Paraguay" msgstr "Paraguay" -#: src/gql/serverErrors.ts:38 +#: src/gql/serverErrors.ts:40 msgid "Participant name already taken" msgstr "Participant name already taken" -#: src/admin/location/AdminLocationEventTable.tsx:53 +#: src/admin/location/AdminLocationEventTable.tsx:54 #: src/event/Event.tsx:60 #: src/event/statbar/EventStatBar.tsx:16 msgid "Participants" @@ -1192,7 +1222,7 @@ msgstr "Western Sahara" msgid "What is your name?" msgstr "What is your name?" -#: src/admin/location/AdminLocationEventTable.tsx:22 +#: src/admin/location/AdminLocationEventTable.tsx:23 msgid "Year" msgstr "Year" diff --git a/src/i18n/locales/en.ts b/src/i18n/locales/en.ts index 6a6b61c..779ec69 100644 --- a/src/i18n/locales/en.ts +++ b/src/i18n/locales/en.ts @@ -1 +1 @@ -/*eslint-disable*/import type{Messages}from"@lingui/core";export const messages=JSON.parse("{\"T6OzMq\":[[\"locationName\"],\" \",[\"eventYear\"]],\"1eHppt\":\"# JID codes\",\"F6pfE9\":\"Active\",\"VbT1oK\":\"Add Code\",\"IYYyC4\":\"Add JID Code\",\"U3pytU\":\"Admin\",\"VFCG/o\":\"Afghanistan\",\"/9JruU\":\"Åland Islands\",\"fl/qbv\":\"Albania\",\"HgfQva\":\"Algeria\",\"HIsSWr\":\"Already have an account? <0>Login\",\"Xp8e0M\":\"American Samoa\",\"i7j+rI\":\"Andorra\",\"fFWMB8\":\"Angola\",\"kRkTOo\":\"Anguilla\",\"hBTNUd\":\"Antigua & Barbuda\",\"n25nMV\":\"Argentina\",\"uImFCC\":\"Armenia\",\"rauLEz\":\"Aruba\",\"QeKGx6\":\"Australia\",\"SNQEUJ\":\"Austria\",\"htuqBH\":\"Authentication failed\",\"R9Khdg\":\"Auto\",\"ntRxPY\":\"Azerbaijan\",\"WdBTIc\":\"Bahamas\",\"4zHav4\":\"Bahrain\",\"N6kXss\":\"Bangladesh\",\"56Z8bT\":\"Barbados\",\"Fax4U2\":\"Belarus\",\"C9G7k0\":\"Belgium\",\"6cyLjb\":\"Belize\",\"nkEPgb\":\"Benin\",\"V+Y2mD\":\"Bermuda\",\"GTOXKV\":\"Bhutan\",\"J3V4yP\":\"Bolivia\",\"/LJfnD\":\"Bosnia & Herzegovina\",\"qgi2wZ\":\"Botswana\",\"P7k2N+\":\"Brazil\",\"ioIIOw\":\"British Indian Ocean Territory\",\"chqr93\":\"British Virgin Islands\",\"2rxD4o\":\"Brunei\",\"umGaDy\":\"Bulgaria\",\"0wg9EY\":\"Burkina Faso\",\"2bZVF9\":\"Burundi\",\"w6uMH2\":\"Cambodia\",\"0jQ4za\":\"Cameroon\",\"RtHGDr\":\"Canada\",\"1rsa2i\":\"Canary Islands\",\"dEgA5A\":\"Cancel\",\"SRy70x\":\"Cape Verde\",\"CBLSFB\":\"Caribbean Netherlands\",\"t1RF/q\":\"Cayman Islands\",\"6yca6H\":\"Central African Republic\",\"uHw40v\":\"Ceuta & Melilla\",\"skKTDB\":\"Chad\",\"VAAqbc\":\"Chile\",\"Rhcdj/\":\"China\",\"JcJnn+\":\"Christmas Island\",\"Tndr67\":[\"Client version: \",[\"uiVersion\"]],\"gcFBCv\":\"Cocos (Keeling) Islands\",\"MhCc7B\":\"Colombia\",\"n/rrHm\":\"Comoros\",\"zm7XGe\":\"Congo - Brazzaville\",\"0iyydL\":\"Congo - Kinshasa\",\"HKZDAB\":\"Cook Islands\",\"blW8gp\":\"Costa Rica\",\"eoehPl\":\"Côte d’Ivoire\",\"wBMjJ2\":\"Count\",\"NW9vMU\":\"Countries\",\"JNCzPW\":\"Country\",\"eT0pTr\":\"Croatia\",\"fYHG5A\":\"Cuba\",\"P7bAUC\":\"Curaçao\",\"xVtOyQ\":\"Cyprus\",\"2SQ/G3\":\"Czechia\",\"Fo2vDn\":\"Danish\",\"E/CKn7\":\"Denmark\",\"OFow6z\":\"Diego Garcia\",\"CBjjAj\":\"Djibouti\",\"9uxqj8\":\"Dominica\",\"FrBQGv\":\"Dominican Republic\",\"kBYV5Z\":\"Don't have an account? <0>Register\",\"MtZ4ZX\":\"Ecuador\",\"NGditG\":\"Egypt\",\"08cLBp\":\"El Salvador\",\"O3oNi5\":\"Email\",\"lYGfRP\":\"English\",\"BnWtS2\":\"Equatorial Guinea\",\"jIhOia\":\"Eritrea\",\"Ija6SC\":\"Estonia\",\"ReEyML\":\"Eswatini\",\"SjhaXQ\":\"Ethiopia\",\"uEfPLo\":\"Event #\",\"tst44n\":\"Events\",\"nZaXmP\":\"Falkland Islands\",\"7LrL7q\":\"Faroe Islands\",\"rx1loD\":\"Fiji\",\"n/d3zN\":\"Finland\",\"+gY+iO\":\"France\",\"Pls7ft\":\"French Guiana\",\"X9yAes\":\"French Polynesia\",\"PE5vOp\":\"Gabon\",\"0ttL3c\":\"Gambia\",\"26mZIT\":\"Georgia\",\"XTtR6a\":\"Germany\",\"ja3lDX\":\"Ghana\",\"NCBDr7\":\"Gibraltar\",\"fpB1B/\":\"Go to event\",\"suigXz\":\"Greece\",\"67xH8L\":\"Greenland\",\"XPW0U9\":\"Grenada\",\"sLECWi\":\"Guadeloupe\",\"sG8Ixz\":\"Guam\",\"OVrih8\":\"Guatemala\",\"qN9XXd\":\"Guernsey\",\"0FI1uz\":\"Guinea\",\"x76C/t\":\"Guinea-Bissau\",\"YH2SkJ\":\"Guyana\",\"hcqzcm\":\"Haiti\",\"G7r4Oi\":\"Honduras\",\"m+5WGh\":\"Hong Kong SAR China\",\"tHPrTV\":\"Hungary\",\"2AB3u7\":\"Iceland\",\"7GbHlU\":\"India\",\"y4CtQD\":\"Indonesia\",\"AF+of8\":\"Iran\",\"w9k801\":\"Iraq\",\"krAJef\":\"Ireland\",\"OCfl1n\":\"Isle of Man\",\"rQFCoH\":\"Israel\",\"MFljzs\":\"Italy\",\"7dOxiL\":\"Jamaica\",\"A1ET6E\":\"Japan\",\"aMTfRY\":\"Jersey\",\"D4a5SN\":\"JID code\",\"5Hjl1F\":\"JID Codes\",\"0wdd7X\":\"Join\",\"/4MiV6\":[\"Join \",[\"locationName\"],\" \",[\"eventYear\"]],\"uqun6A\":\"Jordan\",\"s9irlx\":\"Kazakhstan\",\"QSZYwx\":\"Kenya\",\"yn1Jhl\":\"Kiribati\",\"pky2s/\":\"Kosovo\",\"UYw39m\":\"Kuwait\",\"rQdXWy\":\"Kyrgyzstan\",\"vXIe7J\":\"Language\",\"KGMGzH\":\"Laos\",\"i/OeVc\":\"Latest Event\",\"6/RHJc\":\"Latvia\",\"ss3YZQ\":\"Lebanon\",\"0MAc+x\":\"Lesotho\",\"A49wve\":\"Liberia\",\"pi7ujn\":\"Libya\",\"LZFxxH\":\"Liechtenstein\",\"tPeAHE\":\"Lithuania\",\"VppBoU\":\"Locations\",\"z0t9bb\":\"Login\",\"nOhz3x\":\"Logout\",\"X46cnc\":\"Luxembourg\",\"nO9N5q\":\"Macao SAR China\",\"0zfPc5\":\"Madagascar\",\"mpAmDi\":\"Malawi\",\"3CWdKb\":\"Malaysia\",\"LToFQm\":\"Maldives\",\"myyHLb\":\"Mali\",\"XMC+ix\":\"Malta\",\"4HBFYh\":\"Map\",\"/W1CY2\":\"Marshall Islands\",\"z7ht1P\":\"Martinique\",\"0J/oR9\":\"Mauritania\",\"fDPr0Q\":\"Mauritius\",\"qAeqhI\":\"Mayotte\",\"J6PdvT\":\"Mexico\",\"4KhXAq\":\"Micronesia\",\"ZFfy9b\":\"Moldova\",\"qYYZGC\":\"Monaco\",\"tZtPRG\":\"Mongolia\",\"7SJIDV\":\"Montenegro\",\"IwXxWT\":\"Montserrat\",\"C/IDOH\":\"Morocco\",\"sBQFjV\":\"Mozambique\",\"Qf17XN\":\"Myanmar (Burma)\",\"6YtxFj\":\"Name\",\"lQa3W0\":\"Namibia\",\"HTFZeF\":\"Nauru\",\"zrhWlq\":\"Nepal\",\"lTo/3/\":\"Netherlands\",\"c7mAvD\":\"New Caledonia\",\"ADasb3\":\"New Zealand\",\"cpNoc4\":\"Nicaragua\",\"1cvWEV\":\"Niger\",\"2FumKI\":\"Nigeria\",\"0WI/SI\":\"Niue\",\"OKOh/2\":\"Norfolk Island\",\"0MeemP\":\"North Korea\",\"AtHcAV\":\"North Macedonia\",\"bqlZhX\":\"Northern Mariana Islands\",\"YPOHAm\":\"Norway\",\"mGDLTg\":\"Not active\",\"TDAbIp\":\"Oman\",\"CYRJEX\":\"Owners\",\"GBGf6U\":\"Pakistan\",\"tPTbCz\":\"Palau\",\"BUcdXX\":\"Palestinian Territories\",\"OUUlO8\":\"Panama\",\"pn2ogq\":\"Papua New Guinea\",\"fr2N9b\":\"Paraguay\",\"Sb5/xx\":\"Participant name already taken\",\"MZHPuB\":\"Participants\",\"8ZsakT\":\"Password\",\"RsRRw3\":\"Peru\",\"xR7k0Y\":\"Philippines\",\"I78DIm\":\"Pitcairn Islands\",\"sfwBnA\":\"Poland\",\"htCPf9\":\"Portugal\",\"vERlcd\":\"Profile\",\"eVk4WJ\":\"Puerto Rico\",\"9jKy+T\":\"Qatar\",\"fgLNSM\":\"Register\",\"sarsmw\":\"Réunion\",\"mWoNJT\":\"Romania\",\"X2/NjG\":\"Russia\",\"IAwvQM\":\"Rwanda\",\"zJfCcx\":\"Samoa\",\"bh3WAH\":\"San Marino\",\"pLg5we\":\"São Tomé & Príncipe\",\"Iw7UoY\":\"Saudi Arabia\",\"tfDRzk\":\"Save\",\"ARtLGZ\":\"Senegal\",\"0pXCr4\":\"Serbia\",\"gsy6gb\":\"Serbia and Montenegro\",\"f0iSQt\":[\"Server version: \",[\"serverVersion\"]],\"7YiXQN\":\"Seychelles\",\"YCzKAA\":\"Sierra Leone\",\"8+ImgH\":\"Singapore\",\"lphsuP\":\"Sint Maarten\",\"Chveds\":\"Slovakia\",\"hXSTLN\":\"Slovenia\",\"1vVROZ\":\"Solomon Islands\",\"tMq1xU\":\"Somalia\",\"JJ+vfH\":\"South Africa\",\"jmuzeU\":\"South Korea\",\"VbVDak\":\"South Sudan\",\"OigxPq\":\"Spain\",\"vQPCWm\":\"Sri Lanka\",\"I6mHed\":\"St Barthélemy\",\"tbvf8b\":\"St Helena\",\"5FPgwo\":\"St Kitts & Nevis\",\"y0XxAA\":\"St Lucia\",\"WCD11v\":\"St Martin\",\"myNc6K\":\"St Pierre & Miquelon\",\"YGpK3c\":\"St Vincent & the Grenadines\",\"9umCb1\":\"Sudan\",\"AEd2Vh\":\"Suriname\",\"1vUs6h\":\"Svalbard & Jan Mayen\",\"nnIui6\":\"Sweden\",\"c7yvtA\":\"Switzerland\",\"XmNDeb\":\"Syria\",\"if5Kxg\":\"Taiwan\",\"9Iqild\":\"Tajikistan\",\"Pw3pGz\":\"Tanzania\",\"+tyx++\":\"Thailand\",\"FEr96N\":\"Theme\",\"XDJRcs\":\"Timor-Leste\",\"trNmBM\":\"Togo\",\"hLBqO+\":\"Tokelau\",\"vGzZWo\":\"Tonga\",\"lGJp1X\":\"Trinidad & Tobago\",\"MsTUgs\":\"Tunisia\",\"BQ11x2\":\"Türkiye\",\"9kEOKZ\":\"Turkmenistan\",\"MvzSG0\":\"Turks & Caicos Islands\",\"VHdaJt\":\"Tuvalu\",\"KevOdr\":\"Uganda\",\"Gyc/04\":\"Ukraine\",\"rwCsyF\":\"United Arab Emirates\",\"Eh7Dql\":\"United Kingdom\",\"Mqy/Zy\":\"United States\",\"8HB/Mv\":\"Uruguay\",\"tVVqHY\":\"US Outlying Islands\",\"IdGMXK\":\"US Virgin Islands\",\"1iGIjH\":\"Uzbekistan\",\"iWOlMs\":\"Vanuatu\",\"6w2wqV\":\"Vatican City\",\"5YLAE6\":\"Venezuela\",\"qjyHpe\":\"Vietnam\",\"ePt/mZ\":\"Wallis & Futuna\",\"qP2+4s\":\"Western Sahara\",\"+Mob4T\":\"What is your name?\",\"3PAU4M\":\"Year\",\"ZpORBp\":\"Yemen\",\"2sNADv\":\"You have created an account successfully. Go to <0>Login\",\"kpgmML\":\"Zambia\",\"AmGIGd\":\"Zimbabwe\"}")as Messages; \ No newline at end of file +/*eslint-disable*/import type{Messages}from"@lingui/core";export const messages=JSON.parse("{\"T6OzMq\":[[\"locationName\"],\" \",[\"eventYear\"]],\"1eHppt\":\"# JID codes\",\"F6pfE9\":\"Active\",\"VbT1oK\":\"Add Code\",\"e2ygq+\":\"Add event\",\"IYYyC4\":\"Add JID Code\",\"zfXn+r\":\"Add location\",\"U3pytU\":\"Admin\",\"VFCG/o\":\"Afghanistan\",\"/9JruU\":\"Åland Islands\",\"fl/qbv\":\"Albania\",\"HgfQva\":\"Algeria\",\"HIsSWr\":\"Already have an account? <0>Login\",\"Xp8e0M\":\"American Samoa\",\"3q/cvu\":\"An event is already created with the JID code and year\",\"i7j+rI\":\"Andorra\",\"fFWMB8\":\"Angola\",\"kRkTOo\":\"Anguilla\",\"hBTNUd\":\"Antigua & Barbuda\",\"n25nMV\":\"Argentina\",\"uImFCC\":\"Armenia\",\"rauLEz\":\"Aruba\",\"QeKGx6\":\"Australia\",\"SNQEUJ\":\"Austria\",\"htuqBH\":\"Authentication failed\",\"R9Khdg\":\"Auto\",\"ntRxPY\":\"Azerbaijan\",\"WdBTIc\":\"Bahamas\",\"4zHav4\":\"Bahrain\",\"N6kXss\":\"Bangladesh\",\"56Z8bT\":\"Barbados\",\"Fax4U2\":\"Belarus\",\"C9G7k0\":\"Belgium\",\"6cyLjb\":\"Belize\",\"nkEPgb\":\"Benin\",\"V+Y2mD\":\"Bermuda\",\"GTOXKV\":\"Bhutan\",\"J3V4yP\":\"Bolivia\",\"/LJfnD\":\"Bosnia & Herzegovina\",\"qgi2wZ\":\"Botswana\",\"P7k2N+\":\"Brazil\",\"ioIIOw\":\"British Indian Ocean Territory\",\"chqr93\":\"British Virgin Islands\",\"2rxD4o\":\"Brunei\",\"umGaDy\":\"Bulgaria\",\"0wg9EY\":\"Burkina Faso\",\"2bZVF9\":\"Burundi\",\"w6uMH2\":\"Cambodia\",\"0jQ4za\":\"Cameroon\",\"RtHGDr\":\"Canada\",\"1rsa2i\":\"Canary Islands\",\"dEgA5A\":\"Cancel\",\"SRy70x\":\"Cape Verde\",\"CBLSFB\":\"Caribbean Netherlands\",\"t1RF/q\":\"Cayman Islands\",\"6yca6H\":\"Central African Republic\",\"uHw40v\":\"Ceuta & Melilla\",\"skKTDB\":\"Chad\",\"VAAqbc\":\"Chile\",\"Rhcdj/\":\"China\",\"JcJnn+\":\"Christmas Island\",\"Tndr67\":[\"Client version: \",[\"uiVersion\"]],\"gcFBCv\":\"Cocos (Keeling) Islands\",\"MhCc7B\":\"Colombia\",\"n/rrHm\":\"Comoros\",\"zm7XGe\":\"Congo - Brazzaville\",\"0iyydL\":\"Congo - Kinshasa\",\"HKZDAB\":\"Cook Islands\",\"blW8gp\":\"Costa Rica\",\"eoehPl\":\"Côte d’Ivoire\",\"wBMjJ2\":\"Count\",\"NW9vMU\":\"Countries\",\"JNCzPW\":\"Country\",\"hYgDIe\":\"Create\",\"eT0pTr\":\"Croatia\",\"fYHG5A\":\"Cuba\",\"P7bAUC\":\"Curaçao\",\"xVtOyQ\":\"Cyprus\",\"2SQ/G3\":\"Czechia\",\"Fo2vDn\":\"Danish\",\"E/CKn7\":\"Denmark\",\"OFow6z\":\"Diego Garcia\",\"CBjjAj\":\"Djibouti\",\"9uxqj8\":\"Dominica\",\"FrBQGv\":\"Dominican Republic\",\"kBYV5Z\":\"Don't have an account? <0>Register\",\"MtZ4ZX\":\"Ecuador\",\"NGditG\":\"Egypt\",\"08cLBp\":\"El Salvador\",\"O3oNi5\":\"Email\",\"UID/DW\":\"Email already associated with account\",\"lYGfRP\":\"English\",\"BnWtS2\":\"Equatorial Guinea\",\"jIhOia\":\"Eritrea\",\"Ija6SC\":\"Estonia\",\"ReEyML\":\"Eswatini\",\"SjhaXQ\":\"Ethiopia\",\"uEfPLo\":\"Event #\",\"tst44n\":\"Events\",\"nZaXmP\":\"Falkland Islands\",\"7LrL7q\":\"Faroe Islands\",\"rx1loD\":\"Fiji\",\"n/d3zN\":\"Finland\",\"+gY+iO\":\"France\",\"Pls7ft\":\"French Guiana\",\"X9yAes\":\"French Polynesia\",\"PE5vOp\":\"Gabon\",\"0ttL3c\":\"Gambia\",\"26mZIT\":\"Georgia\",\"XTtR6a\":\"Germany\",\"ja3lDX\":\"Ghana\",\"NCBDr7\":\"Gibraltar\",\"fpB1B/\":\"Go to event\",\"suigXz\":\"Greece\",\"67xH8L\":\"Greenland\",\"XPW0U9\":\"Grenada\",\"sLECWi\":\"Guadeloupe\",\"sG8Ixz\":\"Guam\",\"OVrih8\":\"Guatemala\",\"qN9XXd\":\"Guernsey\",\"0FI1uz\":\"Guinea\",\"x76C/t\":\"Guinea-Bissau\",\"YH2SkJ\":\"Guyana\",\"hcqzcm\":\"Haiti\",\"G7r4Oi\":\"Honduras\",\"m+5WGh\":\"Hong Kong SAR China\",\"tHPrTV\":\"Hungary\",\"2AB3u7\":\"Iceland\",\"7GbHlU\":\"India\",\"y4CtQD\":\"Indonesia\",\"AF+of8\":\"Iran\",\"w9k801\":\"Iraq\",\"krAJef\":\"Ireland\",\"OCfl1n\":\"Isle of Man\",\"rQFCoH\":\"Israel\",\"MFljzs\":\"Italy\",\"7dOxiL\":\"Jamaica\",\"A1ET6E\":\"Japan\",\"aMTfRY\":\"Jersey\",\"D4a5SN\":\"JID code\",\"5Hjl1F\":\"JID Codes\",\"0wdd7X\":\"Join\",\"/4MiV6\":[\"Join \",[\"locationName\"],\" \",[\"eventYear\"]],\"uqun6A\":\"Jordan\",\"s9irlx\":\"Kazakhstan\",\"QSZYwx\":\"Kenya\",\"yn1Jhl\":\"Kiribati\",\"pky2s/\":\"Kosovo\",\"UYw39m\":\"Kuwait\",\"rQdXWy\":\"Kyrgyzstan\",\"vXIe7J\":\"Language\",\"KGMGzH\":\"Laos\",\"i/OeVc\":\"Latest Event\",\"6/RHJc\":\"Latvia\",\"ss3YZQ\":\"Lebanon\",\"0MAc+x\":\"Lesotho\",\"A49wve\":\"Liberia\",\"pi7ujn\":\"Libya\",\"LZFxxH\":\"Liechtenstein\",\"tPeAHE\":\"Lithuania\",\"eRzAA6\":\"Location name\",\"VppBoU\":\"Locations\",\"z0t9bb\":\"Login\",\"nOhz3x\":\"Logout\",\"X46cnc\":\"Luxembourg\",\"nO9N5q\":\"Macao SAR China\",\"0zfPc5\":\"Madagascar\",\"mpAmDi\":\"Malawi\",\"3CWdKb\":\"Malaysia\",\"LToFQm\":\"Maldives\",\"myyHLb\":\"Mali\",\"XMC+ix\":\"Malta\",\"4HBFYh\":\"Map\",\"/W1CY2\":\"Marshall Islands\",\"z7ht1P\":\"Martinique\",\"0J/oR9\":\"Mauritania\",\"fDPr0Q\":\"Mauritius\",\"qAeqhI\":\"Mayotte\",\"J6PdvT\":\"Mexico\",\"4KhXAq\":\"Micronesia\",\"ZFfy9b\":\"Moldova\",\"qYYZGC\":\"Monaco\",\"tZtPRG\":\"Mongolia\",\"7SJIDV\":\"Montenegro\",\"IwXxWT\":\"Montserrat\",\"C/IDOH\":\"Morocco\",\"sBQFjV\":\"Mozambique\",\"Qf17XN\":\"Myanmar (Burma)\",\"6YtxFj\":\"Name\",\"lQa3W0\":\"Namibia\",\"HTFZeF\":\"Nauru\",\"zrhWlq\":\"Nepal\",\"lTo/3/\":\"Netherlands\",\"c7mAvD\":\"New Caledonia\",\"ADasb3\":\"New Zealand\",\"cpNoc4\":\"Nicaragua\",\"1cvWEV\":\"Niger\",\"2FumKI\":\"Nigeria\",\"0WI/SI\":\"Niue\",\"OKOh/2\":\"Norfolk Island\",\"0MeemP\":\"North Korea\",\"AtHcAV\":\"North Macedonia\",\"bqlZhX\":\"Northern Mariana Islands\",\"YPOHAm\":\"Norway\",\"mGDLTg\":\"Not active\",\"TDAbIp\":\"Oman\",\"CYRJEX\":\"Owners\",\"GBGf6U\":\"Pakistan\",\"tPTbCz\":\"Palau\",\"BUcdXX\":\"Palestinian Territories\",\"OUUlO8\":\"Panama\",\"pn2ogq\":\"Papua New Guinea\",\"fr2N9b\":\"Paraguay\",\"Sb5/xx\":\"Participant name already taken\",\"MZHPuB\":\"Participants\",\"8ZsakT\":\"Password\",\"RsRRw3\":\"Peru\",\"xR7k0Y\":\"Philippines\",\"I78DIm\":\"Pitcairn Islands\",\"sfwBnA\":\"Poland\",\"htCPf9\":\"Portugal\",\"vERlcd\":\"Profile\",\"eVk4WJ\":\"Puerto Rico\",\"9jKy+T\":\"Qatar\",\"fgLNSM\":\"Register\",\"sarsmw\":\"Réunion\",\"mWoNJT\":\"Romania\",\"X2/NjG\":\"Russia\",\"IAwvQM\":\"Rwanda\",\"zJfCcx\":\"Samoa\",\"bh3WAH\":\"San Marino\",\"pLg5we\":\"São Tomé & Príncipe\",\"Iw7UoY\":\"Saudi Arabia\",\"tfDRzk\":\"Save\",\"ARtLGZ\":\"Senegal\",\"0pXCr4\":\"Serbia\",\"gsy6gb\":\"Serbia and Montenegro\",\"f0iSQt\":[\"Server version: \",[\"serverVersion\"]],\"7YiXQN\":\"Seychelles\",\"YCzKAA\":\"Sierra Leone\",\"8+ImgH\":\"Singapore\",\"lphsuP\":\"Sint Maarten\",\"Chveds\":\"Slovakia\",\"hXSTLN\":\"Slovenia\",\"1vVROZ\":\"Solomon Islands\",\"tMq1xU\":\"Somalia\",\"JJ+vfH\":\"South Africa\",\"jmuzeU\":\"South Korea\",\"VbVDak\":\"South Sudan\",\"OigxPq\":\"Spain\",\"vQPCWm\":\"Sri Lanka\",\"I6mHed\":\"St Barthélemy\",\"tbvf8b\":\"St Helena\",\"5FPgwo\":\"St Kitts & Nevis\",\"y0XxAA\":\"St Lucia\",\"WCD11v\":\"St Martin\",\"myNc6K\":\"St Pierre & Miquelon\",\"YGpK3c\":\"St Vincent & the Grenadines\",\"9umCb1\":\"Sudan\",\"AEd2Vh\":\"Suriname\",\"1vUs6h\":\"Svalbard & Jan Mayen\",\"nnIui6\":\"Sweden\",\"c7yvtA\":\"Switzerland\",\"XmNDeb\":\"Syria\",\"if5Kxg\":\"Taiwan\",\"9Iqild\":\"Tajikistan\",\"Pw3pGz\":\"Tanzania\",\"+tyx++\":\"Thailand\",\"FEr96N\":\"Theme\",\"XDJRcs\":\"Timor-Leste\",\"trNmBM\":\"Togo\",\"hLBqO+\":\"Tokelau\",\"vGzZWo\":\"Tonga\",\"lGJp1X\":\"Trinidad & Tobago\",\"MsTUgs\":\"Tunisia\",\"BQ11x2\":\"Türkiye\",\"9kEOKZ\":\"Turkmenistan\",\"MvzSG0\":\"Turks & Caicos Islands\",\"VHdaJt\":\"Tuvalu\",\"KevOdr\":\"Uganda\",\"Gyc/04\":\"Ukraine\",\"rwCsyF\":\"United Arab Emirates\",\"Eh7Dql\":\"United Kingdom\",\"Mqy/Zy\":\"United States\",\"8HB/Mv\":\"Uruguay\",\"tVVqHY\":\"US Outlying Islands\",\"IdGMXK\":\"US Virgin Islands\",\"1iGIjH\":\"Uzbekistan\",\"iWOlMs\":\"Vanuatu\",\"6w2wqV\":\"Vatican City\",\"5YLAE6\":\"Venezuela\",\"qjyHpe\":\"Vietnam\",\"ePt/mZ\":\"Wallis & Futuna\",\"qP2+4s\":\"Western Sahara\",\"+Mob4T\":\"What is your name?\",\"3PAU4M\":\"Year\",\"ZpORBp\":\"Yemen\",\"2sNADv\":\"You have created an account successfully. Go to <0>Login\",\"kpgmML\":\"Zambia\",\"AmGIGd\":\"Zimbabwe\"}")as Messages; \ No newline at end of file diff --git a/src/router.tsx b/src/router.tsx index cf2bec6..ea66b9c 100644 --- a/src/router.tsx +++ b/src/router.tsx @@ -20,6 +20,7 @@ import { adminOverviewLoader } from "./admin"; import {AdminRegister, adminRegisterAction, adminRegisterLoader} from "./admin/register"; +import {AdminCreateEvent, adminCreateEventAction} from "./admin/event/new"; export const router = createBrowserRouter([{ path: "/", @@ -61,8 +62,13 @@ export const router = createBrowserRouter([{ path: "locations/:locationId", element: , loader: adminLocationLoader, + children: [{ + path: "events/new", + element: , + action: adminCreateEventAction, + }], }, { - path: "event/:eventId", + path: "locations/:locationId/events/:eventId", element: , loader: adminEventLoader, }]