@fluxhub/fluxhub-lib 9.0.8 → 9.0.9
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 +230 -28
- 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/fluxhub-fluxhub-lib.js +20 -19
- package/esm2015/lib/controls/fhmdreader.js +12 -3
- package/esm2015/lib/fluxhub-lib.module.js +10 -5
- package/esm2015/lib/form_builder/form_builder.js +233 -0
- package/esm2015/lib/form_builder/form_executer.js +115 -0
- package/esm2015/lib/services/prismservice.js +36 -0
- package/esm2015/public_api.js +3 -1
- package/esm5/fluxhub-fluxhub-lib.js +20 -19
- package/esm5/lib/controls/fhmdreader.js +12 -3
- package/esm5/lib/fluxhub-lib.module.js +10 -5
- package/esm5/lib/form_builder/form_builder.js +121 -0
- package/esm5/lib/form_builder/form_executer.js +62 -0
- package/esm5/lib/services/prismservice.js +37 -0
- package/esm5/public_api.js +3 -1
- package/fesm2015/fluxhub-fluxhub-lib.js +385 -9
- package/fesm2015/fluxhub-fluxhub-lib.js.map +1 -1
- package/fesm5/fluxhub-fluxhub-lib.js +222 -10
- package/fesm5/fluxhub-fluxhub-lib.js.map +1 -1
- package/fluxhub-fluxhub-lib.d.ts +20 -19
- package/fluxhub-fluxhub-lib.metadata.json +1 -1
- package/lib/controls/fhmdreader.d.ts +3 -1
- package/lib/form_builder/form_builder.d.ts +27 -0
- package/lib/form_builder/form_executer.d.ts +23 -0
- package/lib/services/prismservice.d.ts +17 -0
- package/package.json +1 -1
- package/public_api.d.ts +2 -0
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { __decorate, __metadata, __read, __extends,
|
|
2
|
-
import { ɵɵdefineInjectable, Injectable, Component, ɵɵinject, ViewChild, ViewContainerRef, Directive, EventEmitter, Input, Output, ElementRef, forwardRef, HostListener, Pipe,
|
|
1
|
+
import { __decorate, __metadata, __read, __extends, __param, __assign } from 'tslib';
|
|
2
|
+
import { ɵɵdefineInjectable, Injectable, Component, ɵɵinject, ViewChild, ViewContainerRef, Directive, EventEmitter, Input, Output, ElementRef, forwardRef, HostListener, Pipe, Inject, PLATFORM_ID, Optional, NgModule } from '@angular/core';
|
|
3
3
|
import { HttpHeaders, HttpClient } from '@angular/common/http';
|
|
4
4
|
import { ToastrService } from 'ngx-toastr';
|
|
5
5
|
import { map, catchError, flatMap } from 'rxjs/operators';
|
|
@@ -18,17 +18,30 @@ import { MatAutocomplete, MatAutocompleteModule } from '@angular/material/autoco
|
|
|
18
18
|
import * as momentNs from 'moment';
|
|
19
19
|
import { isMoment } from 'moment';
|
|
20
20
|
import { DateAdapter, MAT_DATE_FORMATS, MAT_DATE_LOCALE, MatNativeDateModule } from '@angular/material/core';
|
|
21
|
+
import { isPlatformBrowser, CommonModule } from '@angular/common';
|
|
22
|
+
import 'clipboard';
|
|
23
|
+
import 'prismjs';
|
|
24
|
+
import 'prismjs/plugins/toolbar/prism-toolbar';
|
|
25
|
+
import 'prismjs/plugins/copy-to-clipboard/prism-copy-to-clipboard';
|
|
26
|
+
import 'prismjs/components/prism-css';
|
|
27
|
+
import 'prismjs/components/prism-javascript';
|
|
28
|
+
import 'prismjs/components/prism-java';
|
|
29
|
+
import 'prismjs/components/prism-markup';
|
|
30
|
+
import 'prismjs/components/prism-typescript';
|
|
31
|
+
import 'prismjs/components/prism-sass';
|
|
32
|
+
import 'prismjs/components/prism-scss';
|
|
33
|
+
import 'prismjs/components/prism-sql';
|
|
21
34
|
import NavigatedViewer from 'bpmn-js/lib/NavigatedViewer';
|
|
22
35
|
import { MatTabGroup, MatTabsModule } from '@angular/material/tabs';
|
|
23
36
|
import { FlexLayoutModule } from '@angular/flex-layout';
|
|
24
37
|
import { MarkdownModule } from 'ngx-markdown';
|
|
25
38
|
import { CKEditorModule } from 'ng2-ckeditor';
|
|
26
|
-
import { CommonModule } from '@angular/common';
|
|
27
39
|
import { AgGridModule } from 'ag-grid-angular';
|
|
28
40
|
import { AgmCoreModule } from '@agm/core';
|
|
29
41
|
import { CdkTableModule } from '@angular/cdk/table';
|
|
30
42
|
import { NgForage } from 'ngforage';
|
|
31
43
|
import { TranslateModule } from '@ngx-translate/core';
|
|
44
|
+
import { DragulaService, DragulaModule } from 'ng2-dragula';
|
|
32
45
|
import { DomSanitizer } from '@angular/platform-browser';
|
|
33
46
|
import { MatCardModule } from '@angular/material/card';
|
|
34
47
|
import { MatButtonModule } from '@angular/material/button';
|
|
@@ -7855,15 +7868,43 @@ var WinAskNumberComponent = /** @class */ (function () {
|
|
|
7855
7868
|
return WinAskNumberComponent;
|
|
7856
7869
|
}());
|
|
7857
7870
|
|
|
7871
|
+
var HighlightService = /** @class */ (function () {
|
|
7872
|
+
function HighlightService(platformId) {
|
|
7873
|
+
this.platformId = platformId;
|
|
7874
|
+
}
|
|
7875
|
+
HighlightService.prototype.highlightAll = function () {
|
|
7876
|
+
if (isPlatformBrowser(this.platformId)) {
|
|
7877
|
+
Prism.highlightAll();
|
|
7878
|
+
}
|
|
7879
|
+
};
|
|
7880
|
+
HighlightService.ctorParameters = function () { return [
|
|
7881
|
+
{ type: Object, decorators: [{ type: Inject, args: [PLATFORM_ID,] }] }
|
|
7882
|
+
]; };
|
|
7883
|
+
HighlightService = __decorate([
|
|
7884
|
+
Injectable(),
|
|
7885
|
+
__param(0, Inject(PLATFORM_ID)),
|
|
7886
|
+
__metadata("design:paramtypes", [Object])
|
|
7887
|
+
], HighlightService);
|
|
7888
|
+
return HighlightService;
|
|
7889
|
+
}());
|
|
7890
|
+
|
|
7858
7891
|
var FHMdReader = /** @class */ (function () {
|
|
7859
|
-
function FHMdReader() {
|
|
7892
|
+
function FHMdReader(highlightService) {
|
|
7893
|
+
this.highlightService = highlightService;
|
|
7860
7894
|
this.highlighted = false;
|
|
7861
7895
|
this.path_md = "";
|
|
7862
7896
|
}
|
|
7863
7897
|
FHMdReader.prototype.ngAfterViewChecked = function () {
|
|
7898
|
+
if (!this.highlighted && !this.path_md == null) {
|
|
7899
|
+
this.highlightService.highlightAll();
|
|
7900
|
+
this.highlighted = true;
|
|
7901
|
+
}
|
|
7864
7902
|
};
|
|
7865
7903
|
FHMdReader.prototype.ngAfterViewInit = function () {
|
|
7866
7904
|
};
|
|
7905
|
+
FHMdReader.ctorParameters = function () { return [
|
|
7906
|
+
{ type: HighlightService }
|
|
7907
|
+
]; };
|
|
7867
7908
|
__decorate([
|
|
7868
7909
|
Input(),
|
|
7869
7910
|
__metadata("design:type", String)
|
|
@@ -7873,7 +7914,7 @@ var FHMdReader = /** @class */ (function () {
|
|
|
7873
7914
|
selector: 'FHMdReader', template: "\n <markdown [src]=\"path_md\">\n\n </markdown>\n\n ",
|
|
7874
7915
|
styles: ["\n\n "]
|
|
7875
7916
|
}),
|
|
7876
|
-
__metadata("design:paramtypes", [])
|
|
7917
|
+
__metadata("design:paramtypes", [HighlightService])
|
|
7877
7918
|
], FHMdReader);
|
|
7878
7919
|
return FHMdReader;
|
|
7879
7920
|
}());
|
|
@@ -12173,6 +12214,176 @@ var wkf_header_bar = /** @class */ (function () {
|
|
|
12173
12214
|
return wkf_header_bar;
|
|
12174
12215
|
}());
|
|
12175
12216
|
|
|
12217
|
+
var FormBuilderComponent = /** @class */ (function () {
|
|
12218
|
+
function FormBuilderComponent(fhutility, _dialog, dragula) {
|
|
12219
|
+
this.fhutility = fhutility;
|
|
12220
|
+
this._dialog = _dialog;
|
|
12221
|
+
this.dragula = dragula;
|
|
12222
|
+
this.change = new EventEmitter();
|
|
12223
|
+
this.items = [];
|
|
12224
|
+
this.edit_obj = null;
|
|
12225
|
+
this.radio_values = '';
|
|
12226
|
+
}
|
|
12227
|
+
FormBuilderComponent.prototype.add_component = function (o) {
|
|
12228
|
+
if (o == 1)
|
|
12229
|
+
this.items.push({ type: 'text_field', label: 'Label', default_value: '', uiid: this.fhutility.newGuid(), selected: false, required: false });
|
|
12230
|
+
if (o == 2)
|
|
12231
|
+
this.items.push({ type: 'numeric_field', label: 'Label', default_value: 0, decimali: 2, uiid: this.fhutility.newGuid(), selected: false, required: false });
|
|
12232
|
+
if (o == 3)
|
|
12233
|
+
this.items.push({ type: 'textarea', label: 'Label', default_value: '', uiid: this.fhutility.newGuid(), selected: false, required: false });
|
|
12234
|
+
if (o == 4)
|
|
12235
|
+
this.items.push({ type: 'checkbox', label: 'Label', default_value: '', uiid: this.fhutility.newGuid(), selected: false, required: false });
|
|
12236
|
+
if (o == 5)
|
|
12237
|
+
this.items.push({ type: 'radiobutton', label: 'Label', default_value: '', opts: ['Option1', 'Option2'], uiid: this.fhutility.newGuid(), selected: false, required: false });
|
|
12238
|
+
if (o == 6)
|
|
12239
|
+
this.items.push({ type: 'select', label: 'Label', default_value: '', opts: ['', 'Value1', 'Value2'], uiid: this.fhutility.newGuid(), selected: false, required: false });
|
|
12240
|
+
if (o == 7)
|
|
12241
|
+
this.items.push({ type: 'date_field', label: 'Label', default_value: null, uiid: this.fhutility.newGuid(), selected: false, required: false });
|
|
12242
|
+
this.change.emit();
|
|
12243
|
+
this.edit_obj = null;
|
|
12244
|
+
// this.bottoml.nativeElement.scrollIntoView(false)
|
|
12245
|
+
};
|
|
12246
|
+
FormBuilderComponent.prototype.setStyles = function (o) {
|
|
12247
|
+
if (this.edit_obj != null)
|
|
12248
|
+
if (this.edit_obj.uiid == o)
|
|
12249
|
+
return { width: '90%', padding: '15px', margin: '15px', border: '3px solid #3db3cd', 'background-color': "#C2CACB" };
|
|
12250
|
+
return { width: '90%', padding: '15px', margin: '15px', border: '1px solid #3db3cd', 'background-color': "#ECF0F1" };
|
|
12251
|
+
};
|
|
12252
|
+
FormBuilderComponent.prototype.ok_panel = function () {
|
|
12253
|
+
this.change.emit();
|
|
12254
|
+
this.edit_obj = null;
|
|
12255
|
+
};
|
|
12256
|
+
FormBuilderComponent.prototype.edit_item = function (uiid_obj) {
|
|
12257
|
+
for (var i = 0; i < this.items.length; i++) {
|
|
12258
|
+
if (this.items[i].uiid == uiid_obj) {
|
|
12259
|
+
this.edit_obj = this.items[i];
|
|
12260
|
+
if (this.edit_obj.type == 'radiobutton' || this.edit_obj.type == 'select')
|
|
12261
|
+
if (this.edit_obj.opts != null)
|
|
12262
|
+
this.radio_values = this.edit_obj.opts.join(',');
|
|
12263
|
+
}
|
|
12264
|
+
}
|
|
12265
|
+
};
|
|
12266
|
+
FormBuilderComponent.prototype.del_item = function (uiid_obj) {
|
|
12267
|
+
var _this = this;
|
|
12268
|
+
var dialogRef = this._dialog.open(FHConfirmComponent, { 'disableClose': true });
|
|
12269
|
+
setTimeout(function () {
|
|
12270
|
+
dialogRef.componentInstance.title = 'Confirm';
|
|
12271
|
+
dialogRef.componentInstance.msg = "Remove Element?";
|
|
12272
|
+
});
|
|
12273
|
+
dialogRef.afterClosed().subscribe(function (result) {
|
|
12274
|
+
if (result) {
|
|
12275
|
+
for (var i = 0; i < _this.items.length; i++)
|
|
12276
|
+
if (_this.items[i].uiid == uiid_obj) {
|
|
12277
|
+
_this.items.splice(i, 1);
|
|
12278
|
+
_this.change.emit();
|
|
12279
|
+
_this.edit_obj = null;
|
|
12280
|
+
}
|
|
12281
|
+
}
|
|
12282
|
+
});
|
|
12283
|
+
};
|
|
12284
|
+
FormBuilderComponent.prototype.ngAfterViewInit = function () {
|
|
12285
|
+
var _this = this;
|
|
12286
|
+
setTimeout(function () {
|
|
12287
|
+
try {
|
|
12288
|
+
_this.dragula.createGroup('bag-items', {
|
|
12289
|
+
revertOnSpill: true
|
|
12290
|
+
});
|
|
12291
|
+
}
|
|
12292
|
+
catch (e) {
|
|
12293
|
+
console.log(e);
|
|
12294
|
+
}
|
|
12295
|
+
_this.dragula
|
|
12296
|
+
.drag.call(function (value) {
|
|
12297
|
+
_this.change.emit();
|
|
12298
|
+
_this.edit_obj = null;
|
|
12299
|
+
});
|
|
12300
|
+
_this.dragula
|
|
12301
|
+
.drop
|
|
12302
|
+
.call(function (value) {
|
|
12303
|
+
_this.change.emit();
|
|
12304
|
+
_this.edit_obj = null;
|
|
12305
|
+
});
|
|
12306
|
+
});
|
|
12307
|
+
};
|
|
12308
|
+
FormBuilderComponent.ctorParameters = function () { return [
|
|
12309
|
+
{ type: UtilityService },
|
|
12310
|
+
{ type: MatDialog },
|
|
12311
|
+
{ type: DragulaService }
|
|
12312
|
+
]; };
|
|
12313
|
+
__decorate([
|
|
12314
|
+
Output(),
|
|
12315
|
+
__metadata("design:type", EventEmitter)
|
|
12316
|
+
], FormBuilderComponent.prototype, "change", void 0);
|
|
12317
|
+
__decorate([
|
|
12318
|
+
ViewChild('bottoml'),
|
|
12319
|
+
__metadata("design:type", ElementRef)
|
|
12320
|
+
], FormBuilderComponent.prototype, "bottoml", void 0);
|
|
12321
|
+
FormBuilderComponent = __decorate([
|
|
12322
|
+
Component({
|
|
12323
|
+
selector: 'FHFormBuilder', template: "\n <div fxLayout=\"row\" style=\"width: 100%;height:100%\">\n <mat-toolbar color=\"primary\" style=\"max-width: 200px;height:100%;\" >\n <mat-toolbar-row (click)=\"add_component(1)\">\n <mat-icon>text_fields</mat-icon> <span>Text Field</span>\n </mat-toolbar-row>\n <mat-toolbar-row (click)=\"add_component(2)\">\n <mat-icon>filter_1</mat-icon> <span>Number</span>\n </mat-toolbar-row>\n <mat-toolbar-row (click)=\"add_component(3)\">\n <mat-icon>filter_none</mat-icon> <span>Text Area</span>\n </mat-toolbar-row>\n <mat-toolbar-row (click)=\"add_component(4)\">\n <mat-icon>check_box</mat-icon> <span>Check Box</span>\n </mat-toolbar-row>\n <mat-toolbar-row (click)=\"add_component(5)\">\n <mat-icon>radio_button_checked</mat-icon> <span>Radio</span>\n </mat-toolbar-row>\n <mat-toolbar-row (click)=\"add_component(6)\">\n <mat-icon>dehaze</mat-icon> <span>Select</span>\n </mat-toolbar-row>\n <mat-toolbar-row (click)=\"add_component(7)\">\n <mat-icon>today</mat-icon> <span>Date</span>\n </mat-toolbar-row>\n\n </mat-toolbar>\n <div fxLayout=\"column\" fxFlex=\"100\" style=\"width:100%;border:1px solid #004040;height:100%;overflow:auto;background-color: #a6aec4\">\n <div fxLayout=\"row\" style=\"width:90%;width:100%;height:5000px;\">\n\n <ul [dragula]='\"bag-items\"' [(dragulaModel)]='items' style=\"width:100%;\">\n <li fxLayout=\"row\" *ngFor=\"let item of items\" [ngStyle]=\"setStyles(item.uiid)\" fxLayoutAlign=\"start center\">\n <div style=\"width:100%\">\n\n <div style=\"width: 90%\">\n <mat-form-field *ngIf=\"item.type=='text_field'\" style=\"max-width: 350px\" appearance=\"outline\" floatLabel=\"always\"><mat-label>{{item.label}}</mat-label>\n <input matInput [required]=\"item.required\" type=\"text\" [(ngModel)]=\"item.default_value\">\n </mat-form-field>\n\n\n <mat-form-field *ngIf=\"item.type=='numeric_field'\" style=\"max-width: 220px\" appearance=\"outline\" floatLabel=\"always\"><mat-label>{{item.label}}</mat-label>\n <input matInput [required]=\"item.required\" type=\"number\" [(ngModel)]=\"item.default_value\">\n </mat-form-field>\n\n\n <FHRichText *ngIf=\"item.type=='textarea'\" [label]=\"item.label\" [required]=\"item.required\" [(ngModel)]=\"item.default_value\" height=\"15'\" enabled=\"false\"></FHRichText>\n\n <mat-checkbox *ngIf=\"item.type=='checkbox'\" [required]=\"item.required\" [(ngModel)]=\"item.default_value\"><b>{{item.label}}</b></mat-checkbox>\n\n\n <section class=\"custom-section\" *ngIf=\"item.type=='radiobutton'\" >\n <label class=\"custom-margin\">{{item.label}}:</label>\n <mat-radio-group [(ngModel)]=\"item.default_value\" [required]=\"item.required\" >\n <mat-radio-button *ngFor=\"let opt of item.opts\" class=\"custom-margin\" value=\"{{opt}}\"><b>{{opt}}</b></mat-radio-button>\n </mat-radio-group>\n </section>\n\n <mat-form-field *ngIf=\"item.type=='select'\" style=\"max-width: 400px\" appearance=\"outline\" floatLabel=\"always\"><mat-label>{{item.label}}</mat-label>\n <mat-select [required]=\"item.required\" [(ngModel)]=\"item.default_value\">\n <mat-option *ngFor=\"let opt of item.opts\" value=\"{{opt}}\">{{opt}}</mat-option>\n </mat-select>\n </mat-form-field>\n <div style=\"width: 220px\" *ngIf=\"item.type=='date_field'\">\n <FHDatePicker [required]=\"item.required\" [(ngModel)]=\"item.default_value\" [label]=\"item.label\" ></FHDatePicker> \n </div>\n\n </div></div>\n <div fxLayout=\"column\" style=\"width:70px\" fxLayoutGap=\"10px\">\n <button mat-flat-button (click)=\"edit_item(item.uiid)\" color=\"primary\"><mat-icon>edit</mat-icon></button>\n <button mat-flat-button (click)=\"del_item(item.uiid)\" color=\"warn\"><mat-icon>delete</mat-icon></button>\n </div>\n </li>\n </ul>\n\n\n </div>\n <mat-form-field [hidden]=\"true\">\n <input matInput #bottoml>\n </mat-form-field>\n </div>\n\n <div style=\"width:400px;height:100%;background-color: #3F51B5\" fxLayoutAlign=\"start center\" fxLayout=\"column\" *ngIf=\"edit_obj!=null\">\n <br><br>\n <mat-card style=\"width: 96%\">\n <mat-card-title>Properties</mat-card-title>\n <mat-card-content>\n <div fxLayout=\"column\">\n <mat-form-field appearance=\"outline\" floatLabel=\"always\"><mat-label>Label</mat-label>\n <input matInput type=\"text\" [(ngModel)]=\"edit_obj.label\">\n </mat-form-field>\n <mat-checkbox [(ngModel)]=\"edit_obj.required\">Required</mat-checkbox>\n\n <mat-form-field *ngIf=\"edit_obj.type=='numeric_field_tobe'\" appearance=\"outline\" floatLabel=\"always\"><mat-label>Decimal Places</mat-label>\n <input matInput type=\"text\" [(ngModel)]=\"edit_obj.decimali\">\n </mat-form-field>\n <mat-form-field *ngIf=\"edit_obj.type=='text_field'\" appearance=\"outline\" floatLabel=\"always\"><mat-label>Default Value</mat-label>\n <input matInput type=\"text\" [(ngModel)]=\"edit_obj.default_value\" >\n </mat-form-field>\n\n\n <mat-checkbox *ngIf=\"edit_obj.type=='checkbox'\" [(ngModel)]=\"edit_obj.default_value\">Default Value</mat-checkbox>\n\n <mat-form-field *ngIf=\"edit_obj.type=='radiobutton' || edit_obj.type=='select'\" appearance=\"outline\" floatLabel=\"always\"><mat-label>Values</mat-label>\n <input matInput type=\"text\" [(ngModel)]=\"radio_values\" (ngModelChange)=\"edit_obj.opts=$event.split(',');\" >\n </mat-form-field>\n <mat-form-field *ngIf=\"edit_obj.type=='radiobutton' || edit_obj.type=='select'\" appearance=\"outline\" floatLabel=\"always\"><mat-label>Default Value</mat-label>\n <input matInput type=\"text\" [(ngModel)]=\"edit_obj.default_value\" >\n </mat-form-field>\n\n <button mat-flat-button (click)=\"ok_panel()\" color=\"primary\">OK</button>\n </div></mat-card-content>\n </mat-card>\n </div>\n </div>\n ",
|
|
12324
|
+
styles: ["\n\n "]
|
|
12325
|
+
}),
|
|
12326
|
+
__metadata("design:paramtypes", [UtilityService, MatDialog, DragulaService])
|
|
12327
|
+
], FormBuilderComponent);
|
|
12328
|
+
return FormBuilderComponent;
|
|
12329
|
+
}());
|
|
12330
|
+
|
|
12331
|
+
var FormExecuterComponent = /** @class */ (function () {
|
|
12332
|
+
function FormExecuterComponent(fhutility, _dialog, toastr) {
|
|
12333
|
+
this.fhutility = fhutility;
|
|
12334
|
+
this._dialog = _dialog;
|
|
12335
|
+
this.toastr = toastr;
|
|
12336
|
+
this.items = null;
|
|
12337
|
+
this.enabled = true;
|
|
12338
|
+
}
|
|
12339
|
+
FormExecuterComponent.prototype.ck_field_custom = function () {
|
|
12340
|
+
for (var i = 0; i < this.items.length; i++) {
|
|
12341
|
+
if (this.items[i].required) {
|
|
12342
|
+
if (this.items[i].default_value == null)
|
|
12343
|
+
this.items[i].default_value = '';
|
|
12344
|
+
if (('' + this.items[i].default_value).trim() == '') {
|
|
12345
|
+
this.toastr.error('Compilare il campo: ' + this.items[i].label);
|
|
12346
|
+
return false;
|
|
12347
|
+
}
|
|
12348
|
+
}
|
|
12349
|
+
}
|
|
12350
|
+
return true;
|
|
12351
|
+
};
|
|
12352
|
+
FormExecuterComponent.prototype.add_component = function (o) {
|
|
12353
|
+
this.items.push(o);
|
|
12354
|
+
};
|
|
12355
|
+
FormExecuterComponent.prototype.setStyles = function (o) {
|
|
12356
|
+
return { width: '90%', padding: '15px', margin: '15px', border: '1px solid #3db3cd', 'background-color': "#ECF0F1" };
|
|
12357
|
+
};
|
|
12358
|
+
FormExecuterComponent.prototype.ngAfterViewInit = function () {
|
|
12359
|
+
};
|
|
12360
|
+
FormExecuterComponent.ctorParameters = function () { return [
|
|
12361
|
+
{ type: UtilityService },
|
|
12362
|
+
{ type: MatDialog },
|
|
12363
|
+
{ type: ToastrService }
|
|
12364
|
+
]; };
|
|
12365
|
+
__decorate([
|
|
12366
|
+
Input(),
|
|
12367
|
+
__metadata("design:type", Array)
|
|
12368
|
+
], FormExecuterComponent.prototype, "items", void 0);
|
|
12369
|
+
__decorate([
|
|
12370
|
+
Input(),
|
|
12371
|
+
__metadata("design:type", Boolean)
|
|
12372
|
+
], FormExecuterComponent.prototype, "enabled", void 0);
|
|
12373
|
+
__decorate([
|
|
12374
|
+
ViewChild('bottoml'),
|
|
12375
|
+
__metadata("design:type", ElementRef)
|
|
12376
|
+
], FormExecuterComponent.prototype, "bottoml", void 0);
|
|
12377
|
+
FormExecuterComponent = __decorate([
|
|
12378
|
+
Component({
|
|
12379
|
+
selector: 'FHFormExecuter', template: "\n\n <div fxLayout=\"column\" fxFlex=\"100\" style=\"width:100%;border:1px solid #004040;height:100%\" *ngIf=\"items!=null\">\n\n\n <div fxLayout=\"row\" *ngFor=\"let item of items\" [ngStyle]=\"setStyles(item.uiid)\" fxLayoutAlign=\"start center\">\n\n <div style=\"width: 90%\">\n <mat-form-field *ngIf=\"item.type=='text_field'\" style=\"max-width: 350px\" appearance=\"outline\" floatLabel=\"always\"><mat-label>{{item.label}}</mat-label>\n <input matInput [required]=\"item.required\" [disabled]=\"!enabled\" type=\"text\" [(ngModel)]=\"item.default_value\">\n </mat-form-field>\n\n\n\n <mat-form-field *ngIf=\"item.type=='numeric_field'\" style=\"max-width: 220px\" appearance=\"outline\" floatLabel=\"always\"><mat-label>{{item.label}}</mat-label>\n <input matInput [required]=\"item.required\" [disabled]=\"!enabled\" type=\"number\" [(ngModel)]=\"item.default_value\">\n </mat-form-field>\n\n\n <FHRichText *ngIf=\"item.type=='textarea'\" [label]=\"item.label\" [required]=\"item.required\" [(ngModel)]=\"item.default_value\" height=\"15'\" enabled=\"false\"></FHRichText>\n\n <mat-checkbox *ngIf=\"item.type=='checkbox'\" [required]=\"item.required\" [disabled]=\"!enabled\" [(ngModel)]=\"item.default_value\"><b>{{item.label}}</b></mat-checkbox>\n\n\n <section *ngIf=\"item.type=='radiobutton'\" >\n <label *ngIf=\"!item.required\">{{item.label}}: </label> \n <label *ngIf=\"item.required\">{{item.label}}: *</label> \n <mat-radio-group [(ngModel)]=\"item.default_value\" [required]=\"item.required\" >\n <mat-radio-button *ngFor=\"let opt of item.opts\" [disabled]=\"!enabled\" class=\"custom-margin\" value=\"{{opt}}\"><b>{{opt}}</b> </mat-radio-button>\n </mat-radio-group>\n </section>\n\n <mat-form-field *ngIf=\"item.type=='select'\" appearance=\"outline\" floatLabel=\"always\"><mat-label>{{item.label}}</mat-label>\n <mat-select [required]=\"item.required\" [(ngModel)]=\"item.default_value\">\n <mat-option *ngFor=\"let opt of item.opts\" [disabled]=\"!enabled\" value=\"{{opt}}\">{{opt}}</mat-option>\n </mat-select>\n </mat-form-field>\n <div style=\"width: 220px\" *ngIf=\"item.type=='date_field'\">\n <FHDatePicker [required]=\"item.required\" [disabled]=\"!enabled\" [(ngModel)]=\"item.default_value\" [label]=\"item.label\" ></FHDatePicker> \n </div>\n\n </div>\n\n </div>\n\n\n <mat-form-field [hidden]=\"true\">\n <input matInput #bottoml>\n </mat-form-field>\n </div>\n\n\n ",
|
|
12380
|
+
styles: ["\n\n "]
|
|
12381
|
+
}),
|
|
12382
|
+
__metadata("design:paramtypes", [UtilityService, MatDialog, ToastrService])
|
|
12383
|
+
], FormExecuterComponent);
|
|
12384
|
+
return FormExecuterComponent;
|
|
12385
|
+
}());
|
|
12386
|
+
|
|
12176
12387
|
var WinAskButtonsComponent = /** @class */ (function () {
|
|
12177
12388
|
function WinAskButtonsComponent(dialogRef) {
|
|
12178
12389
|
this.dialogRef = dialogRef;
|
|
@@ -13860,7 +14071,7 @@ var FluxhubLibModule = /** @class */ (function () {
|
|
|
13860
14071
|
MatPaginatorModule,
|
|
13861
14072
|
MatSortModule,
|
|
13862
14073
|
MatTableModule,
|
|
13863
|
-
MatNativeDateModule, FileUploadModule, AgGridModule.withComponents([NumericEditorComponent]), CommonModule, FormsModule,
|
|
14074
|
+
MatNativeDateModule, FileUploadModule, AgGridModule.withComponents([NumericEditorComponent]), CommonModule, DragulaModule, FormsModule,
|
|
13864
14075
|
AgmCoreModule.forRoot({
|
|
13865
14076
|
apiKey: 'AIzaSyD3-g3b_QqxUruxBY4PGJKaH2fubIVXvN4'
|
|
13866
14077
|
}),
|
|
@@ -13870,7 +14081,7 @@ var FluxhubLibModule = /** @class */ (function () {
|
|
|
13870
14081
|
FHUserPickerComponent, ApprovaGridComponent, FHCurrencyFormatterDirective, FHCurrencyPipe, win_mappa, win_grid_help, TextAreaEditor,
|
|
13871
14082
|
ComboBoxEditor, FHListComponent, FHWinComboSelect, ReplaceLineBreaks, WinAskTextComponent, FHPickListComponent, WinAskNumberComponent,
|
|
13872
14083
|
FHMdReader, FHLogPanelComponent, WinAskTextBigComponent, FHCurrencyFieldComponent, FHRichText, WinOutputComponent, FHNumericFieldComponent, wkf_header_bar,
|
|
13873
|
-
FHListPick, WinWait, FHUserFieldComponent, FSInput, FSResult, QGParam, QGResult, QParam, QResult, FHGridJSONComponent, win_salva_annulla, FHTableManager],
|
|
14084
|
+
FHListPick, WinWait, FHUserFieldComponent, FSInput, FSResult, QGParam, QGResult, QParam, QResult, FHGridJSONComponent, win_salva_annulla, FormBuilderComponent, FormExecuterComponent, FHTableManager],
|
|
13874
14085
|
declarations: [FHHelpButton, win_user_info, win_insert_commento, FHRoleManager, FHFieldPickListComponent, SafePipe, FHViewerComponent,
|
|
13875
14086
|
fhimagepreview, win_show_image, WinAskButtonsComponent, FHGridToolBarComponent, win_time_slider, DecimalMask, FHTimePickerComponent, CurrencyComponent, FHUploadPanelComponent, FHUploadComponent, wkf_header_bar,
|
|
13876
14087
|
FHGridComponent, FHComboboxComponent, FHConfirmComponent, FHAutoCompleteComponent, FHDatePickerComponent, NumericEditorComponent,
|
|
@@ -13879,8 +14090,9 @@ var FluxhubLibModule = /** @class */ (function () {
|
|
|
13879
14090
|
FHMdReader, FHLogPanelComponent, WinAskTextBigComponent, FHCurrencyFieldComponent, FHRichText, WinOutputComponent, FHNumericFieldComponent,
|
|
13880
14091
|
FHListPick, WinWait, FHUserFieldComponent, FSInput, FSResult, QGParam, QGResult, QParam, QResult, win_salva_annulla, win_assegna,
|
|
13881
14092
|
win_conferma, win_select_canale, win_select_level, win_uploads, win_commenti, win_info_doc, win_log, win_recupera_doc, win_riassegna_select_level,
|
|
13882
|
-
win_riassegna_select_user, win_sostituisci_utente, win_commento_sel_notif, FHGridJSONComponent, FHTableManager, win_manage_values, win_manage_roles, FHComboboxComponentFilter],
|
|
13883
|
-
providers: [
|
|
14093
|
+
win_riassegna_select_user, win_sostituisci_utente, win_commento_sel_notif, FHGridJSONComponent, FormBuilderComponent, FormExecuterComponent, FHTableManager, win_manage_values, win_manage_roles, FHComboboxComponentFilter],
|
|
14094
|
+
providers: [HighlightService, DragulaService
|
|
14095
|
+
],
|
|
13884
14096
|
entryComponents: [
|
|
13885
14097
|
// Customize dialog must be import here.
|
|
13886
14098
|
win_user_info, win_insert_commento, win_manage_roles, win_manage_values, win_show_image, WinAskButtonsComponent, win_salva_annulla, win_assegna, win_conferma, win_select_canale, win_select_level, win_uploads, win_commenti, win_info_doc, win_log, win_recupera_doc, win_riassegna_select_level, win_sostituisci_utente, win_riassegna_select_user, win_commento_sel_notif,
|
|
@@ -14060,5 +14272,5 @@ var FHGuard = /** @class */ (function () {
|
|
|
14060
14272
|
* Generated bundle index. Do not edit.
|
|
14061
14273
|
*/
|
|
14062
14274
|
|
|
14063
|
-
export { AppMakerService, AppService, ApprovaGridComponent, AuthenticationService, ComboBoxEditor, CurrencyComponent, FHAutoCompleteComponent, FHComboboxComponent, FHConfirmComponent, FHCurrencyFieldComponent, FHCurrencyFormatterDirective, FHCurrencyPipe, FHDatePickerComponent, FHFieldPickListComponent, FHGridComponent, FHGridJSONComponent, FHGuard, FHListComponent, FHListPick, FHLogPanelComponent, FHMdReader, FHNumericFieldComponent, FHPickListComponent, FHRichText, FHRoleManager, FHTableManager, FHTimePickerComponent, FHUploadComponent, FHUploadPanelComponent, FHUserFieldComponent, FHUserPickerComponent, FHWinComboSelect, FSInput, FSResult, FileService, FluxhubLibModule, 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$2 as ɵa, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$1 as ɵb,
|
|
14275
|
+
export { AppMakerService, AppService, ApprovaGridComponent, AuthenticationService, ComboBoxEditor, CurrencyComponent, FHAutoCompleteComponent, FHComboboxComponent, FHConfirmComponent, FHCurrencyFieldComponent, FHCurrencyFormatterDirective, FHCurrencyPipe, FHDatePickerComponent, FHFieldPickListComponent, FHGridComponent, FHGridJSONComponent, FHGuard, FHListComponent, FHListPick, FHLogPanelComponent, FHMdReader, FHNumericFieldComponent, FHPickListComponent, FHRichText, FHRoleManager, FHTableManager, 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$2 as ɵa, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR$1 as ɵb, win_riassegna_select_user as ɵba, win_sostituisci_utente as ɵbb, win_commento_sel_notif as ɵbc, win_manage_values as ɵbd, win_manage_roles as ɵbe, FHComboboxComponentFilter as ɵbf, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR_NUMERIC as ɵc, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR_RT as ɵd, CUSTOM_INPUT_CONTROL_VALUE_ACCESSOR as ɵe, FHHelpButton as ɵf, SafePipe as ɵg, DecimalMask as ɵh, FHValueAccessor as ɵi, MOMENT_DATE_FORMATS as ɵj, MomentDateAdapter as ɵk, win_grid_help as ɵl, HighlightService as ɵm, FHViewerComponent as ɵn, FHGridToolBarComponent as ɵp, win_assegna as ɵq, win_conferma as ɵr, win_select_canale as ɵs, win_select_level as ɵt, win_uploads as ɵu, win_commenti as ɵv, win_info_doc as ɵw, win_log as ɵx, win_recupera_doc as ɵy, win_riassegna_select_level as ɵz };
|
|
14064
14276
|
//# sourceMappingURL=fluxhub-fluxhub-lib.js.map
|