@fluxhub/fluxhub-lib 9.0.40 → 9.0.41
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/bundles/fluxhub-fluxhub-lib.umd.js +239 -204
- package/bundles/fluxhub-fluxhub-lib.umd.js.map +1 -1
- package/bundles/fluxhub-fluxhub-lib.umd.min.js +2 -2
- package/bundles/fluxhub-fluxhub-lib.umd.min.js.map +1 -1
- package/esm2015/lib/controls/grid_editors/checkbox-editor.component.js +39 -0
- package/esm2015/lib/fluxhub-lib.module.js +4 -3
- package/esm2015/public_api.js +2 -1
- package/esm5/lib/controls/grid_editors/checkbox-editor.component.js +38 -0
- package/esm5/lib/fluxhub-lib.module.js +4 -3
- package/esm5/public_api.js +2 -1
- package/fesm2015/fluxhub-fluxhub-lib.js +226 -191
- package/fesm2015/fluxhub-fluxhub-lib.js.map +1 -1
- package/fesm5/fluxhub-fluxhub-lib.js +238 -204
- package/fesm5/fluxhub-fluxhub-lib.js.map +1 -1
- package/fluxhub-fluxhub-lib.metadata.json +1 -1
- package/package.json +1 -1
- package/public_api.d.ts +1 -0
- package/lib/controls/app_manager/fhrolemanager.d.ts +0 -16
- package/lib/controls/app_manager/fhtablevaluesmanager.d.ts +0 -16
- package/lib/controls/app_manager/win_manage_roles.d.ts +0 -27
- package/lib/controls/app_manager/win_manage_values.d.ts +0 -27
- package/lib/controls/grid_editors/approvabuttons.d.ts +0 -13
- package/lib/controls/grid_editors/currency.component.d.ts +0 -6
- package/lib/controls/grid_editors/fhcombobox_filter.d.ts +0 -45
- package/lib/controls/grid_editors/numeric-editor.component.d.ts +0 -20
- package/lib/controls/grid_editors/select-editor.component.d.ts +0 -20
- package/lib/controls/grid_editors/textarea-editor.component.d.ts +0 -17
- package/lib/controls/image-viewer/image-viewer-config.model.d.ts +0 -34
- package/lib/controls/image-viewer/image-viewer.component.d.ts +0 -53
- package/lib/controls/image-viewer/save_pipe.d.ts +0 -7
- package/lib/controls/utils/MomentDateAdapter.d.ts +0 -33
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { __decorate, __metadata, __param } from 'tslib';
|
|
2
2
|
import { ɵɵdefineInjectable, Injectable, ɵɵinject, ViewChild, ViewContainerRef, Component, Directive, forwardRef, EventEmitter, Input, Output, Inject, ElementRef, HostListener, Pipe, PLATFORM_ID, Optional, NgModule } from '@angular/core';
|
|
3
|
+
import { SimpleCrypt } from 'ngx-simple-crypt';
|
|
4
|
+
import { AES, enc } from 'crypto-js';
|
|
3
5
|
import { HttpHeaders, HttpClient } from '@angular/common/http';
|
|
4
6
|
import { ToastrService } from 'ngx-toastr';
|
|
5
7
|
import { map, catchError, flatMap } from 'rxjs/operators';
|
|
6
8
|
import { Observable } from 'rxjs';
|
|
7
|
-
import { SimpleCrypt } from 'ngx-simple-crypt';
|
|
8
|
-
import { AES, enc } from 'crypto-js';
|
|
9
9
|
import { MatDialogRef, MatDialog, MAT_DIALOG_DATA, MatDialogModule } from '@angular/material/dialog';
|
|
10
10
|
import { NgControl, NG_VALUE_ACCESSOR, FormsModule } from '@angular/forms';
|
|
11
11
|
import { FileUploader, FileUploadModule } from 'ng2-file-upload';
|
|
@@ -160,192 +160,6 @@ AppService = __decorate([
|
|
|
160
160
|
})
|
|
161
161
|
], AppService);
|
|
162
162
|
|
|
163
|
-
class QGResult {
|
|
164
|
-
}
|
|
165
|
-
|
|
166
|
-
let OdbcService = class OdbcService {
|
|
167
|
-
constructor(http, app_s, toastr) {
|
|
168
|
-
this.http = http;
|
|
169
|
-
this.app_s = app_s;
|
|
170
|
-
this.toastr = toastr;
|
|
171
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.ODBC_ENDPOINT; // URL to web API
|
|
172
|
-
}
|
|
173
|
-
doQuery(queryp, displayError = true) {
|
|
174
|
-
this.headers = new HttpHeaders({
|
|
175
|
-
'Content-Type': 'application/json',
|
|
176
|
-
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
177
|
-
});
|
|
178
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.ODBC_ENDPOINT;
|
|
179
|
-
let post_v = JSON.stringify(queryp);
|
|
180
|
-
return this.http.post(this.url, post_v, { headers: this.headers })
|
|
181
|
-
.pipe(map((res) => {
|
|
182
|
-
// Handle errors, display if enabled
|
|
183
|
-
let err;
|
|
184
|
-
if (!res) {
|
|
185
|
-
err = new Error('Empty server response');
|
|
186
|
-
}
|
|
187
|
-
else if (res.result_msg === 'KO') {
|
|
188
|
-
err = new Error(res.msg);
|
|
189
|
-
}
|
|
190
|
-
if (err) {
|
|
191
|
-
console.error(err);
|
|
192
|
-
if (displayError) {
|
|
193
|
-
this.toastr.error(err.message);
|
|
194
|
-
}
|
|
195
|
-
throw new Error(err);
|
|
196
|
-
}
|
|
197
|
-
return res || new QGResult();
|
|
198
|
-
}), catchError((err) => {
|
|
199
|
-
// In a real world app, we might use a remote logging infrastructure
|
|
200
|
-
// We'd also dig deeper into the error to get a better message
|
|
201
|
-
let errMsg = (err.message) ? err.message : err.status ? `${err.status} - ${err.statusText}` : 'Server error';
|
|
202
|
-
console.error(errMsg); // log to console instead
|
|
203
|
-
throw err;
|
|
204
|
-
}));
|
|
205
|
-
}
|
|
206
|
-
};
|
|
207
|
-
OdbcService.ctorParameters = () => [
|
|
208
|
-
{ type: HttpClient },
|
|
209
|
-
{ type: AppService },
|
|
210
|
-
{ type: ToastrService }
|
|
211
|
-
];
|
|
212
|
-
OdbcService.ɵprov = ɵɵdefineInjectable({ factory: function OdbcService_Factory() { return new OdbcService(ɵɵinject(HttpClient), ɵɵinject(AppService), ɵɵinject(ToastrService)); }, token: OdbcService, providedIn: "root" });
|
|
213
|
-
OdbcService = __decorate([
|
|
214
|
-
Injectable({
|
|
215
|
-
providedIn: 'root',
|
|
216
|
-
}),
|
|
217
|
-
__metadata("design:paramtypes", [HttpClient, AppService, ToastrService])
|
|
218
|
-
], OdbcService);
|
|
219
|
-
|
|
220
|
-
let FileService = class FileService {
|
|
221
|
-
constructor(http, app_s, toastr) {
|
|
222
|
-
this.http = http;
|
|
223
|
-
this.app_s = app_s;
|
|
224
|
-
this.toastr = toastr;
|
|
225
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.FILE_ENDPOINT; // URL to web API this.app_s.API_ENDPOINT
|
|
226
|
-
}
|
|
227
|
-
doQuery(queryp, displayError = true) {
|
|
228
|
-
this.headers = new HttpHeaders({
|
|
229
|
-
'Content-Type': 'application/json',
|
|
230
|
-
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
231
|
-
});
|
|
232
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.FILE_ENDPOINT;
|
|
233
|
-
// console.log('FileService url: '+ this.url);
|
|
234
|
-
let post_v = JSON.stringify(queryp);
|
|
235
|
-
// console.log(post_v);
|
|
236
|
-
return this.http.post(this.url, post_v, {
|
|
237
|
-
headers: this.headers
|
|
238
|
-
}).pipe(map((res) => {
|
|
239
|
-
// Handle errors, display if enabled
|
|
240
|
-
let r = res;
|
|
241
|
-
let err;
|
|
242
|
-
if (!res) {
|
|
243
|
-
err = new Error('Empty server response');
|
|
244
|
-
}
|
|
245
|
-
else if (r.result_msg === 'KO') {
|
|
246
|
-
err = new Error(r.msg);
|
|
247
|
-
}
|
|
248
|
-
if (err) {
|
|
249
|
-
console.error(err);
|
|
250
|
-
if (displayError) {
|
|
251
|
-
this.toastr.error(err.message);
|
|
252
|
-
}
|
|
253
|
-
throw new Error(err);
|
|
254
|
-
}
|
|
255
|
-
return res || new QGResult();
|
|
256
|
-
}), catchError((err) => {
|
|
257
|
-
// In a real world app, we might use a remote logging infrastructure
|
|
258
|
-
// We'd also dig deeper into the error to get a better message
|
|
259
|
-
let errMsg = (err.message) ? err.message : err.status ? `${err.status} - ${err.statusText}` : 'Server error';
|
|
260
|
-
console.error(errMsg); // log to console instead
|
|
261
|
-
throw err;
|
|
262
|
-
}));
|
|
263
|
-
}
|
|
264
|
-
};
|
|
265
|
-
FileService.ctorParameters = () => [
|
|
266
|
-
{ type: HttpClient },
|
|
267
|
-
{ type: AppService },
|
|
268
|
-
{ type: ToastrService }
|
|
269
|
-
];
|
|
270
|
-
FileService.ɵprov = ɵɵdefineInjectable({ factory: function FileService_Factory() { return new FileService(ɵɵinject(HttpClient), ɵɵinject(AppService), ɵɵinject(ToastrService)); }, token: FileService, providedIn: "root" });
|
|
271
|
-
FileService = __decorate([
|
|
272
|
-
Injectable({
|
|
273
|
-
providedIn: 'root',
|
|
274
|
-
}),
|
|
275
|
-
__metadata("design:paramtypes", [HttpClient, AppService, ToastrService])
|
|
276
|
-
], FileService);
|
|
277
|
-
|
|
278
|
-
let AppMakerService = class AppMakerService {
|
|
279
|
-
constructor(http, app_s, toastr) {
|
|
280
|
-
this.http = http;
|
|
281
|
-
this.app_s = app_s;
|
|
282
|
-
this.toastr = toastr;
|
|
283
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.APPMAKER_ENDPOINT; // URL to web API
|
|
284
|
-
}
|
|
285
|
-
doQuery(queryp, displayError = true) {
|
|
286
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.APPMAKER_ENDPOINT;
|
|
287
|
-
this.headers = new HttpHeaders({
|
|
288
|
-
'Content-Type': 'application/json',
|
|
289
|
-
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
290
|
-
});
|
|
291
|
-
// console.log('AppMakerService url: '+ this.url);
|
|
292
|
-
let post_v = JSON.stringify(queryp);
|
|
293
|
-
// console.log(post_v);
|
|
294
|
-
return this.http.post(this.url, post_v)
|
|
295
|
-
.pipe(map((res) => {
|
|
296
|
-
// Handle errors, display if enabled
|
|
297
|
-
let r = res;
|
|
298
|
-
let err;
|
|
299
|
-
if (!res) {
|
|
300
|
-
err = new Error('Empty server response');
|
|
301
|
-
}
|
|
302
|
-
else if (r.result_msg === 'KO') {
|
|
303
|
-
err = new Error(r.msg);
|
|
304
|
-
}
|
|
305
|
-
if (err) {
|
|
306
|
-
console.error(err);
|
|
307
|
-
if (displayError) {
|
|
308
|
-
this.toastr.error(err.message);
|
|
309
|
-
}
|
|
310
|
-
throw new Error(err);
|
|
311
|
-
}
|
|
312
|
-
return r || new QGResult();
|
|
313
|
-
}), catchError((err) => {
|
|
314
|
-
// In a real world app, we might use a remote logging infrastructure
|
|
315
|
-
// We'd also dig deeper into the error to get a better message
|
|
316
|
-
let errMsg = (err.message) ? err.message : err.status ? `${err.status} - ${err.statusText}` : 'Server error';
|
|
317
|
-
console.error(errMsg); // log to console instead
|
|
318
|
-
throw err;
|
|
319
|
-
}));
|
|
320
|
-
}
|
|
321
|
-
extractData(res) {
|
|
322
|
-
//console.log(res);
|
|
323
|
-
let body = res.json();
|
|
324
|
-
// console.log(body);
|
|
325
|
-
return body || {};
|
|
326
|
-
}
|
|
327
|
-
handleError(error) {
|
|
328
|
-
// In a real world app, we might use a remote logging infrastructure
|
|
329
|
-
// We'd also dig deeper into the error to get a better message
|
|
330
|
-
let errMsg = (error.message) ? error.message :
|
|
331
|
-
error.status ? `${error.status} - ${error.statusText}` : 'Server error';
|
|
332
|
-
console.error(errMsg); // log to console instead
|
|
333
|
-
return Observable.throw(errMsg);
|
|
334
|
-
}
|
|
335
|
-
};
|
|
336
|
-
AppMakerService.ctorParameters = () => [
|
|
337
|
-
{ type: HttpClient },
|
|
338
|
-
{ type: AppService },
|
|
339
|
-
{ type: ToastrService }
|
|
340
|
-
];
|
|
341
|
-
AppMakerService.ɵprov = ɵɵdefineInjectable({ factory: function AppMakerService_Factory() { return new AppMakerService(ɵɵinject(HttpClient), ɵɵinject(AppService), ɵɵinject(ToastrService)); }, token: AppMakerService, providedIn: "root" });
|
|
342
|
-
AppMakerService = __decorate([
|
|
343
|
-
Injectable({
|
|
344
|
-
providedIn: 'root',
|
|
345
|
-
}),
|
|
346
|
-
__metadata("design:paramtypes", [HttpClient, AppService, ToastrService])
|
|
347
|
-
], AppMakerService);
|
|
348
|
-
|
|
349
163
|
var UtilityService_1;
|
|
350
164
|
let UtilityService = UtilityService_1 = class UtilityService {
|
|
351
165
|
constructor(app_s) {
|
|
@@ -869,6 +683,227 @@ UtilityService = UtilityService_1 = __decorate([
|
|
|
869
683
|
__metadata("design:paramtypes", [AppService])
|
|
870
684
|
], UtilityService);
|
|
871
685
|
|
|
686
|
+
let CheckboxEditorComponent = class CheckboxEditorComponent {
|
|
687
|
+
constructor(uti_s) {
|
|
688
|
+
this.uti_s = uti_s;
|
|
689
|
+
}
|
|
690
|
+
agInit(params) {
|
|
691
|
+
this.params = params;
|
|
692
|
+
this.value = this.params.value;
|
|
693
|
+
}
|
|
694
|
+
getValue() {
|
|
695
|
+
return this.value;
|
|
696
|
+
}
|
|
697
|
+
ngAfterViewInit() {
|
|
698
|
+
setTimeout(() => {
|
|
699
|
+
this.input.element.nativeElement.focus();
|
|
700
|
+
});
|
|
701
|
+
}
|
|
702
|
+
};
|
|
703
|
+
CheckboxEditorComponent.ctorParameters = () => [
|
|
704
|
+
{ type: UtilityService }
|
|
705
|
+
];
|
|
706
|
+
__decorate([
|
|
707
|
+
ViewChild('input', { read: ViewContainerRef }),
|
|
708
|
+
__metadata("design:type", Object)
|
|
709
|
+
], CheckboxEditorComponent.prototype, "input", void 0);
|
|
710
|
+
CheckboxEditorComponent = __decorate([
|
|
711
|
+
Component({
|
|
712
|
+
selector: 'checkbox-cell',
|
|
713
|
+
template: `
|
|
714
|
+
<FHCheckBox [(ngModel)]="value" label="Altra Normativa">
|
|
715
|
+
</FHCheckBox>
|
|
716
|
+
`
|
|
717
|
+
}),
|
|
718
|
+
__metadata("design:paramtypes", [UtilityService])
|
|
719
|
+
], CheckboxEditorComponent);
|
|
720
|
+
|
|
721
|
+
class QGResult {
|
|
722
|
+
}
|
|
723
|
+
|
|
724
|
+
let OdbcService = class OdbcService {
|
|
725
|
+
constructor(http, app_s, toastr) {
|
|
726
|
+
this.http = http;
|
|
727
|
+
this.app_s = app_s;
|
|
728
|
+
this.toastr = toastr;
|
|
729
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.ODBC_ENDPOINT; // URL to web API
|
|
730
|
+
}
|
|
731
|
+
doQuery(queryp, displayError = true) {
|
|
732
|
+
this.headers = new HttpHeaders({
|
|
733
|
+
'Content-Type': 'application/json',
|
|
734
|
+
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
735
|
+
});
|
|
736
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.ODBC_ENDPOINT;
|
|
737
|
+
let post_v = JSON.stringify(queryp);
|
|
738
|
+
return this.http.post(this.url, post_v, { headers: this.headers })
|
|
739
|
+
.pipe(map((res) => {
|
|
740
|
+
// Handle errors, display if enabled
|
|
741
|
+
let err;
|
|
742
|
+
if (!res) {
|
|
743
|
+
err = new Error('Empty server response');
|
|
744
|
+
}
|
|
745
|
+
else if (res.result_msg === 'KO') {
|
|
746
|
+
err = new Error(res.msg);
|
|
747
|
+
}
|
|
748
|
+
if (err) {
|
|
749
|
+
console.error(err);
|
|
750
|
+
if (displayError) {
|
|
751
|
+
this.toastr.error(err.message);
|
|
752
|
+
}
|
|
753
|
+
throw new Error(err);
|
|
754
|
+
}
|
|
755
|
+
return res || new QGResult();
|
|
756
|
+
}), catchError((err) => {
|
|
757
|
+
// In a real world app, we might use a remote logging infrastructure
|
|
758
|
+
// We'd also dig deeper into the error to get a better message
|
|
759
|
+
let errMsg = (err.message) ? err.message : err.status ? `${err.status} - ${err.statusText}` : 'Server error';
|
|
760
|
+
console.error(errMsg); // log to console instead
|
|
761
|
+
throw err;
|
|
762
|
+
}));
|
|
763
|
+
}
|
|
764
|
+
};
|
|
765
|
+
OdbcService.ctorParameters = () => [
|
|
766
|
+
{ type: HttpClient },
|
|
767
|
+
{ type: AppService },
|
|
768
|
+
{ type: ToastrService }
|
|
769
|
+
];
|
|
770
|
+
OdbcService.ɵprov = ɵɵdefineInjectable({ factory: function OdbcService_Factory() { return new OdbcService(ɵɵinject(HttpClient), ɵɵinject(AppService), ɵɵinject(ToastrService)); }, token: OdbcService, providedIn: "root" });
|
|
771
|
+
OdbcService = __decorate([
|
|
772
|
+
Injectable({
|
|
773
|
+
providedIn: 'root',
|
|
774
|
+
}),
|
|
775
|
+
__metadata("design:paramtypes", [HttpClient, AppService, ToastrService])
|
|
776
|
+
], OdbcService);
|
|
777
|
+
|
|
778
|
+
let FileService = class FileService {
|
|
779
|
+
constructor(http, app_s, toastr) {
|
|
780
|
+
this.http = http;
|
|
781
|
+
this.app_s = app_s;
|
|
782
|
+
this.toastr = toastr;
|
|
783
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.FILE_ENDPOINT; // URL to web API this.app_s.API_ENDPOINT
|
|
784
|
+
}
|
|
785
|
+
doQuery(queryp, displayError = true) {
|
|
786
|
+
this.headers = new HttpHeaders({
|
|
787
|
+
'Content-Type': 'application/json',
|
|
788
|
+
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
789
|
+
});
|
|
790
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.FILE_ENDPOINT;
|
|
791
|
+
// console.log('FileService url: '+ this.url);
|
|
792
|
+
let post_v = JSON.stringify(queryp);
|
|
793
|
+
// console.log(post_v);
|
|
794
|
+
return this.http.post(this.url, post_v, {
|
|
795
|
+
headers: this.headers
|
|
796
|
+
}).pipe(map((res) => {
|
|
797
|
+
// Handle errors, display if enabled
|
|
798
|
+
let r = res;
|
|
799
|
+
let err;
|
|
800
|
+
if (!res) {
|
|
801
|
+
err = new Error('Empty server response');
|
|
802
|
+
}
|
|
803
|
+
else if (r.result_msg === 'KO') {
|
|
804
|
+
err = new Error(r.msg);
|
|
805
|
+
}
|
|
806
|
+
if (err) {
|
|
807
|
+
console.error(err);
|
|
808
|
+
if (displayError) {
|
|
809
|
+
this.toastr.error(err.message);
|
|
810
|
+
}
|
|
811
|
+
throw new Error(err);
|
|
812
|
+
}
|
|
813
|
+
return res || new QGResult();
|
|
814
|
+
}), catchError((err) => {
|
|
815
|
+
// In a real world app, we might use a remote logging infrastructure
|
|
816
|
+
// We'd also dig deeper into the error to get a better message
|
|
817
|
+
let errMsg = (err.message) ? err.message : err.status ? `${err.status} - ${err.statusText}` : 'Server error';
|
|
818
|
+
console.error(errMsg); // log to console instead
|
|
819
|
+
throw err;
|
|
820
|
+
}));
|
|
821
|
+
}
|
|
822
|
+
};
|
|
823
|
+
FileService.ctorParameters = () => [
|
|
824
|
+
{ type: HttpClient },
|
|
825
|
+
{ type: AppService },
|
|
826
|
+
{ type: ToastrService }
|
|
827
|
+
];
|
|
828
|
+
FileService.ɵprov = ɵɵdefineInjectable({ factory: function FileService_Factory() { return new FileService(ɵɵinject(HttpClient), ɵɵinject(AppService), ɵɵinject(ToastrService)); }, token: FileService, providedIn: "root" });
|
|
829
|
+
FileService = __decorate([
|
|
830
|
+
Injectable({
|
|
831
|
+
providedIn: 'root',
|
|
832
|
+
}),
|
|
833
|
+
__metadata("design:paramtypes", [HttpClient, AppService, ToastrService])
|
|
834
|
+
], FileService);
|
|
835
|
+
|
|
836
|
+
let AppMakerService = class AppMakerService {
|
|
837
|
+
constructor(http, app_s, toastr) {
|
|
838
|
+
this.http = http;
|
|
839
|
+
this.app_s = app_s;
|
|
840
|
+
this.toastr = toastr;
|
|
841
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.APPMAKER_ENDPOINT; // URL to web API
|
|
842
|
+
}
|
|
843
|
+
doQuery(queryp, displayError = true) {
|
|
844
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.APPMAKER_ENDPOINT;
|
|
845
|
+
this.headers = new HttpHeaders({
|
|
846
|
+
'Content-Type': 'application/json',
|
|
847
|
+
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
848
|
+
});
|
|
849
|
+
// console.log('AppMakerService url: '+ this.url);
|
|
850
|
+
let post_v = JSON.stringify(queryp);
|
|
851
|
+
// console.log(post_v);
|
|
852
|
+
return this.http.post(this.url, post_v)
|
|
853
|
+
.pipe(map((res) => {
|
|
854
|
+
// Handle errors, display if enabled
|
|
855
|
+
let r = res;
|
|
856
|
+
let err;
|
|
857
|
+
if (!res) {
|
|
858
|
+
err = new Error('Empty server response');
|
|
859
|
+
}
|
|
860
|
+
else if (r.result_msg === 'KO') {
|
|
861
|
+
err = new Error(r.msg);
|
|
862
|
+
}
|
|
863
|
+
if (err) {
|
|
864
|
+
console.error(err);
|
|
865
|
+
if (displayError) {
|
|
866
|
+
this.toastr.error(err.message);
|
|
867
|
+
}
|
|
868
|
+
throw new Error(err);
|
|
869
|
+
}
|
|
870
|
+
return r || new QGResult();
|
|
871
|
+
}), catchError((err) => {
|
|
872
|
+
// In a real world app, we might use a remote logging infrastructure
|
|
873
|
+
// We'd also dig deeper into the error to get a better message
|
|
874
|
+
let errMsg = (err.message) ? err.message : err.status ? `${err.status} - ${err.statusText}` : 'Server error';
|
|
875
|
+
console.error(errMsg); // log to console instead
|
|
876
|
+
throw err;
|
|
877
|
+
}));
|
|
878
|
+
}
|
|
879
|
+
extractData(res) {
|
|
880
|
+
//console.log(res);
|
|
881
|
+
let body = res.json();
|
|
882
|
+
// console.log(body);
|
|
883
|
+
return body || {};
|
|
884
|
+
}
|
|
885
|
+
handleError(error) {
|
|
886
|
+
// In a real world app, we might use a remote logging infrastructure
|
|
887
|
+
// We'd also dig deeper into the error to get a better message
|
|
888
|
+
let errMsg = (error.message) ? error.message :
|
|
889
|
+
error.status ? `${error.status} - ${error.statusText}` : 'Server error';
|
|
890
|
+
console.error(errMsg); // log to console instead
|
|
891
|
+
return Observable.throw(errMsg);
|
|
892
|
+
}
|
|
893
|
+
};
|
|
894
|
+
AppMakerService.ctorParameters = () => [
|
|
895
|
+
{ type: HttpClient },
|
|
896
|
+
{ type: AppService },
|
|
897
|
+
{ type: ToastrService }
|
|
898
|
+
];
|
|
899
|
+
AppMakerService.ɵprov = ɵɵdefineInjectable({ factory: function AppMakerService_Factory() { return new AppMakerService(ɵɵinject(HttpClient), ɵɵinject(AppService), ɵɵinject(ToastrService)); }, token: AppMakerService, providedIn: "root" });
|
|
900
|
+
AppMakerService = __decorate([
|
|
901
|
+
Injectable({
|
|
902
|
+
providedIn: 'root',
|
|
903
|
+
}),
|
|
904
|
+
__metadata("design:paramtypes", [HttpClient, AppService, ToastrService])
|
|
905
|
+
], AppMakerService);
|
|
906
|
+
|
|
872
907
|
let NumericEditorComponent = class NumericEditorComponent {
|
|
873
908
|
constructor(uti_s) {
|
|
874
909
|
this.uti_s = uti_s;
|
|
@@ -16043,13 +16078,13 @@ FluxhubLibModule = FluxhubLibModule_1 = __decorate([
|
|
|
16043
16078
|
apiKey: 'AIzaSyD3-g3b_QqxUruxBY4PGJKaH2fubIVXvN4'
|
|
16044
16079
|
}),
|
|
16045
16080
|
FlexLayoutModule, MarkdownModule, CKEditorModule],
|
|
16046
|
-
exports: [FHCheckBox, FHTextInput, FHHelpButton, win_user_info, win_insert_commento, FHRoleManager, FHFieldPickListComponent, SafePipe, fhimagepreview, win_show_image, WinAskButtonsComponent, win_time_slider, DecimalMask, FHTimePickerComponent, CurrencyComponent, FHUploadPanelComponent, FHUploadComponent,
|
|
16081
|
+
exports: [CheckboxEditorComponent, FHCheckBox, FHTextInput, FHHelpButton, win_user_info, win_insert_commento, FHRoleManager, FHFieldPickListComponent, SafePipe, fhimagepreview, win_show_image, WinAskButtonsComponent, win_time_slider, DecimalMask, FHTimePickerComponent, CurrencyComponent, FHUploadPanelComponent, FHUploadComponent,
|
|
16047
16082
|
FHGridComponent, FHComboboxComponent, FHConfirmComponent, FHAutoCompleteComponent, FHDatePickerComponent, NumericEditorComponent,
|
|
16048
16083
|
FHUserPickerComponent, ApprovaGridComponent, FHCurrencyFormatterDirective, FHCurrencyPipe, win_mappa, win_grid_help, TextAreaEditor,
|
|
16049
16084
|
ComboBoxEditor, FHListComponent, FHWinComboSelect, ReplaceLineBreaks, WinAskTextComponent, FHPickListComponent, WinAskNumberComponent,
|
|
16050
16085
|
FHMdReader, FHLogPanelComponent, WinAskTextBigComponent, FHCurrencyFieldComponent, FHRichText, WinOutputComponent, FHNumericFieldComponent, wkf_header_bar,
|
|
16051
16086
|
FHListPick, WinWait, FHUserFieldComponent, FHGridJSONComponent, win_salva_annulla, FormBuilderComponent, FormExecuterComponent, FHTableManager],
|
|
16052
|
-
declarations: [FHCheckBox, FHTextInput, FHHelpButton, win_user_info, win_insert_commento, FHRoleManager, FHFieldPickListComponent, SafePipe, FHViewerComponent,
|
|
16087
|
+
declarations: [CheckboxEditorComponent, FHCheckBox, FHTextInput, FHHelpButton, win_user_info, win_insert_commento, FHRoleManager, FHFieldPickListComponent, SafePipe, FHViewerComponent,
|
|
16053
16088
|
fhimagepreview, win_show_image, WinAskButtonsComponent, FHGridToolBarComponent, win_time_slider, DecimalMask, FHTimePickerComponent, CurrencyComponent, FHUploadPanelComponent, FHUploadComponent, wkf_header_bar,
|
|
16054
16089
|
FHGridComponent, FHComboboxComponent, FHConfirmComponent, FHAutoCompleteComponent, FHDatePickerComponent, NumericEditorComponent,
|
|
16055
16090
|
FHUserPickerComponent, ApprovaGridComponent, FHCurrencyFormatterDirective, FHCurrencyPipe, win_mappa, win_grid_help, TextAreaEditor,
|
|
@@ -16247,5 +16282,5 @@ class FSResult {
|
|
|
16247
16282
|
* Generated bundle index. Do not edit.
|
|
16248
16283
|
*/
|
|
16249
16284
|
|
|
16250
|
-
export { AppMakerService, AppService, ApprovaGridComponent, AuthenticationService, ComboBoxEditor, CurrencyComponent, FHAutoCompleteComponent, FHCheckBox, FHComboboxComponent, FHConfirmComponent, FHConfirmValues, FHCurrencyFieldComponent, FHCurrencyFormatterDirective, FHCurrencyPipe, FHDatePickerComponent, FHFieldPickListComponent, FHGridComponent, FHGridJSONComponent, FHGuard, FHListComponent, FHListPick, FHLogPanelComponent, FHMdReader, FHNumericFieldComponent, FHPickListComponent, FHRichText, FHRoleManager, FHTableManager, FHTextInput, FHTimePickerComponent, FHUploadComponent, FHUploadPanelComponent, FHUserFieldComponent, FHUserPickerComponent, FHWinComboSelect, FSInput, FSResult, FileService, FluxhubLibModule, FormBuilderComponent, FormExecuterComponent, GridService, LocalDBService, NumericEditorComponent, OdbcService, OfficeAutomatorService, QGParam, QGResult, QParam, QResult, QueryService, ReplaceLineBreaks, TextAreaEditor, UtilityService, WinAskButtonsComponent, WinAskNumberComponent, WinAskTextBigComponent, WinAskTextComponent, WinOutputComponent, WinWait, WkfService, dati_aggiuntivi, fhimagepreview, win_insert_commento, win_mappa, win_salva_annulla, win_show_image, win_time_slider, win_user_info, wkf_header_bar, wkfapp, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$7 as ɵa, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$3 as ɵb, win_commenti as ɵba, win_info_doc as ɵbb, win_log as ɵbc, win_recupera_doc as ɵbd, win_riassegna_select_level as ɵbe, win_riassegna_select_user as ɵbf, win_sostituisci_utente as ɵbg, win_commento_sel_notif as ɵbh, win_manage_values as ɵbi, win_manage_roles as ɵbj, FHComboboxComponentFilter as ɵbk, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$1 as ɵc, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$6 as ɵd, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$4 as ɵe, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR_NUMERIC as ɵf, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR_RT as ɵg, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR as ɵh, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$2 as ɵi, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$5 as ɵj, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$8 as ɵk, FHHelpButton as ɵl, SafePipe as ɵm, DecimalMask as ɵn, MOMENT_DATE_FORMATS as ɵo, MomentDateAdapter as ɵp, win_grid_help as ɵq, HighlightService as ɵr, FHViewerComponent as ɵs, FHGridToolBarComponent as ɵu, win_assegna as ɵv, win_conferma as ɵw, win_select_canale as ɵx, win_select_level as ɵy, win_uploads as ɵz };
|
|
16285
|
+
export { AppMakerService, AppService, ApprovaGridComponent, AuthenticationService, CheckboxEditorComponent, ComboBoxEditor, CurrencyComponent, FHAutoCompleteComponent, FHCheckBox, FHComboboxComponent, FHConfirmComponent, FHConfirmValues, FHCurrencyFieldComponent, FHCurrencyFormatterDirective, FHCurrencyPipe, FHDatePickerComponent, FHFieldPickListComponent, FHGridComponent, FHGridJSONComponent, FHGuard, FHListComponent, FHListPick, FHLogPanelComponent, FHMdReader, FHNumericFieldComponent, FHPickListComponent, FHRichText, FHRoleManager, FHTableManager, FHTextInput, FHTimePickerComponent, FHUploadComponent, FHUploadPanelComponent, FHUserFieldComponent, FHUserPickerComponent, FHWinComboSelect, FSInput, FSResult, FileService, FluxhubLibModule, FormBuilderComponent, FormExecuterComponent, GridService, LocalDBService, NumericEditorComponent, OdbcService, OfficeAutomatorService, QGParam, QGResult, QParam, QResult, QueryService, ReplaceLineBreaks, TextAreaEditor, UtilityService, WinAskButtonsComponent, WinAskNumberComponent, WinAskTextBigComponent, WinAskTextComponent, WinOutputComponent, WinWait, WkfService, dati_aggiuntivi, fhimagepreview, win_insert_commento, win_mappa, win_salva_annulla, win_show_image, win_time_slider, win_user_info, wkf_header_bar, wkfapp, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$7 as ɵa, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$3 as ɵb, win_commenti as ɵba, win_info_doc as ɵbb, win_log as ɵbc, win_recupera_doc as ɵbd, win_riassegna_select_level as ɵbe, win_riassegna_select_user as ɵbf, win_sostituisci_utente as ɵbg, win_commento_sel_notif as ɵbh, win_manage_values as ɵbi, win_manage_roles as ɵbj, FHComboboxComponentFilter as ɵbk, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$1 as ɵc, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$6 as ɵd, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$4 as ɵe, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR_NUMERIC as ɵf, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR_RT as ɵg, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR as ɵh, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$2 as ɵi, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$5 as ɵj, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$8 as ɵk, FHHelpButton as ɵl, SafePipe as ɵm, DecimalMask as ɵn, MOMENT_DATE_FORMATS as ɵo, MomentDateAdapter as ɵp, win_grid_help as ɵq, HighlightService as ɵr, FHViewerComponent as ɵs, FHGridToolBarComponent as ɵu, win_assegna as ɵv, win_conferma as ɵw, win_select_canale as ɵx, win_select_level as ɵy, win_uploads as ɵz };
|
|
16251
16286
|
//# sourceMappingURL=fluxhub-fluxhub-lib.js.map
|