Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,17 @@ protected enum KeyValueType

protected static void ValidateKeysFormat(StringValues keys)
{
foreach (var key in keys.Where(k => string.IsNullOrWhiteSpace(k)))
foreach (var key in keys)
{
throw new UserFriendlyException("There are empty Keys captured which are required");
}
if (string.IsNullOrWhiteSpace(key))
{
throw new UserFriendlyException("There are empty Keys captured which are required");
}

foreach (var key in keys.Where(k => !string.IsNullOrWhiteSpace(k) && !IsValidInput(k)))
{
throw new UserFriendlyException("The following characters are allowed for Keys: " + validInputPattern);
if (!IsValidInput(key))
{
throw new UserFriendlyException("The following characters are allowed for Keys: " + validInputPattern);
}
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -316,18 +316,18 @@ internal static ReportColumnsMap CreateNewMap(UpsertReportColumnsMapDto upsertRe

// Generate column names for fields without user-provided mappings
// For formversion provider, use Key (CHEFS Property Name) as the source; for others, use Label
var autoGeneratedColumnNames = fieldsMap.Fields
.Where(field => !userProvidedMappings.ContainsKey(field.Path))
.ToDictionary(
field => field.Path,
field => {
var columnNameSource = GetDefaultColumnNameSource(field, upsertReportColmnsMapDto.CorrelationProvider);
var sanitizedName = SanitizeColumnName(columnNameSource);
var uniqueName = EnsureUniqueness(sanitizedName, usedColumnNames);
usedColumnNames.Add(uniqueName);
return uniqueName;
}
);
var autoGeneratedColumnNames = new Dictionary<string, string>();
foreach (var field in fieldsMap.Fields)
{
if (!userProvidedMappings.ContainsKey(field.Path))
{
var columnNameSource = GetDefaultColumnNameSource(field, upsertReportColmnsMapDto.CorrelationProvider);
var sanitizedName = SanitizeColumnName(columnNameSource);
var uniqueName = EnsureUniqueness(sanitizedName, usedColumnNames);
autoGeneratedColumnNames[field.Path] = uniqueName;
usedColumnNames.Add(uniqueName);
}
}

// Create mapping rows
var mapRows = fieldsMap.Fields.Select(field =>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
if (CurrentUser.IsAuthenticated && CurrentUser.FindClaimValue("has_multiple_tenants") == "true")
isAuthorizedForTenantSwitch = true;

bool isAuthorizedForPaymentConfiguration = await PermissionChecker.IsGrantedAsync("SettingManagement.ConfigurePayments");
}
<abp-dropdown id="user-dropdown">
<abp-dropdown-button class="btn-dropdown" text="@CurrentTenant.Name" />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
using System.Collections.Generic;
using System.Text.Json;
using System.Threading.Tasks;
using Unity.GrantManager.Applications;
using Unity.GrantManager.GrantApplications;
using Unity.GrantManager.Intakes;
using Unity.Modules.Shared;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
using Unity.Flex.Scoresheets.Enums;
using Unity.Flex.Scoresheets.Events;
using Unity.Flex.Worksheets.Definitions;
using Unity.GrantManager.Applications;
using Unity.GrantManager.Comments;
using Unity.GrantManager.Exceptions;
using Unity.GrantManager.Workflow;
Expand Down
Loading