@fluxhub/fluxhub-lib 9.0.30 → 9.0.31

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.
@@ -1879,30 +1879,37 @@ var WinWait = /** @class */ (function () {
1879
1879
  return WinWait;
1880
1880
  }());
1881
1881
 
1882
- var FHComboboxComponent = /** @class */ (function () {
1882
+ var FHComboboxComponent = /** @class */ (function (_super) {
1883
+ __extends(FHComboboxComponent, _super);
1883
1884
  function FHComboboxComponent(_dataService, _dataService_odbc) {
1884
- this._dataService = _dataService;
1885
- this._dataService_odbc = _dataService_odbc;
1886
- this.init_fill = true;
1887
- this.sql = "";
1888
- this.types = [];
1889
- this.values = [];
1890
- this.hidden = false;
1891
- this.label = "";
1892
- this.enabled = true;
1893
- this.required = false;
1894
- this.sel_label = "";
1895
- this.fillend = new EventEmitter();
1896
- this.selchange = new EventEmitter();
1897
- this.initend = new EventEmitter();
1898
- this.myData = [];
1899
- this.valDef = "-1";
1900
- this.selval = "-1";
1901
- this.errorMsg = "";
1902
- this.db_type = "1";
1903
- this.dis_value = '';
1904
- this.descri_val = "";
1885
+ var _this = _super.call(this) || this;
1886
+ _this._dataService = _dataService;
1887
+ _this._dataService_odbc = _dataService_odbc;
1888
+ _this.init_fill = true;
1889
+ _this.sql = "";
1890
+ _this.types = [];
1891
+ _this.values = [];
1892
+ _this.hidden = false;
1893
+ _this.label = "";
1894
+ _this.enabled = true;
1895
+ _this.required = false;
1896
+ _this.sel_label = "";
1897
+ _this.fillend = new EventEmitter();
1898
+ _this.selchange = new EventEmitter();
1899
+ _this.initend = new EventEmitter();
1900
+ _this.myData = [];
1901
+ _this.valDef = "-1";
1902
+ _this.selval = "-1";
1903
+ _this.errorMsg = "";
1904
+ _this.db_type = "1";
1905
+ _this.dis_value = '';
1906
+ _this.descri_val = "";
1907
+ return _this;
1905
1908
  }
1909
+ FHComboboxComponent_1 = FHComboboxComponent;
1910
+ FHComboboxComponent.prototype.setValue = function (desc_val) {
1911
+ this.setByValue(desc_val);
1912
+ };
1906
1913
  FHComboboxComponent.prototype.update_dis = function () {
1907
1914
  this.dis_value = '';
1908
1915
  try {
@@ -2152,6 +2159,31 @@ var FHComboboxComponent = /** @class */ (function () {
2152
2159
  .selchange
2153
2160
  .emit({ event: this.getObj(), valore: this.getValue(), descrizione_valore: this.getDescri() });
2154
2161
  };
2162
+ FHComboboxComponent.prototype.getModelValue = function () {
2163
+ var value = this.getData('valore');
2164
+ return value;
2165
+ };
2166
+ FHComboboxComponent.prototype.emitChanged = function () {
2167
+ var value = this.getModelValue();
2168
+ this.changed.forEach(function (f) { return f(value); });
2169
+ };
2170
+ Object.defineProperty(FHComboboxComponent.prototype, "value", {
2171
+ get: function () {
2172
+ return this.getModelValue();
2173
+ },
2174
+ set: function (value) {
2175
+ if (this.getModelValue() !== value) {
2176
+ this.setByValue(value);
2177
+ this.changed.forEach(function (f) { return f(value); });
2178
+ }
2179
+ },
2180
+ enumerable: true,
2181
+ configurable: true
2182
+ });
2183
+ FHComboboxComponent.prototype.writeValue = function (value) {
2184
+ this.setValue(value);
2185
+ };
2186
+ var FHComboboxComponent_1;
2155
2187
  FHComboboxComponent.ctorParameters = function () { return [
2156
2188
  { type: QueryService },
2157
2189
  { type: OdbcService }
@@ -2216,15 +2248,18 @@ var FHComboboxComponent = /** @class */ (function () {
2216
2248
  Input(),
2217
2249
  __metadata("design:type", String)
2218
2250
  ], FHComboboxComponent.prototype, "db_type", void 0);
2219
- FHComboboxComponent = __decorate([
2251
+ FHComboboxComponent = FHComboboxComponent_1 = __decorate([
2220
2252
  Component({
2221
2253
  selector: 'FHComboBox', template: "\n <mat-form-field [hidden]=\"!enabled || hidden\" appearance=\"outline\" floatLabel=\"always\"><mat-label>{{label}}</mat-label>\n <mat-select #cmb [(ngModel)]=\"selval\" (selectionChange)=\"sc()\" [required]=\"required\">\n <mat-option value=\"-1\">{{sel_label}}</mat-option>\n <mat-option value=\"{{app.valore}}\" *ngFor=\"let app of myData\">{{app.descrizione_valore}}</mat-option>\n </mat-select>\n </mat-form-field>\n\n <mat-form-field [hidden]=\"enabled || hidden\" appearance=\"outline\" floatLabel=\"always\"><mat-label>{{label}}</mat-label>\n <input type=\"text\" #el1 matInput [disabled]=\"true\" [(ngModel)]=\"dis_value\">\n </mat-form-field>\n ",
2254
+ providers: [
2255
+ { provide: NG_VALUE_ACCESSOR, useExisting: FHComboboxComponent_1, multi: true },
2256
+ ],
2222
2257
  styles: ["\n\n "]
2223
2258
  }),
2224
2259
  __metadata("design:paramtypes", [QueryService, OdbcService])
2225
2260
  ], FHComboboxComponent);
2226
2261
  return FHComboboxComponent;
2227
- }());
2262
+ }(FHValueAccessor));
2228
2263
 
2229
2264
  var FHUploadComponent = /** @class */ (function () {
2230
2265
  function FHUploadComponent(_dataService, toastr, dialog, app_s) {
@@ -3356,7 +3391,7 @@ var WinAskTextComponent = /** @class */ (function () {
3356
3391
  WinAskTextComponent = __decorate([
3357
3392
  Component({
3358
3393
  selector: 'app-win_ask_text',
3359
- template: "\n <div style=\"width:100%\" fxLayout=\"row\" fxLayoutAlign=\"end start\"><img src=\"assets/icons/x.png\" style=\"cursor: pointer;\" (click)=\"close()\" /> </div>\n <hr width=\"100%\" size=\"0.5\" color=\"#DDDDDD\">\n\n <h2 mat-dialog-title>{{title}}</h2>\n <mat-dialog-content style=\"font-size: 15px;\">\n <mat-form-field appearance=\"outline\" floatLabel=\"always\" style=\"width:100%\"><mat-label>{{label}} (min {{min_chars}} - max {{max_chars}} caratteri)</mat-label>\n <input matInput type=\"text\"\n [(ngModel)]=\"valore\" required>\n </mat-form-field>\n </mat-dialog-content>\n\n <div fxLayout=\"row\" fxLayoutAlign=\"center center\" style=\"width: 100%\" [hidden]=\"readonly\">\n <button mat-flat-button color=\"primary\" (click)=\"do_check()\">OK</button>&nbsp;&nbsp;&nbsp;\n <button mat-flat-button color=\"warn\" (click)=\"chiudi()\">ANNULLA</button>\n </div>\n <div fxLayout=\"row\" fxLayoutAlign=\"center center\" style=\"width: 100%\" [hidden]=\"!readonly\">\n <button mat-flat-button color=\"warn\" (click)=\"chiudi()\">CHIUDI</button>\n </div>\n\n "
3394
+ template: "\n <div style=\"width:100%\" fxLayout=\"row\" fxLayoutAlign=\"end start\"><img src=\"assets/icons/x.png\" style=\"cursor: pointer;\" (click)=\"close()\" /> </div>\n <hr width=\"100%\" size=\"0.5\" color=\"#DDDDDD\">\n\n <h2 mat-dialog-title>{{title}}</h2>\n <mat-dialog-content style=\"font-size: 15px;\">\n <mat-form-field appearance=\"outline\" floatLabel=\"always\" style=\"width:100%\"><mat-label>{{label}} (min {{min_chars}} - max {{max_chars}} caratteri)</mat-label>\n <input matInput type=\"text\"\n [(ngModel)]=\"valore\" required>\n </mat-form-field>\n </mat-dialog-content>\n <mat-dialog-actions>\n <div fxLayout=\"row\" fxLayoutAlign=\"center center\" style=\"width: 100%\" [hidden]=\"readonly\">\n <button mat-flat-button color=\"primary\" (click)=\"do_check()\">OK</button>&nbsp;&nbsp;&nbsp;\n <button mat-flat-button color=\"warn\" (click)=\"chiudi()\">ANNULLA</button>\n </div>\n <div fxLayout=\"row\" fxLayoutAlign=\"center center\" style=\"width: 100%\" [hidden]=\"!readonly\">\n <button mat-flat-button color=\"warn\" (click)=\"chiudi()\">CHIUDI</button>\n </div>\n </mat-dialog-actions>\n "
3360
3395
  }),
3361
3396
  __param(2, Inject(MAT_DIALOG_DATA)),
3362
3397
  __metadata("design:paramtypes", [MatDialogRef, ToastrService, Object])