@iapps/ng-dhis2-ui 1.1.77 → 1.1.78

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.
@@ -7,10 +7,12 @@ export declare class FormMetadataSection implements IFormMetadataSection {
7
7
  sectionStateComplete?: boolean | undefined;
8
8
  description?: string | undefined;
9
9
  translations?: any;
10
+ inheritedAttributes: any[];
10
11
  constructor(params: {
11
12
  section: Partial<IFormMetadataSection>;
12
13
  program: Record<string, unknown>;
13
14
  locale?: string;
15
+ excludeInheritedAttributes?: boolean;
14
16
  });
15
17
  get attributes(): {
16
18
  formName: unknown;
@@ -14,6 +14,7 @@ export declare class FormMetaData implements IFormMetadata {
14
14
  splitRegistrationSection?: boolean;
15
15
  includeAllProgramStages?: boolean;
16
16
  disableEnrollmentDate?: boolean;
17
+ excludeInheritedAttributes?: boolean;
17
18
  programStage?: string;
18
19
  customFormMetaData?: Partial<FormMetaData>;
19
20
  });
@@ -1,3 +1,3 @@
1
1
  export declare class FormFieldTypeUtil {
2
- static getFieldType(valueType: string): "text" | "number" | "image" | "org-unit" | "file";
2
+ static getFieldType(valueType: string): "number" | "text" | "image" | "org-unit" | "file";
3
3
  }
@@ -3,7 +3,7 @@ import { DropdownOption } from '../models';
3
3
  export declare class FieldUtil {
4
4
  static getFieldDropdownOptions(field: any): DropdownOption[];
5
5
  static sanitizeOptions(options: any[]): any;
6
- static getFieldType(valueType: string): "text" | "tel" | "email" | "date" | "number" | "org-unit" | "file";
6
+ static getFieldType(valueType: string): "email" | "number" | "text" | "tel" | "date" | "org-unit" | "file";
7
7
  static getFieldControlType(valueType: string, hasOptions: boolean): FieldControlType;
8
8
  static getOptionEntities?(options: any[]): any;
9
9
  }
@@ -1,8 +1,7 @@
1
- import { ActionOptionOrientation } from '../../models';
2
- import { DropdownMenuOption } from '../dropdown-menu';
1
+ import { ActionOptionOrientation, LineListActionOption } from '../../models';
3
2
  import React from 'react';
4
3
  export declare const DataTableActions: (props: {
5
- actionOptions: DropdownMenuOption[];
4
+ actionOptions: LineListActionOption[];
6
5
  actionOptionOrientation: ActionOptionOrientation;
7
- onClick: (dropdownOption: DropdownMenuOption) => void;
6
+ onClick: (dropdownOption: LineListActionOption) => void;
8
7
  }) => React.JSX.Element;
@@ -1,18 +1,9 @@
1
1
  import React from 'react';
2
- export interface DropdownMenuOption {
3
- id?: string;
4
- label: string;
5
- action?: string;
6
- description?: string;
7
- iconOnly?: boolean;
8
- icon?: any;
9
- destructive?: boolean;
10
- onClick?: Function;
11
- }
2
+ import { DropdownMenuOption } from '../../models';
12
3
  export declare const ContextMenu: (params: {
13
4
  dropDownOptions: DropdownMenuOption[];
14
5
  anchorRef: any;
15
- onClose: Function;
6
+ onClose: (event?: any, data?: any) => void;
16
7
  onMenuClick: (dropdownOption: DropdownMenuOption) => void;
17
8
  }) => React.JSX.Element;
18
9
  export declare const DropdownMenu: (props: {
@@ -1,18 +1,17 @@
1
1
  import { EventEmitter, SimpleChanges } from '@angular/core';
2
2
  import React from 'react';
3
3
  import { ReactWrapperModule } from '../../react-wrapper/react-wrapper.component';
4
- import { DropdownMenuOption } from '../components/dropdown-menu';
5
4
  import { AttributeFilter } from '../models/attribute-filter.model';
6
5
  import { FilterConfig } from '../models/filter-config.model';
7
6
  import { TableRow } from '../models/line-list.models';
8
7
  import { LineListService } from '../services/line-list.service';
9
- import { ActionOptionOrientation } from '../models';
8
+ import { ActionOptionOrientation, LineListActionOption } from '../models';
10
9
  import * as i0 from "@angular/core";
11
10
  export declare class LineListTableComponent extends ReactWrapperModule {
12
11
  programId: string;
13
12
  orgUnit: string;
14
13
  programStageId?: string;
15
- actionOptions?: DropdownMenuOption[];
14
+ actionOptions?: LineListActionOption[];
16
15
  actionOptionOrientation: ActionOptionOrientation;
17
16
  attributeFilters?: AttributeFilter[];
18
17
  useOuModeWithOlderDHIS2Instance?: boolean;
@@ -0,0 +1,9 @@
1
+ export interface DropdownMenuOption {
2
+ id?: string;
3
+ label: string;
4
+ action?: string;
5
+ description?: string;
6
+ iconOnly?: boolean;
7
+ icon?: any;
8
+ destructive?: boolean;
9
+ }
@@ -1 +1,3 @@
1
1
  export * from './action-option-orientation.model';
2
+ export * from './dropdown-menu.model';
3
+ export * from './line-list-action-option.model';
@@ -0,0 +1,5 @@
1
+ import { TableRow } from './line-list.models';
2
+ import { DropdownMenuOption } from './dropdown-menu.model';
3
+ export interface LineListActionOption extends DropdownMenuOption {
4
+ onClick?: (tableRow: TableRow) => void;
5
+ }
@@ -14,6 +14,7 @@ export interface IProgramEntryFormConfig {
14
14
  disableEnrollmentDate?: boolean;
15
15
  disabledIncidentDate?: boolean;
16
16
  excludeProgramStages?: boolean;
17
+ excludeInheritedAttributes?: boolean;
17
18
  includedProgramStages?: string[];
18
19
  submitButtonLabel?: string;
19
20
  cancelButtonLabel?: string;
@@ -35,6 +36,7 @@ export declare class ProgramEntryFormConfig implements IProgramEntryFormConfig {
35
36
  disableEnrollmentDate?: boolean;
36
37
  disabledIncidentDate?: boolean;
37
38
  excludeProgramStages?: boolean;
39
+ excludeInheritedAttributes?: boolean;
38
40
  includedProgramStages?: string[];
39
41
  submitButtonLabel: string;
40
42
  cancelButtonLabel: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@iapps/ng-dhis2-ui",
3
- "version": "1.1.77",
3
+ "version": "1.1.78",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^19.0.0",
6
6
  "@angular/core": "^19.0.0",