@fluxhub/fluxhub-lib 9.0.40 → 9.0.42
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/lib/controls/grid_editors/checkbox-editor.component.d.ts +13 -0
- package/package.json +1 -1
- package/public_api.d.ts +1 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
(function (global, factory) {
|
|
2
|
-
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('
|
|
3
|
-
typeof define === 'function' && define.amd ? define('@fluxhub/fluxhub-lib', ['exports', '@angular/core', '@angular/common/http', 'ngx-toastr', 'rxjs/operators', 'rxjs', '
|
|
4
|
-
(global = global || self, factory((global.fluxhub = global.fluxhub || {}, global.fluxhub['fluxhub-lib'] = {}), global.ng.core, global.ng.common.http, global.ngxToastr, global.rxjs.operators, global.rxjs, global.
|
|
5
|
-
}(this, (function (exports, core, http, ngxToastr, operators, rxjs,
|
|
2
|
+
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('ngx-simple-crypt'), require('crypto-js'), require('@angular/common/http'), require('ngx-toastr'), require('rxjs/operators'), require('rxjs'), require('@angular/material/dialog'), require('@angular/forms'), require('ng2-file-upload'), require('@angular/router'), require('ng2-slim-loading-bar'), require('ag-grid-enterprise'), require('@angular/material/select'), require('@angular/material/slide-toggle'), require('@angular/material/autocomplete'), require('moment'), require('@angular/material/core'), require('@angular/common'), require('clipboard'), require('prismjs'), require('prismjs/plugins/toolbar/prism-toolbar'), require('prismjs/plugins/copy-to-clipboard/prism-copy-to-clipboard'), require('prismjs/components/prism-css'), require('prismjs/components/prism-javascript'), require('prismjs/components/prism-java'), require('prismjs/components/prism-markup'), require('prismjs/components/prism-typescript'), require('prismjs/components/prism-sass'), require('prismjs/components/prism-scss'), require('prismjs/components/prism-sql'), require('bpmn-js/lib/NavigatedViewer'), require('@angular/material/tabs'), require('@angular/flex-layout'), require('ngx-markdown'), require('ng2-ckeditor'), require('ag-grid-angular'), require('@agm/core'), require('@angular/cdk/table'), require('ngforage'), require('@ngx-translate/core'), require('ng2-dragula'), require('@angular/platform-browser'), require('@angular/material/card'), require('@angular/material/button'), require('@angular/material/checkbox'), require('@angular/material/button-toggle'), require('@angular/material/chips'), require('@angular/material/datepicker'), require('@angular/material/expansion'), require('@angular/material/form-field'), require('@angular/material/grid-list'), require('@angular/material/icon'), require('@angular/material/input'), require('@angular/material/list'), require('@angular/material/menu'), require('@angular/material/progress-bar'), require('@angular/material/progress-spinner'), require('@angular/material/radio'), require('@angular/material/slider'), require('@angular/material/sidenav'), require('@angular/material/snack-bar'), require('@angular/material/stepper'), require('@angular/material/toolbar'), require('@angular/material/tooltip'), require('@angular/material/paginator'), require('@angular/material/sort'), require('@angular/material/table'), require('@angular/material/badge')) :
|
|
3
|
+
typeof define === 'function' && define.amd ? define('@fluxhub/fluxhub-lib', ['exports', '@angular/core', 'ngx-simple-crypt', 'crypto-js', '@angular/common/http', 'ngx-toastr', 'rxjs/operators', 'rxjs', '@angular/material/dialog', '@angular/forms', 'ng2-file-upload', '@angular/router', 'ng2-slim-loading-bar', 'ag-grid-enterprise', '@angular/material/select', '@angular/material/slide-toggle', '@angular/material/autocomplete', 'moment', '@angular/material/core', '@angular/common', 'clipboard', 'prismjs', 'prismjs/plugins/toolbar/prism-toolbar', 'prismjs/plugins/copy-to-clipboard/prism-copy-to-clipboard', 'prismjs/components/prism-css', 'prismjs/components/prism-javascript', 'prismjs/components/prism-java', 'prismjs/components/prism-markup', 'prismjs/components/prism-typescript', 'prismjs/components/prism-sass', 'prismjs/components/prism-scss', 'prismjs/components/prism-sql', 'bpmn-js/lib/NavigatedViewer', '@angular/material/tabs', '@angular/flex-layout', 'ngx-markdown', 'ng2-ckeditor', 'ag-grid-angular', '@agm/core', '@angular/cdk/table', 'ngforage', '@ngx-translate/core', 'ng2-dragula', '@angular/platform-browser', '@angular/material/card', '@angular/material/button', '@angular/material/checkbox', '@angular/material/button-toggle', '@angular/material/chips', '@angular/material/datepicker', '@angular/material/expansion', '@angular/material/form-field', '@angular/material/grid-list', '@angular/material/icon', '@angular/material/input', '@angular/material/list', '@angular/material/menu', '@angular/material/progress-bar', '@angular/material/progress-spinner', '@angular/material/radio', '@angular/material/slider', '@angular/material/sidenav', '@angular/material/snack-bar', '@angular/material/stepper', '@angular/material/toolbar', '@angular/material/tooltip', '@angular/material/paginator', '@angular/material/sort', '@angular/material/table', '@angular/material/badge'], factory) :
|
|
4
|
+
(global = global || self, factory((global.fluxhub = global.fluxhub || {}, global.fluxhub['fluxhub-lib'] = {}), global.ng.core, global.ngxSimpleCrypt, global.cryptoJs, global.ng.common.http, global.ngxToastr, global.rxjs.operators, global.rxjs, global.ng.material.dialog, global.ng.forms, global.ng2FileUpload, global.ng.router, global.ng2SlimLoadingBar, null, global.ng.material.select, global.ng.material['slide-toggle'], global.ng.material.autocomplete, global.momentNs, global.ng.material.core, global.ng.common, null, null, null, null, null, null, null, null, null, null, null, null, global.NavigatedViewer, global.ng.material.tabs, global.ng['flex-layout'], global.ngxMarkdown, global.ng2Ckeditor, global.agGridAngular, global.core$2, global.ng.cdk.table, global.ngforage, global.core$3, global.ng2Dragula, global.ng.platformBrowser, global.ng.material.card, global.ng.material.button, global.ng.material.checkbox, global.ng.material['button-toggle'], global.ng.material.chips, global.ng.material.datepicker, global.ng.material.expansion, global.ng.material['form-field'], global.ng.material['grid-list'], global.ng.material.icon, global.ng.material.input, global.ng.material.list, global.ng.material.menu, global.ng.material['progress-bar'], global.ng.material['progress-spinner'], global.ng.material.radio, global.ng.material.slider, global.ng.material.sidenav, global.ng.material['snack-bar'], global.ng.material.stepper, global.ng.material.toolbar, global.ng.material.tooltip, global.ng.material.paginator, global.ng.material.sort, global.ng.material.table, global.ng.material.badge));
|
|
5
|
+
}(this, (function (exports, core, ngxSimpleCrypt, cryptoJs, http, ngxToastr, operators, rxjs, dialog, forms, ng2FileUpload, router, ng2SlimLoadingBar, agGridEnterprise, select, slideToggle, autocomplete, momentNs, core$1, common, clipboard, prismjs, prismToolbar, prismCopyToClipboard, prismCss, prismJavascript, prismJava, prismMarkup, prismTypescript, prismSass, prismScss, prismSql, NavigatedViewer, tabs, flexLayout, ngxMarkdown, ng2Ckeditor, agGridAngular, core$2, table, ngforage, core$3, ng2Dragula, platformBrowser, card, button, checkbox, buttonToggle, chips, datepicker, expansion, formField, gridList, icon, input, list, menu, progressBar, progressSpinner, radio, slider, sidenav, snackBar, stepper, toolbar, tooltip, paginator, sort, table$1, badge) { 'use strict';
|
|
6
6
|
|
|
7
7
|
NavigatedViewer = NavigatedViewer && NavigatedViewer.hasOwnProperty('default') ? NavigatedViewer['default'] : NavigatedViewer;
|
|
8
8
|
|
|
@@ -294,204 +294,6 @@
|
|
|
294
294
|
return AppService;
|
|
295
295
|
}());
|
|
296
296
|
|
|
297
|
-
var QGResult = /** @class */ (function () {
|
|
298
|
-
function QGResult() {
|
|
299
|
-
}
|
|
300
|
-
return QGResult;
|
|
301
|
-
}());
|
|
302
|
-
|
|
303
|
-
var OdbcService = /** @class */ (function () {
|
|
304
|
-
function OdbcService(http, app_s, toastr) {
|
|
305
|
-
this.http = http;
|
|
306
|
-
this.app_s = app_s;
|
|
307
|
-
this.toastr = toastr;
|
|
308
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.ODBC_ENDPOINT; // URL to web API
|
|
309
|
-
}
|
|
310
|
-
OdbcService.prototype.doQuery = function (queryp, displayError) {
|
|
311
|
-
var _this = this;
|
|
312
|
-
if (displayError === void 0) { displayError = true; }
|
|
313
|
-
this.headers = new http.HttpHeaders({
|
|
314
|
-
'Content-Type': 'application/json',
|
|
315
|
-
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
316
|
-
});
|
|
317
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.ODBC_ENDPOINT;
|
|
318
|
-
var post_v = JSON.stringify(queryp);
|
|
319
|
-
return this.http.post(this.url, post_v, { headers: this.headers })
|
|
320
|
-
.pipe(operators.map(function (res) {
|
|
321
|
-
// Handle errors, display if enabled
|
|
322
|
-
var err;
|
|
323
|
-
if (!res) {
|
|
324
|
-
err = new Error('Empty server response');
|
|
325
|
-
}
|
|
326
|
-
else if (res.result_msg === 'KO') {
|
|
327
|
-
err = new Error(res.msg);
|
|
328
|
-
}
|
|
329
|
-
if (err) {
|
|
330
|
-
console.error(err);
|
|
331
|
-
if (displayError) {
|
|
332
|
-
_this.toastr.error(err.message);
|
|
333
|
-
}
|
|
334
|
-
throw new Error(err);
|
|
335
|
-
}
|
|
336
|
-
return res || new QGResult();
|
|
337
|
-
}), operators.catchError(function (err) {
|
|
338
|
-
// In a real world app, we might use a remote logging infrastructure
|
|
339
|
-
// We'd also dig deeper into the error to get a better message
|
|
340
|
-
var errMsg = (err.message) ? err.message : err.status ? err.status + " - " + err.statusText : 'Server error';
|
|
341
|
-
console.error(errMsg); // log to console instead
|
|
342
|
-
throw err;
|
|
343
|
-
}));
|
|
344
|
-
};
|
|
345
|
-
OdbcService.ctorParameters = function () { return [
|
|
346
|
-
{ type: http.HttpClient },
|
|
347
|
-
{ type: AppService },
|
|
348
|
-
{ type: ngxToastr.ToastrService }
|
|
349
|
-
]; };
|
|
350
|
-
OdbcService.ɵprov = core["ɵɵdefineInjectable"]({ factory: function OdbcService_Factory() { return new OdbcService(core["ɵɵinject"](http.HttpClient), core["ɵɵinject"](AppService), core["ɵɵinject"](ngxToastr.ToastrService)); }, token: OdbcService, providedIn: "root" });
|
|
351
|
-
OdbcService = __decorate([
|
|
352
|
-
core.Injectable({
|
|
353
|
-
providedIn: 'root',
|
|
354
|
-
}),
|
|
355
|
-
__metadata("design:paramtypes", [http.HttpClient, AppService, ngxToastr.ToastrService])
|
|
356
|
-
], OdbcService);
|
|
357
|
-
return OdbcService;
|
|
358
|
-
}());
|
|
359
|
-
|
|
360
|
-
var FileService = /** @class */ (function () {
|
|
361
|
-
function FileService(http, app_s, toastr) {
|
|
362
|
-
this.http = http;
|
|
363
|
-
this.app_s = app_s;
|
|
364
|
-
this.toastr = toastr;
|
|
365
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.FILE_ENDPOINT; // URL to web API this.app_s.API_ENDPOINT
|
|
366
|
-
}
|
|
367
|
-
FileService.prototype.doQuery = function (queryp, displayError) {
|
|
368
|
-
var _this = this;
|
|
369
|
-
if (displayError === void 0) { displayError = true; }
|
|
370
|
-
this.headers = new http.HttpHeaders({
|
|
371
|
-
'Content-Type': 'application/json',
|
|
372
|
-
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
373
|
-
});
|
|
374
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.FILE_ENDPOINT;
|
|
375
|
-
// console.log('FileService url: '+ this.url);
|
|
376
|
-
var post_v = JSON.stringify(queryp);
|
|
377
|
-
// console.log(post_v);
|
|
378
|
-
return this.http.post(this.url, post_v, {
|
|
379
|
-
headers: this.headers
|
|
380
|
-
}).pipe(operators.map(function (res) {
|
|
381
|
-
// Handle errors, display if enabled
|
|
382
|
-
var r = res;
|
|
383
|
-
var err;
|
|
384
|
-
if (!res) {
|
|
385
|
-
err = new Error('Empty server response');
|
|
386
|
-
}
|
|
387
|
-
else if (r.result_msg === 'KO') {
|
|
388
|
-
err = new Error(r.msg);
|
|
389
|
-
}
|
|
390
|
-
if (err) {
|
|
391
|
-
console.error(err);
|
|
392
|
-
if (displayError) {
|
|
393
|
-
_this.toastr.error(err.message);
|
|
394
|
-
}
|
|
395
|
-
throw new Error(err);
|
|
396
|
-
}
|
|
397
|
-
return res || new QGResult();
|
|
398
|
-
}), operators.catchError(function (err) {
|
|
399
|
-
// In a real world app, we might use a remote logging infrastructure
|
|
400
|
-
// We'd also dig deeper into the error to get a better message
|
|
401
|
-
var errMsg = (err.message) ? err.message : err.status ? err.status + " - " + err.statusText : 'Server error';
|
|
402
|
-
console.error(errMsg); // log to console instead
|
|
403
|
-
throw err;
|
|
404
|
-
}));
|
|
405
|
-
};
|
|
406
|
-
FileService.ctorParameters = function () { return [
|
|
407
|
-
{ type: http.HttpClient },
|
|
408
|
-
{ type: AppService },
|
|
409
|
-
{ type: ngxToastr.ToastrService }
|
|
410
|
-
]; };
|
|
411
|
-
FileService.ɵprov = core["ɵɵdefineInjectable"]({ factory: function FileService_Factory() { return new FileService(core["ɵɵinject"](http.HttpClient), core["ɵɵinject"](AppService), core["ɵɵinject"](ngxToastr.ToastrService)); }, token: FileService, providedIn: "root" });
|
|
412
|
-
FileService = __decorate([
|
|
413
|
-
core.Injectable({
|
|
414
|
-
providedIn: 'root',
|
|
415
|
-
}),
|
|
416
|
-
__metadata("design:paramtypes", [http.HttpClient, AppService, ngxToastr.ToastrService])
|
|
417
|
-
], FileService);
|
|
418
|
-
return FileService;
|
|
419
|
-
}());
|
|
420
|
-
|
|
421
|
-
var AppMakerService = /** @class */ (function () {
|
|
422
|
-
function AppMakerService(http, app_s, toastr) {
|
|
423
|
-
this.http = http;
|
|
424
|
-
this.app_s = app_s;
|
|
425
|
-
this.toastr = toastr;
|
|
426
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.APPMAKER_ENDPOINT; // URL to web API
|
|
427
|
-
}
|
|
428
|
-
AppMakerService.prototype.doQuery = function (queryp, displayError) {
|
|
429
|
-
var _this = this;
|
|
430
|
-
if (displayError === void 0) { displayError = true; }
|
|
431
|
-
this.url = this.app_s.API_ENDPOINT + this.app_s.APPMAKER_ENDPOINT;
|
|
432
|
-
this.headers = new http.HttpHeaders({
|
|
433
|
-
'Content-Type': 'application/json',
|
|
434
|
-
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
435
|
-
});
|
|
436
|
-
// console.log('AppMakerService url: '+ this.url);
|
|
437
|
-
var post_v = JSON.stringify(queryp);
|
|
438
|
-
// console.log(post_v);
|
|
439
|
-
return this.http.post(this.url, post_v)
|
|
440
|
-
.pipe(operators.map(function (res) {
|
|
441
|
-
// Handle errors, display if enabled
|
|
442
|
-
var r = res;
|
|
443
|
-
var err;
|
|
444
|
-
if (!res) {
|
|
445
|
-
err = new Error('Empty server response');
|
|
446
|
-
}
|
|
447
|
-
else if (r.result_msg === 'KO') {
|
|
448
|
-
err = new Error(r.msg);
|
|
449
|
-
}
|
|
450
|
-
if (err) {
|
|
451
|
-
console.error(err);
|
|
452
|
-
if (displayError) {
|
|
453
|
-
_this.toastr.error(err.message);
|
|
454
|
-
}
|
|
455
|
-
throw new Error(err);
|
|
456
|
-
}
|
|
457
|
-
return r || new QGResult();
|
|
458
|
-
}), operators.catchError(function (err) {
|
|
459
|
-
// In a real world app, we might use a remote logging infrastructure
|
|
460
|
-
// We'd also dig deeper into the error to get a better message
|
|
461
|
-
var errMsg = (err.message) ? err.message : err.status ? err.status + " - " + err.statusText : 'Server error';
|
|
462
|
-
console.error(errMsg); // log to console instead
|
|
463
|
-
throw err;
|
|
464
|
-
}));
|
|
465
|
-
};
|
|
466
|
-
AppMakerService.prototype.extractData = function (res) {
|
|
467
|
-
//console.log(res);
|
|
468
|
-
var body = res.json();
|
|
469
|
-
// console.log(body);
|
|
470
|
-
return body || {};
|
|
471
|
-
};
|
|
472
|
-
AppMakerService.prototype.handleError = function (error) {
|
|
473
|
-
// In a real world app, we might use a remote logging infrastructure
|
|
474
|
-
// We'd also dig deeper into the error to get a better message
|
|
475
|
-
var errMsg = (error.message) ? error.message :
|
|
476
|
-
error.status ? error.status + " - " + error.statusText : 'Server error';
|
|
477
|
-
console.error(errMsg); // log to console instead
|
|
478
|
-
return rxjs.Observable.throw(errMsg);
|
|
479
|
-
};
|
|
480
|
-
AppMakerService.ctorParameters = function () { return [
|
|
481
|
-
{ type: http.HttpClient },
|
|
482
|
-
{ type: AppService },
|
|
483
|
-
{ type: ngxToastr.ToastrService }
|
|
484
|
-
]; };
|
|
485
|
-
AppMakerService.ɵprov = core["ɵɵdefineInjectable"]({ factory: function AppMakerService_Factory() { return new AppMakerService(core["ɵɵinject"](http.HttpClient), core["ɵɵinject"](AppService), core["ɵɵinject"](ngxToastr.ToastrService)); }, token: AppMakerService, providedIn: "root" });
|
|
486
|
-
AppMakerService = __decorate([
|
|
487
|
-
core.Injectable({
|
|
488
|
-
providedIn: 'root',
|
|
489
|
-
}),
|
|
490
|
-
__metadata("design:paramtypes", [http.HttpClient, AppService, ngxToastr.ToastrService])
|
|
491
|
-
], AppMakerService);
|
|
492
|
-
return AppMakerService;
|
|
493
|
-
}());
|
|
494
|
-
|
|
495
297
|
var UtilityService = /** @class */ (function () {
|
|
496
298
|
function UtilityService(app_s) {
|
|
497
299
|
this.app_s = app_s;
|
|
@@ -1025,6 +827,238 @@
|
|
|
1025
827
|
return UtilityService;
|
|
1026
828
|
}());
|
|
1027
829
|
|
|
830
|
+
var CheckboxEditorComponent = /** @class */ (function () {
|
|
831
|
+
function CheckboxEditorComponent(uti_s) {
|
|
832
|
+
this.uti_s = uti_s;
|
|
833
|
+
}
|
|
834
|
+
CheckboxEditorComponent.prototype.agInit = function (params) {
|
|
835
|
+
this.params = params;
|
|
836
|
+
this.value = this.params.value;
|
|
837
|
+
};
|
|
838
|
+
CheckboxEditorComponent.prototype.getValue = function () {
|
|
839
|
+
return this.value;
|
|
840
|
+
};
|
|
841
|
+
CheckboxEditorComponent.prototype.ngAfterViewInit = function () {
|
|
842
|
+
var _this = this;
|
|
843
|
+
setTimeout(function () {
|
|
844
|
+
_this.input.element.nativeElement.focus();
|
|
845
|
+
});
|
|
846
|
+
};
|
|
847
|
+
CheckboxEditorComponent.ctorParameters = function () { return [
|
|
848
|
+
{ type: UtilityService }
|
|
849
|
+
]; };
|
|
850
|
+
__decorate([
|
|
851
|
+
core.ViewChild('input', { read: core.ViewContainerRef }),
|
|
852
|
+
__metadata("design:type", Object)
|
|
853
|
+
], CheckboxEditorComponent.prototype, "input", void 0);
|
|
854
|
+
CheckboxEditorComponent = __decorate([
|
|
855
|
+
core.Component({
|
|
856
|
+
selector: 'checkbox-cell',
|
|
857
|
+
template: "\n <FHCheckBox [(ngModel)]=\"value\" label=\"Altra Normativa\">\n </FHCheckBox>\n "
|
|
858
|
+
}),
|
|
859
|
+
__metadata("design:paramtypes", [UtilityService])
|
|
860
|
+
], CheckboxEditorComponent);
|
|
861
|
+
return CheckboxEditorComponent;
|
|
862
|
+
}());
|
|
863
|
+
|
|
864
|
+
var QGResult = /** @class */ (function () {
|
|
865
|
+
function QGResult() {
|
|
866
|
+
}
|
|
867
|
+
return QGResult;
|
|
868
|
+
}());
|
|
869
|
+
|
|
870
|
+
var OdbcService = /** @class */ (function () {
|
|
871
|
+
function OdbcService(http, app_s, toastr) {
|
|
872
|
+
this.http = http;
|
|
873
|
+
this.app_s = app_s;
|
|
874
|
+
this.toastr = toastr;
|
|
875
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.ODBC_ENDPOINT; // URL to web API
|
|
876
|
+
}
|
|
877
|
+
OdbcService.prototype.doQuery = function (queryp, displayError) {
|
|
878
|
+
var _this = this;
|
|
879
|
+
if (displayError === void 0) { displayError = true; }
|
|
880
|
+
this.headers = new http.HttpHeaders({
|
|
881
|
+
'Content-Type': 'application/json',
|
|
882
|
+
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
883
|
+
});
|
|
884
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.ODBC_ENDPOINT;
|
|
885
|
+
var post_v = JSON.stringify(queryp);
|
|
886
|
+
return this.http.post(this.url, post_v, { headers: this.headers })
|
|
887
|
+
.pipe(operators.map(function (res) {
|
|
888
|
+
// Handle errors, display if enabled
|
|
889
|
+
var err;
|
|
890
|
+
if (!res) {
|
|
891
|
+
err = new Error('Empty server response');
|
|
892
|
+
}
|
|
893
|
+
else if (res.result_msg === 'KO') {
|
|
894
|
+
err = new Error(res.msg);
|
|
895
|
+
}
|
|
896
|
+
if (err) {
|
|
897
|
+
console.error(err);
|
|
898
|
+
if (displayError) {
|
|
899
|
+
_this.toastr.error(err.message);
|
|
900
|
+
}
|
|
901
|
+
throw new Error(err);
|
|
902
|
+
}
|
|
903
|
+
return res || new QGResult();
|
|
904
|
+
}), operators.catchError(function (err) {
|
|
905
|
+
// In a real world app, we might use a remote logging infrastructure
|
|
906
|
+
// We'd also dig deeper into the error to get a better message
|
|
907
|
+
var errMsg = (err.message) ? err.message : err.status ? err.status + " - " + err.statusText : 'Server error';
|
|
908
|
+
console.error(errMsg); // log to console instead
|
|
909
|
+
throw err;
|
|
910
|
+
}));
|
|
911
|
+
};
|
|
912
|
+
OdbcService.ctorParameters = function () { return [
|
|
913
|
+
{ type: http.HttpClient },
|
|
914
|
+
{ type: AppService },
|
|
915
|
+
{ type: ngxToastr.ToastrService }
|
|
916
|
+
]; };
|
|
917
|
+
OdbcService.ɵprov = core["ɵɵdefineInjectable"]({ factory: function OdbcService_Factory() { return new OdbcService(core["ɵɵinject"](http.HttpClient), core["ɵɵinject"](AppService), core["ɵɵinject"](ngxToastr.ToastrService)); }, token: OdbcService, providedIn: "root" });
|
|
918
|
+
OdbcService = __decorate([
|
|
919
|
+
core.Injectable({
|
|
920
|
+
providedIn: 'root',
|
|
921
|
+
}),
|
|
922
|
+
__metadata("design:paramtypes", [http.HttpClient, AppService, ngxToastr.ToastrService])
|
|
923
|
+
], OdbcService);
|
|
924
|
+
return OdbcService;
|
|
925
|
+
}());
|
|
926
|
+
|
|
927
|
+
var FileService = /** @class */ (function () {
|
|
928
|
+
function FileService(http, app_s, toastr) {
|
|
929
|
+
this.http = http;
|
|
930
|
+
this.app_s = app_s;
|
|
931
|
+
this.toastr = toastr;
|
|
932
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.FILE_ENDPOINT; // URL to web API this.app_s.API_ENDPOINT
|
|
933
|
+
}
|
|
934
|
+
FileService.prototype.doQuery = function (queryp, displayError) {
|
|
935
|
+
var _this = this;
|
|
936
|
+
if (displayError === void 0) { displayError = true; }
|
|
937
|
+
this.headers = new http.HttpHeaders({
|
|
938
|
+
'Content-Type': 'application/json',
|
|
939
|
+
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
940
|
+
});
|
|
941
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.FILE_ENDPOINT;
|
|
942
|
+
// console.log('FileService url: '+ this.url);
|
|
943
|
+
var post_v = JSON.stringify(queryp);
|
|
944
|
+
// console.log(post_v);
|
|
945
|
+
return this.http.post(this.url, post_v, {
|
|
946
|
+
headers: this.headers
|
|
947
|
+
}).pipe(operators.map(function (res) {
|
|
948
|
+
// Handle errors, display if enabled
|
|
949
|
+
var r = res;
|
|
950
|
+
var err;
|
|
951
|
+
if (!res) {
|
|
952
|
+
err = new Error('Empty server response');
|
|
953
|
+
}
|
|
954
|
+
else if (r.result_msg === 'KO') {
|
|
955
|
+
err = new Error(r.msg);
|
|
956
|
+
}
|
|
957
|
+
if (err) {
|
|
958
|
+
console.error(err);
|
|
959
|
+
if (displayError) {
|
|
960
|
+
_this.toastr.error(err.message);
|
|
961
|
+
}
|
|
962
|
+
throw new Error(err);
|
|
963
|
+
}
|
|
964
|
+
return res || new QGResult();
|
|
965
|
+
}), operators.catchError(function (err) {
|
|
966
|
+
// In a real world app, we might use a remote logging infrastructure
|
|
967
|
+
// We'd also dig deeper into the error to get a better message
|
|
968
|
+
var errMsg = (err.message) ? err.message : err.status ? err.status + " - " + err.statusText : 'Server error';
|
|
969
|
+
console.error(errMsg); // log to console instead
|
|
970
|
+
throw err;
|
|
971
|
+
}));
|
|
972
|
+
};
|
|
973
|
+
FileService.ctorParameters = function () { return [
|
|
974
|
+
{ type: http.HttpClient },
|
|
975
|
+
{ type: AppService },
|
|
976
|
+
{ type: ngxToastr.ToastrService }
|
|
977
|
+
]; };
|
|
978
|
+
FileService.ɵprov = core["ɵɵdefineInjectable"]({ factory: function FileService_Factory() { return new FileService(core["ɵɵinject"](http.HttpClient), core["ɵɵinject"](AppService), core["ɵɵinject"](ngxToastr.ToastrService)); }, token: FileService, providedIn: "root" });
|
|
979
|
+
FileService = __decorate([
|
|
980
|
+
core.Injectable({
|
|
981
|
+
providedIn: 'root',
|
|
982
|
+
}),
|
|
983
|
+
__metadata("design:paramtypes", [http.HttpClient, AppService, ngxToastr.ToastrService])
|
|
984
|
+
], FileService);
|
|
985
|
+
return FileService;
|
|
986
|
+
}());
|
|
987
|
+
|
|
988
|
+
var AppMakerService = /** @class */ (function () {
|
|
989
|
+
function AppMakerService(http, app_s, toastr) {
|
|
990
|
+
this.http = http;
|
|
991
|
+
this.app_s = app_s;
|
|
992
|
+
this.toastr = toastr;
|
|
993
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.APPMAKER_ENDPOINT; // URL to web API
|
|
994
|
+
}
|
|
995
|
+
AppMakerService.prototype.doQuery = function (queryp, displayError) {
|
|
996
|
+
var _this = this;
|
|
997
|
+
if (displayError === void 0) { displayError = true; }
|
|
998
|
+
this.url = this.app_s.API_ENDPOINT + this.app_s.APPMAKER_ENDPOINT;
|
|
999
|
+
this.headers = new http.HttpHeaders({
|
|
1000
|
+
'Content-Type': 'application/json',
|
|
1001
|
+
'Authorization': 'Bearer ' + localStorage.getItem(this.app_s.COMPANY_KEY + "token"),
|
|
1002
|
+
});
|
|
1003
|
+
// console.log('AppMakerService url: '+ this.url);
|
|
1004
|
+
var post_v = JSON.stringify(queryp);
|
|
1005
|
+
// console.log(post_v);
|
|
1006
|
+
return this.http.post(this.url, post_v)
|
|
1007
|
+
.pipe(operators.map(function (res) {
|
|
1008
|
+
// Handle errors, display if enabled
|
|
1009
|
+
var r = res;
|
|
1010
|
+
var err;
|
|
1011
|
+
if (!res) {
|
|
1012
|
+
err = new Error('Empty server response');
|
|
1013
|
+
}
|
|
1014
|
+
else if (r.result_msg === 'KO') {
|
|
1015
|
+
err = new Error(r.msg);
|
|
1016
|
+
}
|
|
1017
|
+
if (err) {
|
|
1018
|
+
console.error(err);
|
|
1019
|
+
if (displayError) {
|
|
1020
|
+
_this.toastr.error(err.message);
|
|
1021
|
+
}
|
|
1022
|
+
throw new Error(err);
|
|
1023
|
+
}
|
|
1024
|
+
return r || new QGResult();
|
|
1025
|
+
}), operators.catchError(function (err) {
|
|
1026
|
+
// In a real world app, we might use a remote logging infrastructure
|
|
1027
|
+
// We'd also dig deeper into the error to get a better message
|
|
1028
|
+
var errMsg = (err.message) ? err.message : err.status ? err.status + " - " + err.statusText : 'Server error';
|
|
1029
|
+
console.error(errMsg); // log to console instead
|
|
1030
|
+
throw err;
|
|
1031
|
+
}));
|
|
1032
|
+
};
|
|
1033
|
+
AppMakerService.prototype.extractData = function (res) {
|
|
1034
|
+
//console.log(res);
|
|
1035
|
+
var body = res.json();
|
|
1036
|
+
// console.log(body);
|
|
1037
|
+
return body || {};
|
|
1038
|
+
};
|
|
1039
|
+
AppMakerService.prototype.handleError = function (error) {
|
|
1040
|
+
// In a real world app, we might use a remote logging infrastructure
|
|
1041
|
+
// We'd also dig deeper into the error to get a better message
|
|
1042
|
+
var errMsg = (error.message) ? error.message :
|
|
1043
|
+
error.status ? error.status + " - " + error.statusText : 'Server error';
|
|
1044
|
+
console.error(errMsg); // log to console instead
|
|
1045
|
+
return rxjs.Observable.throw(errMsg);
|
|
1046
|
+
};
|
|
1047
|
+
AppMakerService.ctorParameters = function () { return [
|
|
1048
|
+
{ type: http.HttpClient },
|
|
1049
|
+
{ type: AppService },
|
|
1050
|
+
{ type: ngxToastr.ToastrService }
|
|
1051
|
+
]; };
|
|
1052
|
+
AppMakerService.ɵprov = core["ɵɵdefineInjectable"]({ factory: function AppMakerService_Factory() { return new AppMakerService(core["ɵɵinject"](http.HttpClient), core["ɵɵinject"](AppService), core["ɵɵinject"](ngxToastr.ToastrService)); }, token: AppMakerService, providedIn: "root" });
|
|
1053
|
+
AppMakerService = __decorate([
|
|
1054
|
+
core.Injectable({
|
|
1055
|
+
providedIn: 'root',
|
|
1056
|
+
}),
|
|
1057
|
+
__metadata("design:paramtypes", [http.HttpClient, AppService, ngxToastr.ToastrService])
|
|
1058
|
+
], AppMakerService);
|
|
1059
|
+
return AppMakerService;
|
|
1060
|
+
}());
|
|
1061
|
+
|
|
1028
1062
|
var NumericEditorComponent = /** @class */ (function () {
|
|
1029
1063
|
function NumericEditorComponent(uti_s) {
|
|
1030
1064
|
this.uti_s = uti_s;
|
|
@@ -14434,13 +14468,13 @@
|
|
|
14434
14468
|
apiKey: 'AIzaSyD3-g3b_QqxUruxBY4PGJKaH2fubIVXvN4'
|
|
14435
14469
|
}),
|
|
14436
14470
|
flexLayout.FlexLayoutModule, ngxMarkdown.MarkdownModule, ng2Ckeditor.CKEditorModule],
|
|
14437
|
-
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,
|
|
14471
|
+
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,
|
|
14438
14472
|
FHGridComponent, FHComboboxComponent, FHConfirmComponent, FHAutoCompleteComponent, FHDatePickerComponent, NumericEditorComponent,
|
|
14439
14473
|
FHUserPickerComponent, ApprovaGridComponent, FHCurrencyFormatterDirective, FHCurrencyPipe, win_mappa, win_grid_help, TextAreaEditor,
|
|
14440
14474
|
ComboBoxEditor, FHListComponent, FHWinComboSelect, ReplaceLineBreaks, WinAskTextComponent, FHPickListComponent, WinAskNumberComponent,
|
|
14441
14475
|
FHMdReader, FHLogPanelComponent, WinAskTextBigComponent, FHCurrencyFieldComponent, FHRichText, WinOutputComponent, FHNumericFieldComponent, wkf_header_bar,
|
|
14442
14476
|
FHListPick, WinWait, FHUserFieldComponent, FHGridJSONComponent, win_salva_annulla, FormBuilderComponent, FormExecuterComponent, FHTableManager],
|
|
14443
|
-
declarations: [FHCheckBox, FHTextInput, FHHelpButton, win_user_info, win_insert_commento, FHRoleManager, FHFieldPickListComponent, SafePipe, FHViewerComponent,
|
|
14477
|
+
declarations: [CheckboxEditorComponent, FHCheckBox, FHTextInput, FHHelpButton, win_user_info, win_insert_commento, FHRoleManager, FHFieldPickListComponent, SafePipe, FHViewerComponent,
|
|
14444
14478
|
fhimagepreview, win_show_image, WinAskButtonsComponent, FHGridToolBarComponent, win_time_slider, DecimalMask, FHTimePickerComponent, CurrencyComponent, FHUploadPanelComponent, FHUploadComponent, wkf_header_bar,
|
|
14445
14479
|
FHGridComponent, FHComboboxComponent, FHConfirmComponent, FHAutoCompleteComponent, FHDatePickerComponent, NumericEditorComponent,
|
|
14446
14480
|
FHUserPickerComponent, ApprovaGridComponent, FHCurrencyFormatterDirective, FHCurrencyPipe, win_mappa, win_grid_help, TextAreaEditor,
|
|
@@ -14640,6 +14674,7 @@
|
|
|
14640
14674
|
exports.AppService = AppService;
|
|
14641
14675
|
exports.ApprovaGridComponent = ApprovaGridComponent;
|
|
14642
14676
|
exports.AuthenticationService = AuthenticationService;
|
|
14677
|
+
exports.CheckboxEditorComponent = CheckboxEditorComponent;
|
|
14643
14678
|
exports.ComboBoxEditor = ComboBoxEditor;
|
|
14644
14679
|
exports.CurrencyComponent = CurrencyComponent;
|
|
14645
14680
|
exports.FHAutoCompleteComponent = FHAutoCompleteComponent;
|