From 7bf17a20f4655e92c01a8ab7d35498314a64776b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rui=20Tom=C3=A9?= <108268980+r-tome@users.noreply.github.com> Date: Mon, 29 Jan 2024 20:04:45 +0000 Subject: [PATCH] [AC-2104] Add flexible collections properties to provider organizations sync response (#3717) --- ...rofileProviderOrganizationResponseModel.cs | 3 ++ .../ProviderUserOrganizationDetails.cs | 3 ++ ...roviderUserOrganizationDetailsViewQuery.cs | 5 +- ...derUserProviderOrganizationDetailsView.sql | 5 +- ...OrganizationsFlexibleCollectionColumns.sql | 54 +++++++++++++++++++ 5 files changed, 68 insertions(+), 2 deletions(-) create mode 100644 util/Migrator/DbScripts/2024-01-29_00_ProviderOrganizationsFlexibleCollectionColumns.sql diff --git a/src/Api/AdminConsole/Models/Response/ProfileProviderOrganizationResponseModel.cs b/src/Api/AdminConsole/Models/Response/ProfileProviderOrganizationResponseModel.cs index d6b7656e4..9c3951c29 100644 --- a/src/Api/AdminConsole/Models/Response/ProfileProviderOrganizationResponseModel.cs +++ b/src/Api/AdminConsole/Models/Response/ProfileProviderOrganizationResponseModel.cs @@ -43,5 +43,8 @@ public class ProfileProviderOrganizationResponseModel : ProfileOrganizationRespo ProviderId = organization.ProviderId; ProviderName = organization.ProviderName; PlanProductType = StaticStore.GetPlan(organization.PlanType).Product; + LimitCollectionCreationDeletion = organization.LimitCollectionCreationDeletion; + AllowAdminAccessToAllCollectionItems = organization.AllowAdminAccessToAllCollectionItems; + FlexibleCollections = organization.FlexibleCollections; } } diff --git a/src/Core/AdminConsole/Models/Data/Provider/ProviderUserOrganizationDetails.cs b/src/Core/AdminConsole/Models/Data/Provider/ProviderUserOrganizationDetails.cs index 92f420a5b..e69217949 100644 --- a/src/Core/AdminConsole/Models/Data/Provider/ProviderUserOrganizationDetails.cs +++ b/src/Core/AdminConsole/Models/Data/Provider/ProviderUserOrganizationDetails.cs @@ -35,4 +35,7 @@ public class ProviderUserOrganizationDetails public Guid? ProviderUserId { get; set; } public string ProviderName { get; set; } public Core.Enums.PlanType PlanType { get; set; } + public bool LimitCollectionCreationDeletion { get; set; } + public bool AllowAdminAccessToAllCollectionItems { get; set; } + public bool FlexibleCollections { get; set; } } diff --git a/src/Infrastructure.EntityFramework/AdminConsole/Repositories/Queries/ProviderUserOrganizationDetailsViewQuery.cs b/src/Infrastructure.EntityFramework/AdminConsole/Repositories/Queries/ProviderUserOrganizationDetailsViewQuery.cs index 95a83968b..2b0ddf752 100644 --- a/src/Infrastructure.EntityFramework/AdminConsole/Repositories/Queries/ProviderUserOrganizationDetailsViewQuery.cs +++ b/src/Infrastructure.EntityFramework/AdminConsole/Repositories/Queries/ProviderUserOrganizationDetailsViewQuery.cs @@ -43,7 +43,10 @@ public class ProviderUserOrganizationDetailsViewQuery : IQuery