@abp/ng.theme.shared 6.0.0-rc.4 → 6.0.0
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/esm2020/extensions/lib/adapters/date-time.adapter.mjs +3 -3
- package/esm2020/extensions/lib/adapters/date.adapter.mjs +3 -3
- package/esm2020/extensions/lib/adapters/time.adapter.mjs +3 -3
- package/esm2020/extensions/lib/components/abstract-actions/abstract-actions.component.mjs +3 -3
- package/esm2020/extensions/lib/components/date-time-picker/date-time-picker.component.mjs +8 -8
- package/esm2020/extensions/lib/components/extensible-form/extensible-form-prop.component.mjs +29 -25
- package/esm2020/extensions/lib/components/extensible-form/extensible-form.component.mjs +19 -10
- package/esm2020/extensions/lib/components/extensible-table/extensible-table.component.mjs +11 -11
- package/esm2020/extensions/lib/components/grid-actions/grid-actions.component.mjs +7 -7
- package/esm2020/extensions/lib/components/page-toolbar/page-toolbar.component.mjs +4 -4
- package/esm2020/extensions/lib/directives/disabled.directive.mjs +3 -3
- package/esm2020/extensions/lib/directives/prop-data.directive.mjs +3 -3
- package/esm2020/extensions/lib/models/form-props.mjs +23 -1
- package/esm2020/extensions/lib/pipes/create-injector.pipe.mjs +3 -3
- package/esm2020/extensions/lib/services/extensions.service.mjs +3 -3
- package/esm2020/extensions/lib/ui-extensions.module.mjs +15 -17
- package/esm2020/extensions/lib/utils/form-props.util.mjs +8 -8
- package/esm2020/extensions/lib/utils/state.util.mjs +5 -5
- package/esm2020/extensions/lib/utils/typeahead.util.mjs +2 -2
- package/esm2020/lib/components/breadcrumb/breadcrumb.component.mjs +5 -5
- package/esm2020/lib/components/breadcrumb-items/breadcrumb-items.component.mjs +3 -3
- package/esm2020/lib/components/button/button.component.mjs +4 -4
- package/esm2020/lib/components/confirmation/confirmation.component.mjs +4 -4
- package/esm2020/lib/components/http-error-wrapper/http-error-wrapper.component.mjs +3 -3
- package/esm2020/lib/components/loader-bar/loader-bar.component.mjs +4 -4
- package/esm2020/lib/components/loading/loading.component.mjs +6 -34
- package/esm2020/lib/components/modal/modal-close.directive.mjs +3 -3
- package/esm2020/lib/components/modal/modal-ref.service.mjs +3 -3
- package/esm2020/lib/components/modal/modal.component.mjs +5 -5
- package/esm2020/lib/components/toast/toast.component.mjs +4 -4
- package/esm2020/lib/components/toast-container/toast-container.component.mjs +6 -6
- package/esm2020/lib/constants/styles.mjs +6 -1
- package/esm2020/lib/directives/ellipsis.directive.mjs +7 -7
- package/esm2020/lib/directives/loading.directive.mjs +3 -3
- package/esm2020/lib/directives/ngx-datatable-default.directive.mjs +3 -3
- package/esm2020/lib/directives/ngx-datatable-list.directive.mjs +3 -3
- package/esm2020/lib/handlers/document-dir.handler.mjs +3 -3
- package/esm2020/lib/handlers/error.handler.mjs +3 -3
- package/esm2020/lib/providers/route.provider.mjs +2 -2
- package/esm2020/lib/services/confirmation.service.mjs +5 -5
- package/esm2020/lib/services/nav-items.service.mjs +3 -3
- package/esm2020/lib/services/page-alert.service.mjs +3 -3
- package/esm2020/lib/services/toaster.service.mjs +3 -3
- package/esm2020/lib/services/user-menu.service.mjs +3 -3
- package/esm2020/lib/theme-shared.module.mjs +13 -15
- package/esm2020/lib/utils/date-parser-formatter.mjs +3 -3
- package/esm2020/testing/lib/theme-shared-testing.module.mjs +5 -5
- package/extensions/{abp-ng.theme.shared-extensions.d.ts → index.d.ts} +0 -0
- package/extensions/lib/components/abstract-actions/abstract-actions.component.d.ts +1 -1
- package/extensions/lib/components/date-time-picker/date-time-picker.component.d.ts +1 -1
- package/extensions/lib/components/extensible-form/extensible-form-prop.component.d.ts +2 -1
- package/extensions/lib/components/extensible-form/extensible-form.component.d.ts +7 -6
- package/extensions/lib/components/extensible-table/extensible-table.component.d.ts +1 -1
- package/extensions/lib/components/grid-actions/grid-actions.component.d.ts +1 -1
- package/extensions/lib/components/page-toolbar/page-toolbar.component.d.ts +1 -1
- package/extensions/lib/directives/disabled.directive.d.ts +1 -1
- package/extensions/lib/directives/prop-data.directive.d.ts +1 -1
- package/extensions/lib/models/form-props.d.ts +13 -0
- package/extensions/lib/pipes/create-injector.pipe.d.ts +1 -1
- package/extensions/lib/utils/form-props.util.d.ts +2 -2
- package/fesm2015/abp-ng.theme.shared-extensions.mjs +228 -195
- package/fesm2015/abp-ng.theme.shared-extensions.mjs.map +1 -1
- package/fesm2015/abp-ng.theme.shared-testing.mjs +4 -4
- package/fesm2015/abp-ng.theme.shared-testing.mjs.map +1 -1
- package/fesm2015/abp-ng.theme.shared.mjs +103 -128
- package/fesm2015/abp-ng.theme.shared.mjs.map +1 -1
- package/fesm2020/abp-ng.theme.shared-extensions.mjs +138 -106
- package/fesm2020/abp-ng.theme.shared-extensions.mjs.map +1 -1
- package/fesm2020/abp-ng.theme.shared-testing.mjs +4 -4
- package/fesm2020/abp-ng.theme.shared-testing.mjs.map +1 -1
- package/fesm2020/abp-ng.theme.shared.mjs +103 -128
- package/fesm2020/abp-ng.theme.shared.mjs.map +1 -1
- package/{abp-ng.theme.shared.d.ts → index.d.ts} +0 -0
- package/lib/components/breadcrumb/breadcrumb.component.d.ts +1 -1
- package/lib/components/breadcrumb-items/breadcrumb-items.component.d.ts +1 -1
- package/lib/components/button/button.component.d.ts +1 -1
- package/lib/components/confirmation/confirmation.component.d.ts +1 -1
- package/lib/components/http-error-wrapper/http-error-wrapper.component.d.ts +1 -1
- package/lib/components/loader-bar/loader-bar.component.d.ts +1 -1
- package/lib/components/loading/loading.component.d.ts +1 -1
- package/lib/components/modal/modal-close.directive.d.ts +1 -1
- package/lib/components/modal/modal.component.d.ts +1 -1
- package/lib/components/toast/toast.component.d.ts +1 -1
- package/lib/components/toast-container/toast-container.component.d.ts +1 -1
- package/lib/constants/styles.d.ts +1 -1
- package/lib/directives/ellipsis.directive.d.ts +1 -1
- package/lib/directives/loading.directive.d.ts +1 -1
- package/lib/directives/ngx-datatable-default.directive.d.ts +1 -1
- package/lib/directives/ngx-datatable-list.directive.d.ts +1 -1
- package/package.json +8 -8
- package/testing/{abp-ng.theme.shared-testing.d.ts → index.d.ts} +0 -0
- package/extensions/package.json +0 -10
- package/testing/package.json +0 -10
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { Injectable, Optional, SkipSelf, Component, ChangeDetectionStrategy, Input, ViewChild, InjectionToken, Directive, Host, Injector, Inject, ViewChildren, LOCALE_ID, Pipe, NgModule } from '@angular/core';
|
|
3
|
-
import * as
|
|
3
|
+
import * as i1$1 from '@angular/common';
|
|
4
4
|
import { formatDate } from '@angular/common';
|
|
5
|
-
import * as
|
|
5
|
+
import * as i4$1 from '@ng-bootstrap/ng-bootstrap';
|
|
6
6
|
import { NgbDateAdapter, NgbTimeAdapter, NgbInputDatepicker, NgbTimepicker, NgbDatepickerModule, NgbDropdownModule, NgbTimepickerModule, NgbTypeaheadModule } from '@ng-bootstrap/ng-bootstrap';
|
|
7
|
-
import * as i2
|
|
8
|
-
import { ControlContainer, FormGroupDirective, Validators,
|
|
7
|
+
import * as i2 from '@angular/forms';
|
|
8
|
+
import { ControlContainer, FormGroupDirective, Validators, UntypedFormGroup, UntypedFormControl } from '@angular/forms';
|
|
9
9
|
import { LinkedList } from '@abp/utils';
|
|
10
|
-
import * as
|
|
10
|
+
import * as i4 from '@ngx-validate/core';
|
|
11
11
|
import { NgxValidateCoreModule } from '@ngx-validate/core';
|
|
12
12
|
import * as i1 from '@abp/ng.core';
|
|
13
13
|
import { RestService, AbpValidators, escapeHtmlChars, PermissionService, getShortDateShortTimeFormat, getShortTimeFormat, getShortDateFormat, CoreModule, LocalizationService, createLocalizationPipeKeyGenerator } from '@abp/ng.core';
|
|
14
14
|
import { of, merge, pipe, zip } from 'rxjs';
|
|
15
15
|
import { map, debounceTime, distinctUntilChanged, switchMap, filter, take } from 'rxjs/operators';
|
|
16
|
-
import * as
|
|
17
|
-
import * as i4 from '@abp/ng.theme.shared';
|
|
16
|
+
import * as i3 from '@swimlane/ngx-datatable';
|
|
17
|
+
import * as i4$2 from '@abp/ng.theme.shared';
|
|
18
18
|
import { ThemeSharedModule } from '@abp/ng.theme.shared';
|
|
19
19
|
|
|
20
20
|
class DateTimeAdapter {
|
|
@@ -53,9 +53,9 @@ class DateTimeAdapter {
|
|
|
53
53
|
return new Date(date).toISOString();
|
|
54
54
|
}
|
|
55
55
|
}
|
|
56
|
-
DateTimeAdapter.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
57
|
-
DateTimeAdapter.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
58
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
56
|
+
DateTimeAdapter.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DateTimeAdapter, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
57
|
+
DateTimeAdapter.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DateTimeAdapter });
|
|
58
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DateTimeAdapter, decorators: [{
|
|
59
59
|
type: Injectable
|
|
60
60
|
}] });
|
|
61
61
|
|
|
@@ -90,9 +90,9 @@ class DateAdapter extends NgbDateAdapter {
|
|
|
90
90
|
return new Date(dateUtc.getTime() + Math.abs(dateUtc.getTimezoneOffset() * 60000));
|
|
91
91
|
}
|
|
92
92
|
}
|
|
93
|
-
DateAdapter.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
94
|
-
DateAdapter.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
95
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
93
|
+
DateAdapter.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DateAdapter, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
|
|
94
|
+
DateAdapter.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DateAdapter });
|
|
95
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DateAdapter, decorators: [{
|
|
96
96
|
type: Injectable
|
|
97
97
|
}] });
|
|
98
98
|
|
|
@@ -119,9 +119,9 @@ class TimeAdapter extends NgbTimeAdapter {
|
|
|
119
119
|
return formattedDate;
|
|
120
120
|
}
|
|
121
121
|
}
|
|
122
|
-
TimeAdapter.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
123
|
-
TimeAdapter.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
124
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
122
|
+
TimeAdapter.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: TimeAdapter, deps: null, target: i0.ɵɵFactoryTarget.Injectable });
|
|
123
|
+
TimeAdapter.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: TimeAdapter });
|
|
124
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: TimeAdapter, decorators: [{
|
|
125
125
|
type: Injectable
|
|
126
126
|
}] });
|
|
127
127
|
function isTimeStr(value) {
|
|
@@ -187,6 +187,26 @@ class FormProps extends Props {
|
|
|
187
187
|
this._ctor = FormPropList;
|
|
188
188
|
}
|
|
189
189
|
}
|
|
190
|
+
class GroupedFormPropList {
|
|
191
|
+
constructor() {
|
|
192
|
+
this.items = [];
|
|
193
|
+
}
|
|
194
|
+
addItem(item) {
|
|
195
|
+
const groupName = item.group?.name;
|
|
196
|
+
let group = this.items.find(i => i.group?.name === groupName);
|
|
197
|
+
if (group) {
|
|
198
|
+
group.formPropList.addTail(item);
|
|
199
|
+
}
|
|
200
|
+
else {
|
|
201
|
+
group = {
|
|
202
|
+
formPropList: new FormPropList(),
|
|
203
|
+
group: item.group,
|
|
204
|
+
};
|
|
205
|
+
group.formPropList.addHead(item);
|
|
206
|
+
this.items.push(group);
|
|
207
|
+
}
|
|
208
|
+
}
|
|
209
|
+
}
|
|
190
210
|
class CreateFormPropsFactory extends PropsFactory {
|
|
191
211
|
constructor() {
|
|
192
212
|
super(...arguments);
|
|
@@ -202,6 +222,8 @@ class EditFormPropsFactory extends PropsFactory {
|
|
|
202
222
|
class FormProp extends Prop {
|
|
203
223
|
constructor(options) {
|
|
204
224
|
super(options.type, options.name, options.displayName, options.permission, options.visible, options.isExtra, options.template, options.className);
|
|
225
|
+
this.group = options.group;
|
|
226
|
+
this.className = options.className;
|
|
205
227
|
this.asyncValidators = options.asyncValidators || (_ => []);
|
|
206
228
|
this.validators = options.validators || (_ => []);
|
|
207
229
|
this.disabled = options.disabled || (_ => false);
|
|
@@ -246,8 +268,8 @@ class DateTimePickerComponent {
|
|
|
246
268
|
this.time.writeValue(datestr);
|
|
247
269
|
}
|
|
248
270
|
}
|
|
249
|
-
DateTimePickerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
250
|
-
DateTimePickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
271
|
+
DateTimePickerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DateTimePickerComponent, deps: [{ token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
|
|
272
|
+
DateTimePickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: DateTimePickerComponent, selector: "abp-date-time-picker", inputs: { prop: "prop", meridian: "meridian" }, viewQueries: [{ propertyName: "date", first: true, predicate: NgbInputDatepicker, descendants: true }, { propertyName: "time", first: true, predicate: NgbTimepicker, descendants: true }], exportAs: ["abpDateTimePicker"], ngImport: i0, template: `
|
|
251
273
|
<input
|
|
252
274
|
[id]="prop.id"
|
|
253
275
|
[formControlName]="prop.name"
|
|
@@ -265,7 +287,7 @@ DateTimePickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0"
|
|
|
265
287
|
(ngModelChange)="setDate($event)"
|
|
266
288
|
[meridian]="meridian"
|
|
267
289
|
></ngb-timepicker>
|
|
268
|
-
`, isInline: true,
|
|
290
|
+
`, isInline: true, dependencies: [{ kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i4.ValidationDirective, selector: "[formControl],[formControlName]", exportAs: ["validationDirective"] }, { kind: "directive", type: i4$1.NgbInputDatepicker, selector: "input[ngbDatepicker]", inputs: ["autoClose", "datepickerClass", "dayTemplate", "dayTemplateData", "displayMonths", "firstDayOfWeek", "footerTemplate", "markDisabled", "minDate", "maxDate", "navigation", "outsideDays", "placement", "restoreFocus", "showWeekNumbers", "startDate", "container", "positionTarget", "weekdays", "disabled"], outputs: ["dateSelect", "navigate", "closed"], exportAs: ["ngbDatepicker"] }, { kind: "component", type: i4$1.NgbTimepicker, selector: "ngb-timepicker", inputs: ["meridian", "spinners", "seconds", "hourStep", "minuteStep", "secondStep", "readonlyInputs", "size"] }], viewProviders: [
|
|
269
291
|
{
|
|
270
292
|
provide: ControlContainer,
|
|
271
293
|
useFactory: selfFactory,
|
|
@@ -280,7 +302,7 @@ DateTimePickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0"
|
|
|
280
302
|
useClass: DateTimeAdapter,
|
|
281
303
|
},
|
|
282
304
|
], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
283
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
305
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DateTimePickerComponent, decorators: [{
|
|
284
306
|
type: Component,
|
|
285
307
|
args: [{
|
|
286
308
|
exportAs: 'abpDateTimePicker',
|
|
@@ -371,9 +393,9 @@ function createTypeaheadOptions(lookup) {
|
|
|
371
393
|
}
|
|
372
394
|
function getTypeaheadType(lookup, name) {
|
|
373
395
|
return Boolean(lookup.url)
|
|
374
|
-
? "typeahead" /* Typeahead */
|
|
396
|
+
? "typeahead" /* ePropType.Typeahead */
|
|
375
397
|
: name.endsWith(TYPEAHEAD_TEXT_SUFFIX)
|
|
376
|
-
? "hidden" /* Hidden */
|
|
398
|
+
? "hidden" /* ePropType.Hidden */
|
|
377
399
|
: undefined;
|
|
378
400
|
}
|
|
379
401
|
function createTypeaheadDisplayNameGenerator(displayNameGeneratorFn, properties) {
|
|
@@ -407,14 +429,14 @@ class DisabledDirective {
|
|
|
407
429
|
}
|
|
408
430
|
}
|
|
409
431
|
}
|
|
410
|
-
DisabledDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
411
|
-
DisabledDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "
|
|
412
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
432
|
+
DisabledDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DisabledDirective, deps: [{ token: i2.NgControl, host: true }], target: i0.ɵɵFactoryTarget.Directive });
|
|
433
|
+
DisabledDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.1", type: DisabledDirective, selector: "[abpDisabled]", inputs: { abpDisabled: "abpDisabled" }, usesOnChanges: true, ngImport: i0 });
|
|
434
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: DisabledDirective, decorators: [{
|
|
413
435
|
type: Directive,
|
|
414
436
|
args: [{
|
|
415
437
|
selector: '[abpDisabled]',
|
|
416
438
|
}]
|
|
417
|
-
}], ctorParameters: function () { return [{ type: i2
|
|
439
|
+
}], ctorParameters: function () { return [{ type: i2.NgControl, decorators: [{
|
|
418
440
|
type: Host
|
|
419
441
|
}] }]; }, propDecorators: { abpDisabled: [{
|
|
420
442
|
type: Input
|
|
@@ -427,6 +449,7 @@ class ExtensibleFormPropComponent {
|
|
|
427
449
|
this.configState = configState;
|
|
428
450
|
this.injector = injector;
|
|
429
451
|
this.asterisk = '';
|
|
452
|
+
this.containerClassName = 'mb-3 form-group';
|
|
430
453
|
this.options$ = of([]);
|
|
431
454
|
this.validators = [];
|
|
432
455
|
this.disabledFn = (data) => false;
|
|
@@ -476,21 +499,21 @@ class ExtensibleFormPropComponent {
|
|
|
476
499
|
return 'template';
|
|
477
500
|
}
|
|
478
501
|
switch (prop.type) {
|
|
479
|
-
case "boolean" /* Boolean */:
|
|
502
|
+
case "boolean" /* ePropType.Boolean */:
|
|
480
503
|
return 'checkbox';
|
|
481
|
-
case "date" /* Date */:
|
|
504
|
+
case "date" /* ePropType.Date */:
|
|
482
505
|
return 'date';
|
|
483
|
-
case "datetime" /* DateTime */:
|
|
506
|
+
case "datetime" /* ePropType.DateTime */:
|
|
484
507
|
return 'dateTime';
|
|
485
|
-
case "hidden" /* Hidden */:
|
|
508
|
+
case "hidden" /* ePropType.Hidden */:
|
|
486
509
|
return 'hidden';
|
|
487
|
-
case "multiselect" /* MultiSelect */:
|
|
510
|
+
case "multiselect" /* ePropType.MultiSelect */:
|
|
488
511
|
return 'multiselect';
|
|
489
|
-
case "text" /* Text */:
|
|
512
|
+
case "text" /* ePropType.Text */:
|
|
490
513
|
return 'textarea';
|
|
491
|
-
case "time" /* Time */:
|
|
514
|
+
case "time" /* ePropType.Time */:
|
|
492
515
|
return 'time';
|
|
493
|
-
case "typeahead" /* Typeahead */:
|
|
516
|
+
case "typeahead" /* ePropType.Typeahead */:
|
|
494
517
|
return 'typeahead';
|
|
495
518
|
default:
|
|
496
519
|
return prop.options ? 'select' : 'input';
|
|
@@ -498,16 +521,16 @@ class ExtensibleFormPropComponent {
|
|
|
498
521
|
}
|
|
499
522
|
getType(prop) {
|
|
500
523
|
switch (prop.type) {
|
|
501
|
-
case "date" /* Date */:
|
|
502
|
-
case "string" /* String */:
|
|
524
|
+
case "date" /* ePropType.Date */:
|
|
525
|
+
case "string" /* ePropType.String */:
|
|
503
526
|
return 'text';
|
|
504
|
-
case "boolean" /* Boolean */:
|
|
527
|
+
case "boolean" /* ePropType.Boolean */:
|
|
505
528
|
return 'checkbox';
|
|
506
|
-
case "number" /* Number */:
|
|
529
|
+
case "number" /* ePropType.Number */:
|
|
507
530
|
return 'number';
|
|
508
|
-
case "email" /* Email */:
|
|
531
|
+
case "email" /* ePropType.Email */:
|
|
509
532
|
return 'email';
|
|
510
|
-
case "password" /* Password */:
|
|
533
|
+
case "password" /* ePropType.Password */:
|
|
511
534
|
return 'password';
|
|
512
535
|
default:
|
|
513
536
|
return 'hidden';
|
|
@@ -515,7 +538,7 @@ class ExtensibleFormPropComponent {
|
|
|
515
538
|
}
|
|
516
539
|
ngOnChanges({ prop, data }) {
|
|
517
540
|
const currentProp = prop?.currentValue;
|
|
518
|
-
const { options, readonly, disabled, validators, template } = currentProp || {};
|
|
541
|
+
const { options, readonly, disabled, validators, className, template } = currentProp || {};
|
|
519
542
|
if (template) {
|
|
520
543
|
this.injectorForCustomComponent = Injector.create({
|
|
521
544
|
providers: [
|
|
@@ -543,13 +566,16 @@ class ExtensibleFormPropComponent {
|
|
|
543
566
|
this.validators = validators(this.data);
|
|
544
567
|
this.setAsterisk();
|
|
545
568
|
}
|
|
569
|
+
if (className !== undefined) {
|
|
570
|
+
this.containerClassName = className;
|
|
571
|
+
}
|
|
546
572
|
const [keyControl, valueControl] = this.getTypeaheadControls();
|
|
547
573
|
if (keyControl && valueControl)
|
|
548
574
|
this.typeaheadModel = { key: keyControl.value, value: valueControl.value };
|
|
549
575
|
}
|
|
550
576
|
}
|
|
551
|
-
ExtensibleFormPropComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
552
|
-
ExtensibleFormPropComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
577
|
+
ExtensibleFormPropComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ExtensibleFormPropComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1.TrackByService }, { token: i1.ConfigStateService }, { token: i2.FormGroupDirective }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
578
|
+
ExtensibleFormPropComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: ExtensibleFormPropComponent, selector: "abp-extensible-form-prop", inputs: { data: "data", prop: "prop", first: "first" }, viewQueries: [{ propertyName: "fieldRef", first: true, predicate: ["field"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<ng-container [ngSwitch]=\"getComponent(prop)\"\r\n\r\n *abpPermission=\"prop.permission; runChangeDetection: false\">\r\n\r\n <ng-template ngSwitchCase=\"template\">\r\n <ng-container\r\n *ngComponentOutlet=\"prop.template;injector:injectorForCustomComponent\">\r\n </ng-container>\r\n </ng-template>\r\n\r\n <div\r\n [ngClass]=\"containerClassName\"\r\n class=\"mb-3 form-group\"\r\n >\r\n <ng-template ngSwitchCase=\"input\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <input\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [autocomplete]=\"prop.autocomplete\"\r\n [type]=\"getType(prop)\"\r\n [abpDisabled]=\"disabled\"\r\n [readonly]=\"readonly\"\r\n class=\"form-control\"\r\n />\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"hidden\">\r\n <input [formControlName]=\"prop.name\" type=\"hidden\"/>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"checkbox\">\r\n <div class=\"form-check\" validationTarget>\r\n <input\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [abpDisabled]=\"disabled\"\r\n type=\"checkbox\"\r\n class=\"form-check-input\"\r\n />\r\n <ng-template\r\n [ngTemplateOutlet]=\"label\"\r\n [ngTemplateOutletContext]=\"{ $implicit: 'form-check-label' }\"\r\n ></ng-template>\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"select\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <select\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [abpDisabled]=\"disabled\"\r\n class=\"form-select form-control\"\r\n >\r\n <option\r\n *ngFor=\"let option of options$ | async; trackBy: track.by('value')\"\r\n [ngValue]=\"option.value\"\r\n >\r\n {{ option.key }}\r\n </option>\r\n </select>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"multiselect\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <select\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [abpDisabled]=\"disabled\"\r\n multiple=\"multiple\"\r\n class=\"form-select form-control\"\r\n >\r\n <option\r\n *ngFor=\"let option of options$ | async; trackBy: track.by('value')\"\r\n [ngValue]=\"option.value\"\r\n >\r\n {{ option.key }}\r\n </option>\r\n </select>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"typeahead\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <div #typeahead class=\"position-relative\" validationStyle validationTarget>\r\n <input\r\n #field\r\n [id]=\"prop.id\"\r\n [autocomplete]=\"prop.autocomplete\"\r\n [abpDisabled]=\"disabled\"\r\n [ngbTypeahead]=\"search\"\r\n [editable]=\"false\"\r\n [inputFormatter]=\"typeaheadFormatter\"\r\n [resultFormatter]=\"typeaheadFormatter\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n [(ngModel)]=\"typeaheadModel\"\r\n (selectItem)=\"setTypeaheadValue($event.item)\"\r\n (blur)=\"setTypeaheadValue(typeaheadModel)\"\r\n [class.is-invalid]=\"typeahead.classList.contains('is-invalid')\"\r\n class=\"form-control\"\r\n />\r\n <input [formControlName]=\"prop.name\" type=\"hidden\"/>\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"date\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <input\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n (click)=\"datepicker.open()\"\r\n (keyup.space)=\"datepicker.open()\"\r\n ngbDatepicker\r\n #datepicker=\"ngbDatepicker\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n />\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"time\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <ngb-timepicker [formControlName]=\"prop.name\"></ngb-timepicker>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"dateTime\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <abp-date-time-picker [prop]=\"prop\" [meridian]=\"meridian\"></abp-date-time-picker>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"textarea\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <textarea\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [abpDisabled]=\"disabled\"\r\n [readonly]=\"readonly\"\r\n class=\"form-control\"\r\n ></textarea>\r\n </ng-template>\r\n </div>\r\n\r\n</ng-container>\r\n\r\n<ng-template #label let-classes>\r\n <label [htmlFor]=\"prop.id\" [ngClass]=\"classes || 'form-label'\" x\r\n >{{ prop.displayName | abpLocalization }} {{ asterisk }}</label\r\n >\r\n</ng-template>\r\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInjector", "ngComponentOutletContent", "ngComponentOutletNgModule", "ngComponentOutletNgModuleFactory"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1$1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1$1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "directive", type: i2.NgSelectOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.ɵNgSelectMultipleOption, selector: "option", inputs: ["ngValue", "value"] }, { kind: "directive", type: i2.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i2.CheckboxControlValueAccessor, selector: "input[type=checkbox][formControlName],input[type=checkbox][formControl],input[type=checkbox][ngModel]" }, { kind: "directive", type: i2.SelectControlValueAccessor, selector: "select:not([multiple])[formControlName],select:not([multiple])[formControl],select:not([multiple])[ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i2.SelectMultipleControlValueAccessor, selector: "select[multiple][formControlName],select[multiple][formControl],select[multiple][ngModel]", inputs: ["compareWith"] }, { kind: "directive", type: i2.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i2.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { kind: "directive", type: i2.FormControlName, selector: "[formControlName]", inputs: ["formControlName", "disabled", "ngModel"], outputs: ["ngModelChange"] }, { kind: "directive", type: i1.PermissionDirective, selector: "[abpPermission]", inputs: ["abpPermission", "abpPermissionRunChangeDetection"] }, { kind: "directive", type: i4.ValidationStyleDirective, selector: "[validationStyle]", exportAs: ["validationStyle"] }, { kind: "directive", type: i4.ValidationTargetDirective, selector: "[validationTarget]", exportAs: ["validationTarget"] }, { kind: "directive", type: i4.ValidationDirective, selector: "[formControl],[formControlName]", exportAs: ["validationDirective"] }, { kind: "directive", type: i4$1.NgbInputDatepicker, selector: "input[ngbDatepicker]", inputs: ["autoClose", "datepickerClass", "dayTemplate", "dayTemplateData", "displayMonths", "firstDayOfWeek", "footerTemplate", "markDisabled", "minDate", "maxDate", "navigation", "outsideDays", "placement", "restoreFocus", "showWeekNumbers", "startDate", "container", "positionTarget", "weekdays", "disabled"], outputs: ["dateSelect", "navigate", "closed"], exportAs: ["ngbDatepicker"] }, { kind: "component", type: i4$1.NgbTimepicker, selector: "ngb-timepicker", inputs: ["meridian", "spinners", "seconds", "hourStep", "minuteStep", "secondStep", "readonlyInputs", "size"] }, { kind: "directive", type: i4$1.NgbTypeahead, selector: "input[ngbTypeahead]", inputs: ["autocomplete", "container", "editable", "focusFirst", "inputFormatter", "ngbTypeahead", "resultFormatter", "resultTemplate", "showHint", "placement", "popupClass"], outputs: ["selectItem"], exportAs: ["ngbTypeahead"] }, { kind: "component", type: DateTimePickerComponent, selector: "abp-date-time-picker", inputs: ["prop", "meridian"], exportAs: ["abpDateTimePicker"] }, { kind: "directive", type: DisabledDirective, selector: "[abpDisabled]", inputs: ["abpDisabled"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i1.LocalizationPipe, name: "abpLocalization" }], viewProviders: [
|
|
553
579
|
{
|
|
554
580
|
provide: ControlContainer,
|
|
555
581
|
useFactory: selfFactory,
|
|
@@ -558,7 +584,7 @@ ExtensibleFormPropComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.
|
|
|
558
584
|
{ provide: NgbDateAdapter, useClass: DateAdapter },
|
|
559
585
|
{ provide: NgbTimeAdapter, useClass: TimeAdapter },
|
|
560
586
|
], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
561
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
587
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ExtensibleFormPropComponent, decorators: [{
|
|
562
588
|
type: Component,
|
|
563
589
|
args: [{ selector: 'abp-extensible-form-prop', changeDetection: ChangeDetectionStrategy.OnPush, viewProviders: [
|
|
564
590
|
{
|
|
@@ -568,8 +594,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.6", ngImpor
|
|
|
568
594
|
},
|
|
569
595
|
{ provide: NgbDateAdapter, useClass: DateAdapter },
|
|
570
596
|
{ provide: NgbTimeAdapter, useClass: TimeAdapter },
|
|
571
|
-
], template: "<ng-container [ngSwitch]=\"getComponent(prop)\"\r\n *abpPermission=\"prop.permission; runChangeDetection: false\">\r\n\r\n <ng-template ngSwitchCase=\"template\">\r\n <ng-container\r\n *ngComponentOutlet=\"prop.template;injector:injectorForCustomComponent\">\r\n </ng-container>\r\n </ng-template>\r\n\r\n <div\r\n class=\"mb-3 form-group\"\r\n >\r\n
|
|
572
|
-
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i1.TrackByService }, { type: i1.ConfigStateService }, { type: i2
|
|
597
|
+
], template: "<ng-container [ngSwitch]=\"getComponent(prop)\"\r\n\r\n *abpPermission=\"prop.permission; runChangeDetection: false\">\r\n\r\n <ng-template ngSwitchCase=\"template\">\r\n <ng-container\r\n *ngComponentOutlet=\"prop.template;injector:injectorForCustomComponent\">\r\n </ng-container>\r\n </ng-template>\r\n\r\n <div\r\n [ngClass]=\"containerClassName\"\r\n class=\"mb-3 form-group\"\r\n >\r\n <ng-template ngSwitchCase=\"input\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <input\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [autocomplete]=\"prop.autocomplete\"\r\n [type]=\"getType(prop)\"\r\n [abpDisabled]=\"disabled\"\r\n [readonly]=\"readonly\"\r\n class=\"form-control\"\r\n />\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"hidden\">\r\n <input [formControlName]=\"prop.name\" type=\"hidden\"/>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"checkbox\">\r\n <div class=\"form-check\" validationTarget>\r\n <input\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [abpDisabled]=\"disabled\"\r\n type=\"checkbox\"\r\n class=\"form-check-input\"\r\n />\r\n <ng-template\r\n [ngTemplateOutlet]=\"label\"\r\n [ngTemplateOutletContext]=\"{ $implicit: 'form-check-label' }\"\r\n ></ng-template>\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"select\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <select\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [abpDisabled]=\"disabled\"\r\n class=\"form-select form-control\"\r\n >\r\n <option\r\n *ngFor=\"let option of options$ | async; trackBy: track.by('value')\"\r\n [ngValue]=\"option.value\"\r\n >\r\n {{ option.key }}\r\n </option>\r\n </select>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"multiselect\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <select\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [abpDisabled]=\"disabled\"\r\n multiple=\"multiple\"\r\n class=\"form-select form-control\"\r\n >\r\n <option\r\n *ngFor=\"let option of options$ | async; trackBy: track.by('value')\"\r\n [ngValue]=\"option.value\"\r\n >\r\n {{ option.key }}\r\n </option>\r\n </select>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"typeahead\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <div #typeahead class=\"position-relative\" validationStyle validationTarget>\r\n <input\r\n #field\r\n [id]=\"prop.id\"\r\n [autocomplete]=\"prop.autocomplete\"\r\n [abpDisabled]=\"disabled\"\r\n [ngbTypeahead]=\"search\"\r\n [editable]=\"false\"\r\n [inputFormatter]=\"typeaheadFormatter\"\r\n [resultFormatter]=\"typeaheadFormatter\"\r\n [ngModelOptions]=\"{ standalone: true }\"\r\n [(ngModel)]=\"typeaheadModel\"\r\n (selectItem)=\"setTypeaheadValue($event.item)\"\r\n (blur)=\"setTypeaheadValue(typeaheadModel)\"\r\n [class.is-invalid]=\"typeahead.classList.contains('is-invalid')\"\r\n class=\"form-control\"\r\n />\r\n <input [formControlName]=\"prop.name\" type=\"hidden\"/>\r\n </div>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"date\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <input\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n (click)=\"datepicker.open()\"\r\n (keyup.space)=\"datepicker.open()\"\r\n ngbDatepicker\r\n #datepicker=\"ngbDatepicker\"\r\n type=\"text\"\r\n class=\"form-control\"\r\n />\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"time\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <ngb-timepicker [formControlName]=\"prop.name\"></ngb-timepicker>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"dateTime\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <abp-date-time-picker [prop]=\"prop\" [meridian]=\"meridian\"></abp-date-time-picker>\r\n </ng-template>\r\n\r\n <ng-template ngSwitchCase=\"textarea\">\r\n <ng-template [ngTemplateOutlet]=\"label\"></ng-template>\r\n <textarea\r\n #field\r\n [id]=\"prop.id\"\r\n [formControlName]=\"prop.name\"\r\n [abpDisabled]=\"disabled\"\r\n [readonly]=\"readonly\"\r\n class=\"form-control\"\r\n ></textarea>\r\n </ng-template>\r\n </div>\r\n\r\n</ng-container>\r\n\r\n<ng-template #label let-classes>\r\n <label [htmlFor]=\"prop.id\" [ngClass]=\"classes || 'form-label'\" x\r\n >{{ prop.displayName | abpLocalization }} {{ asterisk }}</label\r\n >\r\n</ng-template>\r\n" }]
|
|
598
|
+
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i1.TrackByService }, { type: i1.ConfigStateService }, { type: i2.FormGroupDirective }, { type: i0.Injector }]; }, propDecorators: { data: [{
|
|
573
599
|
type: Input
|
|
574
600
|
}], prop: [{
|
|
575
601
|
type: Input
|
|
@@ -743,9 +769,9 @@ class ExtensionsService {
|
|
|
743
769
|
this.editFormProps = new EditFormPropsFactory();
|
|
744
770
|
}
|
|
745
771
|
}
|
|
746
|
-
ExtensionsService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
747
|
-
ExtensionsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "
|
|
748
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
772
|
+
ExtensionsService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ExtensionsService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
773
|
+
ExtensionsService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ExtensionsService, providedIn: 'root' });
|
|
774
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ExtensionsService, decorators: [{
|
|
749
775
|
type: Injectable,
|
|
750
776
|
args: [{
|
|
751
777
|
providedIn: 'root',
|
|
@@ -771,9 +797,9 @@ class PropDataDirective extends PropData {
|
|
|
771
797
|
this.vcRef.clear();
|
|
772
798
|
}
|
|
773
799
|
}
|
|
774
|
-
PropDataDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
775
|
-
PropDataDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "
|
|
776
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
800
|
+
PropDataDirective.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: PropDataDirective, deps: [{ token: i0.TemplateRef }, { token: i0.ViewContainerRef }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Directive });
|
|
801
|
+
PropDataDirective.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.1", type: PropDataDirective, selector: "[abpPropData]", inputs: { propList: ["abpPropDataFromList", "propList"], record: ["abpPropDataWithRecord", "record"], index: ["abpPropDataAtIndex", "index"] }, exportAs: ["abpPropData"], usesInheritance: true, usesOnChanges: true, ngImport: i0 });
|
|
802
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: PropDataDirective, decorators: [{
|
|
777
803
|
type: Directive,
|
|
778
804
|
args: [{
|
|
779
805
|
exportAs: 'abpPropData',
|
|
@@ -801,9 +827,17 @@ class ExtensibleFormComponent {
|
|
|
801
827
|
}
|
|
802
828
|
set selectedRecord(record) {
|
|
803
829
|
const type = !record || JSON.stringify(record) === '{}' ? 'create' : 'edit';
|
|
804
|
-
|
|
830
|
+
const propList = this.extensions[`${type}FormProps`].get(this.identifier).props;
|
|
831
|
+
this.groupedPropList = this.createGroupedList(propList);
|
|
805
832
|
this.record = record;
|
|
806
833
|
}
|
|
834
|
+
createGroupedList(propList) {
|
|
835
|
+
const groupedFormPropList = new GroupedFormPropList();
|
|
836
|
+
propList.forEach(item => {
|
|
837
|
+
groupedFormPropList.addItem(item.value);
|
|
838
|
+
});
|
|
839
|
+
return groupedFormPropList;
|
|
840
|
+
}
|
|
807
841
|
get form() {
|
|
808
842
|
return (this.container ? this.container.control : { controls: {} });
|
|
809
843
|
}
|
|
@@ -811,15 +845,15 @@ class ExtensibleFormComponent {
|
|
|
811
845
|
return (this.form.controls.extraProperties || { controls: {} });
|
|
812
846
|
}
|
|
813
847
|
}
|
|
814
|
-
ExtensibleFormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
815
|
-
ExtensibleFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
848
|
+
ExtensibleFormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ExtensibleFormComponent, deps: [{ token: i0.ChangeDetectorRef }, { token: i1.TrackByService }, { token: i2.ControlContainer }, { token: ExtensionsService }, { token: EXTENSIONS_IDENTIFIER }], target: i0.ɵɵFactoryTarget.Component });
|
|
849
|
+
ExtensibleFormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: ExtensibleFormComponent, selector: "abp-extensible-form", inputs: { selectedRecord: "selectedRecord" }, viewQueries: [{ propertyName: "formProps", predicate: ExtensibleFormPropComponent, descendants: true }], exportAs: ["abpExtensibleForm"], ngImport: i0, template: "<ng-container *ngIf=\"form\">\r\n\r\n <ng-container *ngFor=\"let groupedProp of groupedPropList.items\">\r\n <ng-container *abpPropData=\"let data; fromList: groupedProp.formPropList; withRecord: record\">\r\n\r\n <div *ngIf=\"groupedProp.group?.className; else withoutClassName\"\r\n [class]=\"groupedProp.group?.className\" [attr.data-name]=\"groupedProp.group?.className\">\r\n <ng-container [ngTemplateOutlet]=\"propListTemplate\" [ngTemplateOutletContext]=\"{groupedProp:groupedProp,data:data}\">\r\n </ng-container>\r\n </div>\r\n\r\n <ng-template #withoutClassName>\r\n <ng-container [ngTemplateOutlet]=\"propListTemplate\" [ngTemplateOutletContext]=\"{groupedProp:groupedProp,data:data}\">\r\n </ng-container>\r\n </ng-template>\r\n </ng-container>\r\n\r\n </ng-container>\r\n</ng-container>\r\n\r\n\r\n<ng-template let-groupedProp=\"groupedProp\" let-data=\"data\" #propListTemplate>\r\n <ng-container *ngFor=\"let prop of groupedProp.formPropList; let first = first; trackBy: track.by('name')\">\r\n <ng-container *ngIf=\"prop.visible(data)\">\r\n <ng-container\r\n [formGroupName]=\"extraPropertiesKey\"\r\n *ngIf=\"extraProperties.controls[prop.name]; else tempDefault\"\r\n >\r\n <abp-extensible-form-prop [prop]=\"prop\" [data]=\"data\"\r\n [class]=\"prop.className\">\r\n </abp-extensible-form-prop>\r\n </ng-container>\r\n\r\n <ng-template #tempDefault>\r\n <abp-extensible-form-prop\r\n [class]=\"prop.className\"\r\n *ngIf=\"form.get(prop.name)\"\r\n [prop]=\"prop\"\r\n [data]=\"data\"\r\n [first]=\"first\"\r\n ></abp-extensible-form-prop>\r\n </ng-template>\r\n </ng-container>\r\n </ng-container>\r\n</ng-template>\r\n", dependencies: [{ kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i2.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.FormGroupName, selector: "[formGroupName]", inputs: ["formGroupName"] }, { kind: "directive", type: i4.ValidationGroupDirective, selector: "[formGroup],[formGroupName]", exportAs: ["validationGroup"] }, { kind: "component", type: ExtensibleFormPropComponent, selector: "abp-extensible-form-prop", inputs: ["data", "prop", "first"] }, { kind: "directive", type: PropDataDirective, selector: "[abpPropData]", inputs: ["abpPropDataFromList", "abpPropDataWithRecord", "abpPropDataAtIndex"], exportAs: ["abpPropData"] }], viewProviders: [
|
|
816
850
|
{
|
|
817
851
|
provide: ControlContainer,
|
|
818
852
|
useFactory: selfFactory,
|
|
819
853
|
deps: [[new Optional(), new SkipSelf(), ControlContainer]],
|
|
820
854
|
},
|
|
821
855
|
], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
822
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
856
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ExtensibleFormComponent, decorators: [{
|
|
823
857
|
type: Component,
|
|
824
858
|
args: [{ exportAs: 'abpExtensibleForm', selector: 'abp-extensible-form', changeDetection: ChangeDetectionStrategy.OnPush, viewProviders: [
|
|
825
859
|
{
|
|
@@ -827,8 +861,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.6", ngImpor
|
|
|
827
861
|
useFactory: selfFactory,
|
|
828
862
|
deps: [[new Optional(), new SkipSelf(), ControlContainer]],
|
|
829
863
|
},
|
|
830
|
-
], template: "<ng-container *ngIf=\"form\">\r\n <ng-container *abpPropData=\"let data; fromList:
|
|
831
|
-
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i1.TrackByService }, { type: i2
|
|
864
|
+
], template: "<ng-container *ngIf=\"form\">\r\n\r\n <ng-container *ngFor=\"let groupedProp of groupedPropList.items\">\r\n <ng-container *abpPropData=\"let data; fromList: groupedProp.formPropList; withRecord: record\">\r\n\r\n <div *ngIf=\"groupedProp.group?.className; else withoutClassName\"\r\n [class]=\"groupedProp.group?.className\" [attr.data-name]=\"groupedProp.group?.className\">\r\n <ng-container [ngTemplateOutlet]=\"propListTemplate\" [ngTemplateOutletContext]=\"{groupedProp:groupedProp,data:data}\">\r\n </ng-container>\r\n </div>\r\n\r\n <ng-template #withoutClassName>\r\n <ng-container [ngTemplateOutlet]=\"propListTemplate\" [ngTemplateOutletContext]=\"{groupedProp:groupedProp,data:data}\">\r\n </ng-container>\r\n </ng-template>\r\n </ng-container>\r\n\r\n </ng-container>\r\n</ng-container>\r\n\r\n\r\n<ng-template let-groupedProp=\"groupedProp\" let-data=\"data\" #propListTemplate>\r\n <ng-container *ngFor=\"let prop of groupedProp.formPropList; let first = first; trackBy: track.by('name')\">\r\n <ng-container *ngIf=\"prop.visible(data)\">\r\n <ng-container\r\n [formGroupName]=\"extraPropertiesKey\"\r\n *ngIf=\"extraProperties.controls[prop.name]; else tempDefault\"\r\n >\r\n <abp-extensible-form-prop [prop]=\"prop\" [data]=\"data\"\r\n [class]=\"prop.className\">\r\n </abp-extensible-form-prop>\r\n </ng-container>\r\n\r\n <ng-template #tempDefault>\r\n <abp-extensible-form-prop\r\n [class]=\"prop.className\"\r\n *ngIf=\"form.get(prop.name)\"\r\n [prop]=\"prop\"\r\n [data]=\"data\"\r\n [first]=\"first\"\r\n ></abp-extensible-form-prop>\r\n </ng-template>\r\n </ng-container>\r\n </ng-container>\r\n</ng-template>\r\n" }]
|
|
865
|
+
}], ctorParameters: function () { return [{ type: i0.ChangeDetectorRef }, { type: i1.TrackByService }, { type: i2.ControlContainer }, { type: ExtensionsService }, { type: undefined, decorators: [{
|
|
832
866
|
type: Inject,
|
|
833
867
|
args: [EXTENSIONS_IDENTIFIER]
|
|
834
868
|
}] }]; }, propDecorators: { formProps: [{
|
|
@@ -850,9 +884,9 @@ class AbstractActionsComponent extends ActionData {
|
|
|
850
884
|
this.actionList = extensions[type].get(name).actions;
|
|
851
885
|
}
|
|
852
886
|
}
|
|
853
|
-
AbstractActionsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
854
|
-
AbstractActionsComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "
|
|
855
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
887
|
+
AbstractActionsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: AbstractActionsComponent, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Directive });
|
|
888
|
+
AbstractActionsComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "14.2.1", type: AbstractActionsComponent, inputs: { record: "record" }, usesInheritance: true, ngImport: i0 });
|
|
889
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: AbstractActionsComponent, decorators: [{
|
|
856
890
|
type: Directive
|
|
857
891
|
}], ctorParameters: function () { return [{ type: i0.Injector }]; }, propDecorators: { record: [{
|
|
858
892
|
type: Input
|
|
@@ -866,14 +900,14 @@ class GridActionsComponent extends AbstractActionsComponent {
|
|
|
866
900
|
this.trackByFn = (_, item) => item.text;
|
|
867
901
|
}
|
|
868
902
|
}
|
|
869
|
-
GridActionsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
870
|
-
GridActionsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
903
|
+
GridActionsComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: GridActionsComponent, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
904
|
+
GridActionsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: GridActionsComponent, selector: "abp-grid-actions", inputs: { icon: "icon", index: "index", text: "text" }, providers: [
|
|
871
905
|
{
|
|
872
906
|
provide: EXTENSIONS_ACTION_TYPE,
|
|
873
907
|
useValue: 'entityActions',
|
|
874
908
|
},
|
|
875
|
-
], exportAs: ["abpGridActions"], usesInheritance: true, ngImport: i0, template: "<div *ngIf=\"actionList.length > 1\" ngbDropdown container=\"body\" class=\"d-inline-block\">\r\n <button\r\n class=\"btn btn-primary btn-sm dropdown-toggle\"\r\n data-toggle=\"dropdown\"\r\n aria-haspopup=\"true\"\r\n ngbDropdownToggle\r\n >\r\n <i [ngClass]=\"icon\" [class.me-1]=\"icon\"></i>{{ text | abpLocalization }}\r\n </button>\r\n <div ngbDropdownMenu>\r\n <ng-container\r\n *ngFor=\"let action of actionList; trackBy: trackByFn\"\r\n [ngTemplateOutlet]=\"dropDownBtnItemTmp\"\r\n [ngTemplateOutletContext]=\"{ $implicit: action }\"\r\n >\r\n </ng-container>\r\n </div>\r\n</div>\r\n\r\n<ng-container\r\n *ngIf=\"actionList.length === 1\"\r\n [ngTemplateOutlet]=\"btnTmp\"\r\n [ngTemplateOutletContext]=\"{ $implicit: actionList.get(0).value }\"\r\n></ng-container>\r\n\r\n<ng-template #dropDownBtnItemTmp let-action>\r\n <ng-container *ngIf=\"action.visible(data)\">\r\n <button\r\n ngbDropdownItem\r\n *abpPermission=\"action.permission; runChangeDetection: false\"\r\n (click)=\"action.action(data)\"\r\n type=\"button\"\r\n >\r\n <ng-container\r\n *ngTemplateOutlet=\"buttonContentTmp; context: { $implicit: action }\"\r\n ></ng-container>\r\n </button>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #buttonContentTmp let-action>\r\n <i [ngClass]=\"action.icon\" [class.me-1]=\"action.icon\"></i>\r\n <span *ngIf=\"action.icon; else ellipsis\">{{ action.text | abpLocalization }}</span>\r\n <ng-template #ellipsis>\r\n <div abpEllipsis>{{ action.text | abpLocalization }}</div>\r\n </ng-template>\r\n</ng-template>\r\n\r\n<ng-template #btnTmp let-action>\r\n <ng-container *ngIf=\"action.visible(data)\">\r\n <button\r\n *abpPermission=\"action.permission; runChangeDetection: false\"\r\n (click)=\"action.action(data)\"\r\n type=\"button\"\r\n class=\"btn btn-primary text-center\"\r\n >\r\n <ng-container\r\n *ngTemplateOutlet=\"buttonContentTmp; context: { $implicit: action }\"\r\n ></ng-container>\r\n </button>\r\n </ng-container>\r\n</ng-template>\r\n",
|
|
876
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
909
|
+
], exportAs: ["abpGridActions"], usesInheritance: true, ngImport: i0, template: "<div *ngIf=\"actionList.length > 1\" ngbDropdown container=\"body\" class=\"d-inline-block\">\r\n <button\r\n class=\"btn btn-primary btn-sm dropdown-toggle\"\r\n data-toggle=\"dropdown\"\r\n aria-haspopup=\"true\"\r\n ngbDropdownToggle\r\n >\r\n <i [ngClass]=\"icon\" [class.me-1]=\"icon\"></i>{{ text | abpLocalization }}\r\n </button>\r\n <div ngbDropdownMenu>\r\n <ng-container\r\n *ngFor=\"let action of actionList; trackBy: trackByFn\"\r\n [ngTemplateOutlet]=\"dropDownBtnItemTmp\"\r\n [ngTemplateOutletContext]=\"{ $implicit: action }\"\r\n >\r\n </ng-container>\r\n </div>\r\n</div>\r\n\r\n<ng-container\r\n *ngIf=\"actionList.length === 1\"\r\n [ngTemplateOutlet]=\"btnTmp\"\r\n [ngTemplateOutletContext]=\"{ $implicit: actionList.get(0).value }\"\r\n></ng-container>\r\n\r\n<ng-template #dropDownBtnItemTmp let-action>\r\n <ng-container *ngIf=\"action.visible(data)\">\r\n <button\r\n ngbDropdownItem\r\n *abpPermission=\"action.permission; runChangeDetection: false\"\r\n (click)=\"action.action(data)\"\r\n type=\"button\"\r\n >\r\n <ng-container\r\n *ngTemplateOutlet=\"buttonContentTmp; context: { $implicit: action }\"\r\n ></ng-container>\r\n </button>\r\n </ng-container>\r\n</ng-template>\r\n\r\n<ng-template #buttonContentTmp let-action>\r\n <i [ngClass]=\"action.icon\" [class.me-1]=\"action.icon\"></i>\r\n <span *ngIf=\"action.icon; else ellipsis\">{{ action.text | abpLocalization }}</span>\r\n <ng-template #ellipsis>\r\n <div abpEllipsis>{{ action.text | abpLocalization }}</div>\r\n </ng-template>\r\n</ng-template>\r\n\r\n<ng-template #btnTmp let-action>\r\n <ng-container *ngIf=\"action.visible(data)\">\r\n <button\r\n *abpPermission=\"action.permission; runChangeDetection: false\"\r\n (click)=\"action.action(data)\"\r\n type=\"button\"\r\n class=\"btn btn-primary text-center\"\r\n >\r\n <ng-container\r\n *ngTemplateOutlet=\"buttonContentTmp; context: { $implicit: action }\"\r\n ></ng-container>\r\n </button>\r\n </ng-container>\r\n</ng-template>\r\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.PermissionDirective, selector: "[abpPermission]", inputs: ["abpPermission", "abpPermissionRunChangeDetection"] }, { kind: "directive", type: i4$2.EllipsisDirective, selector: "[abpEllipsis]", inputs: ["abpEllipsis", "title", "abpEllipsisEnabled"] }, { kind: "directive", type: i4$1.NgbDropdown, selector: "[ngbDropdown]", inputs: ["autoClose", "dropdownClass", "open", "placement", "container", "display"], outputs: ["openChange"], exportAs: ["ngbDropdown"] }, { kind: "directive", type: i4$1.NgbDropdownToggle, selector: "[ngbDropdownToggle]" }, { kind: "directive", type: i4$1.NgbDropdownMenu, selector: "[ngbDropdownMenu]" }, { kind: "directive", type: i4$1.NgbDropdownItem, selector: "[ngbDropdownItem]", inputs: ["disabled"] }, { kind: "pipe", type: i1.LocalizationPipe, name: "abpLocalization" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
910
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: GridActionsComponent, decorators: [{
|
|
877
911
|
type: Component,
|
|
878
912
|
args: [{ exportAs: 'abpGridActions', selector: 'abp-grid-actions', providers: [
|
|
879
913
|
{
|
|
@@ -941,15 +975,15 @@ class ExtensibleTableComponent {
|
|
|
941
975
|
getContent(prop, data) {
|
|
942
976
|
return prop.valueResolver(data).pipe(map(value => {
|
|
943
977
|
switch (prop.type) {
|
|
944
|
-
case "boolean" /* Boolean */:
|
|
978
|
+
case "boolean" /* ePropType.Boolean */:
|
|
945
979
|
return this.getIcon(value);
|
|
946
|
-
case "date" /* Date */:
|
|
980
|
+
case "date" /* ePropType.Date */:
|
|
947
981
|
return this.getDate(value, getShortDateFormat(this.config));
|
|
948
|
-
case "time" /* Time */:
|
|
982
|
+
case "time" /* ePropType.Time */:
|
|
949
983
|
return this.getDate(value, getShortTimeFormat(this.config));
|
|
950
|
-
case "datetime" /* DateTime */:
|
|
984
|
+
case "datetime" /* ePropType.DateTime */:
|
|
951
985
|
return this.getDate(value, getShortDateShortTimeFormat(this.config));
|
|
952
|
-
case "enum" /* Enum */:
|
|
986
|
+
case "enum" /* ePropType.Enum */:
|
|
953
987
|
return this.getEnum(value, prop.enumList);
|
|
954
988
|
default:
|
|
955
989
|
return value;
|
|
@@ -987,9 +1021,9 @@ class ExtensibleTableComponent {
|
|
|
987
1021
|
});
|
|
988
1022
|
}
|
|
989
1023
|
}
|
|
990
|
-
ExtensibleTableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
991
|
-
ExtensibleTableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
992
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1024
|
+
ExtensibleTableComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ExtensibleTableComponent, deps: [{ token: LOCALE_ID }, { token: i1.ConfigStateService }, { token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
1025
|
+
ExtensibleTableComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: ExtensibleTableComponent, selector: "abp-extensible-table", inputs: { actionsText: "actionsText", data: "data", list: "list", recordsTotal: "recordsTotal", actionsColumnWidth: "actionsColumnWidth", actionsTemplate: "actionsTemplate" }, exportAs: ["abpExtensibleTable"], usesOnChanges: true, ngImport: i0, template: "<ngx-datatable default [rows]=\"data\" [count]=\"recordsTotal\" [list]=\"list\">\r\n <ngx-datatable-column\r\n *ngIf=\"actionsTemplate || (actionList.length && hasAtLeastOnePermittedAction)\"\r\n [name]=\"actionsText | abpLocalization\"\r\n [maxWidth]=\"columnWidths[0]\"\r\n [width]=\"columnWidths[0]\"\r\n [sortable]=\"false\"\r\n >\r\n <ng-template let-row=\"row\" let-i=\"rowIndex\" ngx-datatable-cell-template>\r\n <ng-container\r\n *ngTemplateOutlet=\"actionsTemplate || gridActions; context: { $implicit: row, index: i }\"\r\n ></ng-container>\r\n <ng-template #gridActions>\r\n <abp-grid-actions [index]=\"i\" [record]=\"row\" text=\"AbpUi::Actions\"></abp-grid-actions>\r\n </ng-template>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n\r\n <ng-container *ngFor=\"let prop of propList; let i = index; trackBy: trackByFn\">\r\n <ngx-datatable-column\r\n [width]=\"columnWidths[i + 1] || 200\"\r\n [name]=\"prop.displayName | abpLocalization\"\r\n [prop]=\"prop.name\"\r\n [sortable]=\"prop.sortable\"\r\n >\r\n <ng-template let-row=\"row\" let-i=\"index\" ngx-datatable-cell-template>\r\n <ng-container *abpPermission=\"prop.permission; runChangeDetection: false\">\r\n <ng-container *ngIf=\"row['_' + prop.name]?.visible\">\r\n <div\r\n *ngIf=\"!row['_' + prop.name].component; else component\"\r\n [innerHTML]=\"row['_' + prop.name]?.value | async\"\r\n (click)=\"\r\n prop.action && prop.action({ getInjected: getInjected, record: row, index: i })\r\n \"\r\n [ngClass]=\"entityPropTypeClasses[prop.type]\"\r\n [class.pointer]=\"prop.action\"\r\n ></div>\r\n </ng-container>\r\n <ng-template #component>\r\n <ng-container\r\n *ngComponentOutlet=\"\r\n row['_' + prop.name].component;\r\n injector: row['_' + prop.name].injector\r\n \"\r\n ></ng-container>\r\n </ng-template>\r\n </ng-container>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n </ng-container>\r\n</ngx-datatable>\r\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInjector", "ngComponentOutletContent", "ngComponentOutletNgModule", "ngComponentOutletNgModuleFactory"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1$1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.PermissionDirective, selector: "[abpPermission]", inputs: ["abpPermission", "abpPermissionRunChangeDetection"] }, { kind: "component", type: i3.DatatableComponent, selector: "ngx-datatable", inputs: ["selected", "scrollbarV", "scrollbarH", "rowHeight", "columnMode", "headerHeight", "footerHeight", "externalPaging", "externalSorting", "loadingIndicator", "reorderable", "swapColumns", "sortType", "sorts", "cssClasses", "messages", "groupExpansionDefault", "selectAllRowsOnPage", "virtualization", "summaryRow", "summaryHeight", "summaryPosition", "rowIdentity", "rows", "groupedRows", "groupRowsBy", "columns", "limit", "count", "offset", "targetMarkerTemplate", "selectionType", "rowClass", "selectCheck", "displayCheck", "trackByProp", "treeFromRelation", "treeToRelation"], outputs: ["scroll", "activate", "select", "sort", "page", "reorder", "resize", "tableContextmenu", "treeAction"] }, { kind: "directive", type: i3.DataTableColumnDirective, selector: "ngx-datatable-column", inputs: ["name", "prop", "frozenLeft", "frozenRight", "flexGrow", "resizeable", "comparator", "pipe", "sortable", "draggable", "canAutoResize", "minWidth", "width", "maxWidth", "checkboxable", "headerCheckboxable", "headerClass", "cellClass", "isTreeColumn", "treeLevelIndent", "summaryFunc", "summaryTemplate", "cellTemplate", "headerTemplate", "treeToggleTemplate"] }, { kind: "directive", type: i3.DataTableColumnCellDirective, selector: "[ngx-datatable-cell-template]" }, { kind: "directive", type: i4$2.NgxDatatableDefaultDirective, selector: "ngx-datatable[default]", inputs: ["class"], exportAs: ["ngxDatatableDefault"] }, { kind: "directive", type: i4$2.NgxDatatableListDirective, selector: "ngx-datatable[list]", inputs: ["list"], exportAs: ["ngxDatatableList"] }, { kind: "component", type: GridActionsComponent, selector: "abp-grid-actions", inputs: ["icon", "index", "text"], exportAs: ["abpGridActions"] }, { kind: "pipe", type: i1$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i1.LocalizationPipe, name: "abpLocalization" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1026
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: ExtensibleTableComponent, decorators: [{
|
|
993
1027
|
type: Component,
|
|
994
1028
|
args: [{ exportAs: 'abpExtensibleTable', selector: 'abp-extensible-table', changeDetection: ChangeDetectionStrategy.OnPush, template: "<ngx-datatable default [rows]=\"data\" [count]=\"recordsTotal\" [list]=\"list\">\r\n <ngx-datatable-column\r\n *ngIf=\"actionsTemplate || (actionList.length && hasAtLeastOnePermittedAction)\"\r\n [name]=\"actionsText | abpLocalization\"\r\n [maxWidth]=\"columnWidths[0]\"\r\n [width]=\"columnWidths[0]\"\r\n [sortable]=\"false\"\r\n >\r\n <ng-template let-row=\"row\" let-i=\"rowIndex\" ngx-datatable-cell-template>\r\n <ng-container\r\n *ngTemplateOutlet=\"actionsTemplate || gridActions; context: { $implicit: row, index: i }\"\r\n ></ng-container>\r\n <ng-template #gridActions>\r\n <abp-grid-actions [index]=\"i\" [record]=\"row\" text=\"AbpUi::Actions\"></abp-grid-actions>\r\n </ng-template>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n\r\n <ng-container *ngFor=\"let prop of propList; let i = index; trackBy: trackByFn\">\r\n <ngx-datatable-column\r\n [width]=\"columnWidths[i + 1] || 200\"\r\n [name]=\"prop.displayName | abpLocalization\"\r\n [prop]=\"prop.name\"\r\n [sortable]=\"prop.sortable\"\r\n >\r\n <ng-template let-row=\"row\" let-i=\"index\" ngx-datatable-cell-template>\r\n <ng-container *abpPermission=\"prop.permission; runChangeDetection: false\">\r\n <ng-container *ngIf=\"row['_' + prop.name]?.visible\">\r\n <div\r\n *ngIf=\"!row['_' + prop.name].component; else component\"\r\n [innerHTML]=\"row['_' + prop.name]?.value | async\"\r\n (click)=\"\r\n prop.action && prop.action({ getInjected: getInjected, record: row, index: i })\r\n \"\r\n [ngClass]=\"entityPropTypeClasses[prop.type]\"\r\n [class.pointer]=\"prop.action\"\r\n ></div>\r\n </ng-container>\r\n <ng-template #component>\r\n <ng-container\r\n *ngComponentOutlet=\"\r\n row['_' + prop.name].component;\r\n injector: row['_' + prop.name].injector\r\n \"\r\n ></ng-container>\r\n </ng-template>\r\n </ng-container>\r\n </ng-template>\r\n </ngx-datatable-column>\r\n </ng-container>\r\n</ngx-datatable>\r\n" }]
|
|
995
1029
|
}], ctorParameters: function () { return [{ type: undefined, decorators: [{
|
|
@@ -1033,9 +1067,9 @@ class CreateInjectorPipe {
|
|
|
1033
1067
|
return { get };
|
|
1034
1068
|
}
|
|
1035
1069
|
}
|
|
1036
|
-
CreateInjectorPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1037
|
-
CreateInjectorPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "
|
|
1038
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1070
|
+
CreateInjectorPipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: CreateInjectorPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe });
|
|
1071
|
+
CreateInjectorPipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: CreateInjectorPipe, name: "createInjector" });
|
|
1072
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: CreateInjectorPipe, decorators: [{
|
|
1039
1073
|
type: Pipe,
|
|
1040
1074
|
args: [{
|
|
1041
1075
|
name: 'createInjector',
|
|
@@ -1051,14 +1085,14 @@ class PageToolbarComponent extends AbstractActionsComponent {
|
|
|
1051
1085
|
this.trackByFn = (_, item) => item.action || item.component;
|
|
1052
1086
|
}
|
|
1053
1087
|
}
|
|
1054
|
-
PageToolbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1055
|
-
PageToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "
|
|
1088
|
+
PageToolbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: PageToolbarComponent, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component });
|
|
1089
|
+
PageToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.2.1", type: PageToolbarComponent, selector: "abp-page-toolbar", providers: [
|
|
1056
1090
|
{
|
|
1057
1091
|
provide: EXTENSIONS_ACTION_TYPE,
|
|
1058
1092
|
useValue: 'toolbarActions',
|
|
1059
1093
|
},
|
|
1060
|
-
], exportAs: ["abpPageToolbar"], usesInheritance: true, ngImport: i0, template: "<div class=\"row justify-content-end mx-0\" id=\"AbpContentToolbar\">\r\n <div\r\n class=\"col-auto px-1 pt-0 pt-md-2\"\r\n [class.pe-0]=\"last\"\r\n *ngFor=\"let action of actionList; trackBy: trackByFn; let last = last\"\r\n >\r\n <ng-container *ngIf=\"action.visible(data)\">\r\n <ng-container *abpPermission=\"action.permission;runChangeDetection: false\">\r\n <ng-container *ngIf=\"action.component as component; else button\">\r\n <ng-container\r\n *ngComponentOutlet=\"component; injector: record | createInjector: action:this\"\r\n ></ng-container>\r\n </ng-container>\r\n\r\n <ng-template #button>\r\n <button\r\n (click)=\"action.action(data)\"\r\n type=\"button\"\r\n [ngClass]=\"action.btnClass ? action.btnClass : defaultBtnClass\"\r\n >\r\n <i [ngClass]=\"action.icon\" [class.me-1]=\"action.icon\"></i>\r\n {{ action.text | abpLocalization }}\r\n </button>\r\n </ng-template>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n</div>\r\n",
|
|
1061
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1094
|
+
], exportAs: ["abpPageToolbar"], usesInheritance: true, ngImport: i0, template: "<div class=\"row justify-content-end mx-0\" id=\"AbpContentToolbar\">\r\n <div\r\n class=\"col-auto px-1 pt-0 pt-md-2\"\r\n [class.pe-0]=\"last\"\r\n *ngFor=\"let action of actionList; trackBy: trackByFn; let last = last\"\r\n >\r\n <ng-container *ngIf=\"action.visible(data)\">\r\n <ng-container *abpPermission=\"action.permission;runChangeDetection: false\">\r\n <ng-container *ngIf=\"action.component as component; else button\">\r\n <ng-container\r\n *ngComponentOutlet=\"component; injector: record | createInjector: action:this\"\r\n ></ng-container>\r\n </ng-container>\r\n\r\n <ng-template #button>\r\n <button\r\n (click)=\"action.action(data)\"\r\n type=\"button\"\r\n [ngClass]=\"action.btnClass ? action.btnClass : defaultBtnClass\"\r\n >\r\n <i [ngClass]=\"action.icon\" [class.me-1]=\"action.icon\"></i>\r\n {{ action.text | abpLocalization }}\r\n </button>\r\n </ng-template>\r\n </ng-container>\r\n </ng-container>\r\n </div>\r\n</div>\r\n", dependencies: [{ kind: "directive", type: i1$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i1$1.NgComponentOutlet, selector: "[ngComponentOutlet]", inputs: ["ngComponentOutlet", "ngComponentOutletInjector", "ngComponentOutletContent", "ngComponentOutletNgModule", "ngComponentOutletNgModuleFactory"] }, { kind: "directive", type: i1$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { kind: "directive", type: i1$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.PermissionDirective, selector: "[abpPermission]", inputs: ["abpPermission", "abpPermissionRunChangeDetection"] }, { kind: "pipe", type: i1.LocalizationPipe, name: "abpLocalization" }, { kind: "pipe", type: CreateInjectorPipe, name: "createInjector" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
1095
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: PageToolbarComponent, decorators: [{
|
|
1062
1096
|
type: Component,
|
|
1063
1097
|
args: [{ exportAs: 'abpPageToolbar', selector: 'abp-page-toolbar', providers: [
|
|
1064
1098
|
{
|
|
@@ -1076,8 +1110,8 @@ const EXTENSIBLE_FORM_VIEW_PROVIDER = { provide: ControlContainer, useExisting:
|
|
|
1076
1110
|
|
|
1077
1111
|
class BaseUiExtensionsModule {
|
|
1078
1112
|
}
|
|
1079
|
-
BaseUiExtensionsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1080
|
-
BaseUiExtensionsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "
|
|
1113
|
+
BaseUiExtensionsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BaseUiExtensionsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1114
|
+
BaseUiExtensionsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: BaseUiExtensionsModule, declarations: [DateTimePickerComponent,
|
|
1081
1115
|
PageToolbarComponent,
|
|
1082
1116
|
GridActionsComponent,
|
|
1083
1117
|
ExtensibleFormPropComponent,
|
|
@@ -1099,16 +1133,14 @@ BaseUiExtensionsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0",
|
|
|
1099
1133
|
PropDataDirective,
|
|
1100
1134
|
DisabledDirective,
|
|
1101
1135
|
CreateInjectorPipe] });
|
|
1102
|
-
BaseUiExtensionsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
]] });
|
|
1111
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.6", ngImport: i0, type: BaseUiExtensionsModule, decorators: [{
|
|
1136
|
+
BaseUiExtensionsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BaseUiExtensionsModule, imports: [CoreModule,
|
|
1137
|
+
ThemeSharedModule,
|
|
1138
|
+
NgxValidateCoreModule,
|
|
1139
|
+
NgbDatepickerModule,
|
|
1140
|
+
NgbDropdownModule,
|
|
1141
|
+
NgbTimepickerModule,
|
|
1142
|
+
NgbTypeaheadModule] });
|
|
1143
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: BaseUiExtensionsModule, decorators: [{
|
|
1112
1144
|
type: NgModule,
|
|
1113
1145
|
args: [{
|
|
1114
1146
|
exports: [
|
|
@@ -1145,10 +1177,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.3.6", ngImpor
|
|
|
1145
1177
|
}] });
|
|
1146
1178
|
class UiExtensionsModule {
|
|
1147
1179
|
}
|
|
1148
|
-
UiExtensionsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "
|
|
1149
|
-
UiExtensionsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "
|
|
1150
|
-
UiExtensionsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "
|
|
1151
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "
|
|
1180
|
+
UiExtensionsModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: UiExtensionsModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1181
|
+
UiExtensionsModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "14.2.1", ngImport: i0, type: UiExtensionsModule, imports: [BaseUiExtensionsModule], exports: [BaseUiExtensionsModule] });
|
|
1182
|
+
UiExtensionsModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: UiExtensionsModule, imports: [BaseUiExtensionsModule, BaseUiExtensionsModule] });
|
|
1183
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.2.1", ngImport: i0, type: UiExtensionsModule, decorators: [{
|
|
1152
1184
|
type: NgModule,
|
|
1153
1185
|
args: [{
|
|
1154
1186
|
exports: [BaseUiExtensionsModule],
|
|
@@ -1168,8 +1200,8 @@ function mergeWithDefaultActions(extension, defaultActions, ...contributors) {
|
|
|
1168
1200
|
function generateFormFromProps(data) {
|
|
1169
1201
|
const extensions = data.getInjected(ExtensionsService);
|
|
1170
1202
|
const identifier = data.getInjected(EXTENSIONS_IDENTIFIER);
|
|
1171
|
-
const form = new
|
|
1172
|
-
const extraForm = new
|
|
1203
|
+
const form = new UntypedFormGroup({});
|
|
1204
|
+
const extraForm = new UntypedFormGroup({});
|
|
1173
1205
|
form.addControl(EXTRA_PROPERTIES_KEY, extraForm);
|
|
1174
1206
|
const record = data.record || {};
|
|
1175
1207
|
const type = JSON.stringify(record) === '{}' ? 'create' : 'edit';
|
|
@@ -1184,15 +1216,15 @@ function generateFormFromProps(data) {
|
|
|
1184
1216
|
if (value) {
|
|
1185
1217
|
let adapter;
|
|
1186
1218
|
switch (prop.type) {
|
|
1187
|
-
case "date" /* Date */:
|
|
1219
|
+
case "date" /* ePropType.Date */:
|
|
1188
1220
|
adapter = new DateAdapter();
|
|
1189
1221
|
value = adapter.toModel(adapter.fromModel(value));
|
|
1190
1222
|
break;
|
|
1191
|
-
case "time" /* Time */:
|
|
1223
|
+
case "time" /* ePropType.Time */:
|
|
1192
1224
|
adapter = new TimeAdapter();
|
|
1193
1225
|
value = adapter.toModel(adapter.fromModel(value));
|
|
1194
1226
|
break;
|
|
1195
|
-
case "datetime" /* DateTime */:
|
|
1227
|
+
case "datetime" /* ePropType.DateTime */:
|
|
1196
1228
|
adapter = new DateTimeAdapter();
|
|
1197
1229
|
value = adapter.toModel(adapter.fromModel(value));
|
|
1198
1230
|
break;
|
|
@@ -1200,7 +1232,7 @@ function generateFormFromProps(data) {
|
|
|
1200
1232
|
break;
|
|
1201
1233
|
}
|
|
1202
1234
|
}
|
|
1203
|
-
const formControl = new
|
|
1235
|
+
const formControl = new UntypedFormControl(value, {
|
|
1204
1236
|
asyncValidators: prop.asyncValidators(data),
|
|
1205
1237
|
validators: prop.validators(data),
|
|
1206
1238
|
});
|
|
@@ -1343,8 +1375,8 @@ function createPropertiesToContributorsMapper(generateDisplayName, resource, enu
|
|
|
1343
1375
|
const displayName = generateDN(property.displayName, { name, resource });
|
|
1344
1376
|
if (property.ui.onTable.isVisible) {
|
|
1345
1377
|
const sortable = Boolean(property.ui.onTable.isSortable);
|
|
1346
|
-
const columnWidth = type === "boolean" /* Boolean */ ? 150 : 250;
|
|
1347
|
-
const valueResolver = type === "enum" /* Enum */
|
|
1378
|
+
const columnWidth = type === "boolean" /* ePropType.Boolean */ ? 150 : 250;
|
|
1379
|
+
const valueResolver = type === "enum" /* ePropType.Enum */
|
|
1348
1380
|
? createEnumValueResolver(property.type, enums[property.type], propName)
|
|
1349
1381
|
: createExtraPropertyValueResolver(propName);
|
|
1350
1382
|
const entityProp = new EntityProp({
|
|
@@ -1365,9 +1397,9 @@ function createPropertiesToContributorsMapper(generateDisplayName, resource, enu
|
|
|
1365
1397
|
const defaultValue = property.defaultValue;
|
|
1366
1398
|
const validators = () => getValidatorsFromProperty(property);
|
|
1367
1399
|
let options;
|
|
1368
|
-
if (type === "enum" /* Enum */)
|
|
1400
|
+
if (type === "enum" /* ePropType.Enum */)
|
|
1369
1401
|
options = createEnumOptions(propName, enums[property.type || '']);
|
|
1370
|
-
else if (type === "typeahead" /* Typeahead */)
|
|
1402
|
+
else if (type === "typeahead" /* ePropType.Typeahead */)
|
|
1371
1403
|
options = createTypeaheadOptions(lookup);
|
|
1372
1404
|
const formProp = new FormProp({
|
|
1373
1405
|
type,
|