@eqproject/eqp-dynamic-module 2.0.5 → 2.0.7
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/README.md +81 -0
- package/esm2020/lib/components/exported/eqp-dynamic-module-configurator/eqp-dynamic-module-configurator.component.mjs +320 -137
- package/esm2020/lib/components/private/add-formula-field/add-formula-field.component.mjs +3 -3
- package/esm2020/lib/components/private/field-templates/list-value-field-template/list-value-field-template.component.mjs +3 -3
- package/esm2020/lib/models/dynamicModuleConfiguratorSpecificConfig.model.mjs +7 -2
- package/fesm2015/eqproject-eqp-dynamic-module.mjs +308 -120
- package/fesm2015/eqproject-eqp-dynamic-module.mjs.map +1 -1
- package/fesm2020/eqproject-eqp-dynamic-module.mjs +308 -120
- package/fesm2020/eqproject-eqp-dynamic-module.mjs.map +1 -1
- package/lib/components/exported/eqp-dynamic-module-configurator/eqp-dynamic-module-configurator.component.d.ts +30 -13
- package/lib/models/dynamicModuleConfiguratorSpecificConfig.model.d.ts +1 -0
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -44,6 +44,87 @@ Input
|
|
|
44
44
|
### eqp-dynamic-module-configurator
|
|
45
45
|
Componente che permette la configurazione delle form dinamiche
|
|
46
46
|
|
|
47
|
+
4 modalità d'uso:
|
|
48
|
+
## Nuovo Modulo:
|
|
49
|
+
```js
|
|
50
|
+
let specific: DynamicModuleConfiguratorSpecificConfig = new DynamicModuleConfiguratorSpecificConfig();
|
|
51
|
+
specific.UserID = this.currentUser.ID
|
|
52
|
+
specific.orgaID = this.currentOrga.ID;
|
|
53
|
+
let general: DynamicModuleGeneralConfig = new DynamicModuleGeneralConfig(this.baseServerUrl, "", this.context, null)
|
|
54
|
+
|
|
55
|
+
this.config = new DynamicModuleConfiguratorConfig(general, specific)
|
|
56
|
+
this.loader=true;
|
|
57
|
+
```
|
|
58
|
+
```html
|
|
59
|
+
<eqp-dynamic-module-configurator
|
|
60
|
+
*ngIf="loader"
|
|
61
|
+
[configurations] = "config"
|
|
62
|
+
(saveFormEvent)="onSaveForm($event)">
|
|
63
|
+
</eqp-dynamic-module-configurator>
|
|
64
|
+
```
|
|
65
|
+
|
|
66
|
+
## Modifica di un modulo esistente:
|
|
67
|
+
```js
|
|
68
|
+
let specific: DynamicModuleConfiguratorSpecificConfig = new DynamicModuleConfiguratorSpecificConfig();
|
|
69
|
+
specific.UserID = this.currentOrga.ID
|
|
70
|
+
specific.orgaID = "2";
|
|
71
|
+
let general: DynamicModuleGeneralConfig = new DynamicModuleGeneralConfig(this.baseServerUrl, "", this.context, null)
|
|
72
|
+
|
|
73
|
+
this.config = new DynamicModuleConfiguratorConfig(general, specific)
|
|
74
|
+
this.formID = "xxxxxx-xxxxxx-xxxxxx";
|
|
75
|
+
this.loader=true;
|
|
76
|
+
```
|
|
77
|
+
```html
|
|
78
|
+
<eqp-dynamic-module-configurator
|
|
79
|
+
*ngIf="loader"
|
|
80
|
+
[configurations] = "config"
|
|
81
|
+
[formID]="formID"
|
|
82
|
+
(saveFormEvent)="onSaveForm($event)">
|
|
83
|
+
</eqp-dynamic-module-configurator>
|
|
84
|
+
```
|
|
85
|
+
## Esportazione di un modulo dato l'ID:
|
|
86
|
+
```js
|
|
87
|
+
let specific: DynamicModuleConfiguratorSpecificConfig = new DynamicModuleConfiguratorSpecificConfig();
|
|
88
|
+
specific.UserID = this.currentOrga.ID
|
|
89
|
+
specific.orgaID = "2";
|
|
90
|
+
let general: DynamicModuleGeneralConfig = new DynamicModuleGeneralConfig(this.baseServerUrl, "", this.context, null)
|
|
91
|
+
|
|
92
|
+
this.config = new DynamicModuleConfiguratorConfig(general, specific)
|
|
93
|
+
this.formID = "xxxxxx-xxxxxx-xxxxxx";
|
|
94
|
+
this.loader=true;
|
|
95
|
+
```
|
|
96
|
+
```html
|
|
97
|
+
<eqp-dynamic-module-configurator
|
|
98
|
+
*ngIf="loader"
|
|
99
|
+
[configurations] = "config"
|
|
100
|
+
[formID]="formID"
|
|
101
|
+
[viewMode] = "'Export'"
|
|
102
|
+
(saveFormEvent)="onSaveForm($event)">
|
|
103
|
+
</eqp-dynamic-module-configurator>
|
|
104
|
+
```
|
|
105
|
+
## importazione di un modulo dato il JSON:
|
|
106
|
+
```js
|
|
107
|
+
let specific: DynamicModuleConfiguratorSpecificConfig = new DynamicModuleConfiguratorSpecificConfig();
|
|
108
|
+
specific.UserID = this.currentOrga.ID
|
|
109
|
+
specific.orgaID = "2";
|
|
110
|
+
specific.form = JSON.parse(this.stringForm)
|
|
111
|
+
let general: DynamicModuleGeneralConfig = new DynamicModuleGeneralConfig(this.baseServerUrl, "", this.context, null)
|
|
112
|
+
|
|
113
|
+
this.config = new DynamicModuleConfiguratorConfig(general, specific)
|
|
114
|
+
this.formID = null;
|
|
115
|
+
this.loader=true;
|
|
116
|
+
```
|
|
117
|
+
```html
|
|
118
|
+
<eqp-dynamic-module-configurator
|
|
119
|
+
*ngIf="loader"
|
|
120
|
+
[configurations] = "config"
|
|
121
|
+
[formID]="formID"
|
|
122
|
+
[viewMode] = "'Export'"
|
|
123
|
+
(saveFormEvent)="onSaveForm($event)">
|
|
124
|
+
</eqp-dynamic-module-configurator>
|
|
125
|
+
```
|
|
126
|
+
|
|
127
|
+
|
|
47
128
|
| Input | Descrizione |
|
|
48
129
|
| ----- | ----------- |
|
|
49
130
|
| configurations: DynamicModuleConfiguratorConfig | an object that is a configurations container. It holds 2 objects: dynamicModuleGeneralConfig, DynamicModuleConfiguratorSpecificConfig |
|