···66 canEditDetails,
77 userContributesTo,
88} from '#modules/student-associations/utils';
99-import type { Prisma } from '@churros/db/prisma';
99+import { type Prisma, GroupType as GroupTypeEnum } from '@churros/db/prisma';
10101111export const StudentAssociationPrismaIncludes = {
1212 contributionOptions: true,
···183183 "Quel type de groupe l'on souhaiterait créer. Si non spécifié, renvoie vrai si l'on peut créer au moins un type de groupe",
184184 }),
185185 },
186186- resolve: async ({ uid }, { type }, { user }) => {
186186+ resolve: async ({ id }, { type }, { user }) => {
187187 if (type) {
188188 return canCreateGroup(user, {
189189- studentAssociationUid: uid,
189189+ studentAssociationId: id,
190190 type,
191191 });
192192 }
193193194194- return Object.values(GroupEnumType).some((type) =>
194194+ return Object.values(GroupTypeEnum).some((type) =>
195195 canCreateGroup(user, {
196196- studentAssociationUid: uid,
196196+ studentAssociationId: id,
197197 type,
198198 }),
199199 );
-34
packages/app/schema.graphql
···32423242 godparentUid: String!
32433243 id: ID
32443244 ): MutationUpsertGodparentRequestResult!
32453245- upsertGroup(input: UpsertGroupInput!, uid: UID): MutationUpsertGroupResult!
32463246- @deprecated(
32473247- reason: "Mutation séparée en plusieurs mutations plus spécifiques. Voir la documentation du module groups"
32483248- )
32493245 upsertGroupMember(
32503246 canEditArticles: Boolean!
32513247 canEditMembers: Boolean!
···4039403540404036type MutationUpsertGodparentRequestSuccess {
40414037 data: GodparentRequest!
40424042-}
40434043-40444044-union MutationUpsertGroupResult = Error | MutationUpsertGroupSuccess | ZodError
40454045-40464046-type MutationUpsertGroupSuccess {
40474047- data: Group!
40484038}
4049403940504040union MutationUpsertLydiaAccountResult = Error | MutationUpsertLydiaAccountSuccess | ZodError
···65796569Une adresse internet (URL). Les protocoles autorisés sont: http:, https:, mailto:, tel:
65806570"""
65816571scalar URL
65826582-65836583-input UpsertGroupInput @graphinx(module: "groups") {
65846584- address: String!
65856585- color: String
65866586- description: String!
65876587- email: String
65886588- longDescription: String!
65896589- mailingList: String
65906590- name: String!
65916591- parent: UID
65926592- related: [String!]!
65936593- school: UID
65946594- @deprecated(
65956595- reason: "N'a aucun effet, les groupes ne peuvent plus être reliés à des écoles directement"
65966596- )
65976597- selfJoinable: Boolean!
65986598- studentAssociation: UID
65996599- type: GroupType!
66006600- """
66016601- Ne sert qu'à la création du groupe. Il est impossible de modifier un uid existant
66026602- """
66036603- uid: UID
66046604- website: String!
66056605-}
6606657266076573"""
66086574Users are the people who use the app