@sumaris-net/ngx-components 18.22.14 → 18.22.15
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/doc/changelog.md +3 -0
- package/esm2022/src/app/shared/services/memory-entity-service.class.mjs +24 -19
- package/fesm2022/sumaris-net.ngx-components.mjs +23 -18
- package/fesm2022/sumaris-net.ngx-components.mjs.map +1 -1
- package/package.json +1 -1
- package/src/app/shared/services/memory-entity-service.class.d.ts +17 -10
- package/src/assets/manifest.json +1 -1
package/package.json
CHANGED
|
@@ -18,27 +18,34 @@ export interface InMemoryEntitiesServiceOptions<T, F> {
|
|
|
18
18
|
[key: string]: string;
|
|
19
19
|
};
|
|
20
20
|
}
|
|
21
|
-
export declare class InMemoryEntitiesService<T extends IEntity<T, ID>, F = any, ID = number, O extends EntitiesServiceWatchOptions = EntitiesServiceWatchOptions> extends StartableObservableService<T[], T[]> implements IEntitiesService<T, F, O>, OnDestroy {
|
|
21
|
+
export declare class InMemoryEntitiesService<T extends IEntity<T, ID>, F = any, ID = number, O extends EntitiesServiceWatchOptions = EntitiesServiceWatchOptions, SO extends InMemoryEntitiesServiceOptions<T, F> = InMemoryEntitiesServiceOptions<T, F>> extends StartableObservableService<T[], T[]> implements IEntitiesService<T, F, O>, OnDestroy {
|
|
22
22
|
protected dataType: new () => T;
|
|
23
23
|
protected filterType: new () => F;
|
|
24
24
|
debug: boolean;
|
|
25
25
|
private _hiddenData;
|
|
26
26
|
readonly dirtySubject: BehaviorSubject<boolean>;
|
|
27
27
|
readonly savingSubject: BehaviorSubject<boolean>;
|
|
28
|
-
protected
|
|
28
|
+
protected sortByReplacement: {
|
|
29
29
|
[key: string]: string;
|
|
30
30
|
};
|
|
31
|
-
private
|
|
32
|
-
private
|
|
33
|
-
private
|
|
34
|
-
private
|
|
35
|
-
private
|
|
31
|
+
private _sortFn;
|
|
32
|
+
private _onLoad;
|
|
33
|
+
private _onSaveFn;
|
|
34
|
+
private _equalsFn;
|
|
35
|
+
private _filterFnFactory;
|
|
36
36
|
get defaultFetchPolicy(): 'cache-only';
|
|
37
37
|
set value(data: T[]);
|
|
38
38
|
get value(): T[];
|
|
39
39
|
get saving(): boolean;
|
|
40
40
|
get dirty(): boolean;
|
|
41
|
-
constructor(dataType: new () => T, filterType: new () => F, options?:
|
|
41
|
+
constructor(dataType: new () => T, filterType: new () => F, options?: SO);
|
|
42
|
+
/**
|
|
43
|
+
* Configures and sets options for the instance.
|
|
44
|
+
*
|
|
45
|
+
* @param {SO} options - An object containing configuration options such as `onSort`, `onLoad`, `onSave`, `equals`, `filterFnFactory`, and `sortByReplacement`.
|
|
46
|
+
* @return {void} This method does not return a value.
|
|
47
|
+
*/
|
|
48
|
+
setOptions(options: SO): void;
|
|
42
49
|
protected ngOnStart(data?: T[]): Promise<T[]>;
|
|
43
50
|
protected ngOnStop(): Promise<void>;
|
|
44
51
|
ngOnDestroy(): void;
|
|
@@ -74,6 +81,6 @@ export declare class InMemoryEntitiesService<T extends IEntity<T, ID>, F = any,
|
|
|
74
81
|
protected waitWhileSaving(opts?: WaitForOptions): Promise<void>;
|
|
75
82
|
protected markAsSaving(): void;
|
|
76
83
|
protected markAsSaved(): void;
|
|
77
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<InMemoryEntitiesService<any, any, any, any>, never>;
|
|
78
|
-
static ɵdir: i0.ɵɵDirectiveDeclaration<InMemoryEntitiesService<any, any, any, any>, never, never, {}, {}, never, never, false, never>;
|
|
84
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<InMemoryEntitiesService<any, any, any, any, any>, never>;
|
|
85
|
+
static ɵdir: i0.ɵɵDirectiveDeclaration<InMemoryEntitiesService<any, any, any, any, any>, never, never, {}, {}, never, never, false, never>;
|
|
79
86
|
}
|
package/src/assets/manifest.json
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
"name": "ngx-sumaris-components",
|
|
3
3
|
"short_name": "ngx-sumaris-components",
|
|
4
4
|
"manifest_version": 1,
|
|
5
|
-
"version": "18.22.
|
|
5
|
+
"version": "18.22.15",
|
|
6
6
|
"default_locale": "fr",
|
|
7
7
|
"description": "Angular components for building beautiful and responsive Apps",
|
|
8
8
|
"icons": [{
|