@farris/jit-engine 1.4.134 → 1.4.135
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/lib/domstructure/devkit/viewmodel/component/component.js +221 -221
- package/lib/domstructure/ui/field-search-box/field-search-box.js +85 -0
- package/lib/domstructure/ui/field-search-box/field-search-box.js.map +1 -0
- package/lib/domstructure/ui/field-search-box/index.js +14 -0
- package/lib/domstructure/ui/field-search-box/index.js.map +1 -0
- package/lib/domstructure/ui/index.js +1 -0
- package/lib/domstructure/ui/index.js.map +1 -1
- package/lib/template/devkit/module.pug +270 -268
- package/lib/template/ui/kendo/field-search-box.pug +9 -0
- package/lib/utility/devkit/component-creator.js +1 -0
- package/lib/utility/devkit/component-creator.js.map +1 -1
- package/lib/utility/devkit/component-parameter-collector/component-parameter-collector-manager.js +4 -0
- package/lib/utility/devkit/component-parameter-collector/component-parameter-collector-manager.js.map +1 -1
- package/lib/utility/devkit/component-parameter-collector/component-parameter-collector-type.js +1 -0
- package/lib/utility/devkit/component-parameter-collector/component-parameter-collector-type.js.map +1 -1
- package/lib/utility/devkit/component-parameter-collector/field-search-box-parameter-collector.js +84 -0
- package/lib/utility/devkit/component-parameter-collector/field-search-box-parameter-collector.js.map +1 -0
- package/lib/utility/devkit/devkit-constant.js +1 -0
- package/lib/utility/devkit/devkit-constant.js.map +1 -1
- package/lib/utility/devkit-template-config.js +3 -0
- package/lib/utility/devkit-template-config.js.map +1 -1
- package/lib/utility/i18n/i18n-resource-manager.js +9 -0
- package/lib/utility/i18n/i18n-resource-manager.js.map +1 -1
- package/lib/utility/internal-entity/component-parameter/component-field-search-box-parameter.js +43 -0
- package/lib/utility/internal-entity/component-parameter/component-field-search-box-parameter.js.map +1 -0
- package/lib/utility/internal-entity/component-parameter/index.js +1 -0
- package/lib/utility/internal-entity/component-parameter/index.js.map +1 -1
- package/lib/utility/template-generator/devkit/component-generator/component-field-search-box-parameter-generator.js +69 -0
- package/lib/utility/template-generator/devkit/component-generator/component-field-search-box-parameter-generator.js.map +1 -0
- package/lib/utility/template-generator/devkit/component-template-generator.js +541 -537
- package/lib/utility/template-generator/devkit/component-template-generator.js.map +1 -1
- package/lib/utility/template-generator/devkit/module-generator/module-import-statement-generator.js +141 -140
- package/lib/utility/template-generator/devkit/module-generator/module-import-statement-generator.js.map +1 -1
- package/lib/utility/template-generator/devkit/module-generator/module-imports-statement-generator.js +143 -142
- package/lib/utility/template-generator/devkit/module-generator/module-imports-statement-generator.js.map +1 -1
- package/package.json +103 -57
|
@@ -1,222 +1,222 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ComponentConfig = void 0;
|
|
4
|
-
const service_1 = require("../service/service");
|
|
5
|
-
const utility_1 = require("../../../../utility");
|
|
6
|
-
const subscription_1 = require("../../event/subscription");
|
|
7
|
-
const component_children_route_1 = require("./component-children-route");
|
|
8
|
-
const module_reference_1 = require("../../module-reference");
|
|
9
|
-
const component_custom_provider_1 = require("./component-custom-provider");
|
|
10
|
-
const ui_1 = require("../../../ui");
|
|
11
|
-
class ComponentConfig {
|
|
12
|
-
constructor(param) {
|
|
13
|
-
this.modalFormControls = [];
|
|
14
|
-
this.isJointSearch = false;
|
|
15
|
-
let obj;
|
|
16
|
-
if (typeof param === 'string') {
|
|
17
|
-
obj = utility_1.ToolHelper.convertToJsonOrDefault(param);
|
|
18
|
-
}
|
|
19
|
-
else {
|
|
20
|
-
obj = param;
|
|
21
|
-
}
|
|
22
|
-
if (!obj) {
|
|
23
|
-
return;
|
|
24
|
-
}
|
|
25
|
-
this.toolbars = [];
|
|
26
|
-
const keys = `id,name,componentType,template,repositoryName,createEmptyScssFile,farrisCheckBoxGroupParamsters,
|
|
27
|
-
fileUploadParameters,headerParameters,dynamic,viewModelName,onInit,onActived,afterViewInit,form,stateMachine,
|
|
28
|
-
states,appearance,farristabstitle,farrisRadioGroupParameters,enumFieldParameters,handlers,services,componentEvents,
|
|
29
|
-
toolbars,dependencies,providers,parentExternalComponent,componentSubscriptions,onInitDeclarationEvents,
|
|
30
|
-
afterViewInitDeclarationEvents,childrenRoutes,farrisNumberSpinnerOrRanges,farristabtoolbars,lookupPickedDeclarationEvents,
|
|
31
|
-
lookupPickingDeclarationEvents,sidebarComponent,farrisDataGridParameter,providers,injectors,componentSidebarToolbar,
|
|
32
|
-
farrisLookups,isJointSearch,moduleReference,fieldSetParameters,farrisTreeGridParameter,componentSidebarToolbar,
|
|
33
|
-
componentSidebarTitle,farrisListNavParameters,querySchemaParameters,scrollSpyTitleParameters,qdpFrameworkQueryName,
|
|
34
|
-
enableUnifiedSession,toolTypeChangeParameters,farrisSectionParameters,wizardParameters,farrisInputGroupParameter,
|
|
35
|
-
farrisListFilterParameter,farrisDatePickers,farrisComboLists,farrisTimePickers,farrisTextBoxs,farrisMultiTextBoxs,
|
|
36
|
-
farrisLanguageTextBoxs,farrisNumericBoxs,farrisDateBoxs,farrisTimeSpinners,footerParameters,buttonParameters,primengTreeGridParameters,
|
|
37
|
-
navTabParameters,viewChangeParameters,tagsParameters,listViewParameters,customProviders,moduleSchemaId,customComponentClass,
|
|
38
|
-
paramTypeTransform,externalContainerParameters,personnelSelectorParameters,organizationSelectorParameters,employeeSelectorParameters,
|
|
39
|
-
adminorganizationSelectorParameters,componentConditionDialogParameter,componentReadonlyProp,runMode,componentAppointmentCalendarParameters,
|
|
40
|
-
changeSetPolicy,avatarParameters,enableServerSideChangeDetection,enableAif,pushMode,defaultFormRule,jit_isRouteForm,metadataId,progressStepParameters,persistSelectedRows`;
|
|
41
|
-
Object.keys(obj).forEach(key => {
|
|
42
|
-
if (keys.includes(key)) {
|
|
43
|
-
if (key == "onInit" || key == "afterViewInit" || key == "onActived") {
|
|
44
|
-
if (obj[key]) {
|
|
45
|
-
this[key] = utility_1.EventViewModelModifier.modify(obj[key], true, true);
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
else if (key == 'services') {
|
|
49
|
-
this.services = [];
|
|
50
|
-
obj[key].forEach((item) => {
|
|
51
|
-
this.services.push(new service_1.Service(item));
|
|
52
|
-
});
|
|
53
|
-
}
|
|
54
|
-
else if (key == "componentSubscriptions") {
|
|
55
|
-
this.componentSubscriptions = [];
|
|
56
|
-
if (obj[key] && utility_1.ToolHelper.isArray(obj[key])) {
|
|
57
|
-
obj[key].forEach((subscriptionItem) => {
|
|
58
|
-
const subscription = new subscription_1.Subscription(subscriptionItem);
|
|
59
|
-
this.componentSubscriptions.push(subscription);
|
|
60
|
-
});
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
else if (key == "onInitDeclarationEvents") {
|
|
64
|
-
this.onInitDeclarationEvents = [];
|
|
65
|
-
if (obj[key] && obj[key].length > 0) {
|
|
66
|
-
obj[key].forEach((onInitDeclarationEvent) => {
|
|
67
|
-
this.onInitDeclarationEvents.push(onInitDeclarationEvent);
|
|
68
|
-
});
|
|
69
|
-
}
|
|
70
|
-
}
|
|
71
|
-
else if (key == "afterViewInitDeclarationEvents") {
|
|
72
|
-
this.afterViewInitDeclarationEvents = [];
|
|
73
|
-
if (obj[key] && obj[key].length > 0) {
|
|
74
|
-
obj[key].forEach((afterViewInitDeclarationEvent) => {
|
|
75
|
-
this.afterViewInitDeclarationEvents.push(afterViewInitDeclarationEvent);
|
|
76
|
-
});
|
|
77
|
-
}
|
|
78
|
-
}
|
|
79
|
-
else if (key == "lookupPickedDeclarationEvents") {
|
|
80
|
-
this.lookupPickedDeclarationEvents = [];
|
|
81
|
-
if (obj[key] && obj[key].length > 0) {
|
|
82
|
-
obj[key].forEach((lookupPickedDeclarationEvent) => {
|
|
83
|
-
this.lookupPickedDeclarationEvents.push(lookupPickedDeclarationEvent);
|
|
84
|
-
});
|
|
85
|
-
}
|
|
86
|
-
}
|
|
87
|
-
else if (key == "lookupPickingDeclarationEvents") {
|
|
88
|
-
this.lookupPickingDeclarationEvents = [];
|
|
89
|
-
if (obj[key] && obj[key].length > 0) {
|
|
90
|
-
obj[key].forEach((lookupPickingDeclarationEvent) => {
|
|
91
|
-
this.lookupPickingDeclarationEvents.push(lookupPickingDeclarationEvent);
|
|
92
|
-
});
|
|
93
|
-
}
|
|
94
|
-
}
|
|
95
|
-
else if (key == "toolbars") {
|
|
96
|
-
if (obj[key] && utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
97
|
-
obj[key].forEach((toolbarItem) => {
|
|
98
|
-
this.toolbars.push(toolbarItem);
|
|
99
|
-
});
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
else if (key == "farrisDataGridParameter") {
|
|
103
|
-
this.farrisDataGridParameter = [];
|
|
104
|
-
if (obj[key] && utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
105
|
-
obj[key].forEach((gridParameter) => {
|
|
106
|
-
this.farrisDataGridParameter.push(gridParameter);
|
|
107
|
-
});
|
|
108
|
-
}
|
|
109
|
-
}
|
|
110
|
-
else if (key == "injectors") {
|
|
111
|
-
this.injectors = [];
|
|
112
|
-
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
113
|
-
obj[key].forEach((injector) => {
|
|
114
|
-
this.injectors.push(injector);
|
|
115
|
-
});
|
|
116
|
-
}
|
|
117
|
-
}
|
|
118
|
-
else if (key == "componentSidebarToolbar") {
|
|
119
|
-
this.componentSidebarToolbar = [];
|
|
120
|
-
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
121
|
-
obj[key].forEach((sidebarToolbar) => {
|
|
122
|
-
this.componentSidebarToolbar.push(sidebarToolbar);
|
|
123
|
-
this.toolbars.push(sidebarToolbar);
|
|
124
|
-
});
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
else if (key == "farrisLookups") {
|
|
128
|
-
this.componentFarrisLookups = [];
|
|
129
|
-
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
130
|
-
obj[key].forEach((item) => {
|
|
131
|
-
this.componentFarrisLookups.push(item);
|
|
132
|
-
});
|
|
133
|
-
}
|
|
134
|
-
}
|
|
135
|
-
else if (key == "template") {
|
|
136
|
-
if (obj[key] && utility_1.ToolHelper.isArray(obj[key], true)) {
|
|
137
|
-
this.template = [];
|
|
138
|
-
obj[key].forEach((item) => {
|
|
139
|
-
this.template.push(item);
|
|
140
|
-
});
|
|
141
|
-
}
|
|
142
|
-
else {
|
|
143
|
-
this[key] = obj[key];
|
|
144
|
-
}
|
|
145
|
-
}
|
|
146
|
-
else if (key == "childrenRoutes") {
|
|
147
|
-
this.childrenRoutes = [];
|
|
148
|
-
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
149
|
-
obj[key].forEach((item) => {
|
|
150
|
-
this.childrenRoutes.push(new component_children_route_1.ComponentChildrenRoute(item));
|
|
151
|
-
});
|
|
152
|
-
}
|
|
153
|
-
}
|
|
154
|
-
else if (key === "moduleReference") {
|
|
155
|
-
if (obj[key]) {
|
|
156
|
-
this[key] = new module_reference_1.ModuleReference(obj[key]);
|
|
157
|
-
}
|
|
158
|
-
}
|
|
159
|
-
else if (key == "farrisNumberSpinnerOrRanges") {
|
|
160
|
-
this.farrisNumberSpinnerOrRanges = [];
|
|
161
|
-
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
162
|
-
obj[key].forEach((item) => {
|
|
163
|
-
this.farrisNumberSpinnerOrRanges.push(item);
|
|
164
|
-
});
|
|
165
|
-
}
|
|
166
|
-
}
|
|
167
|
-
else if (key == "primengTreeGridParameters") {
|
|
168
|
-
this.primengTreeGridParameters = [];
|
|
169
|
-
if (obj[key] && utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
170
|
-
obj[key].forEach((gridParameter) => {
|
|
171
|
-
this.primengTreeGridParameters.push(gridParameter);
|
|
172
|
-
});
|
|
173
|
-
}
|
|
174
|
-
}
|
|
175
|
-
else if (key == "customProviders") {
|
|
176
|
-
this.customProviders = [];
|
|
177
|
-
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
178
|
-
obj[key].forEach((itemProvider) => {
|
|
179
|
-
const customProvider = new component_custom_provider_1.ComponentCustomProvider();
|
|
180
|
-
customProvider.providerToken = itemProvider.providerToken;
|
|
181
|
-
customProvider.providerTokenPath = itemProvider.providerTokenPath;
|
|
182
|
-
customProvider.providerValue = itemProvider.providerValue;
|
|
183
|
-
customProvider.providerValuePath = itemProvider.providerValuePath;
|
|
184
|
-
customProvider.type = itemProvider.type ? itemProvider.type : "useClass";
|
|
185
|
-
customProvider.providerTokenAlias = itemProvider.providerTokenAlias;
|
|
186
|
-
customProvider.providerValueAlias = itemProvider.providerValueAlias;
|
|
187
|
-
this.customProviders.push(customProvider);
|
|
188
|
-
});
|
|
189
|
-
}
|
|
190
|
-
}
|
|
191
|
-
else if (key == "appearance") {
|
|
192
|
-
if (obj[key]) {
|
|
193
|
-
if (utility_1.ToolHelper.isString(obj[key])) {
|
|
194
|
-
this.appearance = obj[key];
|
|
195
|
-
}
|
|
196
|
-
else {
|
|
197
|
-
this.appearance = new ui_1.Appearance(obj[key]);
|
|
198
|
-
}
|
|
199
|
-
}
|
|
200
|
-
}
|
|
201
|
-
else {
|
|
202
|
-
this[key] = obj[key];
|
|
203
|
-
}
|
|
204
|
-
}
|
|
205
|
-
});
|
|
206
|
-
if (utility_1.ToolHelper.isArray(this.listViewParameters, false)) {
|
|
207
|
-
if (!this.toolbars) {
|
|
208
|
-
this.toolbars = [];
|
|
209
|
-
}
|
|
210
|
-
this.listViewParameters.forEach((item) => {
|
|
211
|
-
if (item.toolbar) {
|
|
212
|
-
this.toolbars.push(item.toolbar);
|
|
213
|
-
}
|
|
214
|
-
});
|
|
215
|
-
}
|
|
216
|
-
if (this.id) {
|
|
217
|
-
this.replacedId = utility_1.ToolHelper.replaceHengXianAndDotToXiaHuaXian(this.id);
|
|
218
|
-
}
|
|
219
|
-
}
|
|
220
|
-
}
|
|
221
|
-
exports.ComponentConfig = ComponentConfig;
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ComponentConfig = void 0;
|
|
4
|
+
const service_1 = require("../service/service");
|
|
5
|
+
const utility_1 = require("../../../../utility");
|
|
6
|
+
const subscription_1 = require("../../event/subscription");
|
|
7
|
+
const component_children_route_1 = require("./component-children-route");
|
|
8
|
+
const module_reference_1 = require("../../module-reference");
|
|
9
|
+
const component_custom_provider_1 = require("./component-custom-provider");
|
|
10
|
+
const ui_1 = require("../../../ui");
|
|
11
|
+
class ComponentConfig {
|
|
12
|
+
constructor(param) {
|
|
13
|
+
this.modalFormControls = [];
|
|
14
|
+
this.isJointSearch = false;
|
|
15
|
+
let obj;
|
|
16
|
+
if (typeof param === 'string') {
|
|
17
|
+
obj = utility_1.ToolHelper.convertToJsonOrDefault(param);
|
|
18
|
+
}
|
|
19
|
+
else {
|
|
20
|
+
obj = param;
|
|
21
|
+
}
|
|
22
|
+
if (!obj) {
|
|
23
|
+
return;
|
|
24
|
+
}
|
|
25
|
+
this.toolbars = [];
|
|
26
|
+
const keys = `id,name,componentType,template,repositoryName,createEmptyScssFile,farrisCheckBoxGroupParamsters,
|
|
27
|
+
fileUploadParameters,headerParameters,dynamic,viewModelName,onInit,onActived,afterViewInit,form,stateMachine,
|
|
28
|
+
states,appearance,farristabstitle,farrisRadioGroupParameters,enumFieldParameters,handlers,services,componentEvents,
|
|
29
|
+
toolbars,dependencies,providers,parentExternalComponent,componentSubscriptions,onInitDeclarationEvents,
|
|
30
|
+
afterViewInitDeclarationEvents,childrenRoutes,farrisNumberSpinnerOrRanges,farristabtoolbars,lookupPickedDeclarationEvents,
|
|
31
|
+
lookupPickingDeclarationEvents,sidebarComponent,farrisDataGridParameter,providers,injectors,componentSidebarToolbar,
|
|
32
|
+
farrisLookups,isJointSearch,moduleReference,fieldSetParameters,farrisTreeGridParameter,componentSidebarToolbar,
|
|
33
|
+
componentSidebarTitle,farrisListNavParameters,querySchemaParameters,scrollSpyTitleParameters,qdpFrameworkQueryName,
|
|
34
|
+
enableUnifiedSession,toolTypeChangeParameters,farrisSectionParameters,wizardParameters,farrisInputGroupParameter,
|
|
35
|
+
farrisListFilterParameter,fieldSearchBoxParameters,farrisDatePickers,farrisComboLists,farrisTimePickers,farrisTextBoxs,farrisMultiTextBoxs,
|
|
36
|
+
farrisLanguageTextBoxs,farrisNumericBoxs,farrisDateBoxs,farrisTimeSpinners,footerParameters,buttonParameters,primengTreeGridParameters,
|
|
37
|
+
navTabParameters,viewChangeParameters,tagsParameters,listViewParameters,customProviders,moduleSchemaId,customComponentClass,
|
|
38
|
+
paramTypeTransform,externalContainerParameters,personnelSelectorParameters,organizationSelectorParameters,employeeSelectorParameters,
|
|
39
|
+
adminorganizationSelectorParameters,componentConditionDialogParameter,componentReadonlyProp,runMode,componentAppointmentCalendarParameters,
|
|
40
|
+
changeSetPolicy,avatarParameters,enableServerSideChangeDetection,enableAif,pushMode,defaultFormRule,jit_isRouteForm,metadataId,progressStepParameters,persistSelectedRows`;
|
|
41
|
+
Object.keys(obj).forEach(key => {
|
|
42
|
+
if (keys.includes(key)) {
|
|
43
|
+
if (key == "onInit" || key == "afterViewInit" || key == "onActived") {
|
|
44
|
+
if (obj[key]) {
|
|
45
|
+
this[key] = utility_1.EventViewModelModifier.modify(obj[key], true, true);
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
else if (key == 'services') {
|
|
49
|
+
this.services = [];
|
|
50
|
+
obj[key].forEach((item) => {
|
|
51
|
+
this.services.push(new service_1.Service(item));
|
|
52
|
+
});
|
|
53
|
+
}
|
|
54
|
+
else if (key == "componentSubscriptions") {
|
|
55
|
+
this.componentSubscriptions = [];
|
|
56
|
+
if (obj[key] && utility_1.ToolHelper.isArray(obj[key])) {
|
|
57
|
+
obj[key].forEach((subscriptionItem) => {
|
|
58
|
+
const subscription = new subscription_1.Subscription(subscriptionItem);
|
|
59
|
+
this.componentSubscriptions.push(subscription);
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
else if (key == "onInitDeclarationEvents") {
|
|
64
|
+
this.onInitDeclarationEvents = [];
|
|
65
|
+
if (obj[key] && obj[key].length > 0) {
|
|
66
|
+
obj[key].forEach((onInitDeclarationEvent) => {
|
|
67
|
+
this.onInitDeclarationEvents.push(onInitDeclarationEvent);
|
|
68
|
+
});
|
|
69
|
+
}
|
|
70
|
+
}
|
|
71
|
+
else if (key == "afterViewInitDeclarationEvents") {
|
|
72
|
+
this.afterViewInitDeclarationEvents = [];
|
|
73
|
+
if (obj[key] && obj[key].length > 0) {
|
|
74
|
+
obj[key].forEach((afterViewInitDeclarationEvent) => {
|
|
75
|
+
this.afterViewInitDeclarationEvents.push(afterViewInitDeclarationEvent);
|
|
76
|
+
});
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
else if (key == "lookupPickedDeclarationEvents") {
|
|
80
|
+
this.lookupPickedDeclarationEvents = [];
|
|
81
|
+
if (obj[key] && obj[key].length > 0) {
|
|
82
|
+
obj[key].forEach((lookupPickedDeclarationEvent) => {
|
|
83
|
+
this.lookupPickedDeclarationEvents.push(lookupPickedDeclarationEvent);
|
|
84
|
+
});
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
else if (key == "lookupPickingDeclarationEvents") {
|
|
88
|
+
this.lookupPickingDeclarationEvents = [];
|
|
89
|
+
if (obj[key] && obj[key].length > 0) {
|
|
90
|
+
obj[key].forEach((lookupPickingDeclarationEvent) => {
|
|
91
|
+
this.lookupPickingDeclarationEvents.push(lookupPickingDeclarationEvent);
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
else if (key == "toolbars") {
|
|
96
|
+
if (obj[key] && utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
97
|
+
obj[key].forEach((toolbarItem) => {
|
|
98
|
+
this.toolbars.push(toolbarItem);
|
|
99
|
+
});
|
|
100
|
+
}
|
|
101
|
+
}
|
|
102
|
+
else if (key == "farrisDataGridParameter") {
|
|
103
|
+
this.farrisDataGridParameter = [];
|
|
104
|
+
if (obj[key] && utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
105
|
+
obj[key].forEach((gridParameter) => {
|
|
106
|
+
this.farrisDataGridParameter.push(gridParameter);
|
|
107
|
+
});
|
|
108
|
+
}
|
|
109
|
+
}
|
|
110
|
+
else if (key == "injectors") {
|
|
111
|
+
this.injectors = [];
|
|
112
|
+
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
113
|
+
obj[key].forEach((injector) => {
|
|
114
|
+
this.injectors.push(injector);
|
|
115
|
+
});
|
|
116
|
+
}
|
|
117
|
+
}
|
|
118
|
+
else if (key == "componentSidebarToolbar") {
|
|
119
|
+
this.componentSidebarToolbar = [];
|
|
120
|
+
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
121
|
+
obj[key].forEach((sidebarToolbar) => {
|
|
122
|
+
this.componentSidebarToolbar.push(sidebarToolbar);
|
|
123
|
+
this.toolbars.push(sidebarToolbar);
|
|
124
|
+
});
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
else if (key == "farrisLookups") {
|
|
128
|
+
this.componentFarrisLookups = [];
|
|
129
|
+
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
130
|
+
obj[key].forEach((item) => {
|
|
131
|
+
this.componentFarrisLookups.push(item);
|
|
132
|
+
});
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
else if (key == "template") {
|
|
136
|
+
if (obj[key] && utility_1.ToolHelper.isArray(obj[key], true)) {
|
|
137
|
+
this.template = [];
|
|
138
|
+
obj[key].forEach((item) => {
|
|
139
|
+
this.template.push(item);
|
|
140
|
+
});
|
|
141
|
+
}
|
|
142
|
+
else {
|
|
143
|
+
this[key] = obj[key];
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
else if (key == "childrenRoutes") {
|
|
147
|
+
this.childrenRoutes = [];
|
|
148
|
+
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
149
|
+
obj[key].forEach((item) => {
|
|
150
|
+
this.childrenRoutes.push(new component_children_route_1.ComponentChildrenRoute(item));
|
|
151
|
+
});
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
else if (key === "moduleReference") {
|
|
155
|
+
if (obj[key]) {
|
|
156
|
+
this[key] = new module_reference_1.ModuleReference(obj[key]);
|
|
157
|
+
}
|
|
158
|
+
}
|
|
159
|
+
else if (key == "farrisNumberSpinnerOrRanges") {
|
|
160
|
+
this.farrisNumberSpinnerOrRanges = [];
|
|
161
|
+
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
162
|
+
obj[key].forEach((item) => {
|
|
163
|
+
this.farrisNumberSpinnerOrRanges.push(item);
|
|
164
|
+
});
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
else if (key == "primengTreeGridParameters") {
|
|
168
|
+
this.primengTreeGridParameters = [];
|
|
169
|
+
if (obj[key] && utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
170
|
+
obj[key].forEach((gridParameter) => {
|
|
171
|
+
this.primengTreeGridParameters.push(gridParameter);
|
|
172
|
+
});
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
else if (key == "customProviders") {
|
|
176
|
+
this.customProviders = [];
|
|
177
|
+
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
178
|
+
obj[key].forEach((itemProvider) => {
|
|
179
|
+
const customProvider = new component_custom_provider_1.ComponentCustomProvider();
|
|
180
|
+
customProvider.providerToken = itemProvider.providerToken;
|
|
181
|
+
customProvider.providerTokenPath = itemProvider.providerTokenPath;
|
|
182
|
+
customProvider.providerValue = itemProvider.providerValue;
|
|
183
|
+
customProvider.providerValuePath = itemProvider.providerValuePath;
|
|
184
|
+
customProvider.type = itemProvider.type ? itemProvider.type : "useClass";
|
|
185
|
+
customProvider.providerTokenAlias = itemProvider.providerTokenAlias;
|
|
186
|
+
customProvider.providerValueAlias = itemProvider.providerValueAlias;
|
|
187
|
+
this.customProviders.push(customProvider);
|
|
188
|
+
});
|
|
189
|
+
}
|
|
190
|
+
}
|
|
191
|
+
else if (key == "appearance") {
|
|
192
|
+
if (obj[key]) {
|
|
193
|
+
if (utility_1.ToolHelper.isString(obj[key])) {
|
|
194
|
+
this.appearance = obj[key];
|
|
195
|
+
}
|
|
196
|
+
else {
|
|
197
|
+
this.appearance = new ui_1.Appearance(obj[key]);
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
else {
|
|
202
|
+
this[key] = obj[key];
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
});
|
|
206
|
+
if (utility_1.ToolHelper.isArray(this.listViewParameters, false)) {
|
|
207
|
+
if (!this.toolbars) {
|
|
208
|
+
this.toolbars = [];
|
|
209
|
+
}
|
|
210
|
+
this.listViewParameters.forEach((item) => {
|
|
211
|
+
if (item.toolbar) {
|
|
212
|
+
this.toolbars.push(item.toolbar);
|
|
213
|
+
}
|
|
214
|
+
});
|
|
215
|
+
}
|
|
216
|
+
if (this.id) {
|
|
217
|
+
this.replacedId = utility_1.ToolHelper.replaceHengXianAndDotToXiaHuaXian(this.id);
|
|
218
|
+
}
|
|
219
|
+
}
|
|
220
|
+
}
|
|
221
|
+
exports.ComponentConfig = ComponentConfig;
|
|
222
222
|
//# sourceMappingURL=component.js.map
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.FieldSearchBox = void 0;
|
|
4
|
+
const utility_1 = require("../../../utility");
|
|
5
|
+
const common_1 = require("../common");
|
|
6
|
+
class FieldSearchBox extends common_1.BaseComponent {
|
|
7
|
+
constructor(param) {
|
|
8
|
+
super(param);
|
|
9
|
+
this.type = "FieldSearchBox";
|
|
10
|
+
let obj;
|
|
11
|
+
if (typeof param === 'string') {
|
|
12
|
+
obj = utility_1.ToolHelper.convertToJsonOrDefault(param);
|
|
13
|
+
}
|
|
14
|
+
else {
|
|
15
|
+
obj = param;
|
|
16
|
+
}
|
|
17
|
+
if (!obj) {
|
|
18
|
+
return;
|
|
19
|
+
}
|
|
20
|
+
const keys = 'fields,defaultValue,disabled,useAnyField,customClass,customStyle,change,filterChange,clear';
|
|
21
|
+
Object.keys(obj).forEach(key => {
|
|
22
|
+
if (!keys.includes(key)) {
|
|
23
|
+
return;
|
|
24
|
+
}
|
|
25
|
+
switch (key) {
|
|
26
|
+
case "fields":
|
|
27
|
+
this.fields = [];
|
|
28
|
+
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
29
|
+
obj[key].forEach((item) => {
|
|
30
|
+
this.fields.push(item);
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
break;
|
|
34
|
+
case "defaultValue":
|
|
35
|
+
this.defaultValue = obj[key];
|
|
36
|
+
if (obj[key] && typeof obj[key] === 'object' && Object.keys(obj[key]).length) {
|
|
37
|
+
this.serializedDefaultValue = utility_1.ToolHelper.replaceQuoteToSingle(JSON.stringify(obj[key]));
|
|
38
|
+
}
|
|
39
|
+
break;
|
|
40
|
+
case "disabled":
|
|
41
|
+
this.disabled = utility_1.ToolHelper.createBindingWithoutDefaultValue(utility_1.ToolHelper.isNullOrUndefined(obj[key]) ? false : obj[key], this.externalComponentNameSpace, this.id);
|
|
42
|
+
break;
|
|
43
|
+
case "change":
|
|
44
|
+
case "filterChange":
|
|
45
|
+
case "clear":
|
|
46
|
+
if (obj[key]) {
|
|
47
|
+
this[key] = utility_1.EventViewModelModifier.modify(obj[key], true, true, true, utility_1.JITConstant.defaultCommandParamName);
|
|
48
|
+
}
|
|
49
|
+
break;
|
|
50
|
+
default:
|
|
51
|
+
this[key] = obj[key];
|
|
52
|
+
break;
|
|
53
|
+
}
|
|
54
|
+
});
|
|
55
|
+
if (utility_1.ToolHelper.isArray(this.fields, false) && this.fields.length) {
|
|
56
|
+
this.fieldsLang = FieldSearchBox.createFieldsLangName(this.id);
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
static createFieldsLangName(id) {
|
|
60
|
+
return "fields" + utility_1.ToolHelper.replaceHengXianAndDotToXiaHuaXian(utility_1.ToolHelper.replaceSpecialCharacter(id));
|
|
61
|
+
}
|
|
62
|
+
toJSON() {
|
|
63
|
+
const result = {
|
|
64
|
+
"id": this.id,
|
|
65
|
+
"type": "FieldSearchBox",
|
|
66
|
+
"appearance": this.appearance,
|
|
67
|
+
"fields": this.fields,
|
|
68
|
+
"defaultValue": this.defaultValue,
|
|
69
|
+
"disabled": this.disabled,
|
|
70
|
+
"useAnyField": this.useAnyField,
|
|
71
|
+
"customClass": this.customClass,
|
|
72
|
+
"customStyle": this.customStyle,
|
|
73
|
+
"change": this.change,
|
|
74
|
+
"filterChange": this.filterChange,
|
|
75
|
+
"clear": this.clear,
|
|
76
|
+
"visible": this.visible
|
|
77
|
+
};
|
|
78
|
+
return result;
|
|
79
|
+
}
|
|
80
|
+
toString() {
|
|
81
|
+
return JSON.stringify(this.toJSON());
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
exports.FieldSearchBox = FieldSearchBox;
|
|
85
|
+
//# sourceMappingURL=field-search-box.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"field-search-box.js","sourceRoot":"","sources":["../../../../src/domstructure/ui/field-search-box/field-search-box.ts"],"names":[],"mappings":";;;AAAA,8CAAmF;AACnF,sCAAmD;AAQnD,MAAa,cAAe,SAAQ,sBAAa;IA0B7C,YAAY,KAAmB;QAC3B,KAAK,CAAC,KAAK,CAAC,CAAC;QA1BjB,SAAI,GAAG,gBAAgB,CAAC;QA2BpB,IAAI,GAAQ,CAAC;QACb,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;YAC3B,GAAG,GAAG,oBAAU,CAAC,sBAAsB,CAAC,KAAK,CAAC,CAAC;SAClD;aAAM;YACH,GAAG,GAAG,KAAK,CAAC;SACf;QAED,IAAI,CAAC,GAAG,EAAE;YACN,OAAO;SACV;QAED,MAAM,IAAI,GAAG,4FAA4F,CAAC;QAC1G,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CA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AAC;IAED,QAAQ;QACJ,OAAO,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC;IACzC,CAAC;CACJ;AAnHD,wCAmHC"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./field-search-box"), exports);
|
|
14
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/domstructure/ui/field-search-box/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,qDAAmC"}
|
|
@@ -32,6 +32,7 @@ __exportStar(require("./view-change"), exports);
|
|
|
32
32
|
__exportStar(require("./farris-avatar"), exports);
|
|
33
33
|
__exportStar(require("./list-filter"), exports);
|
|
34
34
|
__exportStar(require("./light-listfilter"), exports);
|
|
35
|
+
__exportStar(require("./field-search-box"), exports);
|
|
35
36
|
__exportStar(require("./farris-calendar"), exports);
|
|
36
37
|
__exportStar(require("./farris-scrollspy"), exports);
|
|
37
38
|
__exportStar(require("./farris-dynamic-control-group"), exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/domstructure/ui/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,6CAA2B;AAC3B,2CAAyB;AACzB,8CAA4B;AAC5B,yCAAuB;AACvB,8CAA4B;AAC5B,yCAAuB;AACvB,wCAAsB;AACtB,sDAAoC;AACpC,4CAA0B;AAC1B,0CAAwB;AACxB,uDAAqC;AACrC,gDAA8B;AAC9B,2CAAyB;AACzB,+CAA6B;AAC7B,6CAA2B;AAC3B,mDAAiC;AACjC,6CAA2B;AAC3B,iDAA+B;AAC/B,gDAA8B;AAC9B,kDAAgC;AAChC,gDAA8B;AAC9B,qDAAmC;AACnC,oDAAkC;AAClC,qDAAmC;AACnC,iEAA+C;AAC/C,wDAAsC;AACtC,uDAAqC;AACrC,iDAA+B;AAC/B,gDAA8B;AAC9B,+CAA6B;AAC7B,4CAA0B;AAC1B,yCAAuB;AACvB,4CAA0B;AAC1B,qDAAmC;AACnC,2CAAyB;AACzB,iDAA+B;AAC/B,iDAA+B;AAC/B,gDAA8B;AAC9B,8DAA4C;AAC5C,0CAAwB;AACxB,yDAAuC;AACvC,4CAA0B;AAC1B,0DAAwC;AACxC,gDAA8B;AAC9B,wDAAsC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/domstructure/ui/index.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,6CAA2B;AAC3B,2CAAyB;AACzB,8CAA4B;AAC5B,yCAAuB;AACvB,8CAA4B;AAC5B,yCAAuB;AACvB,wCAAsB;AACtB,sDAAoC;AACpC,4CAA0B;AAC1B,0CAAwB;AACxB,uDAAqC;AACrC,gDAA8B;AAC9B,2CAAyB;AACzB,+CAA6B;AAC7B,6CAA2B;AAC3B,mDAAiC;AACjC,6CAA2B;AAC3B,iDAA+B;AAC/B,gDAA8B;AAC9B,kDAAgC;AAChC,gDAA8B;AAC9B,qDAAmC;AACnC,qDAAmC;AACnC,oDAAkC;AAClC,qDAAmC;AACnC,iEAA+C;AAC/C,wDAAsC;AACtC,uDAAqC;AACrC,iDAA+B;AAC/B,gDAA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