-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- For creating multiple members under a single family - For changing person relation - For changing head of family
- Loading branch information
1 parent
38191df
commit 4d56af0
Showing
8 changed files
with
155 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
Tithe-Spring/src/main/java/com/tithe/model/PersonRelationInputModel.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
/** | ||
* | ||
*/ | ||
package com.tithe.model; | ||
|
||
import jakarta.validation.constraints.NotNull; | ||
import jakarta.validation.constraints.Positive; | ||
import lombok.Data; | ||
import lombok.NoArgsConstructor; | ||
|
||
/** | ||
* @author Ashish Sam T George | ||
* | ||
*/ | ||
@NoArgsConstructor | ||
@Data | ||
public class PersonRelationInputModel { | ||
|
||
@Positive(message = "Id of Person should be valid") | ||
@NotNull(message = "Id of Person should not be empty or null") | ||
private Long personId; | ||
|
||
@Positive(message = "Id of Relation should be valid") | ||
@NotNull(message = "Id of Relation should not be empty or null") | ||
private Long relationId; | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
5 changes: 4 additions & 1 deletion
5
Tithe-Spring/src/main/resources/graphql/mutations/FamilyMutations.graphqls
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,8 @@ | ||
extend type Mutation{ | ||
createOneFamily(family: FamilyMutationInput): Family | ||
createOneFamily(family: FamilyMutationInput!): Family | ||
|
||
changeHeadOfFamily(familyId: ID!, newHeadOfFamily: PersonRelationSchema!, persons: [PersonRelationSchema]): Family | ||
|
||
activateOneFamily(familyId: ID!): Family | ||
deactivateOneFamily(familyId: ID!): Family | ||
} |
5 changes: 4 additions & 1 deletion
5
Tithe-Spring/src/main/resources/graphql/mutations/PersonMutations.graphqls
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters