Skip to content

Conversation

@plavoie-BC
Copy link
Contributor

@plavoie-BC plavoie-BC commented May 20, 2025

This pull request implements a Setting Management Interface for Tag Management:

Application and Payment Tags Management:

  • Settings Interface:
    • Added a Tag Management Settings UI that combines data from ApplicationTags and PaymentTags into one interface.
    • Added an Edit Modal and Delete Buttons to manage tags of both types.
  • Business Logic:
    • Implemented tag sanitization in CreateorUpdateTagsAsync to ensure consistent formatting of tag strings.
    • Added methods in ApplicationTagAppService and PaymentTagAppService for tag management, including tag summary retrieval, renaming, and deletion with validation and error handling.
  • Data Models:
    • Introduced TagSummaryCountDto and TagSummaryCount for ApplicationTags and PaymentTags classes to represent tag summaries, including tag name and count. [1] [2]
  • Repository Enhancements:
    • Added methods in IApplicationTagsRepository and IPaymentTagRepository and their implementations to support tag summary retrieval and maximum rename length calculation for client-side validation. [1] [2]
  • Payment Request Tag Event Handlers:
    • Created DeleteTagHandler and RenameTagHandler to handle tag deletion and renaming events asynchronously and maintain modular separation. [1] [2]
  • Permissions and Settings:
    • Defined new permissions for tag management (read, update, delete) under the SettingManagement.Tags namespace. [1] [2]
    • Mapped new permissions as defaults for the team-lead and system-admin roles.

@plavoie-BC plavoie-BC requested a review from Copilot May 20, 2025 21:30

This comment was marked as resolved.

@plavoie-BC plavoie-BC marked this pull request as draft May 21, 2025 13:03
@plavoie-BC

This comment was marked as resolved.

@plavoie-BC plavoie-BC marked this pull request as ready for review May 21, 2025 17:52
@plavoie-BC plavoie-BC requested review from Copilot and jimmyPasta May 21, 2025 18:39
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This pull request adds a consolidated Tag Management Settings interface and implements tag-related business logic for both application tags and payment tags. Key changes include new UI-related mappings and permissions, enhanced tag sanitization and renaming logic in the application and payment services, and the addition of event handlers for tag rename and deletion.

Reviewed Changes

Copilot reviewed 34 out of 34 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
GrantManagerApplicationAutoMapperProfile.cs Added mapping for TagSummaryCount to TagSummaryCountDto.
ApplicationTagsAppService.cs Introduced tag sanitization, tag summary retrieval, rename and delete methods for application tags, and integrated local event bus notifications.
PaymentTagAppService.cs Implemented similar tag management features for payment tags along with tag summary, rename, and delete support.
PaymentTagRepository.cs Added repository methods for tag summary grouping and max rename length calculation.
PermissionDefinitionProvider.cs, UnitySelector.cs, DTOs, and event handlers Introduced new tag management permissions and supporting types/events.
NotificationsSettingPageContributor.cs and its view Updated notifications settings with minor ordering improvements.
Comments suppressed due to low confidence (1)

applications/Unity.GrantManager/modules/Unity.Payments/src/Unity.Payments.Application/Events/RenameTagEto.cs:8

  • Consider renaming 'originalTagName' (and similarly 'replacementTagName') to 'OriginalTagName' and 'ReplacementTagName' to follow standard C# property naming conventions.
public required string originalTagName { get; set; }

@jimmyPasta
Copy link
Contributor

Thanks Patrick very thrurough

@jimmyPasta jimmyPasta merged commit 7b81d85 into dev May 21, 2025
5 checks passed
@jimmyPasta jimmyPasta deleted the feature/AB#28576-tag-management-settings branch May 21, 2025 18:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants