ngrx-entity-crud 16.1.0 → 16.1.1
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/package.json +1 -1
- package/schematics/auth/files/views/login/components/logout-button/logout-button.component.ts +0 -1
- package/schematics/auth/files/views/login/login.module.ts +0 -1
- package/schematics/ng-add/files/src/app/root-store/root-reducer.ts +4 -3
- package/schematics/ng-add/files/src/app/root-store/router-store/pop-up-base.module.ts +0 -1
- package/schematics/ng-add/files/src/environments/environment.ts +2 -1
- package/schematics/section/files/ionic/__clazz@dasherize__/__clazz@dasherize__-edit/__clazz@dasherize__-edit.component.ts +2 -2
- package/schematics/section/files/ionic/__clazz@dasherize__/__clazz@dasherize__.module.ts +1 -1
- package/schematics/section/files/no-libs/__clazz@dasherize__/__clazz@dasherize__.module.ts +1 -1
- package/schematics/section/files/primeng/plural/__clazz@dasherize__/__clazz@dasherize__-edit/__clazz@dasherize__-edit.component.ts +2 -2
- package/schematics/section/files/primeng/plural/__clazz@dasherize__/__clazz@dasherize__.module.ts +1 -1
- package/schematics/section/files/primeng/singular/__clazz@dasherize__/__clazz@dasherize__.module.ts +1 -1
- package/schematics/store/files/crud-service/plural/__clazz@dasherize__.service.ts +1 -1
package/package.json
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import {ActionReducerMap, MetaReducer} from '@ngrx/store';
|
|
2
|
-
import {State} from '@root-store/state';
|
|
3
2
|
import {environment} from '../../environments/environment';
|
|
4
3
|
|
|
5
|
-
export
|
|
4
|
+
export interface AppState {}
|
|
6
5
|
|
|
7
|
-
export const
|
|
6
|
+
export const reducers: ActionReducerMap<AppState> = {};
|
|
7
|
+
|
|
8
|
+
export const metaReducers: MetaReducer<AppState>[] = !environment.production ? [] : [];
|
|
@@ -16,14 +16,14 @@ export class <%= clazz %>EditComponent extends EditBaseComponent<<%= clazz %>> {
|
|
|
16
16
|
form: FormGroup;
|
|
17
17
|
keys: string[];
|
|
18
18
|
|
|
19
|
-
setItemPerform(value: <%= clazz %>): void {
|
|
19
|
+
override setItemPerform(value: <%= clazz %>): void {
|
|
20
20
|
const group = this.fb.group({});
|
|
21
21
|
this.keys = Object.keys(value);
|
|
22
22
|
this.keys.forEach(key => group.addControl(key, this.fb.control({value: value[key], disabled: key === 'id'})));
|
|
23
23
|
this.form = group;
|
|
24
24
|
}
|
|
25
25
|
|
|
26
|
-
onSavePerform(item: <%= clazz %>): void {
|
|
26
|
+
override onSavePerform(item: <%= clazz %>): void {
|
|
27
27
|
this.store$.dispatch(<%= clazz %>StoreActions.EditRequest({
|
|
28
28
|
item, onResult: [
|
|
29
29
|
// azione che verrà invocata al result della chiamata all'interno dell'effect.
|
|
@@ -15,14 +15,14 @@ export class <%= clazz %>EditComponent extends PopUpBaseComponent<<%= clazz %>>
|
|
|
15
15
|
form: FormGroup;
|
|
16
16
|
keys: string[];
|
|
17
17
|
|
|
18
|
-
setItemPerform(value: <%= clazz %>): void {
|
|
18
|
+
override setItemPerform(value: <%= clazz %>): void {
|
|
19
19
|
const group = this.fb.group({});
|
|
20
20
|
this.keys = Object.keys(value);
|
|
21
21
|
this.keys.forEach(key => group.addControl(key, this.fb.control({value: value[key], disabled: key === 'id'})));
|
|
22
22
|
this.form = group;
|
|
23
23
|
}
|
|
24
24
|
|
|
25
|
-
acceptPerform(mutationParams: <%= clazz %>): void {
|
|
25
|
+
override acceptPerform(mutationParams: <%= clazz %>): void {
|
|
26
26
|
if (mutationParams.id) {
|
|
27
27
|
this.store$.dispatch(<%= clazz %>StoreActions.EditRequest({
|
|
28
28
|
mutationParams, onResult: [
|
|
@@ -7,5 +7,5 @@ import {BaseCrudService} from 'ngrx-entity-crud';
|
|
|
7
7
|
providedIn: 'root'
|
|
8
8
|
})
|
|
9
9
|
export class <%= clazz %>Service extends BaseCrudService<<%= clazz %>> {
|
|
10
|
-
|
|
10
|
+
public override service = environment.webServiceUri + '<%= dasherize(clazz) %>';
|
|
11
11
|
}
|