diff --git a/schema.graphql b/schema.graphql index 701fd9ec8f..6494d8d587 100644 --- a/schema.graphql +++ b/schema.graphql @@ -112,7 +112,6 @@ type AgendaItem { createdBy: User! description: String duration: String! - isNote: Boolean! itemType: ItemType! organization: Organization! relatedEvent: Event @@ -290,7 +289,6 @@ input CreateAgendaItemInput { categories: [ID] description: String duration: String! - isNote: Boolean! itemType: ItemType! organizationId: ID! relatedEventId: ID diff --git a/src/models/AgendaItem.ts b/src/models/AgendaItem.ts index cf95e88226..b7e4be304d 100644 --- a/src/models/AgendaItem.ts +++ b/src/models/AgendaItem.ts @@ -24,7 +24,6 @@ export interface InterfaceAgendaItem { itemType: ItemType; // Type of the agenda item (Regular or Note). createdAt: Date; // Date when the agenda item was created. updatedAt: Date; // Date when the agenda item was last updated. - isNote: boolean; // Indicates whether the agenda item is a note. organization: PopulatedDoc; // Reference to the organization associated with the agenda item. } @@ -45,8 +44,8 @@ export enum ItemType { * @param attachments - Optional array of attachment URLs. * @param createdBy - Reference to the user who created the agenda item. * @param updatedBy - Reference to the user who last updated the agenda item. - * @param urls - Optional array of URLs related to the agenda item. - * @param user - Optional user associated with the agenda item. + * @param urls - Optional users array indicating key note users for the agenda item. + * @param users - Optional user associated with the agenda item. * @param categories - Optional array of agenda categories associated with the agenda item. * @param sequence - Sequence number of the agenda item. * @param itemType - Type of the agenda item (Regular or Note). @@ -112,10 +111,6 @@ export const AgendaItemSchema = new Schema({ type: Date, // required: true, }, - isNote: { - type: Boolean, - default: false, - }, organization: { type: Schema.Types.ObjectId, ref: "Organization", diff --git a/src/typeDefs/inputs.ts b/src/typeDefs/inputs.ts index 6f7375ff29..10d3216ea1 100644 --- a/src/typeDefs/inputs.ts +++ b/src/typeDefs/inputs.ts @@ -58,7 +58,6 @@ export const inputs = gql` sequence: Int! itemType: ItemType! organizationId: ID! - isNote: Boolean! } input UpdateAgendaItemInput { diff --git a/src/typeDefs/types.ts b/src/typeDefs/types.ts index 74f70c2252..e0225ded5b 100644 --- a/src/typeDefs/types.ts +++ b/src/typeDefs/types.ts @@ -42,7 +42,6 @@ export const types = gql` itemType: ItemType! createdAt: Date! updatedAt: Date! - isNote: Boolean! organization: Organization! relatedEvent: Event } diff --git a/src/types/generatedGraphQLTypes.ts b/src/types/generatedGraphQLTypes.ts index 538e7b880c..4d2f7a51d3 100644 --- a/src/types/generatedGraphQLTypes.ts +++ b/src/types/generatedGraphQLTypes.ts @@ -183,7 +183,6 @@ export type AgendaItem = { createdBy: User; description?: Maybe; duration: Scalars['String']['output']; - isNote: Scalars['Boolean']['output']; itemType: ItemType; organization: Organization; relatedEvent?: Maybe; @@ -366,7 +365,6 @@ export type CreateAgendaItemInput = { categories?: InputMaybe>>; description?: InputMaybe; duration: Scalars['String']['input']; - isNote: Scalars['Boolean']['input']; itemType: ItemType; organizationId: Scalars['ID']['input']; relatedEventId?: InputMaybe; @@ -3620,7 +3618,6 @@ export type AgendaItemResolvers; description?: Resolver, ParentType, ContextType>; duration?: Resolver; - isNote?: Resolver; itemType?: Resolver; organization?: Resolver; relatedEvent?: Resolver, ParentType, ContextType>; diff --git a/tests/resolvers/AgendaItem/Users.spec.ts b/tests/resolvers/AgendaItem/Users.spec.ts index 892d3645f8..a6beeb329a 100644 --- a/tests/resolvers/AgendaItem/Users.spec.ts +++ b/tests/resolvers/AgendaItem/Users.spec.ts @@ -68,7 +68,7 @@ afterAll(async () => { await disconnect(MONGOOSE_INSTANCE); }); -describe("AgendaItem.Users", () => { +describe("resolvers -> AgendaItem -> Users", () => { it("Should return the users of the agenda item", async () => { const users = await usersResolver?.(testAgendaItem, {}, {}); expect(users).toEqual([testUser1, testUser2]); diff --git a/tests/resolvers/Mutation/createAgendaItem.spec.ts b/tests/resolvers/Mutation/createAgendaItem.spec.ts index 6cbefaa379..b12e685fb1 100644 --- a/tests/resolvers/Mutation/createAgendaItem.spec.ts +++ b/tests/resolvers/Mutation/createAgendaItem.spec.ts @@ -112,7 +112,6 @@ describe("resolvers -> Mutation -> createAgendaItem", () => { sequence: 1, itemType: "Regular", organizationId: testOrganization?._id, - isNote: false, }, }; @@ -151,7 +150,6 @@ describe("resolvers -> Mutation -> createAgendaItem", () => { sequence: 1, itemType: "Regular", organizationId: testOrganization?._id, // A random ID that does not exist in the database, - isNote: false, }, }; @@ -184,7 +182,6 @@ describe("resolvers -> Mutation -> createAgendaItem", () => { sequence: 1, itemType: "Regular", organizationId: new Types.ObjectId().toString(), // A random ID that does not exist in the database - isNote: false, }, }; @@ -217,7 +214,6 @@ describe("resolvers -> Mutation -> createAgendaItem", () => { sequence: 1, itemType: "Regular", organizationId: testOrganization?._id, - isNote: false, }, }; @@ -250,7 +246,6 @@ describe("resolvers -> Mutation -> createAgendaItem", () => { sequence: 1, itemType: "Regular", organizationId: testOrganization?._id, - isNote: false, }, }; @@ -282,7 +277,6 @@ describe("resolvers -> Mutation -> createAgendaItem", () => { sequence: 1, itemType: "Regular", organizationId: testOrganization?._id, - isNote: false, }, }; const context = { @@ -309,7 +303,6 @@ describe("resolvers -> Mutation -> createAgendaItem", () => { sequence: 1, itemType: "Regular", organizationId: testOrganization?._id, - isNote: false, }, }; const context = { @@ -340,7 +333,6 @@ describe("resolvers -> Mutation -> createAgendaItem", () => { sequence: 1, itemType: "Regular", organizationId: testOrganization?._id, - isNote: false, }, }; const context = {