Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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 @@ -74,8 +74,8 @@ protected override async Task<bool> CustomPropsAreEqualAsync(NotificationTypeCon
item.AllowAttachments == distributedItem.AllowAttachments &&
item.Disable == distributedItem.Disable &&
item.CanOptOut == distributedItem.CanOptOut &&
item.Category == distributedItem.Category &&
item.OverrideChannels == distributedItem.OverrideChannels;
item.Category == (distributedItem.Category ?? string.Empty) &&
item.OverrideChannels == (distributedItem.OverrideChannels ?? string.Empty);

if (!equals)
return false;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ public static TDestination CopyNotificationSpecificPropsFrom<TDestination>(this
dst.AllowAttachments = src.AllowAttachments;
dst.Disable = src.Disable;
dst.CanOptOut = src.CanOptOut;
dst.Category = src.Category;
dst.OverrideChannels = src.OverrideChannels;
dst.Category = src.Category ?? string.Empty;
dst.OverrideChannels = src.OverrideChannels ?? string.Empty;

return dst;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ namespace Shesha.Domain
[JoinedProperty("Core_RoleAppointmentTypeConfigs")]
[Entity(TypeShortAlias = "Shesha.Core.RoleAppointmentTypeConfig")]
[Prefix(UsePrefixes = false)]
public class RoleAppointmentTypeConfig : ConfigurationItemBase
public class RoleAppointmentTypeConfig : ConfigurationItem
{
public RoleAppointmentTypeConfig()
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
using Abp.Application.Services.Dto;
using Shesha.Domain;
using Shesha.Dto.Interfaces;
using System;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ public override void Up()

if (Schema.Table("SheshaFunctionalTests_TestAccounts").Exists())
IfDatabase("PostgreSql").Execute.Sql(@"ALTER TABLE ""SheshaFunctionalTests_TestAccounts"" DROP CONSTRAINT IF EXISTS ""FK_SheshaFunctionalTests_TestAccounts_CaptureFormId_Frwk_FormCo""");

this.Shesha().MoveForeignKeys("Frwk_FormConfigurations", null, "Id", "form_configuration_revisions", "frwk", "id");

Delete.Table("Frwk_FormConfigurations");
Delete.Table("Frwk_PermissionDefinitions");
Delete.Table("Frwk_ConfigurableComponents");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,10 @@ public override void Up()
IfDatabase("SqlServer").Execute.Sql(@"IF (OBJECT_ID('dbo.FK_Core_DistributionListItems_ShaRoleId_Core_ShaRoles_Id', 'F') IS NOT NULL)
ALTER TABLE entpr_DistributionListItems DROP CONSTRAINT FK_Core_DistributionListItems_ShaRoleId_Core_ShaRoles_Id;");

this.Shesha().MoveForeignKeys("Core_ShaRoles", null, "Id", "role_revisions", "frwk", "id");
this.Shesha().MoveForeignKeys("Frwk_ConfigurationItems", null, "Id", "configuration_item_revisions", "frwk", "id");
this.Shesha().MoveForeignKeys("Frwk_Modules", null, "Id", "modules", "frwk", "id");

Delete.Table("Core_ShaRoles");
Delete.Table("Frwk_ConfigurationItems");
Delete.Table("Frwk_Modules");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ public override void Up()

Delete.Column("frwk_discriminator").FromTable("configuration_item_revisions").InSchema("frwk");

this.Shesha().MoveForeignKeys("form_configuration_revisions", "frwk", "id", "configuration_item_revisions", "frwk", "id");
this.Shesha().MoveForeignKeys("role_revisions", "frwk", "id", "configuration_item_revisions", "frwk", "id");

Delete.Table("form_configuration_revisions").InSchema("frwk");
Delete.Table("reference_list_revisions").InSchema("frwk");
Delete.Table("setting_config_revisions").InSchema("frwk");
Expand Down
48 changes: 0 additions & 48 deletions shesha-core/src/Shesha.Framework/Migrations/M20250529124100.cs

This file was deleted.

2 changes: 2 additions & 0 deletions shesha-reactjs/src/components/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ export { FormWithFlatMarkup, type IFormWithFlatMarkupProps } from './configurabl
export { type IConfigurableFormRendererProps, type IConfigurableFormProps } from './configurableForm/models';
export { default as Show, type IShowProps } from './show';
export { CodeEditor } from '@/designer-components/codeEditor/codeEditor';
export { type ICodeEditorProps, type GetResultTypeFunc, type GetAvailableConstantsFunc } from '@/designer-components/codeEditor/interfaces';
export { default as ModelConfigurator } from './modelConfigurator';
export { ConfigurableApplicationComponent, type IConfigurableApplicationComponentProps } from './configurableComponent';
export { Autocomplete, type IAutocompleteProps } from './autocomplete';
Expand All @@ -108,6 +109,7 @@ export { HelpTextPopover } from './helpTextPopover';
export { StatusTag } from './statusTag';
export { RefListStatus, type IRefListStatusProps } from './refListStatus';
export { ListEditor } from './listEditor';
export { type ListItem } from './listEditor/models';
export { ButtonGroupConfigurator } from './buttonGroupConfigurator';
export { ConfigurableComponentRenderer } from "./configurableComponentRenderer";
export { PermissionAutocomplete, type IPermissionAutocompleteProps } from './permissionAutocomplete';
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Empty, Select, Spin } from 'antd';
import { Empty, Select, SelectProps, Spin } from 'antd';
import { ValidationErrors } from '@/components';
import { useReferenceList } from '@/providers/referenceListDispatcher';
import React, { useMemo } from 'react';
Expand All @@ -10,12 +10,9 @@ import ReflistTag from './reflistTag';
export const GenericRefListDropDown = <TValue = unknown>(props: IGenericRefListDropDownProps<TValue>): JSX.Element => {
const {
referenceListId,
showArrow = true,
value,
filters,
disabledValues,
width,
base,
mode,
onChange,
readOnly,
Expand All @@ -33,7 +30,10 @@ export const GenericRefListDropDown = <TValue = unknown>(props: IGenericRefListD
solidColor,
showItemName,
placeholder,
...rest
size,
variant,
className,
defaultValue,
} = props;
const { data: refList, loading: refListLoading, error: refListError } = useReferenceList(referenceListId);

Expand Down Expand Up @@ -128,10 +128,9 @@ export const GenericRefListDropDown = <TValue = unknown>(props: IGenericRefListD
);
}

const commonSelectProps = {
const commonSelectProps: Partial<SelectProps> = {
labelInValue: true,
defaultActiveFirstOption: false,
suffixIcon: showArrow ? undefined : null,
notFoundContent: refListLoading ? (
<Spin />
) : (
Expand All @@ -144,7 +143,10 @@ export const GenericRefListDropDown = <TValue = unknown>(props: IGenericRefListD
loading: refListLoading,
disabled,
filterOption: filterOption,
...rest,
size: size,
variant: variant,
className: className,
defaultValue: defaultValue,
onChange: handleChange,
value: wrapValue(value, options),
};
Expand Down
9 changes: 3 additions & 6 deletions shesha-reactjs/src/components/refListDropDown/models.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,22 +25,19 @@ export interface IGenericRefListDropDownProps<TValue = any> extends IRefListDrop

}

export interface IRefListDropDownProps<TValue = any> extends Omit<SelectProps<any>, 'onChange'>, IReadOnly {
type LimitedSelectProps = Pick<SelectProps<any>, 'mode' | 'disabled' | 'allowClear' | 'filterOption' | 'placeholder' | 'variant' | 'defaultValue' | 'className'>;

export interface IRefListDropDownProps<TValue = any> extends LimitedSelectProps, IReadOnly {
/**
* Reference List identifier
*/
referenceListId: IReferenceListIdentifier;
/**
* How large should the button be?
*/
filters?: number[];
width?: number;
style?: CSSProperties;
tagStyle?: CSSProperties;
showIcon?: boolean;
solidColor?: boolean;
showItemName?: boolean;
base?: string;
value?: TValue | TValue[];
ignoredValues?: number[];
disabledValues?: number[];
Expand Down
2 changes: 2 additions & 0 deletions shesha-reactjs/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,5 @@ export { useConstantsEvaluator } from './designer-components/codeEditor/hooks/us
export { useResultTypeEvaluator } from './designer-components/codeEditor/hooks/useResultType';

export { default as ConfigurationStudio } from './configuration-studio';
export { useFormViaFactory, useFormBuilderFactory } from './form-factory/hooks';
export { type FormBuilder, type FormBuilderFactory } from './form-factory/interfaces';
11 changes: 7 additions & 4 deletions shesha-reactjs/src/interfaces/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ export { type IChangeable } from './changeable';
export { type IFormItem } from './formItem';
export { type INamed } from './named';
export { type IStylable } from './stylable';
export { type ITableColumn, type IDataTableInstance } from '../providers/dataTable/interfaces';
export { type ITableColumn, type IDataTableInstance, type IStoredFilter, type FilterExpression } from '../providers/dataTable/interfaces';
export type { PageWithLayout } from './pageWithLayout';
export type { InsertMode } from './insertMode';
export type { IColor, IHsl, IHsv, IRgb } from './color';
Expand All @@ -42,10 +42,11 @@ export type {
TypeDefinition,
SourceFile,
ITypeDefinitionLoadingContext,
IEntityReferencePropertyMetadata,
} from './metadata';
export { isPropertiesArray, isEntityReferencePropertyMetadata } from './metadata';
export { isEntityMetadata } from './metadata';
export type { IAjaxResponse, IAjaxResponseBase } from './ajaxResponse';
export { isEntityMetadata, isPropertiesArray, isEntityReferencePropertyMetadata } from './metadata';
export { type NestedPropertyMetadatAccessor } from '../providers/metadataDispatcher/contexts';
export { type IAjaxResponse, type IAjaxResponseBase, type IAjaxErrorResponse, type IAjaxSuccessResponse, isAjaxSuccessResponse, isAjaxErrorResponse, extractAjaxResponse } from './ajaxResponse';
export type { ICommonContainerProps, IContainerComponentProps } from '../designer-components/container/interfaces';
export { DataTypes, StringFormats } from './dataTypes';
export { type IReferenceListIdentifier } from './referenceList';
Expand All @@ -58,3 +59,5 @@ export { type IShaFormInstance } from '@/providers/form/store/interfaces';
export * from './errorInfo';
export * from './publicApis';
export * from './configurableItems';
export { type ISettingsComponent, type ISettingsComponentGroup } from '@/designer-components/settingsInput/settingsInput';
export * from './gql';
2 changes: 2 additions & 0 deletions shesha-reactjs/src/utils/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -171,3 +171,5 @@ export const convertJsonToCss = (style: CSSProperties): string | null => {

export { unwrapAbpResponse } from './fetchers';
export * from './metadata/index';
export * from './datatable';
export * from './url';