@kontur.candy/generator 4.241.0-lazy-loading.5 → 4.241.0-server-norm.10
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/dist/index.js +72 -436
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -112701,14 +112701,6 @@ class AbsoluteModelFieldPath {
|
|
|
112701
112701
|
return new AbsoluteModelFieldPath(AbsoluteModelPath.createAbsoluteFromMask(pathWithFieldName.replace(".$warningCount", ""), multiplicitySymbol), "$warningCount");
|
|
112702
112702
|
}
|
|
112703
112703
|
|
|
112704
|
-
if (pathWithFieldName.endsWith(".errorsCount")) {
|
|
112705
|
-
return new AbsoluteModelFieldPath(AbsoluteModelPath.createAbsoluteFromMask(pathWithFieldName.replace(".errorsCount", ""), multiplicitySymbol), "errorsCount");
|
|
112706
|
-
}
|
|
112707
|
-
|
|
112708
|
-
if (pathWithFieldName.endsWith(".warningsCount")) {
|
|
112709
|
-
return new AbsoluteModelFieldPath(AbsoluteModelPath.createAbsoluteFromMask(pathWithFieldName.replace(".warningsCount", ""), multiplicitySymbol), "warningsCount");
|
|
112710
|
-
}
|
|
112711
|
-
|
|
112712
112704
|
return new AbsoluteModelFieldPath(AbsoluteModelPath.createAbsoluteFromMask(pathWithFieldName, multiplicitySymbol), "value");
|
|
112713
112705
|
}
|
|
112714
112706
|
|
|
@@ -113086,7 +113078,7 @@ class ModelPath {
|
|
|
113086
113078
|
}
|
|
113087
113079
|
|
|
113088
113080
|
let instanceCounter = 0;
|
|
113089
|
-
const result = ModelPath.builder(
|
|
113081
|
+
const result = ModelPath.builder();
|
|
113090
113082
|
|
|
113091
113083
|
for (const token of this.getPathParts()) {
|
|
113092
113084
|
if (PathTokens.isMultiToken(token) && instanceCounter < instances.length) {
|
|
@@ -123366,11 +123358,9 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
123366
123358
|
|
|
123367
123359
|
|
|
123368
123360
|
class FormSchemaRngAttribute {
|
|
123369
|
-
constructor(name, description, type, optional, parent
|
|
123361
|
+
constructor(name, description, type, optional, parent) {
|
|
123370
123362
|
this.name = void 0;
|
|
123371
123363
|
this.optional = void 0;
|
|
123372
|
-
this.lazyLoadMode = void 0;
|
|
123373
|
-
this.lazyLoadAggregations = void 0;
|
|
123374
123364
|
this.type = void 0;
|
|
123375
123365
|
this.description = void 0;
|
|
123376
123366
|
this.parent = void 0;
|
|
@@ -123379,8 +123369,6 @@ class FormSchemaRngAttribute {
|
|
|
123379
123369
|
this.type = type;
|
|
123380
123370
|
this.name = name;
|
|
123381
123371
|
this.parent = parent;
|
|
123382
|
-
this.lazyLoadMode = lazyLoadMode;
|
|
123383
|
-
this.lazyLoadAggregations = lazyLoadAggregations;
|
|
123384
123372
|
}
|
|
123385
123373
|
|
|
123386
123374
|
// @ts-ignore
|
|
@@ -123392,14 +123380,10 @@ class FormSchemaRngAttribute {
|
|
|
123392
123380
|
}
|
|
123393
123381
|
const RootParent = Symbol.for("__ROOT_ELEMENT_PARENT__");
|
|
123394
123382
|
class FormSchemaRngElement {
|
|
123395
|
-
constructor(name, parent, optional, multiple
|
|
123383
|
+
constructor(name, parent, optional, multiple) {
|
|
123396
123384
|
this.name = void 0;
|
|
123397
123385
|
this.optional = void 0;
|
|
123398
123386
|
this.multiple = void 0;
|
|
123399
|
-
this.lazyLoadMode = void 0;
|
|
123400
|
-
this.lazyLoadAggregations = void 0;
|
|
123401
|
-
this.errorAndWarningCountRequired = void 0;
|
|
123402
|
-
this.lazyLoadingThreshold = void 0;
|
|
123403
123387
|
this.innerTextType = void 0;
|
|
123404
123388
|
this.children = new Map();
|
|
123405
123389
|
this.attributes = new Map();
|
|
@@ -123408,10 +123392,6 @@ class FormSchemaRngElement {
|
|
|
123408
123392
|
this.parent = parent;
|
|
123409
123393
|
this.multiple = multiple;
|
|
123410
123394
|
this.optional = optional;
|
|
123411
|
-
this.lazyLoadMode = lazyLoadMode;
|
|
123412
|
-
this.lazyLoadAggregations = lazyLoadAggregations;
|
|
123413
|
-
this.errorAndWarningCountRequired = errorAndWarningCountRequired;
|
|
123414
|
-
this.lazyLoadingThreshold = lazyLoadingThreshold;
|
|
123415
123395
|
}
|
|
123416
123396
|
|
|
123417
123397
|
addElement(element) {
|
|
@@ -123432,14 +123412,6 @@ class FormSchemaRngElement {
|
|
|
123432
123412
|
return (_this$children$get = this.children.get(name)) !== null && _this$children$get !== void 0 ? _this$children$get : this.attributes.get(name);
|
|
123433
123413
|
}
|
|
123434
123414
|
|
|
123435
|
-
getChildren() {
|
|
123436
|
-
return this.children;
|
|
123437
|
-
}
|
|
123438
|
-
|
|
123439
|
-
getAttributes() {
|
|
123440
|
-
return this.attributes;
|
|
123441
|
-
}
|
|
123442
|
-
|
|
123443
123415
|
// @ts-ignore
|
|
123444
123416
|
__reactstandin__regenerateByEval(key, code) {
|
|
123445
123417
|
// @ts-ignore
|
|
@@ -123464,7 +123436,7 @@ class FormSchemaRng {
|
|
|
123464
123436
|
}
|
|
123465
123437
|
|
|
123466
123438
|
static convertSchemaRngElement(schemaRngElement, parent) {
|
|
123467
|
-
const result = new FormSchemaRngElement(schemaRngElement.name, parent, schemaRngElement.optional, schemaRngElement.multiple
|
|
123439
|
+
const result = new FormSchemaRngElement(schemaRngElement.name, parent, schemaRngElement.optional, schemaRngElement.multiple);
|
|
123468
123440
|
|
|
123469
123441
|
if (schemaRngElement.innerText != undefined) {
|
|
123470
123442
|
if (schemaRngElement.innerText.type != undefined) {
|
|
@@ -123543,7 +123515,7 @@ class FormSchemaRng {
|
|
|
123543
123515
|
}
|
|
123544
123516
|
|
|
123545
123517
|
static convertSchemaRngAttribute(attribute, parent) {
|
|
123546
|
-
return new FormSchemaRngAttribute(attribute.name, attribute.description, this.buildTypeInfo(attribute.type), attribute.optional, parent
|
|
123518
|
+
return new FormSchemaRngAttribute(attribute.name, attribute.description, this.buildTypeInfo(attribute.type), attribute.optional, parent);
|
|
123547
123519
|
}
|
|
123548
123520
|
|
|
123549
123521
|
adjustPathMultiplicity(path) {
|
|
@@ -123575,10 +123547,6 @@ class FormSchemaRng {
|
|
|
123575
123547
|
return result.toPath().toAbsolute();
|
|
123576
123548
|
}
|
|
123577
123549
|
|
|
123578
|
-
getRootElement() {
|
|
123579
|
-
return this.rootElement;
|
|
123580
|
-
}
|
|
123581
|
-
|
|
123582
123550
|
getElementByPath(path) {
|
|
123583
123551
|
let expectMultipleElement = false;
|
|
123584
123552
|
let currentElement;
|
|
@@ -123935,7 +123903,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
123935
123903
|
/* harmony export */ });
|
|
123936
123904
|
/* harmony import */ var _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../../generators/markupGenerator/Serializer/SugarSerializer */ "./Generator/src/generators/markupGenerator/Serializer/SugarSerializer.ts");
|
|
123937
123905
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
123938
|
-
var _dec, _dec2, _class, _class2, _descriptor, _dec3, _dec4, _class4, _class5, _descriptor2, _dec5, _dec6, _class7, _class8, _descriptor3, _dec7, _dec8, _class10, _class11, _descriptor4, _dec9, _dec10, _class13, _class14, _descriptor5, _dec11, _dec12, _class16, _class17, _descriptor6, _dec13, _dec14, _class19, _class20, _descriptor7, _dec15, _dec16, _class22, _class23, _descriptor8, _dec17, _dec18, _class25, _class26, _descriptor9, _dec19, _dec20, _class28, _class29, _descriptor10, _dec21, _dec22, _dec23, _dec24, _dec25, _class31, _class32, _descriptor11, _descriptor12, _descriptor13, _descriptor14, _dec26, _dec27, _dec28, _dec29, _dec30,
|
|
123906
|
+
var _dec, _dec2, _class, _class2, _descriptor, _dec3, _dec4, _class4, _class5, _descriptor2, _dec5, _dec6, _class7, _class8, _descriptor3, _dec7, _dec8, _class10, _class11, _descriptor4, _dec9, _dec10, _class13, _class14, _descriptor5, _dec11, _dec12, _class16, _class17, _descriptor6, _dec13, _dec14, _class19, _class20, _descriptor7, _dec15, _dec16, _class22, _class23, _descriptor8, _dec17, _dec18, _class25, _class26, _descriptor9, _dec19, _dec20, _class28, _class29, _descriptor10, _dec21, _dec22, _dec23, _dec24, _dec25, _class31, _class32, _descriptor11, _descriptor12, _descriptor13, _descriptor14, _dec26, _dec27, _dec28, _dec29, _dec30, _class34, _class35, _descriptor15, _descriptor16, _descriptor17, _descriptor18, _dec31, _dec32, _class37, _class38, _descriptor19, _dec33, _dec34, _class40, _class41, _descriptor20, _dec35, _dec36, _dec37, _dec38, _dec39, _dec40, _dec41, _dec42, _dec43, _class43, _class44, _descriptor21, _descriptor22, _descriptor23, _descriptor24, _descriptor25, _descriptor26, _descriptor27, _descriptor28;
|
|
123939
123907
|
|
|
123940
123908
|
(function () {
|
|
123941
123909
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -124184,7 +124152,7 @@ let SchemaRngType = (_dec21 = (0,_generators_markupGenerator_Serializer_SugarSer
|
|
|
124184
124152
|
writable: true,
|
|
124185
124153
|
initializer: null
|
|
124186
124154
|
})), _class32)) || _class31);
|
|
124187
|
-
let SchemaRngAttribute = (_dec26 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.sugarNode)("attribute", ``), _dec27 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("name", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.string, ``), _dec28 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.singleChild)("type", [SchemaRngType]), _dec29 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("optional", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.boolean, ``), _dec30 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("description", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.string, ``),
|
|
124155
|
+
let SchemaRngAttribute = (_dec26 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.sugarNode)("attribute", ``), _dec27 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("name", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.string, ``), _dec28 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.singleChild)("type", [SchemaRngType]), _dec29 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("optional", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.boolean, ``), _dec30 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("description", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.string, ``), _dec26(_class34 = (_class35 = class SchemaRngAttribute extends _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.SugarNodeBase {
|
|
124188
124156
|
constructor(...args) {
|
|
124189
124157
|
super(...args);
|
|
124190
124158
|
|
|
@@ -124195,10 +124163,6 @@ let SchemaRngAttribute = (_dec26 = (0,_generators_markupGenerator_Serializer_Sug
|
|
|
124195
124163
|
_initializerDefineProperty(this, "optional", _descriptor17, this);
|
|
124196
124164
|
|
|
124197
124165
|
_initializerDefineProperty(this, "description", _descriptor18, this);
|
|
124198
|
-
|
|
124199
|
-
_initializerDefineProperty(this, "lazyLoadAggregations", _descriptor19, this);
|
|
124200
|
-
|
|
124201
|
-
_initializerDefineProperty(this, "lazyLoadMode", _descriptor20, this);
|
|
124202
124166
|
}
|
|
124203
124167
|
|
|
124204
124168
|
// @ts-ignore
|
|
@@ -124227,22 +124191,12 @@ let SchemaRngAttribute = (_dec26 = (0,_generators_markupGenerator_Serializer_Sug
|
|
|
124227
124191
|
enumerable: true,
|
|
124228
124192
|
writable: true,
|
|
124229
124193
|
initializer: null
|
|
124230
|
-
}), _descriptor19 = _applyDecoratedDescriptor(_class35.prototype, "lazyLoadAggregations", [_dec31], {
|
|
124231
|
-
configurable: true,
|
|
124232
|
-
enumerable: true,
|
|
124233
|
-
writable: true,
|
|
124234
|
-
initializer: null
|
|
124235
|
-
}), _descriptor20 = _applyDecoratedDescriptor(_class35.prototype, "lazyLoadMode", [_dec32], {
|
|
124236
|
-
configurable: true,
|
|
124237
|
-
enumerable: true,
|
|
124238
|
-
writable: true,
|
|
124239
|
-
initializer: null
|
|
124240
124194
|
})), _class35)) || _class34);
|
|
124241
|
-
let SchemaRngInnerText = (
|
|
124195
|
+
let SchemaRngInnerText = (_dec31 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.sugarNode)("innertext", ``), _dec32 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.singleChild)("type", [SchemaRngType]), _dec31(_class37 = (_class38 = class SchemaRngInnerText extends _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.SugarNodeBase {
|
|
124242
124196
|
constructor(...args) {
|
|
124243
124197
|
super(...args);
|
|
124244
124198
|
|
|
124245
|
-
_initializerDefineProperty(this, "type",
|
|
124199
|
+
_initializerDefineProperty(this, "type", _descriptor19, this);
|
|
124246
124200
|
}
|
|
124247
124201
|
|
|
124248
124202
|
// @ts-ignore
|
|
@@ -124251,17 +124205,17 @@ let SchemaRngInnerText = (_dec33 = (0,_generators_markupGenerator_Serializer_Sug
|
|
|
124251
124205
|
this[key] = eval(code);
|
|
124252
124206
|
}
|
|
124253
124207
|
|
|
124254
|
-
}, (
|
|
124208
|
+
}, (_descriptor19 = _applyDecoratedDescriptor(_class38.prototype, "type", [_dec32], {
|
|
124255
124209
|
configurable: true,
|
|
124256
124210
|
enumerable: true,
|
|
124257
124211
|
writable: true,
|
|
124258
124212
|
initializer: null
|
|
124259
124213
|
})), _class38)) || _class37);
|
|
124260
|
-
let SchemaRngElementChoiceElement = (
|
|
124214
|
+
let SchemaRngElementChoiceElement = (_dec33 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.sugarNode)("choice", ``), _dec34 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.children)("element"), _dec33(_class40 = (_class41 = class SchemaRngElementChoiceElement extends _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.SugarNodeBase {
|
|
124261
124215
|
constructor(...args) {
|
|
124262
124216
|
super(...args);
|
|
124263
124217
|
|
|
124264
|
-
_initializerDefineProperty(this, "children",
|
|
124218
|
+
_initializerDefineProperty(this, "children", _descriptor20, this);
|
|
124265
124219
|
}
|
|
124266
124220
|
|
|
124267
124221
|
// @ts-ignore
|
|
@@ -124270,39 +124224,31 @@ let SchemaRngElementChoiceElement = (_dec35 = (0,_generators_markupGenerator_Ser
|
|
|
124270
124224
|
this[key] = eval(code);
|
|
124271
124225
|
}
|
|
124272
124226
|
|
|
124273
|
-
}, (
|
|
124227
|
+
}, (_descriptor20 = _applyDecoratedDescriptor(_class41.prototype, "children", [_dec34], {
|
|
124274
124228
|
configurable: true,
|
|
124275
124229
|
enumerable: true,
|
|
124276
124230
|
writable: true,
|
|
124277
124231
|
initializer: null
|
|
124278
124232
|
})), _class41)) || _class40);
|
|
124279
|
-
let SchemaRngElement = (
|
|
124233
|
+
let SchemaRngElement = (_dec35 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.sugarNode)("element", ``), _dec36 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("name", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.string.required, ``), _dec37 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("description", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.string, ``), _dec38 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("optional", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.boolean, ``), _dec39 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("multiple", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.boolean, ``), _dec40 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.children)("attribute", [SchemaRngAttribute]), _dec41 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.children)("element"), _dec42 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.children)("choice"), _dec43 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.singleChild)("innertext", [SchemaRngInnerText]), _dec35(_class43 = (_class44 = class SchemaRngElement extends _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.SugarNodeBase {
|
|
124280
124234
|
constructor(...args) {
|
|
124281
124235
|
super(...args);
|
|
124282
124236
|
|
|
124283
|
-
_initializerDefineProperty(this, "name",
|
|
124284
|
-
|
|
124285
|
-
_initializerDefineProperty(this, "description", _descriptor24, this);
|
|
124286
|
-
|
|
124287
|
-
_initializerDefineProperty(this, "optional", _descriptor25, this);
|
|
124288
|
-
|
|
124289
|
-
_initializerDefineProperty(this, "multiple", _descriptor26, this);
|
|
124290
|
-
|
|
124291
|
-
_initializerDefineProperty(this, "attributes", _descriptor27, this);
|
|
124237
|
+
_initializerDefineProperty(this, "name", _descriptor21, this);
|
|
124292
124238
|
|
|
124293
|
-
_initializerDefineProperty(this, "
|
|
124239
|
+
_initializerDefineProperty(this, "description", _descriptor22, this);
|
|
124294
124240
|
|
|
124295
|
-
_initializerDefineProperty(this, "
|
|
124241
|
+
_initializerDefineProperty(this, "optional", _descriptor23, this);
|
|
124296
124242
|
|
|
124297
|
-
_initializerDefineProperty(this, "
|
|
124243
|
+
_initializerDefineProperty(this, "multiple", _descriptor24, this);
|
|
124298
124244
|
|
|
124299
|
-
_initializerDefineProperty(this, "
|
|
124245
|
+
_initializerDefineProperty(this, "attributes", _descriptor25, this);
|
|
124300
124246
|
|
|
124301
|
-
_initializerDefineProperty(this, "
|
|
124247
|
+
_initializerDefineProperty(this, "children", _descriptor26, this);
|
|
124302
124248
|
|
|
124303
|
-
_initializerDefineProperty(this, "
|
|
124249
|
+
_initializerDefineProperty(this, "choices", _descriptor27, this);
|
|
124304
124250
|
|
|
124305
|
-
_initializerDefineProperty(this, "
|
|
124251
|
+
_initializerDefineProperty(this, "innerText", _descriptor28, this);
|
|
124306
124252
|
}
|
|
124307
124253
|
|
|
124308
124254
|
// @ts-ignore
|
|
@@ -124311,62 +124257,42 @@ let SchemaRngElement = (_dec37 = (0,_generators_markupGenerator_Serializer_Sugar
|
|
|
124311
124257
|
this[key] = eval(code);
|
|
124312
124258
|
}
|
|
124313
124259
|
|
|
124314
|
-
}, (
|
|
124315
|
-
configurable: true,
|
|
124316
|
-
enumerable: true,
|
|
124317
|
-
writable: true,
|
|
124318
|
-
initializer: null
|
|
124319
|
-
}), _descriptor24 = _applyDecoratedDescriptor(_class44.prototype, "description", [_dec39], {
|
|
124320
|
-
configurable: true,
|
|
124321
|
-
enumerable: true,
|
|
124322
|
-
writable: true,
|
|
124323
|
-
initializer: null
|
|
124324
|
-
}), _descriptor25 = _applyDecoratedDescriptor(_class44.prototype, "optional", [_dec40], {
|
|
124325
|
-
configurable: true,
|
|
124326
|
-
enumerable: true,
|
|
124327
|
-
writable: true,
|
|
124328
|
-
initializer: null
|
|
124329
|
-
}), _descriptor26 = _applyDecoratedDescriptor(_class44.prototype, "multiple", [_dec41], {
|
|
124260
|
+
}, (_descriptor21 = _applyDecoratedDescriptor(_class44.prototype, "name", [_dec36], {
|
|
124330
124261
|
configurable: true,
|
|
124331
124262
|
enumerable: true,
|
|
124332
124263
|
writable: true,
|
|
124333
124264
|
initializer: null
|
|
124334
|
-
}),
|
|
124265
|
+
}), _descriptor22 = _applyDecoratedDescriptor(_class44.prototype, "description", [_dec37], {
|
|
124335
124266
|
configurable: true,
|
|
124336
124267
|
enumerable: true,
|
|
124337
124268
|
writable: true,
|
|
124338
124269
|
initializer: null
|
|
124339
|
-
}),
|
|
124270
|
+
}), _descriptor23 = _applyDecoratedDescriptor(_class44.prototype, "optional", [_dec38], {
|
|
124340
124271
|
configurable: true,
|
|
124341
124272
|
enumerable: true,
|
|
124342
124273
|
writable: true,
|
|
124343
124274
|
initializer: null
|
|
124344
|
-
}),
|
|
124275
|
+
}), _descriptor24 = _applyDecoratedDescriptor(_class44.prototype, "multiple", [_dec39], {
|
|
124345
124276
|
configurable: true,
|
|
124346
124277
|
enumerable: true,
|
|
124347
124278
|
writable: true,
|
|
124348
124279
|
initializer: null
|
|
124349
|
-
}),
|
|
124280
|
+
}), _descriptor25 = _applyDecoratedDescriptor(_class44.prototype, "attributes", [_dec40], {
|
|
124350
124281
|
configurable: true,
|
|
124351
124282
|
enumerable: true,
|
|
124352
124283
|
writable: true,
|
|
124353
124284
|
initializer: null
|
|
124354
|
-
}),
|
|
124285
|
+
}), _descriptor26 = _applyDecoratedDescriptor(_class44.prototype, "children", [_dec41], {
|
|
124355
124286
|
configurable: true,
|
|
124356
124287
|
enumerable: true,
|
|
124357
124288
|
writable: true,
|
|
124358
124289
|
initializer: null
|
|
124359
|
-
}),
|
|
124290
|
+
}), _descriptor27 = _applyDecoratedDescriptor(_class44.prototype, "choices", [_dec42], {
|
|
124360
124291
|
configurable: true,
|
|
124361
124292
|
enumerable: true,
|
|
124362
124293
|
writable: true,
|
|
124363
124294
|
initializer: null
|
|
124364
|
-
}),
|
|
124365
|
-
configurable: true,
|
|
124366
|
-
enumerable: true,
|
|
124367
|
-
writable: true,
|
|
124368
|
-
initializer: null
|
|
124369
|
-
}), _descriptor34 = _applyDecoratedDescriptor(_class44.prototype, "lazyLoadingThreshold", [_dec49], {
|
|
124295
|
+
}), _descriptor28 = _applyDecoratedDescriptor(_class44.prototype, "innerText", [_dec43], {
|
|
124370
124296
|
configurable: true,
|
|
124371
124297
|
enumerable: true,
|
|
124372
124298
|
writable: true,
|
|
@@ -131287,20 +131213,14 @@ class DataDeclarationGenerationTimeHelper {
|
|
|
131287
131213
|
this.dataDeclaration = dataDeclaration;
|
|
131288
131214
|
}
|
|
131289
131215
|
|
|
131290
|
-
isErrorsAndWarningsCountRequired(targetPath) {
|
|
131291
|
-
var _this$getDataDeclarat, _this$getDataDeclarat2, _this$getDataDeclarat3;
|
|
131292
|
-
|
|
131293
|
-
return (_this$getDataDeclarat = (_this$getDataDeclarat2 = this.getDataDeclarationEntry(targetPath)) === null || _this$getDataDeclarat2 === void 0 ? void 0 : (_this$getDataDeclarat3 = _this$getDataDeclarat2.errorAndWarningCountRequired) === null || _this$getDataDeclarat3 === void 0 ? void 0 : _this$getDataDeclarat3[0]) !== null && _this$getDataDeclarat !== void 0 ? _this$getDataDeclarat : false;
|
|
131294
|
-
}
|
|
131295
|
-
|
|
131296
131216
|
hasMask(targetPath) {
|
|
131297
131217
|
return this.getDataDeclarationEntry(targetPath) != undefined;
|
|
131298
131218
|
}
|
|
131299
131219
|
|
|
131300
131220
|
isNodeHasChildrenEntry(targetPath) {
|
|
131301
|
-
var _this$
|
|
131221
|
+
var _this$getDataDeclarat;
|
|
131302
131222
|
|
|
131303
|
-
return ((_this$
|
|
131223
|
+
return ((_this$getDataDeclarat = this.getDataDeclarationEntry(targetPath)) === null || _this$getDataDeclarat === void 0 ? void 0 : _this$getDataDeclarat.children) != undefined;
|
|
131304
131224
|
}
|
|
131305
131225
|
|
|
131306
131226
|
isNodeHasAutoFlagEntry(targetPath) {
|
|
@@ -131321,9 +131241,9 @@ class DataDeclarationGenerationTimeHelper {
|
|
|
131321
131241
|
}
|
|
131322
131242
|
|
|
131323
131243
|
isNodeOptional(targetPath) {
|
|
131324
|
-
var _this$
|
|
131244
|
+
var _this$getDataDeclarat2, _optionalValue$;
|
|
131325
131245
|
|
|
131326
|
-
const optionalValue = (_this$
|
|
131246
|
+
const optionalValue = (_this$getDataDeclarat2 = this.getDataDeclarationEntry(targetPath)) === null || _this$getDataDeclarat2 === void 0 ? void 0 : _this$getDataDeclarat2.optional;
|
|
131327
131247
|
return (_optionalValue$ = optionalValue === null || optionalValue === void 0 ? void 0 : optionalValue[0]) !== null && _optionalValue$ !== void 0 ? _optionalValue$ : false;
|
|
131328
131248
|
}
|
|
131329
131249
|
|
|
@@ -131377,9 +131297,8 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
131377
131297
|
/* harmony import */ var _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../markupGenerator/Serializer/SugarSerializer */ "./Generator/src/generators/markupGenerator/Serializer/SugarSerializer.ts");
|
|
131378
131298
|
/* harmony import */ var _markupGenerator_AllConverters__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../markupGenerator/AllConverters */ "./Generator/src/generators/markupGenerator/AllConverters.ts");
|
|
131379
131299
|
/* harmony import */ var _Common_TypingUtils__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../Common/TypingUtils */ "./Common/TypingUtils.ts");
|
|
131380
|
-
/* harmony import */ var
|
|
131381
|
-
/* harmony import */ var
|
|
131382
|
-
/* harmony import */ var _DataDeclarationGenerationContext__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./DataDeclarationGenerationContext */ "./Generator/src/generators/DataDeclarationGenerator/DataDeclarationGenerationContext.ts");
|
|
131300
|
+
/* harmony import */ var _placeholders__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./placeholders */ "./Generator/src/generators/DataDeclarationGenerator/placeholders.js");
|
|
131301
|
+
/* harmony import */ var _DataDeclarationGenerationContext__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./DataDeclarationGenerationContext */ "./Generator/src/generators/DataDeclarationGenerator/DataDeclarationGenerationContext.ts");
|
|
131383
131302
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
131384
131303
|
(function () {
|
|
131385
131304
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -131398,15 +131317,12 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
131398
131317
|
|
|
131399
131318
|
|
|
131400
131319
|
|
|
131401
|
-
|
|
131402
131320
|
class DataDeclarationGenerator {
|
|
131403
|
-
constructor(sugarRoot, initSequenceFactory, controlCustomizationContext, typesRegistry
|
|
131321
|
+
constructor(sugarRoot, initSequenceFactory, controlCustomizationContext, typesRegistry) {
|
|
131404
131322
|
this.sugarRoot = void 0;
|
|
131405
131323
|
this.initSequenceFactory = void 0;
|
|
131406
|
-
this.formSchemaRng = void 0;
|
|
131407
131324
|
this.controlCustomizationContext = void 0;
|
|
131408
131325
|
this.typesRegistry = void 0;
|
|
131409
|
-
this.formSchemaRng = formSchemaRng;
|
|
131410
131326
|
this.sugarRoot = sugarRoot;
|
|
131411
131327
|
this.initSequenceFactory = initSequenceFactory;
|
|
131412
131328
|
this.controlCustomizationContext = controlCustomizationContext;
|
|
@@ -131418,9 +131334,8 @@ class DataDeclarationGenerator {
|
|
|
131418
131334
|
|
|
131419
131335
|
const converterClass = (_getConverterByNodeCl = (0,_markupGenerator_AllConverters__WEBPACK_IMPORTED_MODULE_4__.getConverterByNodeClass)((0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_3__.getNodeClass)(this.sugarRoot))) !== null && _getConverterByNodeCl !== void 0 ? _getConverterByNodeCl : (0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_5__.reject)();
|
|
131420
131336
|
const converter = new converterClass(this.sugarRoot);
|
|
131421
|
-
const context = new
|
|
131337
|
+
const context = new _DataDeclarationGenerationContext__WEBPACK_IMPORTED_MODULE_7__.DataDeclarationGenerationContext(this.initSequenceFactory, this.controlCustomizationContext, this.typesRegistry);
|
|
131422
131338
|
const dataDeclaration = converter.buildDataDeclaration(context);
|
|
131423
|
-
this.enrichWithSchemaRng(dataDeclaration);
|
|
131424
131339
|
const orderedDataDeclaration = this.sortDataDeclarationKeys(dataDeclaration);
|
|
131425
131340
|
const result = this.replaceHolder(`
|
|
131426
131341
|
export default function dataDeclaration({
|
|
@@ -131448,27 +131363,12 @@ class DataDeclarationGenerator {
|
|
|
131448
131363
|
};
|
|
131449
131364
|
}
|
|
131450
131365
|
|
|
131451
|
-
enrichWithSchemaRng(dataDeclaration) {
|
|
131452
|
-
const elementEntries = this.formSchemaRng.getAllChildren(this.formSchemaRng.getRootElement()).filter(x => x instanceof _common_SchemaRng_FormSchemaRng__WEBPACK_IMPORTED_MODULE_6__.FormSchemaRngElement && x.errorAndWarningCountRequired).map(x => ({
|
|
131453
|
-
element: x,
|
|
131454
|
-
path: this.formSchemaRng.getPath(x)
|
|
131455
|
-
}));
|
|
131456
|
-
|
|
131457
|
-
for (const elementEntry of elementEntries) {
|
|
131458
|
-
var _dataDeclaration$lega, _elementEntry$element;
|
|
131459
|
-
|
|
131460
|
-
const legacyPath = elementEntry.path.trimLastStarIfLastToken().toLegacyPath();
|
|
131461
|
-
const declarationEntry = (_dataDeclaration$lega = dataDeclaration[legacyPath]) !== null && _dataDeclaration$lega !== void 0 ? _dataDeclaration$lega : {};
|
|
131462
|
-
declarationEntry.errorAndWarningCountRequired = [(_elementEntry$element = elementEntry.element.errorAndWarningCountRequired) !== null && _elementEntry$element !== void 0 ? _elementEntry$element : false];
|
|
131463
|
-
}
|
|
131464
|
-
}
|
|
131465
|
-
|
|
131466
131366
|
generateDataDeclarationFactory() {
|
|
131467
131367
|
var _getConverterByNodeCl2;
|
|
131468
131368
|
|
|
131469
131369
|
const converterClass = (_getConverterByNodeCl2 = (0,_markupGenerator_AllConverters__WEBPACK_IMPORTED_MODULE_4__.getConverterByNodeClass)((0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_3__.getNodeClass)(this.sugarRoot))) !== null && _getConverterByNodeCl2 !== void 0 ? _getConverterByNodeCl2 : (0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_5__.reject)();
|
|
131470
131370
|
const converter = new converterClass(this.sugarRoot);
|
|
131471
|
-
const context = new
|
|
131371
|
+
const context = new _DataDeclarationGenerationContext__WEBPACK_IMPORTED_MODULE_7__.DataDeclarationGenerationContext(this.initSequenceFactory, this.controlCustomizationContext, this.typesRegistry);
|
|
131472
131372
|
const dataDeclaration = converter.buildDataDeclaration(context);
|
|
131473
131373
|
const orderedDataDeclaration = this.sortDataDeclarationKeys(dataDeclaration);
|
|
131474
131374
|
return `
|
|
@@ -131507,7 +131407,7 @@ class DataDeclarationGenerator {
|
|
|
131507
131407
|
replaceHolder(decl) {
|
|
131508
131408
|
let replacedDecl = decl;
|
|
131509
131409
|
|
|
131510
|
-
for (const [placeholderName, placeHoldersFunction] of (0,_Common_IterableUtils__WEBPACK_IMPORTED_MODULE_1__.iterateEntries)(
|
|
131410
|
+
for (const [placeholderName, placeHoldersFunction] of (0,_Common_IterableUtils__WEBPACK_IMPORTED_MODULE_1__.iterateEntries)(_placeholders__WEBPACK_IMPORTED_MODULE_6__.placeHolders)) {
|
|
131511
131411
|
const checkName = `"#(${placeholderName})(\\('[\\w]*'\\))?#"`;
|
|
131512
131412
|
const include = new RegExp(checkName, "i");
|
|
131513
131413
|
|
|
@@ -132444,8 +132344,7 @@ function getWebEntry(gfv, resourcesHash) {
|
|
|
132444
132344
|
localizationDictionary,
|
|
132445
132345
|
autocalculationConfigurators,
|
|
132446
132346
|
kcXmlValidationConfigurator,
|
|
132447
|
-
kcXmlAutoCalculationConfigurator
|
|
132448
|
-
lazyLoadDeclaration
|
|
132347
|
+
kcXmlAutoCalculationConfigurator
|
|
132449
132348
|
} from './resources'
|
|
132450
132349
|
import { Form } from './components'
|
|
132451
132350
|
|
|
@@ -132456,7 +132355,6 @@ window.CF.entryPoint = window.CF.entryPoint || {};
|
|
|
132456
132355
|
window.CF.entryPoint[gfv] = function(container, { renderForm, ...settings }) {
|
|
132457
132356
|
const resources = {
|
|
132458
132357
|
dataDeclaration: dataDeclaration,
|
|
132459
|
-
lazyLoadDeclaration: lazyLoadDeclaration,
|
|
132460
132358
|
calculationFunctions: calculationFunctions,
|
|
132461
132359
|
validationFunctions: validationFunctions,
|
|
132462
132360
|
requisiteList: requisiteList,
|
|
@@ -132821,7 +132719,7 @@ class KCXmlGeneratorBase {
|
|
|
132821
132719
|
const gcf = (selector, ...args) => this.getCompiledFuncWithArgs(selector, args);
|
|
132822
132720
|
|
|
132823
132721
|
if (expression instanceof _AutoCalculationsGenerator_AutoCalculationsFromFormulas_KCXmlContract_Formula__WEBPACK_IMPORTED_MODULE_1__.FormulaArgumentExpression || expression instanceof _AutoCalculationsGenerator_AutoCalculationsFromFormulas_KCXmlContract_Formula__WEBPACK_IMPORTED_MODULE_1__.FormulaMultySumExpression) {
|
|
132824
|
-
const modelPath = this.schema.adjustPathMultiplicity(prefix.joinWith(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.
|
|
132722
|
+
const modelPath = this.schema.adjustPathMultiplicity(prefix.joinWith(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.removeAttributePrefix(expression.select), false, _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.PathTokens.each)).normalize());
|
|
132825
132723
|
const argumentDependency = this.getArgumentDeps(targetFullPath, modelPath, "Sum");
|
|
132826
132724
|
deps.push(argumentDependency);
|
|
132827
132725
|
const finalPath = argumentDependency instanceof _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath ? argumentDependency : argumentDependency.modelPath;
|
|
@@ -132829,13 +132727,13 @@ class KCXmlGeneratorBase {
|
|
|
132829
132727
|
}
|
|
132830
132728
|
|
|
132831
132729
|
if (expression instanceof _AutoCalculationsGenerator_AutoCalculationsFromFormulas_KCXmlContract_Formula__WEBPACK_IMPORTED_MODULE_1__.FormulaExistsExpression) {
|
|
132832
|
-
const modelPath = this.schema.adjustPathMultiplicity(prefix.joinWith(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.removeAttributePrefix(
|
|
132730
|
+
const modelPath = this.schema.adjustPathMultiplicity(prefix.joinWith(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.removeAttributePrefix(expression.select), false, _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.PathTokens.each)).normalize());
|
|
132833
132731
|
deps.push(modelPath);
|
|
132834
132732
|
return gcf(x => x.exists, `"${modelPath.toLegacyPath()}"`);
|
|
132835
132733
|
}
|
|
132836
132734
|
|
|
132837
132735
|
if (expression instanceof _AutoCalculationsGenerator_AutoCalculationsFromFormulas_KCXmlContract_Formula__WEBPACK_IMPORTED_MODULE_1__.FormulaCountExpression) {
|
|
132838
|
-
const modelPath = this.schema.adjustPathMultiplicity(prefix.joinWith(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.removeAttributePrefix(
|
|
132736
|
+
const modelPath = this.schema.adjustPathMultiplicity(prefix.joinWith(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.removeAttributePrefix(expression.select), false, _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.PathTokens.each)).normalize());
|
|
132839
132737
|
const argumentDependency = this.getArgumentDeps(targetFullPath, modelPath, "Count");
|
|
132840
132738
|
deps.push(argumentDependency);
|
|
132841
132739
|
const finalPath = argumentDependency instanceof _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath ? argumentDependency : argumentDependency.modelPath;
|
|
@@ -132959,10 +132857,6 @@ class KCXmlGeneratorBase {
|
|
|
132959
132857
|
return pathPart.replace(/\@/g, "");
|
|
132960
132858
|
}
|
|
132961
132859
|
|
|
132962
|
-
removeMultiplicity(path) {
|
|
132963
|
-
return path.replace(/\/\*/g, "");
|
|
132964
|
-
}
|
|
132965
|
-
|
|
132966
132860
|
modelPathInstance(target) {
|
|
132967
132861
|
return `new ModelPath([${[...target.getPathParts()].map(x => {
|
|
132968
132862
|
if (x === _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.PathTokens.each) {
|
|
@@ -133053,8 +132947,8 @@ class KCXmlValidationGenerator extends _KCXmlGenerator_KCXmlGeneratorBase__WEBPA
|
|
|
133053
132947
|
compileCondition(condition) {
|
|
133054
132948
|
var _condition$descriptio, _condition$errorLevel;
|
|
133055
132949
|
|
|
133056
|
-
const prefix = _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.
|
|
133057
|
-
const target = this.schema.adjustPathMultiplicity(prefix.joinWith(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.
|
|
132950
|
+
const prefix = _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.removeAttributePrefix(condition.match), true, _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.PathTokens.each).toAbsolute();
|
|
132951
|
+
const target = this.schema.adjustPathMultiplicity(prefix.joinWith(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.ModelPath.createFromMask(this.removeAttributePrefix(condition.target), false, _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.PathTokens.each)).normalize());
|
|
133058
132952
|
const deps = [];
|
|
133059
132953
|
const compiledExpression = this.compileExpression(prefix, target, condition.expression, deps);
|
|
133060
132954
|
const compiledTarget = this.modelPathInstance(target);
|
|
@@ -133093,180 +132987,6 @@ class KCXmlValidationGenerator extends _KCXmlGenerator_KCXmlGeneratorBase__WEBPA
|
|
|
133093
132987
|
|
|
133094
132988
|
/***/ }),
|
|
133095
132989
|
|
|
133096
|
-
/***/ "./Generator/src/generators/LazyLoadDeclarationGenerator/LazyLoadDeclarationGenerator.ts":
|
|
133097
|
-
/*!***********************************************************************************************!*\
|
|
133098
|
-
!*** ./Generator/src/generators/LazyLoadDeclarationGenerator/LazyLoadDeclarationGenerator.ts ***!
|
|
133099
|
-
\***********************************************************************************************/
|
|
133100
|
-
/***/ ((module, __webpack_exports__, __webpack_require__) => {
|
|
133101
|
-
|
|
133102
|
-
"use strict";
|
|
133103
|
-
__webpack_require__.r(__webpack_exports__);
|
|
133104
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
133105
|
-
/* harmony export */ "LazyLoadDeclarationGenerator": () => (/* binding */ LazyLoadDeclarationGenerator)
|
|
133106
|
-
/* harmony export */ });
|
|
133107
|
-
/* harmony import */ var serialize_javascript__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! serialize-javascript */ "./node_modules/serialize-javascript/index.js");
|
|
133108
|
-
/* harmony import */ var serialize_javascript__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(serialize_javascript__WEBPACK_IMPORTED_MODULE_0__);
|
|
133109
|
-
/* harmony import */ var _Common_IterableUtils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../Common/IterableUtils */ "./Common/IterableUtils.ts");
|
|
133110
|
-
/* harmony import */ var _DataDeclarationGenerator_placeholders__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../DataDeclarationGenerator/placeholders */ "./Generator/src/generators/DataDeclarationGenerator/placeholders.js");
|
|
133111
|
-
/* harmony import */ var _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../../Common/ModelPath/ModelPath */ "./Common/ModelPath/ModelPath.ts");
|
|
133112
|
-
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
133113
|
-
(function () {
|
|
133114
|
-
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
133115
|
-
enterModule && enterModule(module);
|
|
133116
|
-
})();
|
|
133117
|
-
|
|
133118
|
-
var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
|
|
133119
|
-
return a;
|
|
133120
|
-
};
|
|
133121
|
-
|
|
133122
|
-
|
|
133123
|
-
|
|
133124
|
-
|
|
133125
|
-
|
|
133126
|
-
class LazyLoadDeclarationGenerator {
|
|
133127
|
-
constructor(formSchemaRng) {
|
|
133128
|
-
this.formSchemaRng = void 0;
|
|
133129
|
-
this.formSchemaRng = formSchemaRng;
|
|
133130
|
-
}
|
|
133131
|
-
|
|
133132
|
-
*processElement(path, element) {
|
|
133133
|
-
if (element.lazyLoadMode != undefined) {
|
|
133134
|
-
const currentPath = element.multiple ? path.joinWith(element.name) : path.joinWith(element.name + ".value");
|
|
133135
|
-
const item = {
|
|
133136
|
-
path: this.formSchemaRng.adjustPathMultiplicity(currentPath),
|
|
133137
|
-
lazyLoadMode: element.lazyLoadMode
|
|
133138
|
-
};
|
|
133139
|
-
yield element.lazyLoadingThreshold != undefined ? { ...item,
|
|
133140
|
-
thresholdValue: element.lazyLoadingThreshold
|
|
133141
|
-
} : item;
|
|
133142
|
-
|
|
133143
|
-
if (element.multiple) {
|
|
133144
|
-
const additionalFields = ["children", "errorsCount", "warningsCount"];
|
|
133145
|
-
const additionalItems = additionalFields.map(field => ({
|
|
133146
|
-
path: this.formSchemaRng.adjustPathMultiplicity(path.joinWith(`${element.name}.${field}`)),
|
|
133147
|
-
lazyLoadMode: "initial"
|
|
133148
|
-
}));
|
|
133149
|
-
yield* additionalItems;
|
|
133150
|
-
yield {
|
|
133151
|
-
path: this.formSchemaRng.adjustPathMultiplicity(path.joinWith(element.name).joinWith(".errorsCount")),
|
|
133152
|
-
lazyLoadMode: "initial"
|
|
133153
|
-
};
|
|
133154
|
-
yield {
|
|
133155
|
-
path: this.formSchemaRng.adjustPathMultiplicity(path.joinWith(element.name).joinWith(".warningsCount")),
|
|
133156
|
-
lazyLoadMode: "initial"
|
|
133157
|
-
};
|
|
133158
|
-
} else {
|
|
133159
|
-
yield {
|
|
133160
|
-
path: this.formSchemaRng.adjustPathMultiplicity(path.joinWith(element.name + ".errorsCount")),
|
|
133161
|
-
lazyLoadMode: "initial"
|
|
133162
|
-
};
|
|
133163
|
-
yield {
|
|
133164
|
-
path: this.formSchemaRng.adjustPathMultiplicity(path.joinWith(element.name + ".warningsCount")),
|
|
133165
|
-
lazyLoadMode: "initial"
|
|
133166
|
-
};
|
|
133167
|
-
}
|
|
133168
|
-
}
|
|
133169
|
-
|
|
133170
|
-
for (const attr of element.attributes.values()) {
|
|
133171
|
-
if (attr.lazyLoadMode != undefined) {
|
|
133172
|
-
const currentPath = path.joinWith(element.name, attr.name + ".value");
|
|
133173
|
-
yield {
|
|
133174
|
-
path: this.formSchemaRng.adjustPathMultiplicity(currentPath),
|
|
133175
|
-
lazyLoadMode: attr.lazyLoadMode
|
|
133176
|
-
};
|
|
133177
|
-
}
|
|
133178
|
-
|
|
133179
|
-
if (attr.lazyLoadMode != undefined && attr.lazyLoadAggregations) {
|
|
133180
|
-
const baseAggregationPath = this.formSchemaRng.adjustPathMultiplicity(path.joinWith(element.name)).trimLastStarIfLastToken().joinWith(attr.name);
|
|
133181
|
-
const sumPath = baseAggregationPath.joinWith("Sum.value");
|
|
133182
|
-
yield {
|
|
133183
|
-
path: sumPath,
|
|
133184
|
-
lazyLoadMode: "initial"
|
|
133185
|
-
};
|
|
133186
|
-
const countPath = baseAggregationPath.joinWith("Count.value");
|
|
133187
|
-
yield {
|
|
133188
|
-
path: countPath,
|
|
133189
|
-
lazyLoadMode: "initial"
|
|
133190
|
-
};
|
|
133191
|
-
}
|
|
133192
|
-
}
|
|
133193
|
-
|
|
133194
|
-
const nextPath = path.joinWith(element.name);
|
|
133195
|
-
|
|
133196
|
-
for (const child of element.children.values()) {
|
|
133197
|
-
yield* this.processElement(nextPath, child);
|
|
133198
|
-
}
|
|
133199
|
-
}
|
|
133200
|
-
|
|
133201
|
-
generate() {
|
|
133202
|
-
const declaration = {};
|
|
133203
|
-
const resultItems = this.processElement(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_3__.ModelPath.empty(), this.formSchemaRng.getRootElement());
|
|
133204
|
-
|
|
133205
|
-
for (const lazyLoadingNodeDeclaration of resultItems) {
|
|
133206
|
-
declaration[lazyLoadingNodeDeclaration.path.toLegacyPath()] = {
|
|
133207
|
-
lazyLoadMode: lazyLoadingNodeDeclaration.lazyLoadMode,
|
|
133208
|
-
thresholdValue: lazyLoadingNodeDeclaration.thresholdValue
|
|
133209
|
-
};
|
|
133210
|
-
}
|
|
133211
|
-
|
|
133212
|
-
const result = this.replaceHolder(`
|
|
133213
|
-
export default function lazyLoadDeclaration() {
|
|
133214
|
-
return ${serialize_javascript__WEBPACK_IMPORTED_MODULE_0___default()(declaration, {
|
|
133215
|
-
space: " "
|
|
133216
|
-
})};
|
|
133217
|
-
};`);
|
|
133218
|
-
const content = unescape(result.replace(/(\\)(u[\dA-Fa-f]{4})/g, "%$2"));
|
|
133219
|
-
return {
|
|
133220
|
-
content: content,
|
|
133221
|
-
declaration: declaration
|
|
133222
|
-
};
|
|
133223
|
-
}
|
|
133224
|
-
|
|
133225
|
-
replaceHolder(decl) {
|
|
133226
|
-
let replacedDecl = decl;
|
|
133227
|
-
|
|
133228
|
-
for (const [placeholderName, placeHoldersFunction] of (0,_Common_IterableUtils__WEBPACK_IMPORTED_MODULE_1__.iterateEntries)(_DataDeclarationGenerator_placeholders__WEBPACK_IMPORTED_MODULE_2__.placeHolders)) {
|
|
133229
|
-
const checkName = `"#(${placeholderName})(\\('[\\w]*'\\))?#"`;
|
|
133230
|
-
const include = new RegExp(checkName, "i");
|
|
133231
|
-
|
|
133232
|
-
if (include.test(replacedDecl)) {
|
|
133233
|
-
const regex = new RegExp(checkName, "g");
|
|
133234
|
-
replacedDecl = replacedDecl.replace(regex, "$1$2");
|
|
133235
|
-
replacedDecl = replacedDecl + placeHoldersFunction.toString();
|
|
133236
|
-
}
|
|
133237
|
-
}
|
|
133238
|
-
|
|
133239
|
-
return replacedDecl;
|
|
133240
|
-
}
|
|
133241
|
-
|
|
133242
|
-
// @ts-ignore
|
|
133243
|
-
__reactstandin__regenerateByEval(key, code) {
|
|
133244
|
-
// @ts-ignore
|
|
133245
|
-
this[key] = eval(code);
|
|
133246
|
-
}
|
|
133247
|
-
|
|
133248
|
-
}
|
|
133249
|
-
;
|
|
133250
|
-
|
|
133251
|
-
(function () {
|
|
133252
|
-
var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;
|
|
133253
|
-
|
|
133254
|
-
if (!reactHotLoader) {
|
|
133255
|
-
return;
|
|
133256
|
-
}
|
|
133257
|
-
|
|
133258
|
-
reactHotLoader.register(LazyLoadDeclarationGenerator, "LazyLoadDeclarationGenerator", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\LazyLoadDeclarationGenerator\\LazyLoadDeclarationGenerator.ts");
|
|
133259
|
-
})();
|
|
133260
|
-
|
|
133261
|
-
;
|
|
133262
|
-
|
|
133263
|
-
(function () {
|
|
133264
|
-
var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
|
|
133265
|
-
leaveModule && leaveModule(module);
|
|
133266
|
-
})();
|
|
133267
|
-
|
|
133268
|
-
/***/ }),
|
|
133269
|
-
|
|
133270
132990
|
/***/ "./Generator/src/generators/ProcessFormSources.ts":
|
|
133271
132991
|
/*!********************************************************!*\
|
|
133272
132992
|
!*** ./Generator/src/generators/ProcessFormSources.ts ***!
|
|
@@ -133307,7 +133027,6 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
133307
133027
|
/* harmony import */ var _DataDeclarationGenerator_DataDeclarationGenerationTimeHelper__WEBPACK_IMPORTED_MODULE_26__ = __webpack_require__(/*! ./DataDeclarationGenerator/DataDeclarationGenerationTimeHelper */ "./Generator/src/generators/DataDeclarationGenerator/DataDeclarationGenerationTimeHelper.ts");
|
|
133308
133028
|
/* harmony import */ var _AttachmentPaths_AttachmentPathsGenerator__WEBPACK_IMPORTED_MODULE_27__ = __webpack_require__(/*! ./AttachmentPaths/AttachmentPathsGenerator */ "./Generator/src/generators/AttachmentPaths/AttachmentPathsGenerator.ts");
|
|
133309
133029
|
/* harmony import */ var _AutoCalculationsGenerator_AutoCalculationsFromFormulas_Calculator2_AutoCalculationsCalculator2Generator__WEBPACK_IMPORTED_MODULE_28__ = __webpack_require__(/*! ./AutoCalculationsGenerator/AutoCalculationsFromFormulas/Calculator2/AutoCalculationsCalculator2Generator */ "./Generator/src/generators/AutoCalculationsGenerator/AutoCalculationsFromFormulas/Calculator2/AutoCalculationsCalculator2Generator.ts");
|
|
133310
|
-
/* harmony import */ var _LazyLoadDeclarationGenerator_LazyLoadDeclarationGenerator__WEBPACK_IMPORTED_MODULE_29__ = __webpack_require__(/*! ./LazyLoadDeclarationGenerator/LazyLoadDeclarationGenerator */ "./Generator/src/generators/LazyLoadDeclarationGenerator/LazyLoadDeclarationGenerator.ts");
|
|
133311
133030
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
133312
133031
|
(function () {
|
|
133313
133032
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -133345,7 +133064,6 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
133345
133064
|
|
|
133346
133065
|
|
|
133347
133066
|
|
|
133348
|
-
|
|
133349
133067
|
|
|
133350
133068
|
|
|
133351
133069
|
function processSugar(formSugarContent, additionalContent, generationOptions) {
|
|
@@ -133374,23 +133092,20 @@ function processSugar(formSugarContent, additionalContent, generationOptions) {
|
|
|
133374
133092
|
const fetchFunctions = new _common_FetchFunctions__WEBPACK_IMPORTED_MODULE_2__.FetchFunctions(referencedFetchFunctions); // tslint:disable-next-line no-unsafe-any
|
|
133375
133093
|
|
|
133376
133094
|
const additionalSettings = JSON.parse(additionalContent.additionalSettings || "{}");
|
|
133377
|
-
const dataDeclarationGenerator = new _DataDeclarationGenerator_DataDeclarationGenerator__WEBPACK_IMPORTED_MODULE_19__.DataDeclarationGenerator(sugarRoot, new _DataDeclarationGenerator_DataDeclarationInitSourceSequenceFactory__WEBPACK_IMPORTED_MODULE_20__.DataDeclarationInitSourceSequenceFactory(fetchFunctions), controlCustomizationContext, typeRegistry
|
|
133095
|
+
const dataDeclarationGenerator = new _DataDeclarationGenerator_DataDeclarationGenerator__WEBPACK_IMPORTED_MODULE_19__.DataDeclarationGenerator(sugarRoot, new _DataDeclarationGenerator_DataDeclarationInitSourceSequenceFactory__WEBPACK_IMPORTED_MODULE_20__.DataDeclarationInitSourceSequenceFactory(fetchFunctions), controlCustomizationContext, typeRegistry);
|
|
133378
133096
|
const {
|
|
133379
133097
|
dataDeclarationContent,
|
|
133380
133098
|
dataDeclaration
|
|
133381
133099
|
} = dataDeclarationGenerator.generate();
|
|
133382
133100
|
const dataDeclarationHelper = new _DataDeclarationGenerator_DataDeclarationGenerationTimeHelper__WEBPACK_IMPORTED_MODULE_26__.DataDeclarationGenerationTimeHelper(dataDeclaration);
|
|
133383
133101
|
const validationGenerator = new _validationGenerator_ValidationGenerator__WEBPACK_IMPORTED_MODULE_16__.ValidationGenerator(sugarRoot, typeRegistry, controlCustomizationContext, formSchemaRng, (_sugarRoot$schemaVali = sugarRoot.schemaValidations) !== null && _sugarRoot$schemaVali !== void 0 ? _sugarRoot$schemaVali : false, (_sugarRoot$deepOption = sugarRoot.deepOptionalSchemaValidations) !== null && _sugarRoot$deepOption !== void 0 ? _sugarRoot$deepOption : false, additionalContent.validationsContent);
|
|
133384
|
-
const
|
|
133385
|
-
const lazyLoadGeneratorResult = lazyLoadGenerator.generate();
|
|
133386
|
-
const normalizationRulesGenerator = new _ServerSideFLangNormalization_NormalizationRulesGenerator__WEBPACK_IMPORTED_MODULE_25__.NormalizationRulesGenerator(sugarRoot, dataDeclarationHelper, formSchemaRng, formulas, kcXmlConditions, typeRegistry, (_sugarRoot$schemaVali2 = sugarRoot.schemaValidations) !== null && _sugarRoot$schemaVali2 !== void 0 ? _sugarRoot$schemaVali2 : false, controlCustomizationContext, lazyLoadGeneratorResult.declaration);
|
|
133102
|
+
const normalizationRulesGenerator = new _ServerSideFLangNormalization_NormalizationRulesGenerator__WEBPACK_IMPORTED_MODULE_25__.NormalizationRulesGenerator(sugarRoot, dataDeclarationHelper, formSchemaRng, formulas, kcXmlConditions, typeRegistry, (_sugarRoot$schemaVali2 = sugarRoot.schemaValidations) !== null && _sugarRoot$schemaVali2 !== void 0 ? _sugarRoot$schemaVali2 : false, controlCustomizationContext);
|
|
133387
133103
|
const resourcesHash = (_generationOptions$re = generationOptions === null || generationOptions === void 0 ? void 0 : generationOptions.resourcesHash) !== null && _generationOptions$re !== void 0 ? _generationOptions$re : (0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_0__.reject)("Current generator version requires resources hash");
|
|
133388
133104
|
const builder = new _FormSourcesBuilder_FormSourcesBuilder__WEBPACK_IMPORTED_MODULE_21__.FormSourcesBuilder(additionalContent.formSourcesPath);
|
|
133389
133105
|
const markupGenerator = new _markupGenerator_MarkupGenerator__WEBPACK_IMPORTED_MODULE_12__.MarkupGenerator(additionalContent.formSourcesPath, additionalContent.helpersContent, additionalContent.tourSteps, controlCustomizationContext, typeRegistry, formSchemaRng, dataDeclarationHelper, (_sugarRoot$schemaVali3 = sugarRoot.schemaValidations) !== null && _sugarRoot$schemaVali3 !== void 0 ? _sugarRoot$schemaVali3 : false);
|
|
133390
133106
|
markupGenerator.generate(sugarRoot, builder);
|
|
133391
133107
|
builder.addResource("settings.js", (0,_markupGenerator_getSettings__WEBPACK_IMPORTED_MODULE_9__.getSettings)(sugarRoot, additionalContent.gfv, additionalSettings));
|
|
133392
133108
|
builder.addResource("requisiteList.js", (0,_RequisiteLIst_requisiteList__WEBPACK_IMPORTED_MODULE_24__.getRequisiteList)(sugarRoot, fetchFunctions));
|
|
133393
|
-
builder.addResource("lazyLoadDeclaration.js", lazyLoadGeneratorResult.content);
|
|
133394
133109
|
const autocalcGenerator = new _AutoCalculationsGenerator_AutoCalculationsGenerator__WEBPACK_IMPORTED_MODULE_18__.AutoCalculationsGenerator(dataDeclarationHelper, schemaRng);
|
|
133395
133110
|
builder.addResource("calculationFunctions.js", autocalcGenerator.generate(sugarRoot, formulas, additionalContent.autocalcsContent));
|
|
133396
133111
|
builder.addResource("dataDeclaration.js", dataDeclarationContent);
|
|
@@ -133990,7 +133705,7 @@ class FLangValidationBuildContext {
|
|
|
133990
133705
|
}
|
|
133991
133706
|
|
|
133992
133707
|
buildBasicValidations(targetPath, typeNode, schemaTypeNode, optional) {
|
|
133993
|
-
var _typeNode$base
|
|
133708
|
+
var _typeNode$base;
|
|
133994
133709
|
|
|
133995
133710
|
const validations = [];
|
|
133996
133711
|
const valueReference = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.ValueReferenceExpression(targetPath.toCurrentIteration(), "value");
|
|
@@ -134024,15 +133739,14 @@ class FLangValidationBuildContext {
|
|
|
134024
133739
|
errorExpression = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.ConditionalExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.OrBinaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.IsEqualsBinaryExpression(valueReference, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.NullLiteralExpression()), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.IsEqualsBinaryExpression(valueReference, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.StringLiteralExpression(""))), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.NullLiteralExpression(), errorExpression);
|
|
134025
133740
|
}
|
|
134026
133741
|
|
|
134027
|
-
const checkType = (_typeNode$checkType = typeNode === null || typeNode === void 0 ? void 0 : typeNode.checkType) !== null && _typeNode$checkType !== void 0 ? _typeNode$checkType : "error";
|
|
134028
133742
|
return [{
|
|
134029
|
-
statement: new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.SetStatement(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.ValueReferenceExpression(targetPath,
|
|
134030
|
-
checkType:
|
|
133743
|
+
statement: new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.SetStatement(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.ValueReferenceExpression(targetPath, "error"), errorExpression),
|
|
133744
|
+
checkType: "error"
|
|
134031
133745
|
}];
|
|
134032
133746
|
}
|
|
134033
133747
|
|
|
134034
133748
|
*createTypeValidations(valueReference, typeNode, schemaTypeNode) {
|
|
134035
|
-
var _typeNode$children$fi, _typeNode$children, _typeNode$children$fi2, _schemaTypeNode$enume, _typeNode$children2, _typeNodeLength$value, _typeNode$children3, _typeNodeMinLength$va, _typeNode$children4, _typeNodeMaxLength$va, _typeNode$children5, _typeNodeMinInclusive, _typeNode$children6, _typeNodeMaxInclusive, _typeNode$children7, _typeNodeTotalDigits$, _typeNode$children8, _typeNodePattern$valu, _schemaTypeNode$patte
|
|
133749
|
+
var _typeNode$children$fi, _typeNode$children, _typeNode$children$fi2, _schemaTypeNode$enume, _typeNode$children2, _typeNodeLength$value, _typeNode$children3, _typeNodeMinLength$va, _typeNode$children4, _typeNodeMaxLength$va, _typeNode$children5, _typeNodeMinInclusive, _typeNode$children6, _typeNodeMaxInclusive, _typeNode$children7, _typeNodeTotalDigits$, _typeNode$children8, _typeNodePattern$valu, _schemaTypeNode$patte;
|
|
134036
133750
|
|
|
134037
133751
|
//const baseCheckType = typeNode?.checkType;
|
|
134038
133752
|
const typeNodeEnumerations = (_typeNode$children$fi = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$children = typeNode.children) === null || _typeNode$children === void 0 ? void 0 : (_typeNode$children$fi2 = _typeNode$children.filter(x => x instanceof _validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_1__.EnumerationTypeCheckNode)) === null || _typeNode$children$fi2 === void 0 ? void 0 : _typeNode$children$fi2.map(x => x.value)) !== null && _typeNode$children$fi !== void 0 ? _typeNode$children$fi : [];
|
|
@@ -134105,7 +133819,7 @@ class FLangValidationBuildContext {
|
|
|
134105
133819
|
|
|
134106
133820
|
if (totalDigitsValue != undefined) {
|
|
134107
133821
|
const totalDigitsRuleBody = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.NegateUnaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.LeExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.LenExpression(valueReference), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.DecimalLiteralExpression(totalDigitsValue)));
|
|
134108
|
-
yield [totalDigitsRuleBody, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.StringLiteralExpression(`["
|
|
133822
|
+
yield [totalDigitsRuleBody, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.StringLiteralExpression(`["Поле должно быть заполнено"]`)];
|
|
134109
133823
|
}
|
|
134110
133824
|
|
|
134111
133825
|
const typeNodePattern = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$children8 = typeNode.children) === null || _typeNode$children8 === void 0 ? void 0 : _typeNode$children8.find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_1__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_1__.PatternTypeCheckNode));
|
|
@@ -134115,14 +133829,6 @@ class FLangValidationBuildContext {
|
|
|
134115
133829
|
const totalDigitsRuleBody = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.NegateUnaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.CallExpression("regexMatch", [valueReference, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.StringLiteralExpression(pattern)]));
|
|
134116
133830
|
yield [totalDigitsRuleBody, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.StringLiteralExpression(`["Поле должно быть заполнено"]`)];
|
|
134117
133831
|
}
|
|
134118
|
-
|
|
134119
|
-
const typeNodeFractional = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$children9 = typeNode.children) === null || _typeNode$children9 === void 0 ? void 0 : _typeNode$children9.find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_1__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_1__.FractiondigitsTypeCheckNode));
|
|
134120
|
-
const fractionalDigits = (_typeNodeFractional$v = typeNodeFractional === null || typeNodeFractional === void 0 ? void 0 : typeNodeFractional.value) !== null && _typeNodeFractional$v !== void 0 ? _typeNodeFractional$v : schemaTypeNode === null || schemaTypeNode === void 0 ? void 0 : schemaTypeNode.fractionDigits;
|
|
134121
|
-
|
|
134122
|
-
if (fractionalDigits != undefined) {
|
|
134123
|
-
const fractionalDigitsRuleBody = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.NegateUnaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.LeExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.FractionalLenExpression(this.castOperandToDecimalIfNeed(valueReference)), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.DecimalLiteralExpression(fractionalDigits)));
|
|
134124
|
-
yield [fractionalDigitsRuleBody, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_6__.StringLiteralExpression(`["Число не может содержать более ${fractionalDigits} знаков в дробной части"]`)];
|
|
134125
|
-
}
|
|
134126
133832
|
}
|
|
134127
133833
|
|
|
134128
133834
|
createBaseTypeValidation(valueReference, baseType) {
|
|
@@ -134264,7 +133970,6 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
134264
133970
|
/* harmony export */ "BoolLiteralExpression": () => (/* binding */ BoolLiteralExpression),
|
|
134265
133971
|
/* harmony export */ "AbsExpression": () => (/* binding */ AbsExpression),
|
|
134266
133972
|
/* harmony export */ "LenExpression": () => (/* binding */ LenExpression),
|
|
134267
|
-
/* harmony export */ "FractionalLenExpression": () => (/* binding */ FractionalLenExpression),
|
|
134268
133973
|
/* harmony export */ "RoundExpression": () => (/* binding */ RoundExpression),
|
|
134269
133974
|
/* harmony export */ "IntegerLiteralExpression": () => (/* binding */ IntegerLiteralExpression),
|
|
134270
133975
|
/* harmony export */ "NullLiteralExpression": () => (/* binding */ NullLiteralExpression),
|
|
@@ -134823,24 +134528,6 @@ class LenExpression extends FLangExpression {
|
|
|
134823
134528
|
this[key] = eval(code);
|
|
134824
134529
|
}
|
|
134825
134530
|
|
|
134826
|
-
}
|
|
134827
|
-
class FractionalLenExpression extends FLangExpression {
|
|
134828
|
-
constructor(expression) {
|
|
134829
|
-
super();
|
|
134830
|
-
this.expression = void 0;
|
|
134831
|
-
this.expression = expression;
|
|
134832
|
-
}
|
|
134833
|
-
|
|
134834
|
-
convertToString() {
|
|
134835
|
-
return `fractionalLen(${this.expression.convertToString()})`;
|
|
134836
|
-
}
|
|
134837
|
-
|
|
134838
|
-
// @ts-ignore
|
|
134839
|
-
__reactstandin__regenerateByEval(key, code) {
|
|
134840
|
-
// @ts-ignore
|
|
134841
|
-
this[key] = eval(code);
|
|
134842
|
-
}
|
|
134843
|
-
|
|
134844
134531
|
}
|
|
134845
134532
|
class RoundExpression extends ConstExpression {
|
|
134846
134533
|
constructor(expression, fractionalDigits) {
|
|
@@ -134988,7 +134675,6 @@ class SetStatement extends FLangStatement {
|
|
|
134988
134675
|
reactHotLoader.register(BoolLiteralExpression, "BoolLiteralExpression", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ServerSideFLangNormalization\\FLang\\FLangCodeDom.ts");
|
|
134989
134676
|
reactHotLoader.register(AbsExpression, "AbsExpression", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ServerSideFLangNormalization\\FLang\\FLangCodeDom.ts");
|
|
134990
134677
|
reactHotLoader.register(LenExpression, "LenExpression", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ServerSideFLangNormalization\\FLang\\FLangCodeDom.ts");
|
|
134991
|
-
reactHotLoader.register(FractionalLenExpression, "FractionalLenExpression", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ServerSideFLangNormalization\\FLang\\FLangCodeDom.ts");
|
|
134992
134678
|
reactHotLoader.register(RoundExpression, "RoundExpression", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ServerSideFLangNormalization\\FLang\\FLangCodeDom.ts");
|
|
134993
134679
|
reactHotLoader.register(IntegerLiteralExpression, "IntegerLiteralExpression", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ServerSideFLangNormalization\\FLang\\FLangCodeDom.ts");
|
|
134994
134680
|
reactHotLoader.register(NullLiteralExpression, "NullLiteralExpression", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ServerSideFLangNormalization\\FLang\\FLangCodeDom.ts");
|
|
@@ -135058,7 +134744,7 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
135058
134744
|
|
|
135059
134745
|
|
|
135060
134746
|
class NormalizationRulesGenerator {
|
|
135061
|
-
constructor(sugarRoot, dataDeclarationHelper, formSchemaRng, formulas, conditions, typesRegistry, useSchemaValidations, controlCustomizationContext
|
|
134747
|
+
constructor(sugarRoot, dataDeclarationHelper, formSchemaRng, formulas, conditions, typesRegistry, useSchemaValidations, controlCustomizationContext) {
|
|
135062
134748
|
this.sugarRoot = void 0;
|
|
135063
134749
|
this.dataDeclarationHelper = void 0;
|
|
135064
134750
|
this.formSchemaRng = void 0;
|
|
@@ -135067,8 +134753,6 @@ class NormalizationRulesGenerator {
|
|
|
135067
134753
|
this.typesRegistry = void 0;
|
|
135068
134754
|
this.controlCustomizationContext = void 0;
|
|
135069
134755
|
this.useSchemaValidations = void 0;
|
|
135070
|
-
this.lazyLoadingDeclaration = void 0;
|
|
135071
|
-
this.lazyLoadingDeclaration = lazyLoadingDeclaration;
|
|
135072
134756
|
this.sugarRoot = sugarRoot;
|
|
135073
134757
|
this.dataDeclarationHelper = dataDeclarationHelper;
|
|
135074
134758
|
this.formSchemaRng = formSchemaRng;
|
|
@@ -135125,20 +134809,7 @@ class NormalizationRulesGenerator {
|
|
|
135125
134809
|
}
|
|
135126
134810
|
|
|
135127
134811
|
buildInitializeRules(formRoot, resourcesHash) {
|
|
135128
|
-
|
|
135129
|
-
const thresholdEntry = Object.entries(this.lazyLoadingDeclaration).find(x => x[1].thresholdValue != undefined);
|
|
135130
|
-
|
|
135131
|
-
if (thresholdEntry != undefined) {
|
|
135132
|
-
var _thresholdEntry$1$thr, _thresholdEntry$;
|
|
135133
|
-
|
|
135134
|
-
const thresholdEntryPath = _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.ModelPath.createFromMask(`/${thresholdEntry[0]}`, true, _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.PathTokens.each);
|
|
135135
|
-
const thresholdValue = (_thresholdEntry$1$thr = (_thresholdEntry$ = thresholdEntry[1]) === null || _thresholdEntry$ === void 0 ? void 0 : _thresholdEntry$.thresholdValue) !== null && _thresholdEntry$1$thr !== void 0 ? _thresholdEntry$1$thr : 0;
|
|
135136
|
-
const lazyLoadingEnabledRef = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.AbsoluteModelPath.createAbsolute(formRoot).joinWith("LazyLoadingEnabled"), "value");
|
|
135137
|
-
const statement = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SetStatement(lazyLoadingEnabledRef, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ConditionalExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.GeExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ReduceCallExpression(thresholdEntryPath.trimLastStarIfLastToken().toCurrentIteration(), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.AnonymousFunctionDeclarationExpression(_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.BuildInTypeExpression.decimal, [new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ArgumentDeclarationExpression("result", _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.BuildInTypeExpression.decimal)], new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SumBinaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ArgumentReferenceExpression("result"), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(1))), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(0)), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(thresholdValue)), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.StringLiteralExpression("true"), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.StringLiteralExpression("false")));
|
|
135138
|
-
return mandatoryRules.concat([statement]);
|
|
135139
|
-
}
|
|
135140
|
-
|
|
135141
|
-
return mandatoryRules;
|
|
134812
|
+
return [new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SetStatement(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.AbsoluteModelPath.createAbsolute(formRoot), "resourcesHash"), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.StringLiteralExpression(resourcesHash)), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SetStatement(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.AbsoluteModelPath.createAbsolute(formRoot), "normalizationSource"), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.StringLiteralExpression("server"))];
|
|
135142
134813
|
}
|
|
135143
134814
|
|
|
135144
134815
|
buildSugarFLangRules() {
|
|
@@ -135419,69 +135090,43 @@ class NormalizationRulesGenerator {
|
|
|
135419
135090
|
yield rule;
|
|
135420
135091
|
}
|
|
135421
135092
|
|
|
135422
|
-
|
|
135423
|
-
yield* this.buildErrorWarningCountRules(targetPaths, "error");
|
|
135424
|
-
yield* this.buildErrorWarningCountRules(targetPaths, "warning");
|
|
135093
|
+
yield* this.buildErrorCountRule(context.getAllPathsWithValidations());
|
|
135425
135094
|
}
|
|
135426
135095
|
|
|
135427
|
-
*
|
|
135428
|
-
const tokens = modelPath.getPathPartsAsArray();
|
|
135429
|
-
|
|
135430
|
-
for (let i = 0; i < tokens.length; i++) {
|
|
135431
|
-
const currentModelPath = new _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.ModelPath(tokens.slice(0, i), modelPath.isAbsolute());
|
|
135432
|
-
|
|
135433
|
-
if (tokens[i] === _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.PathTokens.each || this.dataDeclarationHelper.isErrorsAndWarningsCountRequired(currentModelPath)) {
|
|
135434
|
-
yield currentModelPath;
|
|
135435
|
-
}
|
|
135436
|
-
}
|
|
135437
|
-
}
|
|
135438
|
-
|
|
135439
|
-
*buildErrorWarningCountRules(allPathsWithValidations, fieldName) {
|
|
135440
|
-
const countFieldName = `${fieldName}sCount`;
|
|
135096
|
+
*buildErrorCountRule(allPathsWithValidations) {
|
|
135441
135097
|
const zeroExpression = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(0);
|
|
135442
135098
|
const totalErrorCountExpressions = new _Common_ModelPath_ModelPathMap__WEBPACK_IMPORTED_MODULE_10__.ModelPathMap(_Common_ModelPath_EachCurrentCollision__WEBPACK_IMPORTED_MODULE_5__.EachCurrentCollision.AreDifferent);
|
|
135443
135099
|
const errorCountByTarget = new _Common_ModelPath_ModelPathMap__WEBPACK_IMPORTED_MODULE_10__.ModelPathMap(_Common_ModelPath_EachCurrentCollision__WEBPACK_IMPORTED_MODULE_5__.EachCurrentCollision.AreDifferent);
|
|
135444
135100
|
|
|
135445
135101
|
for (const path of allPathsWithValidations) {
|
|
135446
|
-
var _IterUtils$last;
|
|
135447
|
-
|
|
135448
|
-
const iterationSequence = [...(0,_Common_IterableUtils__WEBPACK_IMPORTED_MODULE_0__.reverseArray)([...this.splitModelPathIfErrorCountRequired(path)])];
|
|
135449
|
-
let resultCountExpression = this.getErrorWarningCountExpression(path.toCurrentIteration(), fieldName);
|
|
135102
|
+
var _IterUtils$last$itera, _IterUtils$last;
|
|
135450
135103
|
|
|
135451
|
-
|
|
135452
|
-
|
|
135453
|
-
const multipleTarget = iterationPath.joinWith(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.PathTokens.each);
|
|
135454
|
-
errorCountByTarget.getOrSet(multipleTarget, []).push(resultCountExpression);
|
|
135455
|
-
resultCountExpression = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.CastExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(multipleTarget.toCurrentIteration(), countFieldName), "decimal", new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(0));
|
|
135456
|
-
}
|
|
135104
|
+
const iterationSequence = [...(0,_Common_IterableUtils__WEBPACK_IMPORTED_MODULE_0__.reverseArray)((0,_Common_ModelPath_BuildIterationSequence__WEBPACK_IMPORTED_MODULE_11__.buildIterationSequence)(path))];
|
|
135105
|
+
let resultCountExpression = this.getErrorCountExpression(path.toCurrentIteration());
|
|
135457
135106
|
|
|
135458
|
-
|
|
135459
|
-
|
|
135107
|
+
for (const iterationEntry of iterationSequence) {
|
|
135108
|
+
errorCountByTarget.getOrSet(iterationEntry.iterable, []).push(resultCountExpression);
|
|
135109
|
+
resultCountExpression = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.CastExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(iterationEntry.iterable.toCurrentIteration(), "errorsCount"), "decimal", new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(0));
|
|
135460
135110
|
}
|
|
135461
135111
|
|
|
135462
|
-
totalErrorCountExpressions.set((_IterUtils$last = _Common_IterableUtils__WEBPACK_IMPORTED_MODULE_0__.IterUtils.last(iterationSequence)) !== null && _IterUtils$last !== void 0 ? _IterUtils$last : path, resultCountExpression);
|
|
135112
|
+
totalErrorCountExpressions.set((_IterUtils$last$itera = (_IterUtils$last = _Common_IterableUtils__WEBPACK_IMPORTED_MODULE_0__.IterUtils.last(iterationSequence)) === null || _IterUtils$last === void 0 ? void 0 : _IterUtils$last.iterable) !== null && _IterUtils$last$itera !== void 0 ? _IterUtils$last$itera : path, resultCountExpression);
|
|
135463
135113
|
}
|
|
135464
135114
|
|
|
135465
135115
|
for (const entry of errorCountByTarget.entries()) {
|
|
135466
135116
|
const iterable = entry[0];
|
|
135467
|
-
const items =
|
|
135117
|
+
const items = entry[1];
|
|
135468
135118
|
const firstEmptyExpression = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.NullLiteralExpression();
|
|
135469
135119
|
const allItemsSumExpression = items.reduce((x, y) => x == firstEmptyExpression ? y : new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SumBinaryExpression(x, y), firstEmptyExpression);
|
|
135470
|
-
const nextErrorCountPrecalculation = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(iterable,
|
|
135471
|
-
|
|
135472
|
-
if (_Common_IterableUtils__WEBPACK_IMPORTED_MODULE_0__.IterUtils.last(iterable.getPathParts()) === _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.PathTokens.each || !this.dataDeclarationHelper.isNodeHasChildrenEntry(iterable)) {
|
|
135473
|
-
yield new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SetStatement(nextErrorCountPrecalculation, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.CastExpression(allItemsSumExpression, "string", new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.StringLiteralExpression("G29")));
|
|
135474
|
-
} else {
|
|
135475
|
-
yield new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SetStatement(nextErrorCountPrecalculation, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.CastExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ReduceCallExpression(iterable.toCurrentIteration(), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.AnonymousFunctionDeclarationExpression(_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.BuildInTypeExpression.decimal, [new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ArgumentDeclarationExpression("result", _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.BuildInTypeExpression.decimal)], new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SumBinaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ArgumentReferenceExpression("result"), allItemsSumExpression)), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(0)), "string", new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.StringLiteralExpression("G29")));
|
|
135476
|
-
}
|
|
135120
|
+
const nextErrorCountPrecalculation = new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(iterable, "errorsCount");
|
|
135121
|
+
yield new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SetStatement(nextErrorCountPrecalculation, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.CastExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ReduceCallExpression(iterable.toCurrentIteration(), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.AnonymousFunctionDeclarationExpression(_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.BuildInTypeExpression.decimal, [new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ArgumentDeclarationExpression("result", _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.BuildInTypeExpression.decimal)], new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SumBinaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ArgumentReferenceExpression("result"), allItemsSumExpression)), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(0)), "string", new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.StringLiteralExpression("G29")));
|
|
135477
135122
|
}
|
|
135478
135123
|
|
|
135479
135124
|
const allRules = Iterator.from(totalErrorCountExpressions.values()).reduce((result, expression) => result === zeroExpression ? expression : new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SumBinaryExpression(result, expression), zeroExpression);
|
|
135480
|
-
yield new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SetStatement(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.AbsoluteModelPath.createAbsolute((0,_markupGenerator_getRootPath__WEBPACK_IMPORTED_MODULE_4__.getRootPath)(this.sugarRoot)),
|
|
135125
|
+
yield new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.SetStatement(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.AbsoluteModelPath.createAbsolute((0,_markupGenerator_getRootPath__WEBPACK_IMPORTED_MODULE_4__.getRootPath)(this.sugarRoot)), "errorsCount"), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.CastExpression(allRules, "string", new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.StringLiteralExpression("G29")));
|
|
135481
135126
|
}
|
|
135482
135127
|
|
|
135483
|
-
|
|
135484
|
-
return new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ConditionalExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.OrBinaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.IsEqualsBinaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(path,
|
|
135128
|
+
getErrorCountExpression(path) {
|
|
135129
|
+
return new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ConditionalExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.OrBinaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.IsEqualsBinaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(path, "error"), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.StringLiteralExpression(`[]`)), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.IsEqualsBinaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.ValueReferenceExpression(path, "error"), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.NullLiteralExpression())), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(0), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_13__.DecimalLiteralExpression(1));
|
|
135485
135130
|
}
|
|
135486
135131
|
|
|
135487
135132
|
// @ts-ignore
|
|
@@ -143846,7 +143491,7 @@ class UserPicklistConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE
|
|
|
143846
143491
|
type: "Expression",
|
|
143847
143492
|
expression: validationGenerator.generateValidationsFactory()
|
|
143848
143493
|
});
|
|
143849
|
-
const dataDeclarationGenerator = new _DataDeclarationGenerator_DataDeclarationGenerator__WEBPACK_IMPORTED_MODULE_10__.DataDeclarationGenerator((_findSugarNodeBases$2 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.findSugarNodeBases)(node.editor)[0]) !== null && _findSugarNodeBases$2 !== void 0 ? _findSugarNodeBases$2 : (0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_8__.reject)(), new _DataDeclarationGenerator_DataDeclarationInitSourceSequenceFactory__WEBPACK_IMPORTED_MODULE_11__.DataDeclarationInitSourceSequenceFactory(_common_FetchFunctions__WEBPACK_IMPORTED_MODULE_12__.FetchFunctions.empty()), context.controlCustomizationContext, context.typesRegistry
|
|
143494
|
+
const dataDeclarationGenerator = new _DataDeclarationGenerator_DataDeclarationGenerator__WEBPACK_IMPORTED_MODULE_10__.DataDeclarationGenerator((_findSugarNodeBases$2 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.findSugarNodeBases)(node.editor)[0]) !== null && _findSugarNodeBases$2 !== void 0 ? _findSugarNodeBases$2 : (0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_8__.reject)(), new _DataDeclarationGenerator_DataDeclarationInitSourceSequenceFactory__WEBPACK_IMPORTED_MODULE_11__.DataDeclarationInitSourceSequenceFactory(_common_FetchFunctions__WEBPACK_IMPORTED_MODULE_12__.FetchFunctions.empty()), context.controlCustomizationContext, context.typesRegistry);
|
|
143850
143495
|
userPicklistDeclarationBuilder.prop(x => x.editorDataDeclaration).set({
|
|
143851
143496
|
type: "Expression",
|
|
143852
143497
|
expression: dataDeclarationGenerator.generateDataDeclarationFactory()
|
|
@@ -158936,14 +158581,6 @@ class CheckboxConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_1__
|
|
|
158936
158581
|
}), context.addPathSectionDeclarationEntry(node, node.dataBinding.requisite), context.addVisibilityPathDeclEntryNew(node, node.dataBinding.requisite));
|
|
158937
158582
|
}
|
|
158938
158583
|
|
|
158939
|
-
doBuildNormalizeRules(builder) {
|
|
158940
|
-
const node = this.getCurrentNodeAs(_CheckboxNode__WEBPACK_IMPORTED_MODULE_5__.CheckboxNode);
|
|
158941
|
-
return [builder.valueInitializer(node, node.dataBinding, false), ...builder.specialFieldsInitializer(node, {
|
|
158942
|
-
optional: node.dataBinding.optional,
|
|
158943
|
-
disabled: false
|
|
158944
|
-
})];
|
|
158945
|
-
}
|
|
158946
|
-
|
|
158947
158584
|
getDefaultValue(node) {
|
|
158948
158585
|
var _node$dataBinding$def;
|
|
158949
158586
|
|
|
@@ -167195,15 +166832,14 @@ class FLangNormalizationRulesBuilder {
|
|
|
167195
166832
|
var _dataBinding$defaultV;
|
|
167196
166833
|
|
|
167197
166834
|
const targetPathReference = _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.ModelPath.createFromMask((0,_getBindingPath__WEBPACK_IMPORTED_MODULE_2__.getResolvedBindingPath)(node), true, _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_1__.PathTokens.each);
|
|
167198
|
-
const currentValueReference = new _ServerSideFLangNormalization_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_0__.ValueReferenceExpression(targetPathReference.toCurrentIteration(), "value");
|
|
167199
166835
|
const defaultValue = (_dataBinding$defaultV = dataBinding.defaultValue) !== null && _dataBinding$defaultV !== void 0 ? _dataBinding$defaultV : "";
|
|
167200
166836
|
|
|
167201
166837
|
if (dataBinding.fetchfn !== undefined) {
|
|
167202
166838
|
// eslint-disable-next-line no-console
|
|
167203
166839
|
console.warn("Атрибут fetchfn не поддержиается в режиме серверной нормализации");
|
|
167204
|
-
return new _ServerSideFLangNormalization_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_0__.SetStatement(new _ServerSideFLangNormalization_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_0__.ValueReferenceExpression(targetPathReference, "value"), currentValueReference);
|
|
167205
166840
|
}
|
|
167206
166841
|
|
|
166842
|
+
const currentValueReference = new _ServerSideFLangNormalization_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_0__.ValueReferenceExpression(targetPathReference.toCurrentIteration(), "value");
|
|
167207
166843
|
let valueExpression = new _ServerSideFLangNormalization_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_0__.StringLiteralExpression(defaultValue);
|
|
167208
166844
|
|
|
167209
166845
|
if (dataBinding.settings) {
|