Skip to content

Commit

Permalink
feat: Mentor-Cycle#53 - Tornando experience nullable
Browse files Browse the repository at this point in the history
  • Loading branch information
daniloMelin committed Nov 25, 2023
1 parent 53b9588 commit 9c84573
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 43 deletions.
51 changes: 9 additions & 42 deletions schema.gql
Original file line number Diff line number Diff line change
Expand Up @@ -105,24 +105,6 @@ type Skill {
name: String!
}

type NotificationData {
id: ID!
title: String!
description: String!
imageUrl: String
notifierId: ID
updatedAt: DateTime!
createdAt: DateTime!
}

type Notification {
id: ID!
notificationDataId: ID!
userId: ID!
read: Boolean!
data: NotificationData!
}

type Testimony {
id: ID!
mentorId: String!
Expand Down Expand Up @@ -151,10 +133,7 @@ type Query {
skill(id: Int!): Skill!
findNotifications(userId: String): [Notification!]!
findOneNotification(id: String!): Notification
findTestimonies(
learnerId: String
mentorId: String
): [CreateTestimonyOutput!]!
findTestimonies(learnerId: String, mentorId: String): [CreateTestimonyOutput!]!
findOneTestimony(id: String!): [CreateTestimonyOutput!]!
}

Expand Down Expand Up @@ -196,22 +175,16 @@ type Mutation {
resetUserPassword(userInput: ResetPasswordInput!): Boolean!
sendResetPassword(email: String!): Boolean!
createAvailability(createAvailabilityInput: CreateAvailabilityInput!): User!
updateAvailability(
updateAvailabilityInput: UpdateAvailabilityInput!
): Availability!
updateAvailability(updateAvailabilityInput: UpdateAvailabilityInput!): Availability!
removeAvailability(id: Int!): Availability!
createEvent(createEventInput: CreateEventInput!): Event!
updateEvent(updateEventInput: UpdateEventInput!): Event!
removeEvent(id: Int!): Event!
createSkill(createSkillInput: CreateSkillInput!): Skill!
updateSkill(updateSkillInput: UpdateSkillInput!): Skill!
removeSkill(id: Int!): Skill!
createNotification(
createNotificationInput: CreateNotificationInput!
): NotificationData!
updateNotification(
updateNotificationInput: UpdateNotificationInput!
): NotificationData!
createNotification(createNotificationInput: CreateNotificationInput!): NotificationData!
updateNotification(updateNotificationInput: UpdateNotificationInput!): NotificationData!
markRead(id: String!): Notification!
removeNotification(id: ID!): Boolean!
createTestimony(createTestimonyInput: CreateTestimonyInput!): Testimony!
Expand All @@ -225,7 +198,7 @@ input CreateUserInput {
email: String!
password: String!
photoUrl: String
experience: String!
experience: String
skills: [String!]!
birthDate: DateTime
zipCode: String!
Expand Down Expand Up @@ -283,9 +256,7 @@ input SignInUserInput {
rememberMe: Boolean
}

"""
The `Upload` scalar type represents a file upload.
"""
"""The `Upload` scalar type represents a file upload."""
scalar Upload

input ResetPasswordInput {
Expand Down Expand Up @@ -333,16 +304,12 @@ input UpdateEventInput {
}

input CreateSkillInput {
"""
Example field (placeholder)
"""
"""Example field (placeholder)"""
exampleField: Int!
}

input UpdateSkillInput {
"""
Example field (placeholder)
"""
"""Example field (placeholder)"""
exampleField: Int
id: Int!
}
Expand Down Expand Up @@ -375,4 +342,4 @@ input UpdateTestimonyInput {
learnerId: String
text: String
id: String!
}
}
2 changes: 1 addition & 1 deletion src/modules/user/dto/create-user.input.ts
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ export class CreateUserInput {
@IsUrl()
photoUrl?: string;

@Field()
@Field({ nullable: true })
@IsOptional()
@IsString()
@Length(3, 5)
Expand Down

0 comments on commit 9c84573

Please sign in to comment.