@sumaris-net/ngx-components 2.5.0-beta2 → 2.5.0-beta3
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.
- package/esm2020/src/app/core/account/account.page.mjs +11 -7
- package/esm2020/src/app/core/form/properties/properties.table.mjs +130 -61
- package/esm2020/src/app/shared/material/boolean/material.boolean.mjs +3 -3
- package/fesm2015/sumaris-net.ngx-components.mjs +135 -71
- package/fesm2015/sumaris-net.ngx-components.mjs.map +1 -1
- package/fesm2020/sumaris-net.ngx-components.mjs +128 -60
- package/fesm2020/sumaris-net.ngx-components.mjs.map +1 -1
- package/package.json +1 -1
- package/src/app/core/account/account.page.d.ts +5 -1
- package/src/app/core/form/properties/properties.table.d.ts +21 -10
- package/src/assets/i18n/en-US.json +5 -0
- package/src/assets/i18n/en.json +5 -0
- package/src/assets/i18n/fr.json +5 -1
package/package.json
CHANGED
|
@@ -53,7 +53,11 @@ export declare class AccountPage extends AppForm<Account> implements OnInit, OnD
|
|
|
53
53
|
stopListenChanges(): void;
|
|
54
54
|
sendConfirmationEmail(event: MouseEvent): Promise<boolean>;
|
|
55
55
|
save(event: any): Promise<boolean>;
|
|
56
|
-
enable(
|
|
56
|
+
enable(opts?: {
|
|
57
|
+
accountReadOnly?: boolean;
|
|
58
|
+
onlySelf?: boolean;
|
|
59
|
+
emitEvent?: boolean;
|
|
60
|
+
}): void;
|
|
57
61
|
cancel(): Promise<void>;
|
|
58
62
|
close(event?: Event): Promise<boolean>;
|
|
59
63
|
protected markForCheck(): void;
|
|
@@ -2,17 +2,17 @@ import { AppInMemoryTable } from '../../table/memory-table.class';
|
|
|
2
2
|
import { Injector, OnInit } from '@angular/core';
|
|
3
3
|
import { Entity, EntityAsObjectOptions } from '../../services/model/entity.model';
|
|
4
4
|
import { AppValidatorService } from '../../services/validator/base.validator.class';
|
|
5
|
-
import { UntypedFormBuilder, UntypedFormGroup } from '@angular/forms';
|
|
5
|
+
import { AbstractControl, UntypedFormBuilder, UntypedFormGroup } from '@angular/forms';
|
|
6
6
|
import { FormFieldDefinition, FormFieldDefinitionMap } from '../../../shared/form/field.model';
|
|
7
|
-
import { FilterFn
|
|
8
|
-
import { BehaviorSubject } from 'rxjs';
|
|
7
|
+
import { FilterFn } from '../../../shared/services/entity-service.class';
|
|
9
8
|
import { Environment } from '../../../../environments/environment.class';
|
|
10
9
|
import { TableElement } from '@e-is/ngx-material-table';
|
|
11
10
|
import { EntityFilter } from '../../services/model/filter.model';
|
|
12
11
|
import { ObjectMap } from '../../../shared/types';
|
|
12
|
+
import { MatExpansionPanel } from '@angular/material/expansion';
|
|
13
13
|
import * as i0 from "@angular/core";
|
|
14
14
|
interface TranslatedFormFieldDefinition extends FormFieldDefinition {
|
|
15
|
-
|
|
15
|
+
translatedName?: string;
|
|
16
16
|
}
|
|
17
17
|
export declare class PropertyEntity extends Entity<PropertyEntity, string> {
|
|
18
18
|
static fromObject: (source: any, opts?: any) => PropertyEntity;
|
|
@@ -23,10 +23,12 @@ export declare class PropertyEntity extends Entity<PropertyEntity, string> {
|
|
|
23
23
|
}
|
|
24
24
|
export declare class PropertyEntityFilter extends EntityFilter<PropertyEntityFilter, PropertyEntity> {
|
|
25
25
|
static fromObject: (source: any, opts?: any) => PropertyEntityFilter;
|
|
26
|
-
|
|
26
|
+
searchText: string;
|
|
27
|
+
notDefaultOnly: boolean;
|
|
27
28
|
fromObject(source: any): void;
|
|
28
29
|
asObject(opts?: EntityAsObjectOptions): any;
|
|
29
30
|
protected buildFilter(): FilterFn<PropertyEntity>[];
|
|
31
|
+
protected isCriteriaNotEmpty(key: string, value: any): boolean;
|
|
30
32
|
}
|
|
31
33
|
export declare class PropertyEntityValidator extends AppValidatorService<PropertyEntity> {
|
|
32
34
|
protected formBuilder: UntypedFormBuilder;
|
|
@@ -43,10 +45,12 @@ export declare class AppPropertiesTable extends AppInMemoryTable<PropertyEntity,
|
|
|
43
45
|
protected validatorService: PropertyEntityValidator;
|
|
44
46
|
definitions: FormFieldDefinition[];
|
|
45
47
|
showToolbar: boolean;
|
|
46
|
-
|
|
48
|
+
filterExpansionPanel: MatExpansionPanel;
|
|
47
49
|
definitionsMapByKey: FormFieldDefinitionMap;
|
|
48
50
|
translationsByKey: ObjectMap<string>;
|
|
49
51
|
filterForm: UntypedFormGroup;
|
|
52
|
+
filterCriteriaCount: number;
|
|
53
|
+
filterPanelFloating: boolean;
|
|
50
54
|
constructor(injector: Injector, formBuilder: UntypedFormBuilder, validatorService: PropertyEntityValidator, environment: Environment);
|
|
51
55
|
ngOnInit(): void;
|
|
52
56
|
get value(): PropertyEntity[];
|
|
@@ -54,12 +58,19 @@ export declare class AppPropertiesTable extends AppInMemoryTable<PropertyEntity,
|
|
|
54
58
|
setValue(value: PropertyEntity[], opts?: {
|
|
55
59
|
emitEvent?: boolean;
|
|
56
60
|
}): void;
|
|
57
|
-
|
|
58
|
-
|
|
61
|
+
clearControlValue(event: Event, formControl: AbstractControl): boolean;
|
|
62
|
+
resetFilter(value?: any, opts?: {
|
|
63
|
+
emitEvent: boolean;
|
|
64
|
+
}): void;
|
|
65
|
+
setFilter(filter: PropertyEntityFilter, opts?: {
|
|
59
66
|
emitEvent?: boolean;
|
|
60
|
-
}):
|
|
61
|
-
|
|
67
|
+
}): void;
|
|
68
|
+
get filterIsEmpty(): boolean;
|
|
69
|
+
toggleFilterPanelFloating(): void;
|
|
70
|
+
closeFilterPanel(): void;
|
|
71
|
+
applyFilterAndClosePanel(event?: Event): void;
|
|
62
72
|
toTranslatedFormFieldDefinition: (definition: FormFieldDefinition) => TranslatedFormFieldDefinition;
|
|
73
|
+
resetProperty(event: UIEvent, row: TableElement<PropertyEntity>): void;
|
|
63
74
|
static ɵfac: i0.ɵɵFactoryDeclaration<AppPropertiesTable, never>;
|
|
64
75
|
static ɵcmp: i0.ɵɵComponentDeclaration<AppPropertiesTable, "app-properties-table", never, { "definitions": "definitions"; "showToolbar": "showToolbar"; }, {}, never, never, false>;
|
|
65
76
|
}
|
|
@@ -322,6 +322,7 @@
|
|
|
322
322
|
"PROPERTY_KEY": "Entry field",
|
|
323
323
|
"PROPERTY_VALUE": "Display",
|
|
324
324
|
"BTN_ADD_PROPERTY": "Add a entry field",
|
|
325
|
+
"BTN_RESET_PROPERTY": "Reset option",
|
|
325
326
|
"FIELDS": {
|
|
326
327
|
"DEPARTMENT": "Dropdown list > Departments",
|
|
327
328
|
"ATTRIBUTES": {
|
|
@@ -331,6 +332,10 @@
|
|
|
331
332
|
"NAME_LABEL": "Name - Code"
|
|
332
333
|
}
|
|
333
334
|
},
|
|
335
|
+
"FILTER": {
|
|
336
|
+
"SEARCH": "Search : Option",
|
|
337
|
+
"ONLY_NOT_DEFAULT": "Show only personal options"
|
|
338
|
+
},
|
|
334
339
|
"ERROR": {
|
|
335
340
|
"PEER_NOT_REACHABLE": "Unreachable node"
|
|
336
341
|
}
|
package/src/assets/i18n/en.json
CHANGED
|
@@ -322,6 +322,7 @@
|
|
|
322
322
|
"PROPERTY_KEY": "Entry field",
|
|
323
323
|
"PROPERTY_VALUE": "Display",
|
|
324
324
|
"BTN_ADD_PROPERTY": "Add a entry field",
|
|
325
|
+
"BTN_RESET_PROPERTY": "Reset option",
|
|
325
326
|
"FIELDS": {
|
|
326
327
|
"DEPARTMENT": "Dropdown list > Departments",
|
|
327
328
|
"ATTRIBUTES": {
|
|
@@ -331,6 +332,10 @@
|
|
|
331
332
|
"NAME_LABEL": "Name - Code"
|
|
332
333
|
}
|
|
333
334
|
},
|
|
335
|
+
"FILTER": {
|
|
336
|
+
"SEARCH": "Search : Option",
|
|
337
|
+
"ONLY_NOT_DEFAULT": "Show only personal options"
|
|
338
|
+
},
|
|
334
339
|
"ERROR": {
|
|
335
340
|
"PEER_NOT_REACHABLE": "Unreachable node"
|
|
336
341
|
}
|
package/src/assets/i18n/fr.json
CHANGED
|
@@ -321,7 +321,7 @@
|
|
|
321
321
|
"PROPERTY_KEY": "Option",
|
|
322
322
|
"PROPERTY_VALUE": "Valeur",
|
|
323
323
|
"BTN_ADD_PROPERTY": "Ajouter une option",
|
|
324
|
-
"
|
|
324
|
+
"BTN_RESET_PROPERTY": "Réinitialiser l'option",
|
|
325
325
|
"FIELDS": {
|
|
326
326
|
"DEPARTMENT": "Liste déroulante > Organismes",
|
|
327
327
|
"ATTRIBUTES": {
|
|
@@ -331,6 +331,10 @@
|
|
|
331
331
|
"NAME_LABEL": "Libellé - Code"
|
|
332
332
|
}
|
|
333
333
|
},
|
|
334
|
+
"FILTER": {
|
|
335
|
+
"SEARCH": "Recherche : Option",
|
|
336
|
+
"ONLY_NOT_DEFAULT": "Afficher seulement les options personnelles"
|
|
337
|
+
},
|
|
334
338
|
"ERROR": {
|
|
335
339
|
"PEER_NOT_REACHABLE": "nœud injoignable"
|
|
336
340
|
}
|