-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Services list for multiple services (#70)
* Add ChurchTools /groups/:id/members endpoint * Include comment in service history endpoint * Change service history endpoint for multiple services * Change frontend to use changed backend endpoint * Add documentation for additional ChurchTools permission * add multiselect and sort options to service list * fix lint errors * Rename interface Services in frontend * remove unnecessary css class and show all comments from all groups * Leave multiselect open and make comment non-nullable * display the sort selection in the same line as the service selection * show a badge, when user is inactive in a group * show only one status tag, if all the other tags would be the same status --------- Co-authored-by: Beniox <37512887+Beniox@users.noreply.github.com>
- Loading branch information
1 parent
6e83dc5
commit ff6bdbe
Showing
16 changed files
with
331 additions
and
88 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
using System.Collections.Generic; | ||
using System.Text.Json.Nodes; | ||
|
||
namespace ChurchTools.Model; | ||
|
||
public record DomainObject( | ||
string Title, | ||
string DomainType, | ||
string DomainIdentifier, | ||
Dictionary<string, JsonValue> DomainAttributes); |
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,19 +1,13 @@ | ||
namespace ChurchTools.Model; | ||
using System; | ||
|
||
public class GroupMember : IIdentifiable<long> | ||
{ | ||
public GroupMember(int personId, int groupId, int groupTypeRoleId, string groupMemberStatus) | ||
{ | ||
PersonId = personId; | ||
GroupId = groupId; | ||
GroupTypeRoleId = groupTypeRoleId; | ||
GroupMemberStatus = groupMemberStatus; | ||
} | ||
namespace ChurchTools.Model; | ||
|
||
public int PersonId { get; set; } | ||
public int GroupId { get; set; } | ||
public int GroupTypeRoleId { get; set; } | ||
public string GroupMemberStatus { get; set; } | ||
|
||
long IIdentifiable<long>.Id => (long)PersonId << 32 | (long)GroupId; | ||
} | ||
public record GroupMember( | ||
int PersonId, | ||
DomainObject Person, | ||
DomainObject Group, | ||
int GroupTypeRoleId, | ||
GroupMemberStatus GroupMemberStatus, | ||
DateOnly MemberStartDate, | ||
DateOnly? MemberEndDate, | ||
string? Comment); |
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,8 +1,12 @@ | ||
namespace ChurchTools.Model; | ||
using System.Text.Json.Serialization; | ||
|
||
namespace ChurchTools.Model; | ||
|
||
[JsonConverter(typeof(JsonStringEnumConverter))] | ||
public enum GroupMemberStatus | ||
{ | ||
Active, | ||
Requested, | ||
ToDelete | ||
Waiting, | ||
To_Delete // Custom JSON values are not supported by System.Text.Json: https://stackoverflow.com/a/59061296 | ||
} |
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,19 @@ | ||
namespace ChurchTools.Model; | ||
|
||
public class GroupsMember : IIdentifiable<long> | ||
{ | ||
public GroupsMember(int personId, int groupId, int groupTypeRoleId, string groupMemberStatus) | ||
{ | ||
PersonId = personId; | ||
GroupId = groupId; | ||
GroupTypeRoleId = groupTypeRoleId; | ||
GroupMemberStatus = groupMemberStatus; | ||
} | ||
|
||
public int PersonId { get; set; } | ||
public int GroupId { get; set; } | ||
public int GroupTypeRoleId { get; set; } | ||
public string GroupMemberStatus { get; set; } | ||
|
||
long IIdentifiable<long>.Id => (long)PersonId << 32 | (long)GroupId; | ||
} |
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
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
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
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
Oops, something went wrong.