@isettingkit/business-rules 2.1.9 → 2.1.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -84,6 +84,7 @@ export declare const formatDecisionForBackend: (props: {
84
84
  businessRuleId?: string;
85
85
  conditionDataType?: ValueDataType[keyof ValueDataType];
86
86
  conditionName?: string;
87
+ conditionGroups?: ICondition[];
87
88
  decision?: IDecision;
88
89
  decisions?: IDecision[];
89
90
  decisionDataType?: ValueDataType[keyof ValueDataType];
@@ -102,7 +103,12 @@ export declare const formatDecisionForBackend: (props: {
102
103
 
103
104
  export declare const FormFilter: (props: IFormFilter) => JSX.Element;
104
105
 
105
- export declare const getConditionsByGroup: (decision: IRuleDecision) => {};
106
+ export declare const getConditionsByGroupNew: (raw: any) => Record<string, any[]>;
107
+
108
+ export declare const groupsRecordToArrayNew: (record: Record<string, any[]>) => {
109
+ ConditionGroupId: string;
110
+ conditionsThatEstablishesTheDecision: any[];
111
+ }[];
106
112
 
107
113
  export declare interface IBackAndNextButton extends Omit<IButton, "onClick" | "path" | "children"> {
108
114
  handleBack: () => void;
@@ -410,10 +416,14 @@ declare interface ITranslateOptions {
410
416
  apiKey: string;
411
417
  }
412
418
 
413
- export declare const mapByGroup: <T, R>(obj: Record<string, T[]>, fn: (c: T, idx: number, arr: T[], group: string) => R) => Record<string, R[]>;
419
+ export declare const mapByGroupNew: (raw: any, mapFn: (condition: any) => any) => Record<string, any[]>;
414
420
 
415
421
  export declare const ModalRules: (props: IModalRules) => ReactPortal;
416
422
 
423
+ export declare const normalizeDecisionToNewShape: <T extends {
424
+ [k: string]: any;
425
+ }>(decision: T) => T;
426
+
417
427
  export declare const parseRangeFromString: (value: string | number | string[] | IValue | undefined) => string | number | IValue | string[] | {
418
428
  from?: number;
419
429
  to?: number;
@@ -424,6 +434,7 @@ export declare const revertSortedDataSampleSwitchPlaces: (props: IRevertSortedDa
424
434
  businessRuleId?: string;
425
435
  conditionDataType?: ValueDataType[keyof ValueDataType];
426
436
  conditionName?: string;
437
+ conditionGroups?: ICondition[];
427
438
  decision?: IDecision;
428
439
  decisions?: IDecision[];
429
440
  decisionDataType?: ValueDataType[keyof ValueDataType];
@@ -454,6 +465,7 @@ export declare const sortDisplayDataSampleSwitchPlaces: (props: IRevertSortedDat
454
465
  businessRuleId?: string;
455
466
  conditionDataType?: ValueDataType[keyof ValueDataType];
456
467
  conditionName?: string;
468
+ conditionGroups?: ICondition[];
457
469
  conditionsThatEstablishesTheDecision?: ICondition[];
458
470
  decision?: IDecision;
459
471
  decisions?: IDecision[];