@kontur.candy/generator 4.240.0-nightly.6b8np → 4.240.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +285 -1212
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -115117,7 +115117,7 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
115117
115117
|
|
|
115118
115118
|
|
|
115119
115119
|
|
|
115120
|
-
const jsConditionRegexp = /
|
|
115120
|
+
const jsConditionRegexp = /path\s*?\(.*?\)|^js\:|(?!\')\s*?(true|false)\s*?(?!\')|===|\s*?\'.*?\'\s*?[\=\!]=\s*?\'.*?\'\s*?|this\.|\&\&|\|\||\[.*?\]\.includes/;
|
|
115121
115121
|
function isJsCondition(condition) {
|
|
115122
115122
|
return condition != undefined && jsConditionRegexp.test(condition);
|
|
115123
115123
|
}
|
|
@@ -122026,394 +122026,6 @@ class CompositionOperandContext extends antlr4ts_ParserRuleContext__WEBPACK_IMPO
|
|
|
122026
122026
|
|
|
122027
122027
|
/***/ }),
|
|
122028
122028
|
|
|
122029
|
-
/***/ "./Generator/src/common/KCLang/IKCLangExpressionVisitor.ts":
|
|
122030
|
-
/*!*****************************************************************!*\
|
|
122031
|
-
!*** ./Generator/src/common/KCLang/IKCLangExpressionVisitor.ts ***!
|
|
122032
|
-
\*****************************************************************/
|
|
122033
|
-
/***/ ((module, __webpack_exports__, __webpack_require__) => {
|
|
122034
|
-
|
|
122035
|
-
"use strict";
|
|
122036
|
-
__webpack_require__.r(__webpack_exports__);
|
|
122037
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
122038
|
-
/* harmony export */ "traverseKCLangExpression": () => (/* binding */ traverseKCLangExpression),
|
|
122039
|
-
/* harmony export */ "DefaultKCLangExpressionVisitor": () => (/* binding */ DefaultKCLangExpressionVisitor)
|
|
122040
|
-
/* harmony export */ });
|
|
122041
|
-
/* harmony import */ var _Common_TypingUtils__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../../../Common/TypingUtils */ "./Common/TypingUtils.ts");
|
|
122042
|
-
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
122043
|
-
(function () {
|
|
122044
|
-
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
122045
|
-
enterModule && enterModule(module);
|
|
122046
|
-
})();
|
|
122047
|
-
|
|
122048
|
-
var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
|
|
122049
|
-
return a;
|
|
122050
|
-
};
|
|
122051
|
-
|
|
122052
|
-
|
|
122053
|
-
// tslint:disable-next-line:cyclomatic-complexity
|
|
122054
|
-
function traverseKCLangExpression(node, visitor) {
|
|
122055
|
-
switch (node.type) {
|
|
122056
|
-
case "cast":
|
|
122057
|
-
traverseKCLangExpression(node.expression, visitor);
|
|
122058
|
-
visitor.visitCastExpressionKCLangNode(node);
|
|
122059
|
-
break;
|
|
122060
|
-
|
|
122061
|
-
case "oneof":
|
|
122062
|
-
traverseKCLangExpression(node.testExpression, visitor);
|
|
122063
|
-
visitor.visitOneOfExpressionKCLangNode(node);
|
|
122064
|
-
break;
|
|
122065
|
-
|
|
122066
|
-
case "abs":
|
|
122067
|
-
traverseKCLangExpression(node.expression, visitor);
|
|
122068
|
-
visitor.visitAbsKCLangNode(node);
|
|
122069
|
-
break;
|
|
122070
|
-
|
|
122071
|
-
case "xabs":
|
|
122072
|
-
traverseKCLangExpression(node.expression, visitor);
|
|
122073
|
-
visitor.visitXAbsKCLangNode(node);
|
|
122074
|
-
break;
|
|
122075
|
-
|
|
122076
|
-
case "exists":
|
|
122077
|
-
visitor.visitExistsKCLangNode(node);
|
|
122078
|
-
break;
|
|
122079
|
-
|
|
122080
|
-
case "length":
|
|
122081
|
-
traverseKCLangExpression(node.expression, visitor);
|
|
122082
|
-
visitor.visitLengthKCLangNode(node);
|
|
122083
|
-
break;
|
|
122084
|
-
|
|
122085
|
-
case "and":
|
|
122086
|
-
for (const expression of node.expressions) {
|
|
122087
|
-
traverseKCLangExpression(expression, visitor);
|
|
122088
|
-
}
|
|
122089
|
-
|
|
122090
|
-
visitor.visitAndKCLangNode(node);
|
|
122091
|
-
break;
|
|
122092
|
-
|
|
122093
|
-
case "sum":
|
|
122094
|
-
visitor.visitSumKCLangNode(node);
|
|
122095
|
-
break;
|
|
122096
|
-
|
|
122097
|
-
case "gt":
|
|
122098
|
-
case "ge":
|
|
122099
|
-
case "lt":
|
|
122100
|
-
case "le":
|
|
122101
|
-
case "eq":
|
|
122102
|
-
case "noteq":
|
|
122103
|
-
for (const expression of node.expressions) {
|
|
122104
|
-
traverseKCLangExpression(expression, visitor);
|
|
122105
|
-
}
|
|
122106
|
-
|
|
122107
|
-
visitor.visitComparisonKCLangNode(node);
|
|
122108
|
-
break;
|
|
122109
|
-
|
|
122110
|
-
case "division":
|
|
122111
|
-
case "multiply":
|
|
122112
|
-
for (const expression of node.expressions) {
|
|
122113
|
-
traverseKCLangExpression(expression, visitor);
|
|
122114
|
-
}
|
|
122115
|
-
|
|
122116
|
-
visitor.visitMultiplyKCLangNode(node);
|
|
122117
|
-
break;
|
|
122118
|
-
|
|
122119
|
-
case "minus":
|
|
122120
|
-
traverseKCLangExpression(node.expression, visitor);
|
|
122121
|
-
visitor.visitMinusKCLangNode(node);
|
|
122122
|
-
break;
|
|
122123
|
-
|
|
122124
|
-
case "not":
|
|
122125
|
-
traverseKCLangExpression(node.expression, visitor);
|
|
122126
|
-
visitor.visitNotKCLangNode(node);
|
|
122127
|
-
break;
|
|
122128
|
-
|
|
122129
|
-
case "round":
|
|
122130
|
-
traverseKCLangExpression(node.expression, visitor);
|
|
122131
|
-
visitor.visitRoundKCLangNode(node);
|
|
122132
|
-
break;
|
|
122133
|
-
|
|
122134
|
-
case "choose":
|
|
122135
|
-
traverseKCLangExpression(node.if, visitor);
|
|
122136
|
-
traverseKCLangExpression(node.else, visitor);
|
|
122137
|
-
traverseKCLangExpression(node.then, visitor);
|
|
122138
|
-
visitor.visitChooseKCLangNode(node);
|
|
122139
|
-
break;
|
|
122140
|
-
|
|
122141
|
-
case "const":
|
|
122142
|
-
visitor.visitConstKCLangNode(node);
|
|
122143
|
-
break;
|
|
122144
|
-
|
|
122145
|
-
case "argument":
|
|
122146
|
-
visitor.visitArgumentKCLangNode(node);
|
|
122147
|
-
break;
|
|
122148
|
-
|
|
122149
|
-
case "or":
|
|
122150
|
-
for (const expression of node.expressions) {
|
|
122151
|
-
traverseKCLangExpression(expression, visitor);
|
|
122152
|
-
}
|
|
122153
|
-
|
|
122154
|
-
visitor.visitOrKCLangNode(node);
|
|
122155
|
-
break;
|
|
122156
|
-
|
|
122157
|
-
case "multySum":
|
|
122158
|
-
visitor.visitMultySumKCLangNode(node);
|
|
122159
|
-
break;
|
|
122160
|
-
|
|
122161
|
-
case "substring":
|
|
122162
|
-
traverseKCLangExpression(node.expression, visitor);
|
|
122163
|
-
visitor.visitSubstringKCLangNode(node);
|
|
122164
|
-
break;
|
|
122165
|
-
|
|
122166
|
-
case "regexMatch":
|
|
122167
|
-
traverseKCLangExpression(node.expression, visitor);
|
|
122168
|
-
visitor.visitRegexMatchKCLangNode(node);
|
|
122169
|
-
break;
|
|
122170
|
-
|
|
122171
|
-
default:
|
|
122172
|
-
(0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_0__.ensureNever)(node);
|
|
122173
|
-
break;
|
|
122174
|
-
}
|
|
122175
|
-
}
|
|
122176
|
-
class DefaultKCLangExpressionVisitor {
|
|
122177
|
-
visitAbsKCLangNode(node) {// default empty implementation
|
|
122178
|
-
}
|
|
122179
|
-
|
|
122180
|
-
visitAndKCLangNode(node) {// default empty implementation
|
|
122181
|
-
}
|
|
122182
|
-
|
|
122183
|
-
visitArgumentKCLangNode(node) {// default empty implementation
|
|
122184
|
-
}
|
|
122185
|
-
|
|
122186
|
-
visitCastExpressionKCLangNode(node) {// default empty implementation
|
|
122187
|
-
}
|
|
122188
|
-
|
|
122189
|
-
visitChooseKCLangNode(node) {// default empty implementation
|
|
122190
|
-
}
|
|
122191
|
-
|
|
122192
|
-
visitComparisonKCLangNode(node) {// default empty implementation
|
|
122193
|
-
}
|
|
122194
|
-
|
|
122195
|
-
visitConstKCLangNode(node) {// default empty implementation
|
|
122196
|
-
}
|
|
122197
|
-
|
|
122198
|
-
visitExistsKCLangNode(node) {// default empty implementation
|
|
122199
|
-
}
|
|
122200
|
-
|
|
122201
|
-
visitLengthKCLangNode(node) {// default empty implementation
|
|
122202
|
-
}
|
|
122203
|
-
|
|
122204
|
-
visitMinusKCLangNode(node) {// default empty implementation
|
|
122205
|
-
}
|
|
122206
|
-
|
|
122207
|
-
visitMultiplyKCLangNode(node) {// default empty implementation
|
|
122208
|
-
}
|
|
122209
|
-
|
|
122210
|
-
visitMultySumKCLangNode(node) {// default empty implementation
|
|
122211
|
-
}
|
|
122212
|
-
|
|
122213
|
-
visitNotKCLangNode(node) {// default empty implementation
|
|
122214
|
-
}
|
|
122215
|
-
|
|
122216
|
-
visitOneOfExpressionKCLangNode(node) {// default empty implementation
|
|
122217
|
-
}
|
|
122218
|
-
|
|
122219
|
-
visitOrKCLangNode(node) {// default empty implementation
|
|
122220
|
-
}
|
|
122221
|
-
|
|
122222
|
-
visitRegexMatchKCLangNode(node) {// default empty implementation
|
|
122223
|
-
}
|
|
122224
|
-
|
|
122225
|
-
visitRoundKCLangNode(node) {// default empty implementation
|
|
122226
|
-
}
|
|
122227
|
-
|
|
122228
|
-
visitSubstringKCLangNode(node) {// default empty implementation
|
|
122229
|
-
}
|
|
122230
|
-
|
|
122231
|
-
visitSumKCLangNode(node) {// default empty implementation
|
|
122232
|
-
}
|
|
122233
|
-
|
|
122234
|
-
visitXAbsKCLangNode(node) {// default empty implementation
|
|
122235
|
-
}
|
|
122236
|
-
|
|
122237
|
-
// @ts-ignore
|
|
122238
|
-
__reactstandin__regenerateByEval(key, code) {
|
|
122239
|
-
// @ts-ignore
|
|
122240
|
-
this[key] = eval(code);
|
|
122241
|
-
}
|
|
122242
|
-
|
|
122243
|
-
}
|
|
122244
|
-
;
|
|
122245
|
-
|
|
122246
|
-
(function () {
|
|
122247
|
-
var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;
|
|
122248
|
-
|
|
122249
|
-
if (!reactHotLoader) {
|
|
122250
|
-
return;
|
|
122251
|
-
}
|
|
122252
|
-
|
|
122253
|
-
reactHotLoader.register(traverseKCLangExpression, "traverseKCLangExpression", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\IKCLangExpressionVisitor.ts");
|
|
122254
|
-
reactHotLoader.register(DefaultKCLangExpressionVisitor, "DefaultKCLangExpressionVisitor", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\IKCLangExpressionVisitor.ts");
|
|
122255
|
-
})();
|
|
122256
|
-
|
|
122257
|
-
;
|
|
122258
|
-
|
|
122259
|
-
(function () {
|
|
122260
|
-
var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
|
|
122261
|
-
leaveModule && leaveModule(module);
|
|
122262
|
-
})();
|
|
122263
|
-
|
|
122264
|
-
/***/ }),
|
|
122265
|
-
|
|
122266
|
-
/***/ "./Generator/src/common/KCLang/KCLangDescriptionGrammar.ts":
|
|
122267
|
-
/*!*****************************************************************!*\
|
|
122268
|
-
!*** ./Generator/src/common/KCLang/KCLangDescriptionGrammar.ts ***!
|
|
122269
|
-
\*****************************************************************/
|
|
122270
|
-
/***/ ((module) => {
|
|
122271
|
-
|
|
122272
|
-
var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
|
|
122273
|
-
return a;
|
|
122274
|
-
};
|
|
122275
|
-
|
|
122276
|
-
// this file was prevaled
|
|
122277
|
-
|
|
122278
|
-
/* eslint-disable */
|
|
122279
|
-
// @ts-ignore
|
|
122280
|
-
module.exports = "/*\n * Generated by PEG.js 0.10.0.\n *\n * http://pegjs.org/\n */\n(function() {\n \"use strict\";\n\n function peg$subclass(child, parent) {\n function ctor() { this.constructor = child; }\n ctor.prototype = parent.prototype;\n child.prototype = new ctor();\n }\n\n function peg$SyntaxError(message, expected, found, location) {\n this.message = message;\n this.expected = expected;\n this.found = found;\n this.location = location;\n this.name = \"SyntaxError\";\n\n if (typeof Error.captureStackTrace === \"function\") {\n Error.captureStackTrace(this, peg$SyntaxError);\n }\n }\n\n peg$subclass(peg$SyntaxError, Error);\n\n peg$SyntaxError.buildMessage = function(expected, found) {\n var DESCRIBE_EXPECTATION_FNS = {\n literal: function(expectation) {\n return \"\\\"\" + literalEscape(expectation.text) + \"\\\"\";\n },\n\n \"class\": function(expectation) {\n var escapedParts = \"\",\n i;\n\n for (i = 0; i < expectation.parts.length; i++) {\n escapedParts += expectation.parts[i] instanceof Array\n ? classEscape(expectation.parts[i][0]) + \"-\" + classEscape(expectation.parts[i][1])\n : classEscape(expectation.parts[i]);\n }\n\n return \"[\" + (expectation.inverted ? \"^\" : \"\") + escapedParts + \"]\";\n },\n\n any: function(expectation) {\n return \"any character\";\n },\n\n end: function(expectation) {\n return \"end of input\";\n },\n\n other: function(expectation) {\n return expectation.description;\n }\n };\n\n function hex(ch) {\n return ch.charCodeAt(0).toString(16).toUpperCase();\n }\n\n function literalEscape(s) {\n return s\n .replace(/\\\\/g, '\\\\\\\\')\n .replace(/\"/g, '\\\\\"')\n .replace(/\\0/g, '\\\\0')\n .replace(/\\t/g, '\\\\t')\n .replace(/\\n/g, '\\\\n')\n .replace(/\\r/g, '\\\\r')\n .replace(/[\\x00-\\x0F]/g, function(ch) { return '\\\\x0' + hex(ch); })\n .replace(/[\\x10-\\x1F\\x7F-\\x9F]/g, function(ch) { return '\\\\x' + hex(ch); });\n }\n\n function classEscape(s) {\n return s\n .replace(/\\\\/g, '\\\\\\\\')\n .replace(/\\]/g, '\\\\]')\n .replace(/\\^/g, '\\\\^')\n .replace(/-/g, '\\\\-')\n .replace(/\\0/g, '\\\\0')\n .replace(/\\t/g, '\\\\t')\n .replace(/\\n/g, '\\\\n')\n .replace(/\\r/g, '\\\\r')\n .replace(/[\\x00-\\x0F]/g, function(ch) { return '\\\\x0' + hex(ch); })\n .replace(/[\\x10-\\x1F\\x7F-\\x9F]/g, function(ch) { return '\\\\x' + hex(ch); });\n }\n\n function describeExpectation(expectation) {\n return DESCRIBE_EXPECTATION_FNS[expectation.type](expectation);\n }\n\n function describeExpected(expected) {\n var descriptions = new Array(expected.length),\n i, j;\n\n for (i = 0; i < expected.length; i++) {\n descriptions[i] = describeExpectation(expected[i]);\n }\n\n descriptions.sort();\n\n if (descriptions.length > 0) {\n for (i = 1, j = 1; i < descriptions.length; i++) {\n if (descriptions[i - 1] !== descriptions[i]) {\n descriptions[j] = descriptions[i];\n j++;\n }\n }\n descriptions.length = j;\n }\n\n switch (descriptions.length) {\n case 1:\n return descriptions[0];\n\n case 2:\n return descriptions[0] + \" or \" + descriptions[1];\n\n default:\n return descriptions.slice(0, -1).join(\", \")\n + \", or \"\n + descriptions[descriptions.length - 1];\n }\n }\n\n function describeFound(found) {\n return found ? \"\\\"\" + literalEscape(found) + \"\\\"\" : \"end of input\";\n }\n\n return \"Expected \" + describeExpected(expected) + \" but \" + describeFound(found) + \" found.\";\n };\n\n function peg$parse(input, options) {\n options = options !== void 0 ? options : {};\n\n var peg$FAILED = {},\n\n peg$startRuleFunctions = { Text: peg$parseText },\n peg$startRuleFunction = peg$parseText,\n\n peg$c0 = function(items) {\r\n \treturn items.filter(x => x !== \"\");\r\n },\n peg$c1 = \"[\",\n peg$c2 = peg$literalExpectation(\"[\", false),\n peg$c3 = \"]\",\n peg$c4 = peg$literalExpectation(\"]\", false),\n peg$c5 = \"(\",\n peg$c6 = peg$literalExpectation(\"(\", false),\n peg$c7 = \")\",\n peg$c8 = peg$literalExpectation(\")\", false),\n peg$c9 = function(text, src) {\r\n return {\r\n \ttype: \"link\",\r\n text: text,\r\n src: src,\r\n }\r\n },\n peg$c10 = /^[^ \\]\\t\\n\\r]/,\n peg$c11 = peg$classExpectation([\" \", \"]\", \"\\t\", \"\\n\", \"\\r\"], true, false),\n peg$c12 = function(w) { return w.join(\"\") },\n peg$c13 = function(items) {\r\n return items.filter(x => x !== \"\");\r\n },\n peg$c14 = /^[^)]/,\n peg$c15 = peg$classExpectation([\")\"], true, false),\n peg$c16 = function(w) {\r\n \treturn w.join(\"\").trim()\r\n },\n peg$c17 = /^[\\n]/,\n peg$c18 = peg$classExpectation([\"\\n\"], false, false),\n peg$c19 = /^[ \\t\\n\\r]/,\n peg$c20 = peg$classExpectation([\" \", \"\\t\", \"\\n\", \"\\r\"], false, false),\n peg$c21 = function() {\r\n \treturn \"\\n\"\r\n },\n peg$c22 = /^[^ \\t\\n\\r]/,\n peg$c23 = peg$classExpectation([\" \", \"\\t\", \"\\n\", \"\\r\"], true, false),\n peg$c24 = function(w) {\r\n \treturn w.join(\"\");\r\n },\n peg$c25 = function() {\r\n \treturn \"\";\r\n },\n\n peg$currPos = 0,\n peg$savedPos = 0,\n peg$posDetailsCache = [{ line: 1, column: 1 }],\n peg$maxFailPos = 0,\n peg$maxFailExpected = [],\n peg$silentFails = 0,\n\n peg$result;\n\n if (\"startRule\" in options) {\n if (!(options.startRule in peg$startRuleFunctions)) {\n throw new Error(\"Can't start parsing from rule \\\"\" + options.startRule + \"\\\".\");\n }\n\n peg$startRuleFunction = peg$startRuleFunctions[options.startRule];\n }\n\n function text() {\n return input.substring(peg$savedPos, peg$currPos);\n }\n\n function location() {\n return peg$computeLocation(peg$savedPos, peg$currPos);\n }\n\n function expected(description, location) {\n location = location !== void 0 ? location : peg$computeLocation(peg$savedPos, peg$currPos)\n\n throw peg$buildStructuredError(\n [peg$otherExpectation(description)],\n input.substring(peg$savedPos, peg$currPos),\n location\n );\n }\n\n function error(message, location) {\n location = location !== void 0 ? location : peg$computeLocation(peg$savedPos, peg$currPos)\n\n throw peg$buildSimpleError(message, location);\n }\n\n function peg$literalExpectation(text, ignoreCase) {\n return { type: \"literal\", text: text, ignoreCase: ignoreCase };\n }\n\n function peg$classExpectation(parts, inverted, ignoreCase) {\n return { type: \"class\", parts: parts, inverted: inverted, ignoreCase: ignoreCase };\n }\n\n function peg$anyExpectation() {\n return { type: \"any\" };\n }\n\n function peg$endExpectation() {\n return { type: \"end\" };\n }\n\n function peg$otherExpectation(description) {\n return { type: \"other\", description: description };\n }\n\n function peg$computePosDetails(pos) {\n var details = peg$posDetailsCache[pos], p;\n\n if (details) {\n return details;\n } else {\n p = pos - 1;\n while (!peg$posDetailsCache[p]) {\n p--;\n }\n\n details = peg$posDetailsCache[p];\n details = {\n line: details.line,\n column: details.column\n };\n\n while (p < pos) {\n if (input.charCodeAt(p) === 10) {\n details.line++;\n details.column = 1;\n } else {\n details.column++;\n }\n\n p++;\n }\n\n peg$posDetailsCache[pos] = details;\n return details;\n }\n }\n\n function peg$computeLocation(startPos, endPos) {\n var startPosDetails = peg$computePosDetails(startPos),\n endPosDetails = peg$computePosDetails(endPos);\n\n return {\n start: {\n offset: startPos,\n line: startPosDetails.line,\n column: startPosDetails.column\n },\n end: {\n offset: endPos,\n line: endPosDetails.line,\n column: endPosDetails.column\n }\n };\n }\n\n function peg$fail(expected) {\n if (peg$currPos < peg$maxFailPos) { return; }\n\n if (peg$currPos > peg$maxFailPos) {\n peg$maxFailPos = peg$currPos;\n peg$maxFailExpected = [];\n }\n\n peg$maxFailExpected.push(expected);\n }\n\n function peg$buildSimpleError(message, location) {\n return new peg$SyntaxError(message, null, null, location);\n }\n\n function peg$buildStructuredError(expected, found, location) {\n return new peg$SyntaxError(\n peg$SyntaxError.buildMessage(expected, found),\n expected,\n found,\n location\n );\n }\n\n function peg$parseText() {\n var s0, s1, s2;\n\n s0 = peg$currPos;\n s1 = [];\n s2 = peg$parseLink();\n if (s2 === peg$FAILED) {\n s2 = peg$parseWord();\n if (s2 === peg$FAILED) {\n s2 = peg$parseNewLine();\n if (s2 === peg$FAILED) {\n s2 = peg$parse_();\n }\n }\n }\n while (s2 !== peg$FAILED) {\n s1.push(s2);\n s2 = peg$parseLink();\n if (s2 === peg$FAILED) {\n s2 = peg$parseWord();\n if (s2 === peg$FAILED) {\n s2 = peg$parseNewLine();\n if (s2 === peg$FAILED) {\n s2 = peg$parse_();\n }\n }\n }\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c0(s1);\n }\n s0 = s1;\n\n return s0;\n }\n\n function peg$parseLink() {\n var s0, s1, s2, s3, s4, s5, s6;\n\n s0 = peg$currPos;\n if (input.charCodeAt(peg$currPos) === 91) {\n s1 = peg$c1;\n peg$currPos++;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c2); }\n }\n if (s1 !== peg$FAILED) {\n s2 = peg$parseLinkText();\n if (s2 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 93) {\n s3 = peg$c3;\n peg$currPos++;\n } else {\n s3 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c4); }\n }\n if (s3 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 40) {\n s4 = peg$c5;\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c6); }\n }\n if (s4 !== peg$FAILED) {\n s5 = peg$parseLinkSrc();\n if (s5 !== peg$FAILED) {\n if (input.charCodeAt(peg$currPos) === 41) {\n s6 = peg$c7;\n peg$currPos++;\n } else {\n s6 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c8); }\n }\n if (s6 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c9(s2, s5);\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n\n return s0;\n }\n\n function peg$parseLinkText() {\n var s0, s1, s2, s3, s4;\n\n s0 = peg$currPos;\n s1 = [];\n s2 = peg$currPos;\n s3 = [];\n if (peg$c10.test(input.charAt(peg$currPos))) {\n s4 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c11); }\n }\n if (s4 !== peg$FAILED) {\n while (s4 !== peg$FAILED) {\n s3.push(s4);\n if (peg$c10.test(input.charAt(peg$currPos))) {\n s4 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c11); }\n }\n }\n } else {\n s3 = peg$FAILED;\n }\n if (s3 !== peg$FAILED) {\n peg$savedPos = s2;\n s3 = peg$c12(s3);\n }\n s2 = s3;\n if (s2 === peg$FAILED) {\n s2 = peg$parse_();\n }\n if (s2 !== peg$FAILED) {\n while (s2 !== peg$FAILED) {\n s1.push(s2);\n s2 = peg$currPos;\n s3 = [];\n if (peg$c10.test(input.charAt(peg$currPos))) {\n s4 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c11); }\n }\n if (s4 !== peg$FAILED) {\n while (s4 !== peg$FAILED) {\n s3.push(s4);\n if (peg$c10.test(input.charAt(peg$currPos))) {\n s4 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c11); }\n }\n }\n } else {\n s3 = peg$FAILED;\n }\n if (s3 !== peg$FAILED) {\n peg$savedPos = s2;\n s3 = peg$c12(s3);\n }\n s2 = s3;\n if (s2 === peg$FAILED) {\n s2 = peg$parse_();\n }\n }\n } else {\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c13(s1);\n }\n s0 = s1;\n\n return s0;\n }\n\n function peg$parseLinkSrc() {\n var s0, s1, s2;\n\n s0 = peg$currPos;\n s1 = [];\n if (peg$c14.test(input.charAt(peg$currPos))) {\n s2 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c15); }\n }\n if (s2 !== peg$FAILED) {\n while (s2 !== peg$FAILED) {\n s1.push(s2);\n if (peg$c14.test(input.charAt(peg$currPos))) {\n s2 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c15); }\n }\n }\n } else {\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c16(s1);\n }\n s0 = s1;\n\n return s0;\n }\n\n function peg$parseNewLine() {\n var s0, s1, s2, s3, s4;\n\n s0 = peg$currPos;\n if (peg$c17.test(input.charAt(peg$currPos))) {\n s1 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s1 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c18); }\n }\n if (s1 !== peg$FAILED) {\n if (peg$c17.test(input.charAt(peg$currPos))) {\n s2 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c18); }\n }\n if (s2 !== peg$FAILED) {\n s3 = [];\n if (peg$c19.test(input.charAt(peg$currPos))) {\n s4 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c20); }\n }\n while (s4 !== peg$FAILED) {\n s3.push(s4);\n if (peg$c19.test(input.charAt(peg$currPos))) {\n s4 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c20); }\n }\n }\n if (s3 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c21();\n s0 = s1;\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n } else {\n peg$currPos = s0;\n s0 = peg$FAILED;\n }\n\n return s0;\n }\n\n function peg$parseWord() {\n var s0, s1, s2;\n\n s0 = peg$currPos;\n s1 = [];\n if (peg$c22.test(input.charAt(peg$currPos))) {\n s2 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c23); }\n }\n if (s2 !== peg$FAILED) {\n while (s2 !== peg$FAILED) {\n s1.push(s2);\n if (peg$c22.test(input.charAt(peg$currPos))) {\n s2 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s2 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c23); }\n }\n }\n } else {\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c24(s1);\n }\n s0 = s1;\n\n return s0;\n }\n\n function peg$parse_() {\n var s0, s1, s2, s3, s4, s5, s6;\n\n s0 = peg$currPos;\n s1 = [];\n s2 = peg$currPos;\n s3 = peg$currPos;\n peg$silentFails++;\n s4 = peg$currPos;\n if (peg$c17.test(input.charAt(peg$currPos))) {\n s5 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s5 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c18); }\n }\n if (s5 !== peg$FAILED) {\n if (peg$c17.test(input.charAt(peg$currPos))) {\n s6 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s6 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c18); }\n }\n if (s6 !== peg$FAILED) {\n s5 = [s5, s6];\n s4 = s5;\n } else {\n peg$currPos = s4;\n s4 = peg$FAILED;\n }\n } else {\n peg$currPos = s4;\n s4 = peg$FAILED;\n }\n peg$silentFails--;\n if (s4 === peg$FAILED) {\n s3 = void 0;\n } else {\n peg$currPos = s3;\n s3 = peg$FAILED;\n }\n if (s3 !== peg$FAILED) {\n if (peg$c19.test(input.charAt(peg$currPos))) {\n s4 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c20); }\n }\n if (s4 !== peg$FAILED) {\n s3 = [s3, s4];\n s2 = s3;\n } else {\n peg$currPos = s2;\n s2 = peg$FAILED;\n }\n } else {\n peg$currPos = s2;\n s2 = peg$FAILED;\n }\n if (s2 !== peg$FAILED) {\n while (s2 !== peg$FAILED) {\n s1.push(s2);\n s2 = peg$currPos;\n s3 = peg$currPos;\n peg$silentFails++;\n s4 = peg$currPos;\n if (peg$c17.test(input.charAt(peg$currPos))) {\n s5 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s5 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c18); }\n }\n if (s5 !== peg$FAILED) {\n if (peg$c17.test(input.charAt(peg$currPos))) {\n s6 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s6 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c18); }\n }\n if (s6 !== peg$FAILED) {\n s5 = [s5, s6];\n s4 = s5;\n } else {\n peg$currPos = s4;\n s4 = peg$FAILED;\n }\n } else {\n peg$currPos = s4;\n s4 = peg$FAILED;\n }\n peg$silentFails--;\n if (s4 === peg$FAILED) {\n s3 = void 0;\n } else {\n peg$currPos = s3;\n s3 = peg$FAILED;\n }\n if (s3 !== peg$FAILED) {\n if (peg$c19.test(input.charAt(peg$currPos))) {\n s4 = input.charAt(peg$currPos);\n peg$currPos++;\n } else {\n s4 = peg$FAILED;\n if (peg$silentFails === 0) { peg$fail(peg$c20); }\n }\n if (s4 !== peg$FAILED) {\n s3 = [s3, s4];\n s2 = s3;\n } else {\n peg$currPos = s2;\n s2 = peg$FAILED;\n }\n } else {\n peg$currPos = s2;\n s2 = peg$FAILED;\n }\n }\n } else {\n s1 = peg$FAILED;\n }\n if (s1 !== peg$FAILED) {\n peg$savedPos = s0;\n s1 = peg$c25();\n }\n s0 = s1;\n\n return s0;\n }\n\n peg$result = peg$startRuleFunction();\n\n if (peg$result !== peg$FAILED && peg$currPos === input.length) {\n return peg$result;\n } else {\n if (peg$result !== peg$FAILED && peg$currPos < input.length) {\n peg$fail(peg$endExpectation());\n }\n\n throw peg$buildStructuredError(\n peg$maxFailExpected,\n peg$maxFailPos < input.length ? input.charAt(peg$maxFailPos) : null,\n peg$maxFailPos < input.length\n ? peg$computeLocation(peg$maxFailPos, peg$maxFailPos + 1)\n : peg$computeLocation(peg$maxFailPos, peg$maxFailPos)\n );\n }\n }\n\n return {\n SyntaxError: peg$SyntaxError,\n parse: peg$parse\n };\n})()";
|
|
122281
|
-
|
|
122282
|
-
/***/ }),
|
|
122283
|
-
|
|
122284
|
-
/***/ "./Generator/src/common/KCLang/KCLangDescriptionParser.ts":
|
|
122285
|
-
/*!****************************************************************!*\
|
|
122286
|
-
!*** ./Generator/src/common/KCLang/KCLangDescriptionParser.ts ***!
|
|
122287
|
-
\****************************************************************/
|
|
122288
|
-
/***/ ((module, __webpack_exports__, __webpack_require__) => {
|
|
122289
|
-
|
|
122290
|
-
"use strict";
|
|
122291
|
-
__webpack_require__.r(__webpack_exports__);
|
|
122292
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
122293
|
-
/* harmony export */ "KCLangDescriptionParser": () => (/* binding */ KCLangDescriptionParser)
|
|
122294
|
-
/* harmony export */ });
|
|
122295
|
-
/* harmony import */ var _KCLangDescriptionGrammar__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./KCLangDescriptionGrammar */ "./Generator/src/common/KCLang/KCLangDescriptionGrammar.ts");
|
|
122296
|
-
/* harmony import */ var _KCLangDescriptionGrammar__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(_KCLangDescriptionGrammar__WEBPACK_IMPORTED_MODULE_0__);
|
|
122297
|
-
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
122298
|
-
(function () {
|
|
122299
|
-
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
122300
|
-
enterModule && enterModule(module);
|
|
122301
|
-
})();
|
|
122302
|
-
|
|
122303
|
-
var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
|
|
122304
|
-
return a;
|
|
122305
|
-
};
|
|
122306
|
-
|
|
122307
|
-
// @ts-ignore
|
|
122308
|
-
// eslint-disable-next-line @typescript-eslint/no-unsafe-argument
|
|
122309
|
-
|
|
122310
|
-
const evalParse = eval((_KCLangDescriptionGrammar__WEBPACK_IMPORTED_MODULE_0___default())).parse;
|
|
122311
|
-
class KCLangDescriptionParser {
|
|
122312
|
-
static getOrCreateParser() {
|
|
122313
|
-
return evalParse;
|
|
122314
|
-
}
|
|
122315
|
-
|
|
122316
|
-
static parse(code) {
|
|
122317
|
-
const parser = this.getOrCreateParser();
|
|
122318
|
-
return parser(code);
|
|
122319
|
-
}
|
|
122320
|
-
|
|
122321
|
-
}
|
|
122322
|
-
;
|
|
122323
|
-
|
|
122324
|
-
(function () {
|
|
122325
|
-
var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;
|
|
122326
|
-
|
|
122327
|
-
if (!reactHotLoader) {
|
|
122328
|
-
return;
|
|
122329
|
-
}
|
|
122330
|
-
|
|
122331
|
-
reactHotLoader.register(evalParse, "evalParse", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangDescriptionParser.ts");
|
|
122332
|
-
reactHotLoader.register(KCLangDescriptionParser, "KCLangDescriptionParser", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangDescriptionParser.ts");
|
|
122333
|
-
})();
|
|
122334
|
-
|
|
122335
|
-
;
|
|
122336
|
-
|
|
122337
|
-
(function () {
|
|
122338
|
-
var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
|
|
122339
|
-
leaveModule && leaveModule(module);
|
|
122340
|
-
})();
|
|
122341
|
-
|
|
122342
|
-
/***/ }),
|
|
122343
|
-
|
|
122344
|
-
/***/ "./Generator/src/common/KCLang/KCLangNodes.ts":
|
|
122345
|
-
/*!****************************************************!*\
|
|
122346
|
-
!*** ./Generator/src/common/KCLang/KCLangNodes.ts ***!
|
|
122347
|
-
\****************************************************/
|
|
122348
|
-
/***/ ((module, __webpack_exports__, __webpack_require__) => {
|
|
122349
|
-
|
|
122350
|
-
"use strict";
|
|
122351
|
-
__webpack_require__.r(__webpack_exports__);
|
|
122352
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
122353
|
-
/* harmony export */ "isFormulaStatement": () => (/* binding */ isFormulaStatement),
|
|
122354
|
-
/* harmony export */ "isBlockStatement": () => (/* binding */ isBlockStatement),
|
|
122355
|
-
/* harmony export */ "isEnsureStatement": () => (/* binding */ isEnsureStatement),
|
|
122356
|
-
/* harmony export */ "isConditionalStatement": () => (/* binding */ isConditionalStatement),
|
|
122357
|
-
/* harmony export */ "isDescribeStatement": () => (/* binding */ isDescribeStatement),
|
|
122358
|
-
/* harmony export */ "andKCLangNode": () => (/* binding */ andKCLangNode)
|
|
122359
|
-
/* harmony export */ });
|
|
122360
|
-
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
122361
|
-
(function () {
|
|
122362
|
-
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
122363
|
-
enterModule && enterModule(module);
|
|
122364
|
-
})();
|
|
122365
|
-
|
|
122366
|
-
var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
|
|
122367
|
-
return a;
|
|
122368
|
-
};
|
|
122369
|
-
|
|
122370
|
-
function isFormulaStatement(node) {
|
|
122371
|
-
return node.type === "formula";
|
|
122372
|
-
}
|
|
122373
|
-
function isBlockStatement(node) {
|
|
122374
|
-
return node.type === "block";
|
|
122375
|
-
}
|
|
122376
|
-
function isEnsureStatement(node) {
|
|
122377
|
-
return node.type === "ensure";
|
|
122378
|
-
}
|
|
122379
|
-
function isConditionalStatement(node) {
|
|
122380
|
-
return node.type === "if";
|
|
122381
|
-
}
|
|
122382
|
-
function isDescribeStatement(node) {
|
|
122383
|
-
return node.type === "describe";
|
|
122384
|
-
}
|
|
122385
|
-
function andKCLangNode(...expressions) {
|
|
122386
|
-
return {
|
|
122387
|
-
type: "and",
|
|
122388
|
-
expressions: expressions
|
|
122389
|
-
};
|
|
122390
|
-
}
|
|
122391
|
-
;
|
|
122392
|
-
|
|
122393
|
-
(function () {
|
|
122394
|
-
var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;
|
|
122395
|
-
|
|
122396
|
-
if (!reactHotLoader) {
|
|
122397
|
-
return;
|
|
122398
|
-
}
|
|
122399
|
-
|
|
122400
|
-
reactHotLoader.register(isFormulaStatement, "isFormulaStatement", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangNodes.ts");
|
|
122401
|
-
reactHotLoader.register(isBlockStatement, "isBlockStatement", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangNodes.ts");
|
|
122402
|
-
reactHotLoader.register(isEnsureStatement, "isEnsureStatement", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangNodes.ts");
|
|
122403
|
-
reactHotLoader.register(isConditionalStatement, "isConditionalStatement", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangNodes.ts");
|
|
122404
|
-
reactHotLoader.register(isDescribeStatement, "isDescribeStatement", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangNodes.ts");
|
|
122405
|
-
reactHotLoader.register(andKCLangNode, "andKCLangNode", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangNodes.ts");
|
|
122406
|
-
})();
|
|
122407
|
-
|
|
122408
|
-
;
|
|
122409
|
-
|
|
122410
|
-
(function () {
|
|
122411
|
-
var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
|
|
122412
|
-
leaveModule && leaveModule(module);
|
|
122413
|
-
})();
|
|
122414
|
-
|
|
122415
|
-
/***/ }),
|
|
122416
|
-
|
|
122417
122029
|
/***/ "./Generator/src/common/KCLang/KCLangToJsTranspiler.ts":
|
|
122418
122030
|
/*!*************************************************************!*\
|
|
122419
122031
|
!*** ./Generator/src/common/KCLang/KCLangToJsTranspiler.ts ***!
|
|
@@ -122742,421 +122354,6 @@ class KCLangToJsTranspiler {
|
|
|
122742
122354
|
|
|
122743
122355
|
/***/ }),
|
|
122744
122356
|
|
|
122745
|
-
/***/ "./Generator/src/common/KCLang/KCLangToXmlTranspiler.ts":
|
|
122746
|
-
/*!**************************************************************!*\
|
|
122747
|
-
!*** ./Generator/src/common/KCLang/KCLangToXmlTranspiler.ts ***!
|
|
122748
|
-
\**************************************************************/
|
|
122749
|
-
/***/ ((module, __webpack_exports__, __webpack_require__) => {
|
|
122750
|
-
|
|
122751
|
-
"use strict";
|
|
122752
|
-
__webpack_require__.r(__webpack_exports__);
|
|
122753
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
122754
|
-
/* harmony export */ "KCLangToXmlTranspiler": () => (/* binding */ KCLangToXmlTranspiler),
|
|
122755
|
-
/* harmony export */ "kclang": () => (/* binding */ kclang)
|
|
122756
|
-
/* harmony export */ });
|
|
122757
|
-
/* harmony import */ var _Common_Errors__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../../../Common/Errors */ "./Common/Errors.ts");
|
|
122758
|
-
/* harmony import */ var _Common_TypingUtils__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../Common/TypingUtils */ "./Common/TypingUtils.ts");
|
|
122759
|
-
/* harmony import */ var _IKCLangExpressionVisitor__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./IKCLangExpressionVisitor */ "./Generator/src/common/KCLang/IKCLangExpressionVisitor.ts");
|
|
122760
|
-
/* harmony import */ var _KCLangDescriptionParser__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./KCLangDescriptionParser */ "./Generator/src/common/KCLang/KCLangDescriptionParser.ts");
|
|
122761
|
-
/* harmony import */ var _KCLangNodes__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./KCLangNodes */ "./Generator/src/common/KCLang/KCLangNodes.ts");
|
|
122762
|
-
/* harmony import */ var _Utils__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./Utils */ "./Generator/src/common/KCLang/Utils.ts");
|
|
122763
|
-
/* harmony import */ var _Antlr_KCLangAntlrParser__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./Antlr/KCLangAntlrParser */ "./Generator/src/common/KCLang/Antlr/KCLangAntlrParser.ts");
|
|
122764
|
-
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
122765
|
-
(function () {
|
|
122766
|
-
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
122767
|
-
enterModule && enterModule(module);
|
|
122768
|
-
})();
|
|
122769
|
-
|
|
122770
|
-
var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
|
|
122771
|
-
return a;
|
|
122772
|
-
};
|
|
122773
|
-
|
|
122774
|
-
|
|
122775
|
-
|
|
122776
|
-
|
|
122777
|
-
|
|
122778
|
-
|
|
122779
|
-
|
|
122780
|
-
// tslint:disable-next-line:cyclomatic-complexity
|
|
122781
|
-
|
|
122782
|
-
function generateKCXmlExpression(expression) {
|
|
122783
|
-
switch (expression.type) {
|
|
122784
|
-
case "abs":
|
|
122785
|
-
case "xabs":
|
|
122786
|
-
case "length":
|
|
122787
|
-
return [`<m:${expression.type}>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.expression), 1), `</m:${expression.type}>`].join("\n");
|
|
122788
|
-
|
|
122789
|
-
case "exists":
|
|
122790
|
-
case "multySum":
|
|
122791
|
-
return `<m:${expression.type} select="${expression.select}" />`;
|
|
122792
|
-
|
|
122793
|
-
case "cast":
|
|
122794
|
-
if (expression.expression.type === "argument") {
|
|
122795
|
-
return `<m:argument select="${expression.expression.select}" type="${expression.targetType}" />`;
|
|
122796
|
-
}
|
|
122797
|
-
|
|
122798
|
-
throw new Error("Cast supports only for argument");
|
|
122799
|
-
|
|
122800
|
-
case "and":
|
|
122801
|
-
case "or":
|
|
122802
|
-
return [`<m:${expression.type}>`, ...expression.expressions.map(generateKCXmlExpression).map(x => (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(x, 1)), `</m:${expression.type}>`].join("\n");
|
|
122803
|
-
|
|
122804
|
-
case "sum":
|
|
122805
|
-
return [`<m:sum>`, ...expression.operands.map(operand => {
|
|
122806
|
-
if (operand.operator === "+") {
|
|
122807
|
-
return generateKCXmlExpression(operand.expression);
|
|
122808
|
-
}
|
|
122809
|
-
|
|
122810
|
-
return [`<m:minus>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(operand.expression), 1), `</m:minus>`].join("\n");
|
|
122811
|
-
}).map(x => (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(x, 1)), `</m:sum>`].join("\n");
|
|
122812
|
-
|
|
122813
|
-
case "gt":
|
|
122814
|
-
case "ge":
|
|
122815
|
-
case "lt":
|
|
122816
|
-
case "le":
|
|
122817
|
-
case "eq":
|
|
122818
|
-
case "multiply":
|
|
122819
|
-
case "division":
|
|
122820
|
-
return [`<m:${expression.type}>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.expressions[0]), 1), (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.expressions[1]), 1), `</m:${expression.type}>`].join("\n");
|
|
122821
|
-
|
|
122822
|
-
case "noteq":
|
|
122823
|
-
return [`<m:not>`, ` <m:eq>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.expressions[0]), 2), (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.expressions[1]), 2), ` </m:eq>`, `</m:not>`].join("\n");
|
|
122824
|
-
|
|
122825
|
-
case "minus":
|
|
122826
|
-
case "not":
|
|
122827
|
-
return [`<m:${expression.type}>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.expression), 1), `</m:${expression.type}>`].join("\n");
|
|
122828
|
-
break;
|
|
122829
|
-
break;
|
|
122830
|
-
|
|
122831
|
-
case "round":
|
|
122832
|
-
return [expression.fractionalDigits != undefined ? `<m:round fractionalDigits="${expression.fractionalDigits}">` : `<m:round>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.expression), 1), `</m:round>`].join("\n");
|
|
122833
|
-
|
|
122834
|
-
case "substring":
|
|
122835
|
-
return [expression.length != undefined ? `<m:substring start="${expression.start}" length="${expression.length}">` : `<m:substring start="${expression.start}">`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.expression), 1), `</m:substring>`].join("\n");
|
|
122836
|
-
|
|
122837
|
-
case "regexMatch":
|
|
122838
|
-
return [`<m:regexMatch pattern="${expression.pattern}">`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.expression), 1), `</m:regexMatch>`].join("\n");
|
|
122839
|
-
|
|
122840
|
-
case "choose":
|
|
122841
|
-
return [`<m:choose>`, ` <m:if>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.if), 2), ` </m:if>`, ` <m:then>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.then), 2), ` </m:then>`, ` <m:else>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(expression.else), 2), ` </m:else>`, `</m:choose>`].join("\n");
|
|
122842
|
-
break;
|
|
122843
|
-
|
|
122844
|
-
case "const":
|
|
122845
|
-
if (expression.value.type === "decimal") {
|
|
122846
|
-
return `<m:const value="${expression.value.value}" type="decimal" />`;
|
|
122847
|
-
}
|
|
122848
|
-
|
|
122849
|
-
if (expression.value.type === "string") {
|
|
122850
|
-
return `<m:const value="${expression.value.value}" type="string" />`;
|
|
122851
|
-
}
|
|
122852
|
-
|
|
122853
|
-
throw new _Common_Errors__WEBPACK_IMPORTED_MODULE_0__.NotImplementedError();
|
|
122854
|
-
|
|
122855
|
-
case "argument":
|
|
122856
|
-
return `<m:argument select="${expression.select}" />`;
|
|
122857
|
-
|
|
122858
|
-
case "oneof":
|
|
122859
|
-
{
|
|
122860
|
-
const testExpr = generateKCXmlExpression(expression.testExpression);
|
|
122861
|
-
return [`<m:or>`, ...expression.expressions.items.map(x => [`<m:eq>`, (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(testExpr, 1), (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(x), 1), `</m:eq>`]).flat().map(x => (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(x, 1)), `</m:or>`].join("\n");
|
|
122862
|
-
}
|
|
122863
|
-
|
|
122864
|
-
default:
|
|
122865
|
-
// @ts-ignore
|
|
122866
|
-
throw new Error(`Expression of type '${expression.type}' is not supported`);
|
|
122867
|
-
}
|
|
122868
|
-
}
|
|
122869
|
-
|
|
122870
|
-
function formatDescribeStatement(ast, matchPath, describe) {
|
|
122871
|
-
return _KCLangDescriptionParser__WEBPACK_IMPORTED_MODULE_3__.KCLangDescriptionParser.parse(describe.text).map(item => {
|
|
122872
|
-
if (typeof item === "string") {
|
|
122873
|
-
return item;
|
|
122874
|
-
} else {
|
|
122875
|
-
return `{{link ref=${item.src}}}${item.text.join(" ")}{{/link}}`;
|
|
122876
|
-
}
|
|
122877
|
-
}).join(" ");
|
|
122878
|
-
}
|
|
122879
|
-
|
|
122880
|
-
function generateKCXmlFormula(ast, matchPath, describe) {
|
|
122881
|
-
const descriptionAttr = describe != undefined ? ` description="${formatDescribeStatement(ast, matchPath, describe)}"` : "";
|
|
122882
|
-
return `<m:formula match="${matchPath}" target="${ast.target}"${descriptionAttr}>\n` + (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(ast.expression), 1) + "\n" + `</m:formula>`;
|
|
122883
|
-
}
|
|
122884
|
-
|
|
122885
|
-
function removeTrailingSlash(inputStr) {
|
|
122886
|
-
if (inputStr.endsWith("/")) {
|
|
122887
|
-
return inputStr.substring(0, inputStr.length - 1);
|
|
122888
|
-
}
|
|
122889
|
-
|
|
122890
|
-
return inputStr;
|
|
122891
|
-
}
|
|
122892
|
-
|
|
122893
|
-
function joinPaths(paths) {
|
|
122894
|
-
return paths.map(removeTrailingSlash).join("/");
|
|
122895
|
-
}
|
|
122896
|
-
|
|
122897
|
-
function generateBlockKCXmlFormulas(block, parents) {
|
|
122898
|
-
const matchPath = joinPaths([...(parents !== null && parents !== void 0 ? parents : []).map(x => x.path), block.path]);
|
|
122899
|
-
const result = [];
|
|
122900
|
-
let lastDescribeStatement;
|
|
122901
|
-
|
|
122902
|
-
for (const statement of block.statements) {
|
|
122903
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isFormulaStatement)(statement)) {
|
|
122904
|
-
result.push(generateKCXmlFormula(statement, matchPath, lastDescribeStatement));
|
|
122905
|
-
lastDescribeStatement = undefined;
|
|
122906
|
-
}
|
|
122907
|
-
|
|
122908
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isEnsureStatement)(statement)) {
|
|
122909
|
-
lastDescribeStatement = undefined;
|
|
122910
|
-
}
|
|
122911
|
-
|
|
122912
|
-
if (lastDescribeStatement != undefined) {
|
|
122913
|
-
throw new Error("Describe should be placed before assign of ensure statements");
|
|
122914
|
-
}
|
|
122915
|
-
|
|
122916
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isDescribeStatement)(statement)) {
|
|
122917
|
-
lastDescribeStatement = statement;
|
|
122918
|
-
}
|
|
122919
|
-
|
|
122920
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isBlockStatement)(statement)) {
|
|
122921
|
-
result.push(generateBlockKCXmlFormulas(statement, [...(parents !== null && parents !== void 0 ? parents : []), block]));
|
|
122922
|
-
}
|
|
122923
|
-
}
|
|
122924
|
-
|
|
122925
|
-
return result.join("\n");
|
|
122926
|
-
}
|
|
122927
|
-
|
|
122928
|
-
function guessConditionTarget(condition) {
|
|
122929
|
-
let result;
|
|
122930
|
-
|
|
122931
|
-
class GuessConditionTargetVisitor extends _IKCLangExpressionVisitor__WEBPACK_IMPORTED_MODULE_2__.DefaultKCLangExpressionVisitor {
|
|
122932
|
-
visitExistsKCLangNode(node) {
|
|
122933
|
-
if (result == undefined) {
|
|
122934
|
-
result = node.select;
|
|
122935
|
-
}
|
|
122936
|
-
}
|
|
122937
|
-
|
|
122938
|
-
visitArgumentKCLangNode(node) {
|
|
122939
|
-
if (result == undefined) {
|
|
122940
|
-
result = node.select;
|
|
122941
|
-
}
|
|
122942
|
-
}
|
|
122943
|
-
|
|
122944
|
-
// @ts-ignore
|
|
122945
|
-
__reactstandin__regenerateByEval(key, code) {
|
|
122946
|
-
// @ts-ignore
|
|
122947
|
-
this[key] = eval(code);
|
|
122948
|
-
}
|
|
122949
|
-
|
|
122950
|
-
}
|
|
122951
|
-
|
|
122952
|
-
(0,_IKCLangExpressionVisitor__WEBPACK_IMPORTED_MODULE_2__.traverseKCLangExpression)(condition.expression, new GuessConditionTargetVisitor());
|
|
122953
|
-
return result;
|
|
122954
|
-
}
|
|
122955
|
-
|
|
122956
|
-
function generateKCXmlCondition(ast, matchPath, parentConditions, describe) {
|
|
122957
|
-
const levelAttr = ast.level === "error" ? ` errorLevel="Error"` : "";
|
|
122958
|
-
const descriptionAttr = describe != undefined ? ` description="${formatDescribeStatement(ast, matchPath, describe)}"` : "";
|
|
122959
|
-
const guessedTarget = guessConditionTarget(ast);
|
|
122960
|
-
const targetAttr = guessedTarget != undefined ? ` target="${guessedTarget}"` : "";
|
|
122961
|
-
|
|
122962
|
-
if (parentConditions != undefined && (0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_1__.arrayIsNotEmpty)(parentConditions)) {
|
|
122963
|
-
var _parentConditions$map;
|
|
122964
|
-
|
|
122965
|
-
const condition = parentConditions.length === 1 ? parentConditions[0].condition : (0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.andKCLangNode)(...((_parentConditions$map = parentConditions === null || parentConditions === void 0 ? void 0 : parentConditions.map(z => z.condition)) !== null && _parentConditions$map !== void 0 ? _parentConditions$map : []));
|
|
122966
|
-
return `<m:condition match="${matchPath}"${descriptionAttr}${levelAttr}${targetAttr}>\n` + ` <m:when>\n` + (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(condition), 2) + "\n" + (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(ast.expression), 2) + "\n" + ` </m:when>\n` + `</m:condition>`;
|
|
122967
|
-
}
|
|
122968
|
-
|
|
122969
|
-
return `<m:condition match="${matchPath}"${descriptionAttr}${levelAttr}${targetAttr}>\n` + (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlExpression(ast.expression), 1) + "\n" + `</m:condition>`;
|
|
122970
|
-
}
|
|
122971
|
-
|
|
122972
|
-
function generateBlockKCXmlConditions(block, parents, parentConditions) {
|
|
122973
|
-
const matchPath = joinPaths([...(parents !== null && parents !== void 0 ? parents : []).map(x => x.path), block.path]);
|
|
122974
|
-
const result = [];
|
|
122975
|
-
let lastDescribeStatement;
|
|
122976
|
-
|
|
122977
|
-
for (const statement of block.statements) {
|
|
122978
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isFormulaStatement)(statement)) {
|
|
122979
|
-
lastDescribeStatement = undefined;
|
|
122980
|
-
}
|
|
122981
|
-
|
|
122982
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isEnsureStatement)(statement)) {
|
|
122983
|
-
result.push(generateKCXmlCondition(statement, matchPath, parentConditions, lastDescribeStatement));
|
|
122984
|
-
lastDescribeStatement = undefined;
|
|
122985
|
-
}
|
|
122986
|
-
|
|
122987
|
-
if (lastDescribeStatement != undefined) {
|
|
122988
|
-
throw new Error("Describe should be placed before assign of ensure statements");
|
|
122989
|
-
}
|
|
122990
|
-
|
|
122991
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isDescribeStatement)(statement)) {
|
|
122992
|
-
lastDescribeStatement = statement;
|
|
122993
|
-
}
|
|
122994
|
-
|
|
122995
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isConditionalStatement)(statement)) {
|
|
122996
|
-
result.push(generateConditionalConditions(statement, [...(parents !== null && parents !== void 0 ? parents : []), block], parentConditions));
|
|
122997
|
-
}
|
|
122998
|
-
|
|
122999
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isBlockStatement)(statement)) {
|
|
123000
|
-
result.push(generateBlockKCXmlConditions(statement, [...(parents !== null && parents !== void 0 ? parents : []), block], parentConditions));
|
|
123001
|
-
}
|
|
123002
|
-
}
|
|
123003
|
-
|
|
123004
|
-
return result.join("\n");
|
|
123005
|
-
}
|
|
123006
|
-
|
|
123007
|
-
function generateConditionalConditions(conditionalStatement, parents, parentConditions) {
|
|
123008
|
-
const matchPath = joinPaths([...(parents !== null && parents !== void 0 ? parents : []).map(x => x.path)]);
|
|
123009
|
-
const result = [];
|
|
123010
|
-
let lastDescribeStatement;
|
|
123011
|
-
|
|
123012
|
-
for (const x of conditionalStatement.statements) {
|
|
123013
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isEnsureStatement)(x)) {
|
|
123014
|
-
result.push(generateKCXmlCondition(x, matchPath, [...(parentConditions !== null && parentConditions !== void 0 ? parentConditions : []), conditionalStatement], lastDescribeStatement));
|
|
123015
|
-
lastDescribeStatement = undefined;
|
|
123016
|
-
}
|
|
123017
|
-
|
|
123018
|
-
if (lastDescribeStatement != undefined) {
|
|
123019
|
-
throw new Error("Describe should be placed before assign of ensure statements");
|
|
123020
|
-
}
|
|
123021
|
-
|
|
123022
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isDescribeStatement)(x)) {
|
|
123023
|
-
lastDescribeStatement = x;
|
|
123024
|
-
}
|
|
123025
|
-
|
|
123026
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isConditionalStatement)(x)) {
|
|
123027
|
-
result.push(generateConditionalConditions(x, parents, [...(parentConditions !== null && parentConditions !== void 0 ? parentConditions : []), conditionalStatement]));
|
|
123028
|
-
}
|
|
123029
|
-
|
|
123030
|
-
if ((0,_KCLangNodes__WEBPACK_IMPORTED_MODULE_4__.isBlockStatement)(x)) {
|
|
123031
|
-
result.push(generateBlockKCXmlConditions(x, parents, [...(parentConditions !== null && parentConditions !== void 0 ? parentConditions : []), conditionalStatement]));
|
|
123032
|
-
}
|
|
123033
|
-
}
|
|
123034
|
-
|
|
123035
|
-
return result.join("\n");
|
|
123036
|
-
}
|
|
123037
|
-
|
|
123038
|
-
function generateKCXmlFormulas(blocks) {
|
|
123039
|
-
const formulas = Iterator.from(blocks).map(generateBlockKCXmlFormulas).toArray();
|
|
123040
|
-
|
|
123041
|
-
if (formulas.filter(x => x !== "").length > 0) {
|
|
123042
|
-
return `<m:formulas>\n` + (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(formulas.join("\n"), 1) + "\n" + `</m:formulas>\n`;
|
|
123043
|
-
} else {
|
|
123044
|
-
return "";
|
|
123045
|
-
}
|
|
123046
|
-
}
|
|
123047
|
-
|
|
123048
|
-
function generateKCXmlConditions(blocks) {
|
|
123049
|
-
const conditions = Iterator.from(blocks).map(generateBlockKCXmlConditions).toArray();
|
|
123050
|
-
|
|
123051
|
-
if (conditions.filter(x => x !== "").length > 0) {
|
|
123052
|
-
return `<m:conditions>\n` + (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(conditions.join("\n"), 1) + "\n" + `</m:conditions>\n`;
|
|
123053
|
-
} else {
|
|
123054
|
-
return "";
|
|
123055
|
-
}
|
|
123056
|
-
}
|
|
123057
|
-
|
|
123058
|
-
function generateKCXml(blocks) {
|
|
123059
|
-
return `<?xml version="1.0" encoding="utf-8"?>\n` + `<m:math xmlns:m="http://www.kontur-extern.ru/ФНС 4.0/math.xsd">\n` + (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlFormulas(blocks), 1) + (0,_Utils__WEBPACK_IMPORTED_MODULE_5__.indent)(generateKCXmlConditions(blocks), 1) + `</m:math>`;
|
|
123060
|
-
}
|
|
123061
|
-
|
|
123062
|
-
class KCLangToXmlTranspiler {
|
|
123063
|
-
static transpile(kcLang, customParser) {
|
|
123064
|
-
const parser = customParser !== null && customParser !== void 0 ? customParser : _Antlr_KCLangAntlrParser__WEBPACK_IMPORTED_MODULE_6__.KCLangAntlrParser.parse;
|
|
123065
|
-
const kcxml = generateKCXml(parser(kcLang).blocks);
|
|
123066
|
-
return kcxml;
|
|
123067
|
-
}
|
|
123068
|
-
|
|
123069
|
-
}
|
|
123070
|
-
function kclang(str) {
|
|
123071
|
-
return KCLangToXmlTranspiler.transpile(str.join(""));
|
|
123072
|
-
}
|
|
123073
|
-
;
|
|
123074
|
-
|
|
123075
|
-
(function () {
|
|
123076
|
-
var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;
|
|
123077
|
-
|
|
123078
|
-
if (!reactHotLoader) {
|
|
123079
|
-
return;
|
|
123080
|
-
}
|
|
123081
|
-
|
|
123082
|
-
reactHotLoader.register(generateKCXmlExpression, "generateKCXmlExpression", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123083
|
-
reactHotLoader.register(formatDescribeStatement, "formatDescribeStatement", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123084
|
-
reactHotLoader.register(generateKCXmlFormula, "generateKCXmlFormula", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123085
|
-
reactHotLoader.register(removeTrailingSlash, "removeTrailingSlash", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123086
|
-
reactHotLoader.register(joinPaths, "joinPaths", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123087
|
-
reactHotLoader.register(generateBlockKCXmlFormulas, "generateBlockKCXmlFormulas", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123088
|
-
reactHotLoader.register(guessConditionTarget, "guessConditionTarget", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123089
|
-
reactHotLoader.register(generateKCXmlCondition, "generateKCXmlCondition", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123090
|
-
reactHotLoader.register(generateBlockKCXmlConditions, "generateBlockKCXmlConditions", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123091
|
-
reactHotLoader.register(generateConditionalConditions, "generateConditionalConditions", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123092
|
-
reactHotLoader.register(generateKCXmlFormulas, "generateKCXmlFormulas", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123093
|
-
reactHotLoader.register(generateKCXmlConditions, "generateKCXmlConditions", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123094
|
-
reactHotLoader.register(generateKCXml, "generateKCXml", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123095
|
-
reactHotLoader.register(KCLangToXmlTranspiler, "KCLangToXmlTranspiler", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123096
|
-
reactHotLoader.register(kclang, "kclang", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\KCLangToXmlTranspiler.ts");
|
|
123097
|
-
})();
|
|
123098
|
-
|
|
123099
|
-
;
|
|
123100
|
-
|
|
123101
|
-
(function () {
|
|
123102
|
-
var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
|
|
123103
|
-
leaveModule && leaveModule(module);
|
|
123104
|
-
})();
|
|
123105
|
-
|
|
123106
|
-
/***/ }),
|
|
123107
|
-
|
|
123108
|
-
/***/ "./Generator/src/common/KCLang/Utils.ts":
|
|
123109
|
-
/*!**********************************************!*\
|
|
123110
|
-
!*** ./Generator/src/common/KCLang/Utils.ts ***!
|
|
123111
|
-
\**********************************************/
|
|
123112
|
-
/***/ ((module, __webpack_exports__, __webpack_require__) => {
|
|
123113
|
-
|
|
123114
|
-
"use strict";
|
|
123115
|
-
__webpack_require__.r(__webpack_exports__);
|
|
123116
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
123117
|
-
/* harmony export */ "indent": () => (/* binding */ indent)
|
|
123118
|
-
/* harmony export */ });
|
|
123119
|
-
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
123120
|
-
(function () {
|
|
123121
|
-
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
123122
|
-
enterModule && enterModule(module);
|
|
123123
|
-
})();
|
|
123124
|
-
|
|
123125
|
-
var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
|
|
123126
|
-
return a;
|
|
123127
|
-
};
|
|
123128
|
-
|
|
123129
|
-
function indent(str, count) {
|
|
123130
|
-
const indentStr = new Array(count * 2).fill(" ").join("");
|
|
123131
|
-
return str.split("\n").map(x => {
|
|
123132
|
-
if (x === "") {
|
|
123133
|
-
return x;
|
|
123134
|
-
}
|
|
123135
|
-
|
|
123136
|
-
return indentStr + x;
|
|
123137
|
-
}).join("\n");
|
|
123138
|
-
}
|
|
123139
|
-
;
|
|
123140
|
-
|
|
123141
|
-
(function () {
|
|
123142
|
-
var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;
|
|
123143
|
-
|
|
123144
|
-
if (!reactHotLoader) {
|
|
123145
|
-
return;
|
|
123146
|
-
}
|
|
123147
|
-
|
|
123148
|
-
reactHotLoader.register(indent, "indent", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\common\\KCLang\\Utils.ts");
|
|
123149
|
-
})();
|
|
123150
|
-
|
|
123151
|
-
;
|
|
123152
|
-
|
|
123153
|
-
(function () {
|
|
123154
|
-
var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
|
|
123155
|
-
leaveModule && leaveModule(module);
|
|
123156
|
-
})();
|
|
123157
|
-
|
|
123158
|
-
/***/ }),
|
|
123159
|
-
|
|
123160
122357
|
/***/ "./Generator/src/common/RequireContext/LoadDocumentationFileFormContext.ts":
|
|
123161
122358
|
/*!*********************************************************************************!*\
|
|
123162
122359
|
!*** ./Generator/src/common/RequireContext/LoadDocumentationFileFormContext.ts ***!
|
|
@@ -124006,7 +123203,7 @@ let MaxinclusiveTypeCheck = (_dec19 = (0,_generators_markupGenerator_Serializer_
|
|
|
124006
123203
|
writable: true,
|
|
124007
123204
|
initializer: null
|
|
124008
123205
|
})), _class29)) || _class28);
|
|
124009
|
-
let SchemaRngType = (_dec21 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.sugarNode)("type", ``), _dec22 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("base", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType["enum"]("string", "pattern", "integer", "decimal", "date", "gYear", "
|
|
123206
|
+
let SchemaRngType = (_dec21 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.sugarNode)("type", ``), _dec22 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("base", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType["enum"]("string", "pattern", "integer", "decimal", "date", "gYear", "dateTime", "int", "boolean", "double"), ``), _dec23 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("description", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.string, ``), _dec24 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attr)("requiredDescription", _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.attrType.string, ``), _dec25 = (0,_generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.children)(undefined, [PatternTypeCheck, EnumerationTypeCheck, LengthTypeCheck, MinlengthTypeCheck, MaxlengthTypeCheck, TotaldigitsTypeCheck, IntegerdigitsTypeCheck, FractiondigitsTypeCheck, MininclusiveTypeCheck, MaxinclusiveTypeCheck]), _dec21(_class31 = (_class32 = class SchemaRngType extends _generators_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_0__.SugarNodeBase {
|
|
124010
123207
|
constructor(...args) {
|
|
124011
123208
|
super(...args);
|
|
124012
123209
|
|
|
@@ -130205,7 +129402,8 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
130205
129402
|
|
|
130206
129403
|
|
|
130207
129404
|
class FormulasAutoCalculationsGenerator {
|
|
130208
|
-
generate(
|
|
129405
|
+
generate(formulaContainer, schemaRng, dataDeclarationHelper) {
|
|
129406
|
+
const formulas = formulaContainer.formulas == undefined || formulaContainer.formulas.items == undefined ? [] : formulaContainer.formulas.items;
|
|
130209
129407
|
const formulaAutoCalculations = formulas.map(formula => this.buildFormulaAutoCalculation(formula, schemaRng, dataDeclarationHelper)).flat();
|
|
130210
129408
|
return this.mergeFormulaAutoCalculations(formulaAutoCalculations);
|
|
130211
129409
|
}
|
|
@@ -131215,8 +130413,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
131215
130413
|
/* harmony export */ });
|
|
131216
130414
|
/* harmony import */ var _common_XmlParser_XmlParser__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../../../common/XmlParser/XmlParser */ "./Generator/src/common/XmlParser/XmlParser.ts");
|
|
131217
130415
|
/* harmony import */ var _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../markupGenerator/Serializer/SugarSerializer */ "./Generator/src/generators/markupGenerator/Serializer/SugarSerializer.ts");
|
|
131218
|
-
/* harmony import */ var
|
|
131219
|
-
/* harmony import */ var _Formula__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./Formula */ "./Generator/src/generators/AutoCalculationsGenerator/AutoCalculationsFromFormulas/KCXmlContract/Formula.ts");
|
|
130416
|
+
/* harmony import */ var _Formula__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./Formula */ "./Generator/src/generators/AutoCalculationsGenerator/AutoCalculationsFromFormulas/KCXmlContract/Formula.ts");
|
|
131220
130417
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
131221
130418
|
(function () {
|
|
131222
130419
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -131230,68 +130427,31 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
131230
130427
|
|
|
131231
130428
|
|
|
131232
130429
|
|
|
131233
|
-
|
|
131234
130430
|
class FormulaReader {
|
|
131235
|
-
readFormulas(
|
|
130431
|
+
readFormulas(kcxmlSource) {
|
|
131236
130432
|
const serializer = this.createFormulaSerializer();
|
|
131237
|
-
const result =
|
|
130433
|
+
const result = serializer.deserializeFromSugarXmlNode((0,_common_XmlParser_XmlParser__WEBPACK_IMPORTED_MODULE_0__.parseXml)(kcxmlSource));
|
|
131238
130434
|
|
|
131239
|
-
|
|
131240
|
-
|
|
131241
|
-
|
|
131242
|
-
if (rootNode instanceof _Formula__WEBPACK_IMPORTED_MODULE_3__.MathContainer) {
|
|
131243
|
-
var _rootNode$formulas$it, _rootNode$formulas;
|
|
131244
|
-
|
|
131245
|
-
result.push(...((_rootNode$formulas$it = (_rootNode$formulas = rootNode.formulas) === null || _rootNode$formulas === void 0 ? void 0 : _rootNode$formulas.items) !== null && _rootNode$formulas$it !== void 0 ? _rootNode$formulas$it : []));
|
|
131246
|
-
}
|
|
131247
|
-
}
|
|
131248
|
-
|
|
131249
|
-
for (const kclangSource of kclangSources) {
|
|
131250
|
-
const rootNode = serializer.deserializeFromSugarXmlNode((0,_common_XmlParser_XmlParser__WEBPACK_IMPORTED_MODULE_0__.parseXml)(_common_KCLang_KCLangToXmlTranspiler__WEBPACK_IMPORTED_MODULE_2__.KCLangToXmlTranspiler.transpile(kclangSource)));
|
|
131251
|
-
|
|
131252
|
-
if (rootNode instanceof _Formula__WEBPACK_IMPORTED_MODULE_3__.MathContainer) {
|
|
131253
|
-
var _rootNode$formulas$it2, _rootNode$formulas2;
|
|
131254
|
-
|
|
131255
|
-
result.push(...((_rootNode$formulas$it2 = (_rootNode$formulas2 = rootNode.formulas) === null || _rootNode$formulas2 === void 0 ? void 0 : _rootNode$formulas2.items) !== null && _rootNode$formulas$it2 !== void 0 ? _rootNode$formulas$it2 : []));
|
|
131256
|
-
}
|
|
130435
|
+
if (result instanceof _Formula__WEBPACK_IMPORTED_MODULE_2__.DummyContent) {
|
|
130436
|
+
return this.createEmptyMathContainer();
|
|
131257
130437
|
}
|
|
131258
130438
|
|
|
131259
130439
|
return result;
|
|
131260
130440
|
}
|
|
131261
130441
|
|
|
131262
|
-
|
|
131263
|
-
const
|
|
131264
|
-
|
|
131265
|
-
|
|
131266
|
-
|
|
131267
|
-
const rootNode = serializer.deserializeFromSugarXmlNode((0,_common_XmlParser_XmlParser__WEBPACK_IMPORTED_MODULE_0__.parseXml)(kcxmlSource));
|
|
131268
|
-
|
|
131269
|
-
if (rootNode instanceof _Formula__WEBPACK_IMPORTED_MODULE_3__.MathContainer) {
|
|
131270
|
-
var _rootNode$conditions$, _rootNode$conditions;
|
|
131271
|
-
|
|
131272
|
-
result.push(...((_rootNode$conditions$ = (_rootNode$conditions = rootNode.conditions) === null || _rootNode$conditions === void 0 ? void 0 : _rootNode$conditions.items) !== null && _rootNode$conditions$ !== void 0 ? _rootNode$conditions$ : []));
|
|
131273
|
-
}
|
|
131274
|
-
}
|
|
131275
|
-
|
|
131276
|
-
for (const kclangSource of kclangSources) {
|
|
131277
|
-
const rootNode = serializer.deserializeFromSugarXmlNode((0,_common_XmlParser_XmlParser__WEBPACK_IMPORTED_MODULE_0__.parseXml)(_common_KCLang_KCLangToXmlTranspiler__WEBPACK_IMPORTED_MODULE_2__.KCLangToXmlTranspiler.transpile(kclangSource)));
|
|
131278
|
-
|
|
131279
|
-
if (rootNode instanceof _Formula__WEBPACK_IMPORTED_MODULE_3__.MathContainer) {
|
|
131280
|
-
var _rootNode$conditions$2, _rootNode$conditions2;
|
|
131281
|
-
|
|
131282
|
-
result.push(...((_rootNode$conditions$2 = (_rootNode$conditions2 = rootNode.conditions) === null || _rootNode$conditions2 === void 0 ? void 0 : _rootNode$conditions2.items) !== null && _rootNode$conditions$2 !== void 0 ? _rootNode$conditions$2 : []));
|
|
131283
|
-
}
|
|
131284
|
-
}
|
|
131285
|
-
|
|
131286
|
-
return result;
|
|
130442
|
+
createEmptyMathContainer() {
|
|
130443
|
+
const mathContainer = new _Formula__WEBPACK_IMPORTED_MODULE_2__.MathContainer();
|
|
130444
|
+
mathContainer.formulas = new _Formula__WEBPACK_IMPORTED_MODULE_2__.Formulas();
|
|
130445
|
+
mathContainer.formulas.items = [];
|
|
130446
|
+
return mathContainer;
|
|
131287
130447
|
}
|
|
131288
130448
|
|
|
131289
130449
|
createFormulaSerializer() {
|
|
131290
130450
|
const result = new _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.SugarSerializer();
|
|
131291
|
-
result.registerNode(
|
|
131292
|
-
result.registerNode(
|
|
130451
|
+
result.registerNode(_Formula__WEBPACK_IMPORTED_MODULE_2__.DummyContent);
|
|
130452
|
+
result.registerNode(_Formula__WEBPACK_IMPORTED_MODULE_2__.MathContainer);
|
|
131293
130453
|
|
|
131294
|
-
for (const formulaExpression of
|
|
130454
|
+
for (const formulaExpression of _Formula__WEBPACK_IMPORTED_MODULE_2__.formulaExpressions) {
|
|
131295
130455
|
result.registerNode(formulaExpression);
|
|
131296
130456
|
}
|
|
131297
130457
|
|
|
@@ -131732,7 +130892,6 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
131732
130892
|
/* harmony import */ var _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../Common/ModelPath/ModelPath */ "./Common/ModelPath/ModelPath.ts");
|
|
131733
130893
|
/* harmony import */ var _markupGenerator_getBindingPath__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../markupGenerator/getBindingPath */ "./Generator/src/generators/markupGenerator/getBindingPath.ts");
|
|
131734
130894
|
/* harmony import */ var _markupGenerator_ElementProcessors_FormParts_Page_PageNode__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../markupGenerator/ElementProcessors/FormParts/Page/PageNode */ "./Generator/src/generators/markupGenerator/ElementProcessors/FormParts/Page/PageNode.ts");
|
|
131735
|
-
/* harmony import */ var _common_SchemaRng_FormSchemaRng__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ../../common/SchemaRng/FormSchemaRng */ "./Generator/src/common/SchemaRng/FormSchemaRng.ts");
|
|
131736
130895
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
131737
130896
|
(function () {
|
|
131738
130897
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -131752,7 +130911,6 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
131752
130911
|
|
|
131753
130912
|
|
|
131754
130913
|
|
|
131755
|
-
|
|
131756
130914
|
var RequisiteSectionMode;
|
|
131757
130915
|
|
|
131758
130916
|
(function (RequisiteSectionMode) {
|
|
@@ -131763,10 +130921,8 @@ var RequisiteSectionMode;
|
|
|
131763
130921
|
|
|
131764
130922
|
const emptyDataDeclarationCollection = {};
|
|
131765
130923
|
class DataDeclarationGenerationContext {
|
|
131766
|
-
constructor(initSequenceFactory, controlCustomizationContext, typesRegistry
|
|
130924
|
+
constructor(initSequenceFactory, controlCustomizationContext, typesRegistry) {
|
|
131767
130925
|
this.initSequenceFactory = void 0;
|
|
131768
|
-
this.formSchemaRng = void 0;
|
|
131769
|
-
this.schemeValidations = void 0;
|
|
131770
130926
|
this.controlCustomizationContext = void 0;
|
|
131771
130927
|
this.typesRegistry = void 0;
|
|
131772
130928
|
|
|
@@ -131796,29 +130952,11 @@ class DataDeclarationGenerationContext {
|
|
|
131796
130952
|
return undefined;
|
|
131797
130953
|
};
|
|
131798
130954
|
|
|
131799
|
-
this.formSchemaRng = formSchemaRng;
|
|
131800
|
-
this.schemeValidations = schemeValidations;
|
|
131801
130955
|
this.initSequenceFactory = initSequenceFactory;
|
|
131802
130956
|
this.controlCustomizationContext = controlCustomizationContext;
|
|
131803
130957
|
this.typesRegistry = typesRegistry;
|
|
131804
130958
|
}
|
|
131805
130959
|
|
|
131806
|
-
isMultipleNodeOptionalFromScheme(path) {
|
|
131807
|
-
if (!this.schemeValidations) {
|
|
131808
|
-
return undefined;
|
|
131809
|
-
}
|
|
131810
|
-
|
|
131811
|
-
const schemaNode = this.formSchemaRng.getElementByPath(path);
|
|
131812
|
-
|
|
131813
|
-
if (schemaNode instanceof _common_SchemaRng_FormSchemaRng__WEBPACK_IMPORTED_MODULE_9__.FormSchemaRngElement) {
|
|
131814
|
-
var _schemaNode$optional;
|
|
131815
|
-
|
|
131816
|
-
return (_schemaNode$optional = schemaNode.optional) !== null && _schemaNode$optional !== void 0 ? _schemaNode$optional : false;
|
|
131817
|
-
}
|
|
131818
|
-
|
|
131819
|
-
return undefined;
|
|
131820
|
-
}
|
|
131821
|
-
|
|
131822
130960
|
getTypeNode(node) {
|
|
131823
130961
|
if (node.anonymousType != undefined) {
|
|
131824
130962
|
return node.anonymousType;
|
|
@@ -132196,15 +131334,11 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
132196
131334
|
|
|
132197
131335
|
|
|
132198
131336
|
class DataDeclarationGenerator {
|
|
132199
|
-
constructor(sugarRoot, initSequenceFactory, controlCustomizationContext, typesRegistry
|
|
131337
|
+
constructor(sugarRoot, initSequenceFactory, controlCustomizationContext, typesRegistry) {
|
|
132200
131338
|
this.sugarRoot = void 0;
|
|
132201
131339
|
this.initSequenceFactory = void 0;
|
|
132202
|
-
this.formSchemaRng = void 0;
|
|
132203
|
-
this.schemeValidations = void 0;
|
|
132204
131340
|
this.controlCustomizationContext = void 0;
|
|
132205
131341
|
this.typesRegistry = void 0;
|
|
132206
|
-
this.formSchemaRng = formSchemaRng;
|
|
132207
|
-
this.schemeValidations = schemeValidations;
|
|
132208
131342
|
this.sugarRoot = sugarRoot;
|
|
132209
131343
|
this.initSequenceFactory = initSequenceFactory;
|
|
132210
131344
|
this.controlCustomizationContext = controlCustomizationContext;
|
|
@@ -132216,7 +131350,7 @@ class DataDeclarationGenerator {
|
|
|
132216
131350
|
|
|
132217
131351
|
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)();
|
|
132218
131352
|
const converter = new converterClass(this.sugarRoot);
|
|
132219
|
-
const context = new _DataDeclarationGenerationContext__WEBPACK_IMPORTED_MODULE_7__.DataDeclarationGenerationContext(this.initSequenceFactory, this.controlCustomizationContext, this.typesRegistry
|
|
131353
|
+
const context = new _DataDeclarationGenerationContext__WEBPACK_IMPORTED_MODULE_7__.DataDeclarationGenerationContext(this.initSequenceFactory, this.controlCustomizationContext, this.typesRegistry);
|
|
132220
131354
|
const dataDeclaration = converter.buildDataDeclaration(context);
|
|
132221
131355
|
const orderedDataDeclaration = this.sortDataDeclarationKeys(dataDeclaration);
|
|
132222
131356
|
const result = this.replaceHolder(`
|
|
@@ -132250,7 +131384,7 @@ class DataDeclarationGenerator {
|
|
|
132250
131384
|
|
|
132251
131385
|
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)();
|
|
132252
131386
|
const converter = new converterClass(this.sugarRoot);
|
|
132253
|
-
const context = new _DataDeclarationGenerationContext__WEBPACK_IMPORTED_MODULE_7__.DataDeclarationGenerationContext(this.initSequenceFactory, this.controlCustomizationContext, this.typesRegistry
|
|
131387
|
+
const context = new _DataDeclarationGenerationContext__WEBPACK_IMPORTED_MODULE_7__.DataDeclarationGenerationContext(this.initSequenceFactory, this.controlCustomizationContext, this.typesRegistry);
|
|
132254
131388
|
const dataDeclaration = converter.buildDataDeclaration(context);
|
|
132255
131389
|
const orderedDataDeclaration = this.sortDataDeclarationKeys(dataDeclaration);
|
|
132256
131390
|
return `
|
|
@@ -133510,9 +132644,11 @@ class KCXmlValidationGenerator {
|
|
|
133510
132644
|
const conditionReader = new _AutoCalculationsGenerator_AutoCalculationsFromFormulas_KCXmlContract_FormulaReader__WEBPACK_IMPORTED_MODULE_2__.FormulaReader();
|
|
133511
132645
|
|
|
133512
132646
|
for (const file of importedKcXmlValidations) {
|
|
133513
|
-
const
|
|
132647
|
+
const math = conditionReader.readFormulas(file);
|
|
132648
|
+
|
|
132649
|
+
for (const condition of (_math$conditions$item = math === null || math === void 0 ? void 0 : (_math$conditions = math.conditions) === null || _math$conditions === void 0 ? void 0 : _math$conditions.items) !== null && _math$conditions$item !== void 0 ? _math$conditions$item : []) {
|
|
132650
|
+
var _math$conditions$item, _math$conditions;
|
|
133514
132651
|
|
|
133515
|
-
for (const condition of conditions) {
|
|
133516
132652
|
compiledConditions.push(this.compileCondition(condition));
|
|
133517
132653
|
}
|
|
133518
132654
|
}
|
|
@@ -133727,12 +132863,12 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
133727
132863
|
|
|
133728
132864
|
function processSugar(formSugarContent, additionalContent, generationOptions) {
|
|
133729
132865
|
try {
|
|
133730
|
-
var _generationOptions$in, _generationOptions$in2, _sugarRoot$schemaVali, _sugarRoot$
|
|
132866
|
+
var _generationOptions$in, _generationOptions$in2, _sugarRoot$schemaVali, _sugarRoot$deepOption, _sugarRoot$schemaVali2, _generationOptions$re, _sugarRoot$schemaVali3, _additionalContent$fo, _additionalContent$fo2;
|
|
133731
132867
|
|
|
133732
132868
|
const sugarAst = (0,_common_SugarXmlParser_SugarParser__WEBPACK_IMPORTED_MODULE_4__.parseSugar)(formSugarContent, additionalContent.preprocessor || {});
|
|
133733
132869
|
const serializer = (0,_markupGenerator_SugarNodes_DefaultSugarSerializer__WEBPACK_IMPORTED_MODULE_12__.createDefaultSugarSerializer)();
|
|
133734
132870
|
const sugarRoot = (0,_markupGenerator_SugarNodes_SugarNodeUtils__WEBPACK_IMPORTED_MODULE_13__.strictCastNode)(serializer.deserializeFromSugarXmlNode(sugarAst), _markupGenerator_ElementProcessors_FormParts_Form_FormNode__WEBPACK_IMPORTED_MODULE_10__.FormNode);
|
|
133735
|
-
const formulas = new _AutoCalculationsGenerator_AutoCalculationsFromFormulas_KCXmlContract_FormulaReader__WEBPACK_IMPORTED_MODULE_16__.FormulaReader().readFormulas(additionalContent.kcJsXmlContent
|
|
132871
|
+
const formulas = new _AutoCalculationsGenerator_AutoCalculationsFromFormulas_KCXmlContract_FormulaReader__WEBPACK_IMPORTED_MODULE_16__.FormulaReader().readFormulas(additionalContent.kcJsXmlContent);
|
|
133736
132872
|
const schemaRng = (0,_common_XmlParser_XmlParser__WEBPACK_IMPORTED_MODULE_5__.parseXml)(additionalContent.schemaRngContent);
|
|
133737
132873
|
const formSchemaRng = _common_SchemaRng_FormSchemaRng__WEBPACK_IMPORTED_MODULE_3__.FormSchemaRng.createFromSchemaRng(additionalContent.schemaRngContent);
|
|
133738
132874
|
const typeRegistry = (0,_validationGenerator_TypesRegistry__WEBPACK_IMPORTED_MODULE_14__.buildTypesRegistry)(sugarRoot);
|
|
@@ -133742,17 +132878,17 @@ function processSugar(formSugarContent, additionalContent, generationOptions) {
|
|
|
133742
132878
|
const fetchFunctions = new _common_FetchFunctions__WEBPACK_IMPORTED_MODULE_2__.FetchFunctions(referencedFetchFunctions); // tslint:disable-next-line no-unsafe-any
|
|
133743
132879
|
|
|
133744
132880
|
const additionalSettings = JSON.parse(additionalContent.additionalSettings || "{}");
|
|
133745
|
-
const dataDeclarationGenerator = new _DataDeclarationGenerator_DataDeclarationGenerator__WEBPACK_IMPORTED_MODULE_18__.DataDeclarationGenerator(sugarRoot, new _DataDeclarationGenerator_DataDeclarationInitSourceSequenceFactory__WEBPACK_IMPORTED_MODULE_19__.DataDeclarationInitSourceSequenceFactory(fetchFunctions), controlCustomizationContext, typeRegistry
|
|
132881
|
+
const dataDeclarationGenerator = new _DataDeclarationGenerator_DataDeclarationGenerator__WEBPACK_IMPORTED_MODULE_18__.DataDeclarationGenerator(sugarRoot, new _DataDeclarationGenerator_DataDeclarationInitSourceSequenceFactory__WEBPACK_IMPORTED_MODULE_19__.DataDeclarationInitSourceSequenceFactory(fetchFunctions), controlCustomizationContext, typeRegistry);
|
|
133746
132882
|
const {
|
|
133747
132883
|
dataDeclarationContent,
|
|
133748
132884
|
dataDeclaration
|
|
133749
132885
|
} = dataDeclarationGenerator.generate();
|
|
133750
132886
|
const dataDeclarationHelper = new _DataDeclarationGenerator_DataDeclarationGenerationTimeHelper__WEBPACK_IMPORTED_MODULE_25__.DataDeclarationGenerationTimeHelper(dataDeclaration);
|
|
133751
|
-
const validationGenerator = new _validationGenerator_ValidationGenerator__WEBPACK_IMPORTED_MODULE_15__.ValidationGenerator(sugarRoot, typeRegistry, controlCustomizationContext, formSchemaRng, (_sugarRoot$
|
|
133752
|
-
const normalizationRulesGenerator = new _ServerSideFLangNormalization_NormalizationRulesGenerator__WEBPACK_IMPORTED_MODULE_24__.NormalizationRulesGenerator(sugarRoot, dataDeclarationHelper, formSchemaRng, formulas, typeRegistry, (_sugarRoot$
|
|
132887
|
+
const validationGenerator = new _validationGenerator_ValidationGenerator__WEBPACK_IMPORTED_MODULE_15__.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);
|
|
132888
|
+
const normalizationRulesGenerator = new _ServerSideFLangNormalization_NormalizationRulesGenerator__WEBPACK_IMPORTED_MODULE_24__.NormalizationRulesGenerator(sugarRoot, dataDeclarationHelper, formSchemaRng, formulas, typeRegistry, (_sugarRoot$schemaVali2 = sugarRoot.schemaValidations) !== null && _sugarRoot$schemaVali2 !== void 0 ? _sugarRoot$schemaVali2 : false, controlCustomizationContext);
|
|
133753
132889
|
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");
|
|
133754
132890
|
const builder = new _FormSourcesBuilder_FormSourcesBuilder__WEBPACK_IMPORTED_MODULE_20__.FormSourcesBuilder(additionalContent.formSourcesPath);
|
|
133755
|
-
const markupGenerator = new _markupGenerator_MarkupGenerator__WEBPACK_IMPORTED_MODULE_11__.MarkupGenerator(additionalContent.formSourcesPath, additionalContent.helpersContent, additionalContent.tourSteps, controlCustomizationContext, typeRegistry, formSchemaRng, dataDeclarationHelper, (_sugarRoot$
|
|
132891
|
+
const markupGenerator = new _markupGenerator_MarkupGenerator__WEBPACK_IMPORTED_MODULE_11__.MarkupGenerator(additionalContent.formSourcesPath, additionalContent.helpersContent, additionalContent.tourSteps, controlCustomizationContext, typeRegistry, formSchemaRng, dataDeclarationHelper, (_sugarRoot$schemaVali3 = sugarRoot.schemaValidations) !== null && _sugarRoot$schemaVali3 !== void 0 ? _sugarRoot$schemaVali3 : false);
|
|
133756
132892
|
markupGenerator.generate(sugarRoot, builder);
|
|
133757
132893
|
builder.addResource("settings.js", (0,_markupGenerator_getSettings__WEBPACK_IMPORTED_MODULE_8__.getSettings)(sugarRoot, additionalContent.gfv, additionalSettings));
|
|
133758
132894
|
builder.addResource("requisiteList.js", (0,_RequisiteLIst_requisiteList__WEBPACK_IMPORTED_MODULE_23__.getRequisiteList)(sugarRoot, fetchFunctions));
|
|
@@ -133885,17 +133021,19 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
133885
133021
|
/* harmony import */ var fs__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(fs__WEBPACK_IMPORTED_MODULE_0__);
|
|
133886
133022
|
/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! path */ "path");
|
|
133887
133023
|
/* harmony import */ var path__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(path__WEBPACK_IMPORTED_MODULE_1__);
|
|
133888
|
-
/* harmony import */ var
|
|
133889
|
-
/* harmony import */ var
|
|
133890
|
-
/* harmony import */ var
|
|
133891
|
-
/* harmony import */ var
|
|
133892
|
-
/* harmony import */ var
|
|
133893
|
-
/* harmony import */ var
|
|
133894
|
-
/* harmony import */ var
|
|
133895
|
-
/* harmony import */ var
|
|
133896
|
-
/* harmony import */ var
|
|
133897
|
-
/* harmony import */ var
|
|
133898
|
-
/* harmony import */ var
|
|
133024
|
+
/* harmony import */ var util__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! util */ "util");
|
|
133025
|
+
/* harmony import */ var util__WEBPACK_IMPORTED_MODULE_2___default = /*#__PURE__*/__webpack_require__.n(util__WEBPACK_IMPORTED_MODULE_2__);
|
|
133026
|
+
/* harmony import */ var chalk__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! chalk */ "./node_modules/chalk/source/index.js");
|
|
133027
|
+
/* harmony import */ var chalk__WEBPACK_IMPORTED_MODULE_3___default = /*#__PURE__*/__webpack_require__.n(chalk__WEBPACK_IMPORTED_MODULE_3__);
|
|
133028
|
+
/* harmony import */ var fs_extra__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! fs-extra */ "./node_modules/fs-extra/lib/index.js");
|
|
133029
|
+
/* harmony import */ var fs_extra__WEBPACK_IMPORTED_MODULE_4___default = /*#__PURE__*/__webpack_require__.n(fs_extra__WEBPACK_IMPORTED_MODULE_4__);
|
|
133030
|
+
/* harmony import */ var md5__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! md5 */ "./node_modules/md5/md5.js");
|
|
133031
|
+
/* harmony import */ var md5__WEBPACK_IMPORTED_MODULE_5___default = /*#__PURE__*/__webpack_require__.n(md5__WEBPACK_IMPORTED_MODULE_5__);
|
|
133032
|
+
/* harmony import */ var md5_file__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! md5-file */ "./node_modules/md5-file/index.js");
|
|
133033
|
+
/* harmony import */ var md5_file__WEBPACK_IMPORTED_MODULE_6___default = /*#__PURE__*/__webpack_require__.n(md5_file__WEBPACK_IMPORTED_MODULE_6__);
|
|
133034
|
+
/* harmony import */ var recursive_readdir__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! recursive-readdir */ "./node_modules/recursive-readdir/index.js");
|
|
133035
|
+
/* harmony import */ var recursive_readdir__WEBPACK_IMPORTED_MODULE_7___default = /*#__PURE__*/__webpack_require__.n(recursive_readdir__WEBPACK_IMPORTED_MODULE_7__);
|
|
133036
|
+
/* harmony import */ var _common_ExtractSugarReferences__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ../common/ExtractSugarReferences */ "./Generator/src/common/ExtractSugarReferences.ts");
|
|
133899
133037
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
133900
133038
|
(function () {
|
|
133901
133039
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -133914,6 +133052,10 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
133914
133052
|
|
|
133915
133053
|
|
|
133916
133054
|
|
|
133055
|
+
|
|
133056
|
+
const statAsync = (0,util__WEBPACK_IMPORTED_MODULE_2__.promisify)(fs__WEBPACK_IMPORTED_MODULE_0__.stat);
|
|
133057
|
+
const readFileAsync = (0,util__WEBPACK_IMPORTED_MODULE_2__.promisify)(fs__WEBPACK_IMPORTED_MODULE_0__.readFile);
|
|
133058
|
+
const readdirAsync = (0,util__WEBPACK_IMPORTED_MODULE_2__.promisify)(fs__WEBPACK_IMPORTED_MODULE_0__.readdir);
|
|
133917
133059
|
async function readFormSources(formSourcesPath, farmDirectory) {
|
|
133918
133060
|
var _JSON$parse$settings;
|
|
133919
133061
|
|
|
@@ -133925,9 +133067,9 @@ async function readFormSources(formSourcesPath, farmDirectory) {
|
|
|
133925
133067
|
|
|
133926
133068
|
if (sugarReferences.fetchFunctionFiles.length === 0) {
|
|
133927
133069
|
// eslint-disable-next-line no-console
|
|
133928
|
-
console.warn(
|
|
133070
|
+
console.warn(chalk__WEBPACK_IMPORTED_MODULE_3___default().yellow(`[WARN] Форма не содержит ссылок на fetch-функции. Будут автоматически подключены функции из каталога legacyfetchfuctions\n` + `[WARN] В будущем необходимо явно прописывать ссылки на используемые fetch-функции`));
|
|
133929
133071
|
const legacyfetchfunctionsDirectory = path__WEBPACK_IMPORTED_MODULE_1___default().join(farmDirectory, "legacyfetchfunctions");
|
|
133930
|
-
sugarReferences.fetchFunctionFiles = (await (
|
|
133072
|
+
sugarReferences.fetchFunctionFiles = (await readdirAsync(legacyfetchfunctionsDirectory)).map(x => path__WEBPACK_IMPORTED_MODULE_1___default().resolve(legacyfetchfunctionsDirectory, x));
|
|
133931
133073
|
}
|
|
133932
133074
|
|
|
133933
133075
|
const result = {
|
|
@@ -133937,12 +133079,11 @@ async function readFormSources(formSourcesPath, farmDirectory) {
|
|
|
133937
133079
|
formSourcesPath: formSourcesPath,
|
|
133938
133080
|
formJsonSettings: (_JSON$parse$settings = JSON.parse(await readFileSource(formSourcesPath, "form.json", "{}"))["settings"]) !== null && _JSON$parse$settings !== void 0 ? _JSON$parse$settings : {},
|
|
133939
133081
|
additionalSettings: await readFileSource(formSourcesPath, "settings.json", "{}"),
|
|
133940
|
-
autocalcsContent: await
|
|
133082
|
+
autocalcsContent: await readAutoCalcFiles(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "autocalc")),
|
|
133941
133083
|
helpersContent: await readJavaScriptFilesWithNames(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "helpers")),
|
|
133942
133084
|
validationsContent: await readJavaScriptFilesWithNames(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "validations")),
|
|
133943
133085
|
schemaRngContent: await readSchemaRngFile(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "schemas"), formName),
|
|
133944
|
-
kcJsXmlContent: await
|
|
133945
|
-
kclangAutocaclulationsContent: await readFilesFromDir(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "autocalc"), /\.kclang$/),
|
|
133086
|
+
kcJsXmlContent: (await readFileSource(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "autocalc"), `${formName}.КС.candy.js.xml`, "<dummy/>")) || "",
|
|
133946
133087
|
tourSteps: await readFileSource(path__WEBPACK_IMPORTED_MODULE_1___default().join(rootPath, "tour"), "tour.js", "{}"),
|
|
133947
133088
|
hooksContent: await readHooksFile(formSourcesPath),
|
|
133948
133089
|
customControlsContent: await readCustomControlsFiles(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "controls")),
|
|
@@ -133986,7 +133127,7 @@ function evalModule(moduleCode) {
|
|
|
133986
133127
|
|
|
133987
133128
|
async function isDirectoryExists(directoryPath) {
|
|
133988
133129
|
try {
|
|
133989
|
-
const dirStat = await (
|
|
133130
|
+
const dirStat = await statAsync(directoryPath);
|
|
133990
133131
|
return dirStat.isDirectory();
|
|
133991
133132
|
} catch (ignoreError) {
|
|
133992
133133
|
return false;
|
|
@@ -133997,27 +133138,27 @@ async function readFiles(filePaths) {
|
|
|
133997
133138
|
const result = [];
|
|
133998
133139
|
|
|
133999
133140
|
for (const filePath of filePaths) {
|
|
134000
|
-
result.push(await (
|
|
133141
|
+
result.push(await readFileAsync(filePath, "utf-8"));
|
|
134001
133142
|
}
|
|
134002
133143
|
|
|
134003
133144
|
return result;
|
|
134004
133145
|
}
|
|
134005
133146
|
|
|
134006
133147
|
async function extractReferences(formSugarDirectoryPath) {
|
|
134007
|
-
const indexContent = await (
|
|
134008
|
-
return (0,
|
|
133148
|
+
const indexContent = await readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSugarDirectoryPath, "index.sugar.xml"), "utf-8");
|
|
133149
|
+
return (0,_common_ExtractSugarReferences__WEBPACK_IMPORTED_MODULE_8__.extractSugarReferences)(indexContent, filePath => readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSugarDirectoryPath, filePath), "utf-8"));
|
|
134009
133150
|
}
|
|
134010
133151
|
|
|
134011
133152
|
async function getAllFilePathsInDirectory(directoryPath, _filelist) {
|
|
134012
|
-
if (!(await (0,
|
|
133153
|
+
if (!(await (0,fs_extra__WEBPACK_IMPORTED_MODULE_4__.pathExists)(directoryPath))) {
|
|
134013
133154
|
return [];
|
|
134014
133155
|
}
|
|
134015
133156
|
|
|
134016
|
-
const files = await (
|
|
133157
|
+
const files = await readdirAsync(directoryPath);
|
|
134017
133158
|
let filelist = _filelist || [];
|
|
134018
133159
|
|
|
134019
133160
|
for (const file of files) {
|
|
134020
|
-
if ((await (
|
|
133161
|
+
if ((await statAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(directoryPath, file))).isDirectory()) {
|
|
134021
133162
|
filelist = await getAllFilePathsInDirectory(path__WEBPACK_IMPORTED_MODULE_1___default().join(directoryPath, file), filelist);
|
|
134022
133163
|
} else {
|
|
134023
133164
|
filelist.push(path__WEBPACK_IMPORTED_MODULE_1___default().join(directoryPath, file));
|
|
@@ -134028,7 +133169,7 @@ async function getAllFilePathsInDirectory(directoryPath, _filelist) {
|
|
|
134028
133169
|
}
|
|
134029
133170
|
|
|
134030
133171
|
async function checkFileExists(filePath) {
|
|
134031
|
-
if (!(await (0,
|
|
133172
|
+
if (!(await (0,fs_extra__WEBPACK_IMPORTED_MODULE_4__.pathExists)(filePath))) {
|
|
134032
133173
|
return [];
|
|
134033
133174
|
}
|
|
134034
133175
|
|
|
@@ -134041,7 +133182,7 @@ async function getAllDependencies(formSourcesPath, farmDirectory) {
|
|
|
134041
133182
|
|
|
134042
133183
|
if (sugarReferences.fetchFunctionFiles.length === 0) {
|
|
134043
133184
|
const legacyfetchfunctionsDirectory = path__WEBPACK_IMPORTED_MODULE_1___default().join(farmDirectory, "legacyfetchfunctions");
|
|
134044
|
-
sugarReferences.fetchFunctionFiles = (await (
|
|
133185
|
+
sugarReferences.fetchFunctionFiles = (await readdirAsync(legacyfetchfunctionsDirectory)).map(x => path__WEBPACK_IMPORTED_MODULE_1___default().resolve(legacyfetchfunctionsDirectory, x));
|
|
134045
133186
|
}
|
|
134046
133187
|
|
|
134047
133188
|
return [path__WEBPACK_IMPORTED_MODULE_1___default().join(formSugarDirectoryPath, "index.sugar.xml"), ...sugarReferences.fetchFunctionFiles.map(x => path__WEBPACK_IMPORTED_MODULE_1___default().resolve(formSugarDirectoryPath, x)), ...sugarReferences.sugarFiles.map(x => path__WEBPACK_IMPORTED_MODULE_1___default().resolve(formSugarDirectoryPath, x + ".sugar.xml")), ...sugarReferences.resourceFiles.map(x => path__WEBPACK_IMPORTED_MODULE_1___default().resolve(formSugarDirectoryPath, x)), ...(await checkFileExists(path__WEBPACK_IMPORTED_MODULE_1___default().resolve(formSourcesPath, "settings.json"))), ...(await getAllFilePathsInDirectory(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "autocalc"))), ...(await getAllFilePathsInDirectory(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "helpers"))), ...(await getAllFilePathsInDirectory(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "validations"))), ...(await getAllFilePathsInDirectory(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "schemas"))), ...(await checkFileExists(path__WEBPACK_IMPORTED_MODULE_1___default().join(farmDirectory, "tour", "tour.js"))), ...(await getAllFilePathsInDirectory(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "controls"))), ...(await getAllFilePathsInDirectory(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSourcesPath, "localization")))];
|
|
@@ -134054,23 +133195,23 @@ function normalizeLineEndings(content) {
|
|
|
134054
133195
|
async function getAllDependenciesHash(formSourcesPath, farmDirectory) {
|
|
134055
133196
|
const allDeps = await getAllDependencies(formSourcesPath, farmDirectory);
|
|
134056
133197
|
const hashes = await Promise.all(allDeps.map(async depFilePath => {
|
|
134057
|
-
if ([".js", ".
|
|
134058
|
-
let content = await (
|
|
133198
|
+
if ([".js", ".xml", ".xslt", ".json"].some(ext => depFilePath.endsWith(ext))) {
|
|
133199
|
+
let content = await readFileAsync(depFilePath, "utf-8");
|
|
134059
133200
|
content = normalizeLineEndings(content);
|
|
134060
|
-
return
|
|
133201
|
+
return md5__WEBPACK_IMPORTED_MODULE_5___default()(content);
|
|
134061
133202
|
}
|
|
134062
133203
|
|
|
134063
|
-
return
|
|
133204
|
+
return md5_file__WEBPACK_IMPORTED_MODULE_6___default()(depFilePath);
|
|
134064
133205
|
}));
|
|
134065
|
-
return
|
|
133206
|
+
return md5__WEBPACK_IMPORTED_MODULE_5___default()(hashes.join(""));
|
|
134066
133207
|
}
|
|
134067
133208
|
async function readSugarFiles(formSugarDirectoryPath, references) {
|
|
134068
133209
|
const result = {
|
|
134069
|
-
"./index": await (
|
|
133210
|
+
"./index": await readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSugarDirectoryPath, "index.sugar.xml"), "utf-8")
|
|
134070
133211
|
};
|
|
134071
133212
|
|
|
134072
133213
|
for (const sugarPath of references.sugarFiles) {
|
|
134073
|
-
const sugarModuleContent = await (
|
|
133214
|
+
const sugarModuleContent = await readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSugarDirectoryPath, sugarPath + ".sugar.xml"), "utf-8");
|
|
134074
133215
|
result[sugarPath] = sugarModuleContent;
|
|
134075
133216
|
}
|
|
134076
133217
|
|
|
@@ -134082,11 +133223,11 @@ async function readCustomControlsFiles(formSugarDirectoryPath) {
|
|
|
134082
133223
|
return {};
|
|
134083
133224
|
}
|
|
134084
133225
|
|
|
134085
|
-
const fileNames = await
|
|
133226
|
+
const fileNames = await recursive_readdir__WEBPACK_IMPORTED_MODULE_7___default()(formSugarDirectoryPath);
|
|
134086
133227
|
const result = {};
|
|
134087
133228
|
|
|
134088
133229
|
for (const fileName of fileNames) {
|
|
134089
|
-
const sugarModuleContent = await (
|
|
133230
|
+
const sugarModuleContent = await readFileAsync(fileName, "utf-8");
|
|
134090
133231
|
const relativeFileName = ("controls\\" + fileName.replace(formSugarDirectoryPath + "\\", "")).replace(/\\/g, "/");
|
|
134091
133232
|
result[relativeFileName] = sugarModuleContent;
|
|
134092
133233
|
}
|
|
@@ -134094,23 +133235,23 @@ async function readCustomControlsFiles(formSugarDirectoryPath) {
|
|
|
134094
133235
|
return result;
|
|
134095
133236
|
}
|
|
134096
133237
|
|
|
134097
|
-
async function
|
|
134098
|
-
|
|
133238
|
+
async function readAutoCalcFiles(formAutoCalcPath) {
|
|
133239
|
+
try {
|
|
133240
|
+
const files = await readdirAsync(formAutoCalcPath);
|
|
133241
|
+
const jsFiles = files.filter(filename => /\.js$/.test(filename));
|
|
133242
|
+
return Promise.all(jsFiles.map(filename => readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(formAutoCalcPath, filename), "utf-8")));
|
|
133243
|
+
} catch (ignoreError) {
|
|
134099
133244
|
return [];
|
|
134100
133245
|
}
|
|
134101
|
-
|
|
134102
|
-
const files = await (0,fs_extra__WEBPACK_IMPORTED_MODULE_3__.readdir)(directoryPath);
|
|
134103
|
-
const jsFiles = files.filter(filename => fileNameTest.test(filename));
|
|
134104
|
-
return Promise.all(jsFiles.map(filename => (0,fs_extra__WEBPACK_IMPORTED_MODULE_3__.readFile)(path__WEBPACK_IMPORTED_MODULE_1___default().join(directoryPath, filename), "utf-8")));
|
|
134105
133246
|
}
|
|
134106
133247
|
|
|
134107
133248
|
async function readImportedFiles(rootPath) {
|
|
134108
133249
|
try {
|
|
134109
133250
|
const result = {};
|
|
134110
|
-
const files = await (
|
|
133251
|
+
const files = await readdirAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(rootPath, "validations"));
|
|
134111
133252
|
|
|
134112
133253
|
for (const fileName of files) {
|
|
134113
|
-
result["../validations/" + fileName] = await (
|
|
133254
|
+
result["../validations/" + fileName] = await readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(rootPath, "validations", fileName), "utf-8");
|
|
134114
133255
|
}
|
|
134115
133256
|
|
|
134116
133257
|
return result;
|
|
@@ -134121,11 +133262,11 @@ async function readImportedFiles(rootPath) {
|
|
|
134121
133262
|
|
|
134122
133263
|
async function readJavaScriptFilesWithNames(formJavaScriptFilesPath) {
|
|
134123
133264
|
try {
|
|
134124
|
-
const files = await (
|
|
133265
|
+
const files = await readdirAsync(formJavaScriptFilesPath);
|
|
134125
133266
|
const jsFiles = files.filter(filename => /\.js$/.test(filename));
|
|
134126
133267
|
return Promise.all(jsFiles.map(async filename => ({
|
|
134127
133268
|
filename: path__WEBPACK_IMPORTED_MODULE_1___default().parse(filename).name,
|
|
134128
|
-
content: await (
|
|
133269
|
+
content: await readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(formJavaScriptFilesPath, filename), "utf-8")
|
|
134129
133270
|
})));
|
|
134130
133271
|
} catch (ignoreError) {
|
|
134131
133272
|
return [];
|
|
@@ -134136,7 +133277,7 @@ async function connectJSFilesWithNames(formJavaScriptFilesPath) {
|
|
|
134136
133277
|
let jsFiles;
|
|
134137
133278
|
|
|
134138
133279
|
try {
|
|
134139
|
-
const files = await (
|
|
133280
|
+
const files = await readdirAsync(formJavaScriptFilesPath);
|
|
134140
133281
|
jsFiles = files.filter(filename => /\.js$/.test(filename));
|
|
134141
133282
|
const result = [];
|
|
134142
133283
|
|
|
@@ -134144,7 +133285,7 @@ async function connectJSFilesWithNames(formJavaScriptFilesPath) {
|
|
|
134144
133285
|
result.push({
|
|
134145
133286
|
filename: path__WEBPACK_IMPORTED_MODULE_1___default().parse(filename).name,
|
|
134146
133287
|
// tslint:disable-next-line no-unsafe-any
|
|
134147
|
-
content: evalModule(await (
|
|
133288
|
+
content: evalModule(await readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(formJavaScriptFilesPath, filename), "utf-8"))
|
|
134148
133289
|
});
|
|
134149
133290
|
}
|
|
134150
133291
|
|
|
@@ -134155,16 +133296,16 @@ async function connectJSFilesWithNames(formJavaScriptFilesPath) {
|
|
|
134155
133296
|
}
|
|
134156
133297
|
|
|
134157
133298
|
function readSchemaRngFile(formSchemasPath, gfv) {
|
|
134158
|
-
return (
|
|
133299
|
+
return readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(formSchemasPath, `${gfv}.rng.xml`), "utf-8");
|
|
134159
133300
|
}
|
|
134160
133301
|
|
|
134161
133302
|
function readHooksFile(formDirectoryPath) {
|
|
134162
|
-
return (
|
|
133303
|
+
return readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(formDirectoryPath, "hooks.js"), "utf-8").catch(() => "");
|
|
134163
133304
|
}
|
|
134164
133305
|
|
|
134165
133306
|
async function readFileSource(filePath, filename, defaultValue) {
|
|
134166
133307
|
try {
|
|
134167
|
-
return await (
|
|
133308
|
+
return await readFileAsync(path__WEBPACK_IMPORTED_MODULE_1___default().join(filePath, filename), "utf-8");
|
|
134168
133309
|
} catch (ingoreError) {
|
|
134169
133310
|
return defaultValue;
|
|
134170
133311
|
}
|
|
@@ -134179,6 +133320,9 @@ async function readFileSource(filePath, filename, defaultValue) {
|
|
|
134179
133320
|
return;
|
|
134180
133321
|
}
|
|
134181
133322
|
|
|
133323
|
+
reactHotLoader.register(statAsync, "statAsync", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
133324
|
+
reactHotLoader.register(readFileAsync, "readFileAsync", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
133325
|
+
reactHotLoader.register(readdirAsync, "readdirAsync", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
134182
133326
|
reactHotLoader.register(readFormSources, "readFormSources", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
134183
133327
|
reactHotLoader.register(evalModule, "evalModule", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
134184
133328
|
reactHotLoader.register(isDirectoryExists, "isDirectoryExists", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
@@ -134191,7 +133335,7 @@ async function readFileSource(filePath, filename, defaultValue) {
|
|
|
134191
133335
|
reactHotLoader.register(getAllDependenciesHash, "getAllDependenciesHash", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
134192
133336
|
reactHotLoader.register(readSugarFiles, "readSugarFiles", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
134193
133337
|
reactHotLoader.register(readCustomControlsFiles, "readCustomControlsFiles", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
134194
|
-
reactHotLoader.register(
|
|
133338
|
+
reactHotLoader.register(readAutoCalcFiles, "readAutoCalcFiles", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
134195
133339
|
reactHotLoader.register(readImportedFiles, "readImportedFiles", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
134196
133340
|
reactHotLoader.register(readJavaScriptFilesWithNames, "readJavaScriptFilesWithNames", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
134197
133341
|
reactHotLoader.register(connectJSFilesWithNames, "connectJSFilesWithNames", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\ReadFormSources.ts");
|
|
@@ -134387,11 +133531,6 @@ class FLangValidationBuildContext {
|
|
|
134387
133531
|
return [new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_3__.NegateUnaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_3__.CallExpression("regexMatch", [valueReference, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_3__.StringLiteralExpression("^\\d{4}$")])), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_3__.StringLiteralExpression('["Значение должно быть корректным годом длиной 4 знака"]')];
|
|
134388
133532
|
}
|
|
134389
133533
|
|
|
134390
|
-
case "gMonth":
|
|
134391
|
-
{
|
|
134392
|
-
return [new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_3__.NegateUnaryExpression(new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_3__.CallExpression("regexMatch", [valueReference, new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_3__.StringLiteralExpression("^(--(0[1-9]|1[0-2]))$")])), new _FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_3__.StringLiteralExpression('["Значение должно быть месяцем в формате --00"]')];
|
|
134393
|
-
}
|
|
134394
|
-
|
|
134395
133534
|
default:
|
|
134396
133535
|
throw new Error(`Unknown base type name: '${baseType}'`);
|
|
134397
133536
|
}
|
|
@@ -135018,18 +134157,18 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
135018
134157
|
|
|
135019
134158
|
|
|
135020
134159
|
class NormalizationRulesGenerator {
|
|
135021
|
-
constructor(sugarRoot, dataDeclarationHelper, formSchemaRng,
|
|
134160
|
+
constructor(sugarRoot, dataDeclarationHelper, formSchemaRng, mathContainer, typesRegistry, useSchemaValidations, controlCustomizationContext) {
|
|
135022
134161
|
this.sugarRoot = void 0;
|
|
135023
134162
|
this.dataDeclarationHelper = void 0;
|
|
135024
134163
|
this.formSchemaRng = void 0;
|
|
135025
|
-
this.
|
|
134164
|
+
this.mathContainer = void 0;
|
|
135026
134165
|
this.typesRegistry = void 0;
|
|
135027
134166
|
this.controlCustomizationContext = void 0;
|
|
135028
134167
|
this.useSchemaValidations = void 0;
|
|
135029
134168
|
this.sugarRoot = sugarRoot;
|
|
135030
134169
|
this.dataDeclarationHelper = dataDeclarationHelper;
|
|
135031
134170
|
this.formSchemaRng = formSchemaRng;
|
|
135032
|
-
this.
|
|
134171
|
+
this.mathContainer = mathContainer;
|
|
135033
134172
|
this.typesRegistry = typesRegistry;
|
|
135034
134173
|
this.useSchemaValidations = useSchemaValidations;
|
|
135035
134174
|
this.controlCustomizationContext = controlCustomizationContext;
|
|
@@ -135059,7 +134198,9 @@ class NormalizationRulesGenerator {
|
|
|
135059
134198
|
}
|
|
135060
134199
|
|
|
135061
134200
|
*buildFormulaFLangRules() {
|
|
135062
|
-
for (const formula of this.formulas) {
|
|
134201
|
+
for (const formula of (_this$mathContainer$f = (_this$mathContainer = this.mathContainer) === null || _this$mathContainer === void 0 ? void 0 : (_this$mathContainer$f2 = _this$mathContainer.formulas) === null || _this$mathContainer$f2 === void 0 ? void 0 : _this$mathContainer$f2.items) !== null && _this$mathContainer$f !== void 0 ? _this$mathContainer$f : []) {
|
|
134202
|
+
var _this$mathContainer$f, _this$mathContainer, _this$mathContainer$f2;
|
|
134203
|
+
|
|
135063
134204
|
yield* this.buildFormulaFlashRule(formula);
|
|
135064
134205
|
}
|
|
135065
134206
|
}
|
|
@@ -138915,10 +138056,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
138915
138056
|
/* harmony import */ var _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../../../common/XmlParser/XmlNode */ "./Generator/src/common/XmlParser/XmlNode.ts");
|
|
138916
138057
|
/* harmony import */ var _common_ConditionUtils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../../common/ConditionUtils */ "./Generator/src/common/ConditionUtils.ts");
|
|
138917
138058
|
/* harmony import */ var _Common_KCLangRuntimeUtils__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../../../../Common/KCLangRuntimeUtils */ "./Common/KCLangRuntimeUtils.ts");
|
|
138918
|
-
/* harmony import */ var
|
|
138919
|
-
/* harmony import */ var
|
|
138920
|
-
/* harmony import */ var
|
|
138921
|
-
/* harmony import */ var _IfNode__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./IfNode */ "./Generator/src/generators/markupGenerator/ElementProcessors/ControlFlow/If/IfNode.ts");
|
|
138059
|
+
/* harmony import */ var _ComponentMarkupBuilder_PathHelper__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../ComponentMarkupBuilder/PathHelper */ "./Generator/src/generators/markupGenerator/ComponentMarkupBuilder/PathHelper.ts");
|
|
138060
|
+
/* harmony import */ var _RequisiteLIst_requisiteList__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../../RequisiteLIst/requisiteList */ "./Generator/src/generators/RequisiteLIst/requisiteList.ts");
|
|
138061
|
+
/* harmony import */ var _IfNode__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./IfNode */ "./Generator/src/generators/markupGenerator/ElementProcessors/ControlFlow/If/IfNode.ts");
|
|
138922
138062
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
138923
138063
|
(function () {
|
|
138924
138064
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -138938,15 +138078,14 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
138938
138078
|
|
|
138939
138079
|
|
|
138940
138080
|
|
|
138941
|
-
|
|
138942
138081
|
class IfConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.SugarNodeConverterBase {
|
|
138943
138082
|
static getAcceptNodeClass() {
|
|
138944
|
-
return
|
|
138083
|
+
return _IfNode__WEBPACK_IMPORTED_MODULE_8__.IfNode;
|
|
138945
138084
|
}
|
|
138946
138085
|
|
|
138947
138086
|
doGetRequisites() {
|
|
138948
|
-
const node = this.getCurrentNodeAs(
|
|
138949
|
-
return (0,
|
|
138087
|
+
const node = this.getCurrentNodeAs(_IfNode__WEBPACK_IMPORTED_MODULE_8__.IfNode);
|
|
138088
|
+
return (0,_RequisiteLIst_requisiteList__WEBPACK_IMPORTED_MODULE_7__.getRequisitesFromEvaluableProps)(node.condition);
|
|
138950
138089
|
}
|
|
138951
138090
|
|
|
138952
138091
|
doBuildDataDeclaration(context) {
|
|
@@ -138954,13 +138093,13 @@ class IfConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Sugar
|
|
|
138954
138093
|
}
|
|
138955
138094
|
|
|
138956
138095
|
buildChildrenDataDeclaration(context) {
|
|
138957
|
-
const node = this.getCurrentNodeAs(
|
|
138096
|
+
const node = this.getCurrentNodeAs(_IfNode__WEBPACK_IMPORTED_MODULE_8__.IfNode);
|
|
138958
138097
|
return context.processChildrenDataDeclaration(node.children, x => {
|
|
138959
|
-
if (x instanceof
|
|
138098
|
+
if (x instanceof _IfNode__WEBPACK_IMPORTED_MODULE_8__.ThenNode) {
|
|
138960
138099
|
return context.processChildrenDataDeclaration(x.children);
|
|
138961
138100
|
}
|
|
138962
138101
|
|
|
138963
|
-
if (x instanceof
|
|
138102
|
+
if (x instanceof _IfNode__WEBPACK_IMPORTED_MODULE_8__.ElseNode) {
|
|
138964
138103
|
return context.processChildrenDataDeclaration(x.children);
|
|
138965
138104
|
}
|
|
138966
138105
|
|
|
@@ -138969,12 +138108,12 @@ class IfConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Sugar
|
|
|
138969
138108
|
}
|
|
138970
138109
|
|
|
138971
138110
|
*doTraverseChildren() {
|
|
138972
|
-
const node = this.getCurrentNodeAs(
|
|
138111
|
+
const node = this.getCurrentNodeAs(_IfNode__WEBPACK_IMPORTED_MODULE_8__.IfNode);
|
|
138973
138112
|
|
|
138974
138113
|
for (const child of node.children) {
|
|
138975
|
-
if (child instanceof
|
|
138114
|
+
if (child instanceof _IfNode__WEBPACK_IMPORTED_MODULE_8__.ThenNode) {
|
|
138976
138115
|
yield* child.children;
|
|
138977
|
-
} else if (child instanceof
|
|
138116
|
+
} else if (child instanceof _IfNode__WEBPACK_IMPORTED_MODULE_8__.ElseNode) {
|
|
138978
138117
|
yield* child.children;
|
|
138979
138118
|
} else {
|
|
138980
138119
|
yield child;
|
|
@@ -138985,30 +138124,42 @@ class IfConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Sugar
|
|
|
138985
138124
|
doConvert(context) {
|
|
138986
138125
|
var _node$then, _node$else;
|
|
138987
138126
|
|
|
138988
|
-
const node = this.getCurrentNodeAs(
|
|
138127
|
+
const node = this.getCurrentNodeAs(_IfNode__WEBPACK_IMPORTED_MODULE_8__.IfNode);
|
|
138989
138128
|
const builder = (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_1__.componentMarkupBuilder)("If");
|
|
138990
138129
|
|
|
138991
|
-
if (node.isIndividual
|
|
138992
|
-
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_3__.SugarAttributeReadError(`ifnode должна иметь свойство condition или isIndividual`, node, "
|
|
138130
|
+
if (node.isIndividual === undefined && node.condition === undefined) {
|
|
138131
|
+
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_3__.SugarAttributeReadError(`ifnode должна иметь свойство condition или isIndividual`, node, "ifNode");
|
|
138132
|
+
}
|
|
138133
|
+
|
|
138134
|
+
if (node.isIndividual !== undefined && node.condition !== undefined) {
|
|
138135
|
+
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_3__.SugarAttributeReadError(`Выберите или condition или isIndividual`, node, "ifNode");
|
|
138993
138136
|
}
|
|
138994
138137
|
|
|
138995
|
-
if (node.
|
|
138996
|
-
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_3__.SugarAttributeReadError(
|
|
138138
|
+
if (node.condition !== undefined && node.condition === "") {
|
|
138139
|
+
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_3__.SugarAttributeReadError(`condition не может быть пустым`, node, "ifNode");
|
|
138997
138140
|
}
|
|
138998
138141
|
|
|
138999
138142
|
const condition = node.isIndividual !== undefined ? `path("@settings/isIndividual") === '${node.isIndividual}'` : node.condition;
|
|
139000
|
-
const conditionWithDependencies = (0,_common_ConditionUtils__WEBPACK_IMPORTED_MODULE_4__.convertConditionToJsOrFailWithFriendlySugarError)(condition
|
|
138143
|
+
const conditionWithDependencies = (0,_common_ConditionUtils__WEBPACK_IMPORTED_MODULE_4__.convertConditionToJsOrFailWithFriendlySugarError)(condition, "path", _Common_KCLangRuntimeUtils__WEBPACK_IMPORTED_MODULE_5__.KCLangRuntimeUtils.kcLangUtilsName, node, (0,_ComponentMarkupBuilder_PathHelper__WEBPACK_IMPORTED_MODULE_6__.extractPath)(x => x.condition));
|
|
139001
138144
|
const thenBuilder = builder.createChild("Then");
|
|
139002
138145
|
thenBuilder.appendChild(context.convertChildNodes(((_node$then = node.then) !== null && _node$then !== void 0 ? _node$then : node).children));
|
|
139003
138146
|
thenBuilder.prop(x => x.evaluatorsContextPath).set(this.getEvaluatorsContextPathExpression());
|
|
139004
|
-
thenBuilder.prop(x => x.positiveCondition).set(
|
|
138147
|
+
thenBuilder.prop(x => x.positiveCondition).set({
|
|
138148
|
+
type: "Expression",
|
|
138149
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => ${conditionWithDependencies.condition}}`,
|
|
138150
|
+
dependencies: conditionWithDependencies.dependencies
|
|
138151
|
+
});
|
|
139005
138152
|
|
|
139006
138153
|
if (((_node$else = node.else) === null || _node$else === void 0 ? void 0 : _node$else.children) !== undefined) {
|
|
139007
138154
|
var _node$else2;
|
|
139008
138155
|
|
|
139009
138156
|
const elseBuilder = builder.createChild("Else");
|
|
139010
138157
|
elseBuilder.prop(x => x.evaluatorsContextPath).set(this.getEvaluatorsContextPathExpression());
|
|
139011
|
-
elseBuilder.prop(x => x.positiveCondition).set(
|
|
138158
|
+
elseBuilder.prop(x => x.positiveCondition).set({
|
|
138159
|
+
type: "Expression",
|
|
138160
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => ${conditionWithDependencies.condition}}`,
|
|
138161
|
+
dependencies: conditionWithDependencies.dependencies
|
|
138162
|
+
});
|
|
139012
138163
|
elseBuilder.appendChild(context.convertChildNodes((_node$else2 = node.else) === null || _node$else2 === void 0 ? void 0 : _node$else2.children));
|
|
139013
138164
|
}
|
|
139014
138165
|
|
|
@@ -139358,8 +138509,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
139358
138509
|
/* harmony import */ var _Common_KCLangRuntimeUtils__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../../../../../Common/KCLangRuntimeUtils */ "./Common/KCLangRuntimeUtils.ts");
|
|
139359
138510
|
/* harmony import */ var _ComponentMarkupBuilder_PathHelper__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../ComponentMarkupBuilder/PathHelper */ "./Generator/src/generators/markupGenerator/ComponentMarkupBuilder/PathHelper.ts");
|
|
139360
138511
|
/* harmony import */ var _RequisiteLIst_requisiteList__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../RequisiteLIst/requisiteList */ "./Generator/src/generators/RequisiteLIst/requisiteList.ts");
|
|
139361
|
-
/* harmony import */ var
|
|
139362
|
-
/* harmony import */ var _SwitchNode__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./SwitchNode */ "./Generator/src/generators/markupGenerator/ElementProcessors/ControlFlow/Switch/SwitchNode.ts");
|
|
138512
|
+
/* harmony import */ var _SwitchNode__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ./SwitchNode */ "./Generator/src/generators/markupGenerator/ElementProcessors/ControlFlow/Switch/SwitchNode.ts");
|
|
139363
138513
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
139364
138514
|
(function () {
|
|
139365
138515
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -139378,10 +138528,9 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
139378
138528
|
|
|
139379
138529
|
|
|
139380
138530
|
|
|
139381
|
-
|
|
139382
138531
|
class SwitchDefaultConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.SugarNodeConverterBase {
|
|
139383
138532
|
static getAcceptNodeClass() {
|
|
139384
|
-
return
|
|
138533
|
+
return _SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchDefaultNode;
|
|
139385
138534
|
}
|
|
139386
138535
|
|
|
139387
138536
|
doBuildDataDeclaration(context) {
|
|
@@ -139389,17 +138538,17 @@ class SwitchDefaultConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODUL
|
|
|
139389
138538
|
}
|
|
139390
138539
|
|
|
139391
138540
|
buildChildrenDataDeclaration(context) {
|
|
139392
|
-
const node = this.getCurrentNodeAs(
|
|
138541
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchDefaultNode);
|
|
139393
138542
|
return context.processChildrenDataDeclaration(node.children);
|
|
139394
138543
|
}
|
|
139395
138544
|
|
|
139396
138545
|
*doTraverseChildren() {
|
|
139397
|
-
const node = this.getCurrentNodeAs(
|
|
138546
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchDefaultNode);
|
|
139398
138547
|
yield* node.children;
|
|
139399
138548
|
}
|
|
139400
138549
|
|
|
139401
138550
|
doConvert(context) {
|
|
139402
|
-
const node = this.getCurrentNodeAs(
|
|
138551
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchDefaultNode);
|
|
139403
138552
|
const builder = (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_1__.componentMarkupBuilder)("SwitchDefault");
|
|
139404
138553
|
builder.appendChild(context.convertChildNodes(node.children));
|
|
139405
138554
|
return builder.buildConverterResult();
|
|
@@ -139414,7 +138563,7 @@ class SwitchDefaultConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODUL
|
|
|
139414
138563
|
}
|
|
139415
138564
|
class SwitchCaseConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.SugarNodeConverterBase {
|
|
139416
138565
|
static getAcceptNodeClass() {
|
|
139417
|
-
return
|
|
138566
|
+
return _SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchCaseNode;
|
|
139418
138567
|
}
|
|
139419
138568
|
|
|
139420
138569
|
doBuildDataDeclaration(context) {
|
|
@@ -139422,25 +138571,29 @@ class SwitchCaseConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2
|
|
|
139422
138571
|
}
|
|
139423
138572
|
|
|
139424
138573
|
buildChildrenDataDeclaration(context) {
|
|
139425
|
-
const node = this.getCurrentNodeAs(
|
|
138574
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchCaseNode);
|
|
139426
138575
|
return context.processChildrenDataDeclaration(node.children);
|
|
139427
138576
|
}
|
|
139428
138577
|
|
|
139429
138578
|
doGetRequisites() {
|
|
139430
|
-
const node = this.getCurrentNodeAs(
|
|
138579
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchCaseNode);
|
|
139431
138580
|
return (0,_RequisiteLIst_requisiteList__WEBPACK_IMPORTED_MODULE_6__.getRequisitesFromEvaluableProps)(node.condition);
|
|
139432
138581
|
}
|
|
139433
138582
|
|
|
139434
138583
|
*doTraverseChildren() {
|
|
139435
|
-
const node = this.getCurrentNodeAs(
|
|
138584
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchCaseNode);
|
|
139436
138585
|
yield* node.children;
|
|
139437
138586
|
}
|
|
139438
138587
|
|
|
139439
138588
|
doConvert(context) {
|
|
139440
|
-
const node = this.getCurrentNodeAs(
|
|
138589
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchCaseNode);
|
|
139441
138590
|
const builder = (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_1__.componentMarkupBuilder)("SwitchCase");
|
|
139442
138591
|
const conditionWithDependencies = (0,_common_ConditionUtils__WEBPACK_IMPORTED_MODULE_3__.convertConditionToJsOrFailWithFriendlySugarError)(node.condition, "path", _Common_KCLangRuntimeUtils__WEBPACK_IMPORTED_MODULE_4__.KCLangRuntimeUtils.kcLangUtilsName, node, (0,_ComponentMarkupBuilder_PathHelper__WEBPACK_IMPORTED_MODULE_5__.extractPath)(x => x.condition));
|
|
139443
|
-
builder.prop(x => x.condition).set(
|
|
138592
|
+
builder.prop(x => x.condition).set({
|
|
138593
|
+
type: "Expression",
|
|
138594
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => ${conditionWithDependencies.condition} }`,
|
|
138595
|
+
dependencies: conditionWithDependencies.dependencies
|
|
138596
|
+
});
|
|
139444
138597
|
builder.prop(x => x.evaluatorsContextPath).set(this.getEvaluatorsContextPathExpression());
|
|
139445
138598
|
builder.appendChild(context.convertChildNodes(node.children));
|
|
139446
138599
|
return builder.buildConverterResult();
|
|
@@ -139455,11 +138608,11 @@ class SwitchCaseConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2
|
|
|
139455
138608
|
}
|
|
139456
138609
|
class SwitchConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.SugarNodeConverterBase {
|
|
139457
138610
|
static getAcceptNodeClass() {
|
|
139458
|
-
return
|
|
138611
|
+
return _SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchNode;
|
|
139459
138612
|
}
|
|
139460
138613
|
|
|
139461
138614
|
doGetRequisites() {
|
|
139462
|
-
const node = this.getCurrentNodeAs(
|
|
138615
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchNode);
|
|
139463
138616
|
return node.cases.flatMap(x => (0,_RequisiteLIst_requisiteList__WEBPACK_IMPORTED_MODULE_6__.getRequisitesFromEvaluableProps)(x.condition));
|
|
139464
138617
|
}
|
|
139465
138618
|
|
|
@@ -139470,12 +138623,12 @@ class SwitchConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.S
|
|
|
139470
138623
|
buildChildrenDataDeclaration(context) {
|
|
139471
138624
|
var _node$default, _node$default2;
|
|
139472
138625
|
|
|
139473
|
-
const node = this.getCurrentNodeAs(
|
|
138626
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchNode);
|
|
139474
138627
|
return context.mergeDataDeclaration(...node.cases.map(x => context.processChildrenDataDeclaration(x.children)).flat(), ((_node$default = node.default) === null || _node$default === void 0 ? void 0 : _node$default.children) && context.processChildrenDataDeclaration((_node$default2 = node.default) === null || _node$default2 === void 0 ? void 0 : _node$default2.children));
|
|
139475
138628
|
}
|
|
139476
138629
|
|
|
139477
138630
|
*doTraverseChildren() {
|
|
139478
|
-
const node = this.getCurrentNodeAs(
|
|
138631
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchNode);
|
|
139479
138632
|
yield* node.cases;
|
|
139480
138633
|
|
|
139481
138634
|
if (node.default != undefined) {
|
|
@@ -139484,7 +138637,7 @@ class SwitchConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.S
|
|
|
139484
138637
|
}
|
|
139485
138638
|
|
|
139486
138639
|
doConvert(context) {
|
|
139487
|
-
const node = this.getCurrentNodeAs(
|
|
138640
|
+
const node = this.getCurrentNodeAs(_SwitchNode__WEBPACK_IMPORTED_MODULE_7__.SwitchNode);
|
|
139488
138641
|
const builder = (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_1__.componentMarkupBuilder)("Switch");
|
|
139489
138642
|
const prevConditions = [];
|
|
139490
138643
|
|
|
@@ -139492,7 +138645,11 @@ class SwitchConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.S
|
|
|
139492
138645
|
const caseBuilder = (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_1__.componentMarkupBuilder)("SwitchCase");
|
|
139493
138646
|
caseBuilder.prop(x => x.prevCaseConditions).set([...prevConditions]);
|
|
139494
138647
|
const conditionWithDependencies = (0,_common_ConditionUtils__WEBPACK_IMPORTED_MODULE_3__.convertConditionToJsOrFailWithFriendlySugarError)(caseNode.condition, "path", _Common_KCLangRuntimeUtils__WEBPACK_IMPORTED_MODULE_4__.KCLangRuntimeUtils.kcLangUtilsName, node, (0,_ComponentMarkupBuilder_PathHelper__WEBPACK_IMPORTED_MODULE_5__.extractPath)(x => x.condition));
|
|
139495
|
-
const currentCaseCondition =
|
|
138648
|
+
const currentCaseCondition = {
|
|
138649
|
+
type: "Expression",
|
|
138650
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => ${conditionWithDependencies.condition} }`,
|
|
138651
|
+
dependencies: conditionWithDependencies.dependencies
|
|
138652
|
+
};
|
|
139496
138653
|
caseBuilder.prop(x => x.condition).set(currentCaseCondition);
|
|
139497
138654
|
prevConditions.push(currentCaseCondition);
|
|
139498
138655
|
caseBuilder.prop(x => x.evaluatorsContextPath).set(this.getEvaluatorsContextPathExpression());
|
|
@@ -143540,7 +142697,7 @@ class UserPicklistConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE
|
|
|
143540
142697
|
type: "Expression",
|
|
143541
142698
|
expression: validationGenerator.generateValidationsFactory()
|
|
143542
142699
|
});
|
|
143543
|
-
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
|
|
142700
|
+
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);
|
|
143544
142701
|
userPicklistDeclarationBuilder.prop(x => x.editorDataDeclaration).set({
|
|
143545
142702
|
type: "Expression",
|
|
143546
142703
|
expression: dataDeclarationGenerator.generateDataDeclarationFactory()
|
|
@@ -150500,10 +149657,10 @@ class CrossfitTableConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODUL
|
|
|
150500
149657
|
}
|
|
150501
149658
|
|
|
150502
149659
|
if (rowNode instanceof _CrossfitTableNode__WEBPACK_IMPORTED_MODULE_11__.MultilineNode) {
|
|
150503
|
-
var
|
|
149660
|
+
var _rowNode$optional2;
|
|
150504
149661
|
|
|
150505
149662
|
this.ensurePathExists(rowNode, rowNode.dataScope.path);
|
|
150506
|
-
return context.mergeDataDeclaration(context.addPathDeclEntry(rowNode, [["children", context.initSequenceFactory.children((
|
|
149663
|
+
return context.mergeDataDeclaration(context.addPathDeclEntry(rowNode, [["children", context.initSequenceFactory.children((_rowNode$optional2 = rowNode.optional) !== null && _rowNode$optional2 !== void 0 ? _rowNode$optional2 : false, rowNode.defaultChildren)]]), context.addSpecialFieldsEntry(rowNode, {
|
|
150507
149664
|
optional: rowNode.optional
|
|
150508
149665
|
}), context.addPathSectionDeclarationEntry(rowNode), context.addVisibilityPathDeclEntryNew(rowNode), context.processChildrenDataDeclaration(rowNode.rows, rowNode2 => {
|
|
150509
149666
|
if (rowNode2 instanceof _CrossfitTableNode__WEBPACK_IMPORTED_MODULE_11__.CrossfitTableRowNode) {
|
|
@@ -152911,10 +152068,10 @@ class MultilineFieldConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODU
|
|
|
152911
152068
|
}
|
|
152912
152069
|
|
|
152913
152070
|
doBuildDataDeclaration(context) {
|
|
152914
|
-
var
|
|
152071
|
+
var _node$optional;
|
|
152915
152072
|
|
|
152916
152073
|
const node = this.getCurrentNodeAs(_MultilineFieldNode__WEBPACK_IMPORTED_MODULE_3__.MultilineFieldNode);
|
|
152917
|
-
return context.mergeDataDeclaration(context.addPathDeclEntry(node, [["children", context.initSequenceFactory.children((
|
|
152074
|
+
return context.mergeDataDeclaration(context.addPathDeclEntry(node, [["children", context.initSequenceFactory.children((_node$optional = node.optional) !== null && _node$optional !== void 0 ? _node$optional : false)]]), context.addSpecialFieldsEntry(node, {
|
|
152918
152075
|
optional: node.optional
|
|
152919
152076
|
}), context.addPathSectionDeclarationEntry(node), context.addVisibilityPathDeclEntryNew(node));
|
|
152920
152077
|
}
|
|
@@ -153144,10 +152301,10 @@ class MultipleConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_0__
|
|
|
153144
152301
|
}
|
|
153145
152302
|
|
|
153146
152303
|
doBuildDataDeclaration(context) {
|
|
153147
|
-
var
|
|
152304
|
+
var _node$optional;
|
|
153148
152305
|
|
|
153149
152306
|
const node = this.getCurrentNodeAs(_MultipleNode__WEBPACK_IMPORTED_MODULE_3__.MultipleNode);
|
|
153150
|
-
return context.mergeDataDeclaration(context.addPathDeclEntry(node, [["children", context.initSequenceFactory.children((
|
|
152307
|
+
return context.mergeDataDeclaration(context.addPathDeclEntry(node, [["children", context.initSequenceFactory.children((_node$optional = node.optional) !== null && _node$optional !== void 0 ? _node$optional : false)]]), context.addSpecialFieldsEntry(node, {
|
|
153151
152308
|
optional: node.optional
|
|
153152
152309
|
}), context.addPathSectionDeclarationEntry(node));
|
|
153153
152310
|
}
|
|
@@ -154642,9 +153799,9 @@ class StickyTableWithMultilineConverter extends _SugarNodeConverter__WEBPACK_IMP
|
|
|
154642
153799
|
|
|
154643
153800
|
processMultilineNode(context, rowNode) {
|
|
154644
153801
|
if (rowNode instanceof _StickyTableNode__WEBPACK_IMPORTED_MODULE_14__.StickyTableMultilineNode) {
|
|
154645
|
-
var
|
|
153802
|
+
var _rowNode$optional;
|
|
154646
153803
|
|
|
154647
|
-
return context.mergeDataDeclaration(context.addPathDeclEntry(rowNode, [["children", context.initSequenceFactory.children((
|
|
153804
|
+
return context.mergeDataDeclaration(context.addPathDeclEntry(rowNode, [["children", context.initSequenceFactory.children((_rowNode$optional = rowNode.optional) !== null && _rowNode$optional !== void 0 ? _rowNode$optional : false, rowNode.defaultChildren)]]), context.addSpecialFieldsEntry(rowNode, {
|
|
154648
153805
|
optional: rowNode.optional
|
|
154649
153806
|
}), context.addPathSectionDeclarationEntry(rowNode), context.addVisibilityPathDeclEntryNew(rowNode), context.processChildrenDataDeclaration(rowNode.rows, rowNode2 => this.processMultilineRowNode(context, rowNode2)));
|
|
154650
153807
|
}
|
|
@@ -154717,11 +153874,11 @@ class StickyTableWithMultilineConverter extends _SugarNodeConverter__WEBPACK_IMP
|
|
|
154717
153874
|
const sideSize = (_node$side2 = node.side) !== null && _node$side2 !== void 0 ? _node$side2 : 0;
|
|
154718
153875
|
|
|
154719
153876
|
if (this.isSimpleForm()) {
|
|
154720
|
-
var
|
|
153877
|
+
var _ref, _node$deprecatedDiado;
|
|
154721
153878
|
|
|
154722
153879
|
mb.prop(x => x.maxWidth).set(orientation === "landscape" ? maxWidth : undefined);
|
|
154723
153880
|
mb.prop(x => x.sideSize).set(this.hasActionButton(node) && sideSize !== 0 ? sideSize + 1 : sideSize);
|
|
154724
|
-
const width = (
|
|
153881
|
+
const width = (_ref = (_node$deprecatedDiado = node.deprecatedDiadocWidth) !== null && _node$deprecatedDiado !== void 0 ? _node$deprecatedDiado : node.width) !== null && _ref !== void 0 ? _ref : maxWidthSimpleForm;
|
|
154725
153882
|
mb.prop(x => x.width).set(width);
|
|
154726
153883
|
mb.prop(x => x.footerHeight).set(160);
|
|
154727
153884
|
} else {
|
|
@@ -155004,10 +154161,10 @@ BindingPath: ${errorPath}`));
|
|
|
155004
154161
|
if (this.isSimpleForm()) {
|
|
155005
154162
|
mb.prop(x => x.buttonType).set(undefined);
|
|
155006
154163
|
} else {
|
|
155007
|
-
var _multiline$rowmenu,
|
|
154164
|
+
var _multiline$rowmenu, _ref2, _tableNode$removeButt;
|
|
155008
154165
|
|
|
155009
154166
|
const rowMenu = (_multiline$rowmenu = multiline.rowmenu) !== null && _multiline$rowmenu !== void 0 ? _multiline$rowmenu : false;
|
|
155010
|
-
const removebutton = (
|
|
154167
|
+
const removebutton = (_ref2 = (_tableNode$removeButt = tableNode.removeButton) !== null && _tableNode$removeButt !== void 0 ? _tableNode$removeButt : multiline.removebutton) !== null && _ref2 !== void 0 ? _ref2 : true;
|
|
155011
154168
|
mb.prop(x => x.buttonType).set(rowMenu ? "RowMenu" : removebutton ? "RemoveRowButton" : undefined);
|
|
155012
154169
|
}
|
|
155013
154170
|
|
|
@@ -155020,7 +154177,7 @@ BindingPath: ${errorPath}`));
|
|
|
155020
154177
|
}
|
|
155021
154178
|
|
|
155022
154179
|
getMultiline(context, node, multiline, start, end = Infinity) {
|
|
155023
|
-
var
|
|
154180
|
+
var _ref3, _node$removeButton, _multiline$rowmenu2, _ref4, _node$removeButton2, _context$popPathsCont2;
|
|
155024
154181
|
|
|
155025
154182
|
const overrideInfo = multiline.override ? context.controlCustomizationContext.getControlCustomizationInfo("multiline", multiline.override) : undefined;
|
|
155026
154183
|
const mb = overrideInfo == undefined ? (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_5__.componentMarkupBuilder)("MultiLine") : (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_5__.componentMarkupBuilder)(overrideInfo.dependencies, overrideInfo.controlName);
|
|
@@ -155033,7 +154190,7 @@ BindingPath: ${errorPath}`));
|
|
|
155033
154190
|
mb.prop(x => x.isList).set(multiline.usepager === false ? true : undefined);
|
|
155034
154191
|
mb.prop(x => x.bindingPath).set((0,_getBindingPath__WEBPACK_IMPORTED_MODULE_13__.getNewBindingPathExpression)(multiline));
|
|
155035
154192
|
mb.prop(x => x.showRowBorder).set(multiline.showRowBorder);
|
|
155036
|
-
const hasRemoveButton = ((
|
|
154193
|
+
const hasRemoveButton = ((_ref3 = (_node$removeButton = node.removeButton) !== null && _node$removeButton !== void 0 ? _node$removeButton : multiline.removebutton) !== null && _ref3 !== void 0 ? _ref3 : true) || ((_multiline$rowmenu2 = multiline.rowmenu) !== null && _multiline$rowmenu2 !== void 0 ? _multiline$rowmenu2 : false);
|
|
155037
154194
|
const needAddButton = multiline.addbutton !== "false";
|
|
155038
154195
|
|
|
155039
154196
|
if (this.isSimpleForm()) {
|
|
@@ -155046,7 +154203,7 @@ BindingPath: ${errorPath}`));
|
|
|
155046
154203
|
mb.prop(x => x.removeButtonPosition).set(undefined);
|
|
155047
154204
|
}
|
|
155048
154205
|
|
|
155049
|
-
mb.prop(x => x.disableScroll).set(needAddButton || ((
|
|
154206
|
+
mb.prop(x => x.disableScroll).set(needAddButton || ((_ref4 = (_node$removeButton2 = node.removeButton) !== null && _node$removeButton2 !== void 0 ? _node$removeButton2 : multiline.removebutton) !== null && _ref4 !== void 0 ? _ref4 : true) ? undefined : true);
|
|
155050
154207
|
context.pushPathsContext();
|
|
155051
154208
|
|
|
155052
154209
|
if ((0,_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_3__.arrayHasLength)(multiline.rows, 1)) {
|
|
@@ -155072,9 +154229,9 @@ BindingPath: ${errorPath}`));
|
|
|
155072
154229
|
hasActionButton(node) {
|
|
155073
154230
|
const multilines = node.rows.map(child => (0,_StickyTableNode__WEBPACK_IMPORTED_MODULE_14__.isMultilineNode)(child) ? child : child.columns.find(_StickyTableNode__WEBPACK_IMPORTED_MODULE_14__.isMultilineNode)).filter(_Common_TypingUtils__WEBPACK_IMPORTED_MODULE_3__.isNotNullOrUndefined);
|
|
155074
154231
|
return multilines.some(multiline => {
|
|
155075
|
-
var
|
|
154232
|
+
var _ref5, _node$removeButton3;
|
|
155076
154233
|
|
|
155077
|
-
return ((
|
|
154234
|
+
return ((_ref5 = (_node$removeButton3 = node.removeButton) !== null && _node$removeButton3 !== void 0 ? _node$removeButton3 : multiline.removebutton) !== null && _ref5 !== void 0 ? _ref5 : true) || multiline.rowmenu;
|
|
155078
154235
|
});
|
|
155079
154236
|
}
|
|
155080
154237
|
|
|
@@ -155388,10 +154545,10 @@ class Table2MultirowConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODU
|
|
|
155388
154545
|
}
|
|
155389
154546
|
|
|
155390
154547
|
doBuildDataDeclaration(context) {
|
|
155391
|
-
var
|
|
154548
|
+
var _node$optional;
|
|
155392
154549
|
|
|
155393
154550
|
const node = this.getCurrentNodeAs(_Table2Node__WEBPACK_IMPORTED_MODULE_3__.Table2MultirowNode);
|
|
155394
|
-
return context.mergeDataDeclaration(context.addPathDeclEntry(node, [["children", context.initSequenceFactory.children((
|
|
154551
|
+
return context.mergeDataDeclaration(context.addPathDeclEntry(node, [["children", context.initSequenceFactory.children((_node$optional = node.optional) !== null && _node$optional !== void 0 ? _node$optional : false)]]), context.addPathSectionDeclarationEntry(node));
|
|
155395
154552
|
}
|
|
155396
154553
|
|
|
155397
154554
|
buildChildrenDataDeclaration(context) {
|
|
@@ -156551,10 +155708,13 @@ class TabsConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Sug
|
|
|
156551
155708
|
}
|
|
156552
155709
|
|
|
156553
155710
|
doBuildDataDeclaration(context) {
|
|
156554
|
-
var _ref, _node$optional;
|
|
156555
|
-
|
|
156556
155711
|
const node = this.getCurrentNodeAs(_TabsNode__WEBPACK_IMPORTED_MODULE_4__.TabsNode);
|
|
156557
|
-
|
|
155712
|
+
|
|
155713
|
+
if (node.optional) {
|
|
155714
|
+
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_3__.SugarAttributeReadError("Элемент tabs не может быть опциональным", node, "optional");
|
|
155715
|
+
}
|
|
155716
|
+
|
|
155717
|
+
return context.mergeDataDeclaration(context.addPathDeclEntry(node, [["children", context.initSequenceFactory.children(false)]]), context.addPathSectionDeclarationEntry(node));
|
|
156558
155718
|
}
|
|
156559
155719
|
|
|
156560
155720
|
buildChildrenDataDeclaration(context) {
|
|
@@ -158975,7 +158135,7 @@ class ComboBoxConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__
|
|
|
158975
158135
|
if (node.disabled2 != undefined) {
|
|
158976
158136
|
markupBuilder.prop(x => x.disabled2).set({
|
|
158977
158137
|
type: "Expression",
|
|
158978
|
-
expression: `{ type: "ModelDependentEvaluator", expression: (path
|
|
158138
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => ${node.disabled2} }`
|
|
158979
158139
|
});
|
|
158980
158140
|
}
|
|
158981
158141
|
|
|
@@ -161645,14 +160805,15 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
161645
160805
|
/* harmony export */ "InputConverter": () => (/* binding */ InputConverter)
|
|
161646
160806
|
/* harmony export */ });
|
|
161647
160807
|
/* harmony import */ var _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../../../../../../Common/ModelPath/ModelPath */ "./Common/ModelPath/ModelPath.ts");
|
|
161648
|
-
/* harmony import */ var
|
|
161649
|
-
/* harmony import */ var
|
|
161650
|
-
/* harmony import */ var
|
|
161651
|
-
/* harmony import */ var
|
|
161652
|
-
/* harmony import */ var
|
|
161653
|
-
/* harmony import */ var
|
|
161654
|
-
/* harmony import */ var
|
|
161655
|
-
/* harmony import */ var
|
|
160808
|
+
/* harmony import */ var _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../../common/XmlParser/XmlNode */ "./Generator/src/common/XmlParser/XmlNode.ts");
|
|
160809
|
+
/* harmony import */ var _validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../../../../validationGenerator/Nodes/TypeNode */ "./Generator/src/generators/validationGenerator/Nodes/TypeNode.ts");
|
|
160810
|
+
/* harmony import */ var _ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../../../ComponentMarkupBuilder/ComponentMarkupBuilder */ "./Generator/src/generators/markupGenerator/ComponentMarkupBuilder/ComponentMarkupBuilder.ts");
|
|
160811
|
+
/* harmony import */ var _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../../../SugarNodeConverter */ "./Generator/src/generators/markupGenerator/SugarNodeConverter.ts");
|
|
160812
|
+
/* harmony import */ var _CommonNodeProperties_TooltipProperties_SetTooltipSettingsProps__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../CommonNodeProperties/TooltipProperties/SetTooltipSettingsProps */ "./Generator/src/generators/markupGenerator/ElementProcessors/CommonNodeProperties/TooltipProperties/SetTooltipSettingsProps.ts");
|
|
160813
|
+
/* harmony import */ var _getBindingPath__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../getBindingPath */ "./Generator/src/generators/markupGenerator/getBindingPath.ts");
|
|
160814
|
+
/* harmony import */ var _SugarNodes_SugarNodeUtils__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../../SugarNodes/SugarNodeUtils */ "./Generator/src/generators/markupGenerator/SugarNodes/SugarNodeUtils.ts");
|
|
160815
|
+
/* harmony import */ var _InputLimitations__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./InputLimitations */ "./Generator/src/generators/markupGenerator/ElementProcessors/ValueEditors/Input/InputLimitations.ts");
|
|
160816
|
+
/* harmony import */ var _InputNode__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./InputNode */ "./Generator/src/generators/markupGenerator/ElementProcessors/ValueEditors/Input/InputNode.ts");
|
|
161656
160817
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
161657
160818
|
(function () {
|
|
161658
160819
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -161672,18 +160833,19 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
161672
160833
|
|
|
161673
160834
|
|
|
161674
160835
|
|
|
161675
|
-
|
|
160836
|
+
|
|
160837
|
+
class InputConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_4__.SugarNodeConverterBase {
|
|
161676
160838
|
static getAcceptNodeClass() {
|
|
161677
|
-
return
|
|
160839
|
+
return _InputNode__WEBPACK_IMPORTED_MODULE_9__.InputNode;
|
|
161678
160840
|
}
|
|
161679
160841
|
|
|
161680
160842
|
get nodePaths() {
|
|
161681
|
-
const node = this.getCurrentNodeAs(
|
|
161682
|
-
return [(0,
|
|
160843
|
+
const node = this.getCurrentNodeAs(_InputNode__WEBPACK_IMPORTED_MODULE_9__.InputNode);
|
|
160844
|
+
return [(0,_getBindingPath__WEBPACK_IMPORTED_MODULE_6__.getNewBindingPathExpression)(node)];
|
|
161683
160845
|
}
|
|
161684
160846
|
|
|
161685
160847
|
doBuildFLangValidations(buildContext) {
|
|
161686
|
-
const node = this.getCurrentNodeAs(
|
|
160848
|
+
const node = this.getCurrentNodeAs(_InputNode__WEBPACK_IMPORTED_MODULE_9__.InputNode);
|
|
161687
160849
|
const targetPath = _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.AbsoluteModelPath.createAbsoluteFromMask(this.getResolvedBindingPath(node), _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_0__.PathTokens.each);
|
|
161688
160850
|
const typeNode = buildContext.getTypeNode(node.validationInfo);
|
|
161689
160851
|
const schemaTypeNode = buildContext.getSchemaTypeInfo(targetPath);
|
|
@@ -161696,12 +160858,12 @@ class InputConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Su
|
|
|
161696
160858
|
}
|
|
161697
160859
|
|
|
161698
160860
|
doBuildNodeValidations(validationGenerator) {
|
|
161699
|
-
const node = this.getCurrentNodeAs(
|
|
160861
|
+
const node = this.getCurrentNodeAs(_InputNode__WEBPACK_IMPORTED_MODULE_9__.InputNode);
|
|
161700
160862
|
validationGenerator.processValidations(this.getResolvedBindingPath(node), node.validationInfo.optional, validationGenerator.getTypeNode(node.validationInfo), undefined, node.validationInfo.emptydescription);
|
|
161701
160863
|
}
|
|
161702
160864
|
|
|
161703
160865
|
doBuildDataDeclaration(context) {
|
|
161704
|
-
const node = this.getCurrentNodeAs(
|
|
160866
|
+
const node = this.getCurrentNodeAs(_InputNode__WEBPACK_IMPORTED_MODULE_9__.InputNode);
|
|
161705
160867
|
return context.mergeDataDeclaration(context.addPathDeclEntry(node, [["value", context.initSequenceFactory.dataValue(node.dataBinding, node.disabled)], node.auto ? ["autoFlag", context.initSequenceFactory.takeFromModel()] : undefined, node.auto ? ["autoValue", context.initSequenceFactory.takeFromModelOrDefaultValue(node.dataBinding.defaultValue)] : undefined]), context.addSpecialFieldsEntry(node, {
|
|
161706
160868
|
optional: node.dataBinding.optional,
|
|
161707
160869
|
disabled: node.disabled
|
|
@@ -161709,7 +160871,7 @@ class InputConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Su
|
|
|
161709
160871
|
}
|
|
161710
160872
|
|
|
161711
160873
|
doBuildNormalizeRules(builder) {
|
|
161712
|
-
const node = this.getCurrentNodeAs(
|
|
160874
|
+
const node = this.getCurrentNodeAs(_InputNode__WEBPACK_IMPORTED_MODULE_9__.InputNode);
|
|
161713
160875
|
return [builder.valueInitializer(node, node.dataBinding, node.disabled), ...builder.specialFieldsInitializer(node, {
|
|
161714
160876
|
optional: node.dataBinding.optional,
|
|
161715
160877
|
disabled: node.disabled
|
|
@@ -161717,17 +160879,17 @@ class InputConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Su
|
|
|
161717
160879
|
}
|
|
161718
160880
|
|
|
161719
160881
|
buildChildrenDataDeclaration(context) {
|
|
161720
|
-
const node = this.getCurrentNodeAs(
|
|
160882
|
+
const node = this.getCurrentNodeAs(_InputNode__WEBPACK_IMPORTED_MODULE_9__.InputNode);
|
|
161721
160883
|
return context.processChildrenDataDeclaration(node.helpNodes);
|
|
161722
160884
|
}
|
|
161723
160885
|
|
|
161724
160886
|
*doTraverseChildren() {
|
|
161725
|
-
const node = this.getCurrentNodeAs(
|
|
160887
|
+
const node = this.getCurrentNodeAs(_InputNode__WEBPACK_IMPORTED_MODULE_9__.InputNode);
|
|
161726
160888
|
yield* node.helpNodes;
|
|
161727
160889
|
}
|
|
161728
160890
|
|
|
161729
160891
|
doConvert(context) {
|
|
161730
|
-
const node = this.getCurrentNodeAs(
|
|
160892
|
+
const node = this.getCurrentNodeAs(_InputNode__WEBPACK_IMPORTED_MODULE_9__.InputNode);
|
|
161731
160893
|
this.ensurePathExists(node, node.dataBinding.path);
|
|
161732
160894
|
|
|
161733
160895
|
if (node.auto) {
|
|
@@ -161737,27 +160899,76 @@ class InputConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Su
|
|
|
161737
160899
|
}
|
|
161738
160900
|
}
|
|
161739
160901
|
|
|
160902
|
+
setCurrencyProps(markupBuilder, context, node) {
|
|
160903
|
+
const typeNode = context.getTypeNode(node.validationInfo);
|
|
160904
|
+
const schemaTypeInfo = context.getSchemaTypeInfo(node.getFullPath());
|
|
160905
|
+
markupBuilder.prop(x => x.currency).set(node.currency);
|
|
160906
|
+
|
|
160907
|
+
if (node.currency) {
|
|
160908
|
+
var _typeNode$base;
|
|
160909
|
+
|
|
160910
|
+
const baseTypeName = (_typeNode$base = typeNode === null || typeNode === void 0 ? void 0 : typeNode.base) !== null && _typeNode$base !== void 0 ? _typeNode$base : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.baseType;
|
|
160911
|
+
|
|
160912
|
+
if (baseTypeName === "decimal") {
|
|
160913
|
+
var _ref, _ref2, _ref3, _ref4, _typeNode$flattenType, _typeNode$flattenType2, _typeNode$flattenType3, _typeNode$flattenType4, _typeNode$flattenType5, _typeNode$flattenType6, _typeNode$flattenType7, _typeNode$flattenType8;
|
|
160914
|
+
|
|
160915
|
+
const maxLength = (_ref = (_ref2 = (_ref3 = (_ref4 = (_typeNode$flattenType = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType2 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.LengthTypeCheckNode))) === null || _typeNode$flattenType2 === void 0 ? void 0 : _typeNode$flattenType2.value) !== null && _typeNode$flattenType !== void 0 ? _typeNode$flattenType : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.length) !== null && _ref4 !== void 0 ? _ref4 : typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType3 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.MaxlengthTypeCheckNode))) === null || _typeNode$flattenType3 === void 0 ? void 0 : _typeNode$flattenType3.value) !== null && _ref3 !== void 0 ? _ref3 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.maxLength) !== null && _ref2 !== void 0 ? _ref2 : typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType4 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.TotaldigitsTypeCheckNode))) === null || _typeNode$flattenType4 === void 0 ? void 0 : _typeNode$flattenType4.value) !== null && _ref !== void 0 ? _ref : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.totalDigits;
|
|
160916
|
+
const fractionDigits = (_typeNode$flattenType5 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType6 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.FractiondigitsTypeCheckNode))) === null || _typeNode$flattenType6 === void 0 ? void 0 : _typeNode$flattenType6.value) !== null && _typeNode$flattenType5 !== void 0 ? _typeNode$flattenType5 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.fractionDigits;
|
|
160917
|
+
const integerDigits = (_typeNode$flattenType7 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType8 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.IntegerdigitsTypeCheckNode))) === null || _typeNode$flattenType8 === void 0 ? void 0 : _typeNode$flattenType8.value) !== null && _typeNode$flattenType7 !== void 0 ? _typeNode$flattenType7 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.integerDigits;
|
|
160918
|
+
markupBuilder.prop(x => x.currencyIntegerDigits).set(integerDigits);
|
|
160919
|
+
markupBuilder.prop(x => x.currencyFractionDigits).set(fractionDigits);
|
|
160920
|
+
|
|
160921
|
+
if (maxLength != undefined && fractionDigits != undefined && integerDigits == undefined) {
|
|
160922
|
+
markupBuilder.prop(x => x.currencyIntegerDigits).set(maxLength - fractionDigits);
|
|
160923
|
+
markupBuilder.prop(x => x.currencyFractionDigits).set(fractionDigits);
|
|
160924
|
+
} else if (maxLength != undefined && fractionDigits == undefined && integerDigits != undefined) {
|
|
160925
|
+
markupBuilder.prop(x => x.currencyIntegerDigits).set(integerDigits);
|
|
160926
|
+
markupBuilder.prop(x => x.currencyFractionDigits).set(maxLength - integerDigits);
|
|
160927
|
+
} else if (maxLength == undefined && fractionDigits != undefined && integerDigits != undefined) {
|
|
160928
|
+
markupBuilder.prop(x => x.currencyIntegerDigits).set(integerDigits);
|
|
160929
|
+
markupBuilder.prop(x => x.currencyFractionDigits).set(fractionDigits);
|
|
160930
|
+
} else if (maxLength == undefined && fractionDigits != undefined && integerDigits == undefined) {
|
|
160931
|
+
markupBuilder.prop(x => x.currencyIntegerDigits).set(undefined);
|
|
160932
|
+
markupBuilder.prop(x => x.currencyFractionDigits).set(fractionDigits);
|
|
160933
|
+
} else if (maxLength == undefined && fractionDigits == undefined && integerDigits == undefined) {
|
|
160934
|
+
markupBuilder.prop(x => x.currencyIntegerDigits).set(undefined);
|
|
160935
|
+
markupBuilder.prop(x => x.currencyFractionDigits).set(2);
|
|
160936
|
+
} else {
|
|
160937
|
+
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_1__.SugarAttributeReadError("Unable to use currency editor with decimal type with length, maxLength or totaldigits constraints", node, "currency");
|
|
160938
|
+
}
|
|
160939
|
+
} else if (baseTypeName === "integer") {
|
|
160940
|
+
var _ref5, _typeNode$flattenType9, _typeNode$flattenType10, _ref6, _typeNode$flattenType11, _typeNode$flattenType12, _ref7, _typeNode$flattenType13, _typeNode$flattenType14;
|
|
160941
|
+
|
|
160942
|
+
const maxLength = Math.max((_ref5 = (_typeNode$flattenType9 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType10 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.LengthTypeCheckNode))) === null || _typeNode$flattenType10 === void 0 ? void 0 : _typeNode$flattenType10.value) !== null && _typeNode$flattenType9 !== void 0 ? _typeNode$flattenType9 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.length) !== null && _ref5 !== void 0 ? _ref5 : -1, (_ref6 = (_typeNode$flattenType11 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType12 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.MaxlengthTypeCheckNode))) === null || _typeNode$flattenType12 === void 0 ? void 0 : _typeNode$flattenType12.value) !== null && _typeNode$flattenType11 !== void 0 ? _typeNode$flattenType11 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.maxLength) !== null && _ref6 !== void 0 ? _ref6 : -1, (_ref7 = (_typeNode$flattenType13 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType14 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_2__.TotaldigitsTypeCheckNode))) === null || _typeNode$flattenType14 === void 0 ? void 0 : _typeNode$flattenType14.value) !== null && _typeNode$flattenType13 !== void 0 ? _typeNode$flattenType13 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.totalDigits) !== null && _ref7 !== void 0 ? _ref7 : -1);
|
|
160943
|
+
markupBuilder.prop(x => x.currencyIntegerDigits).set(maxLength === -1 ? undefined : maxLength);
|
|
160944
|
+
markupBuilder.prop(x => x.currencyFractionDigits).set(0);
|
|
160945
|
+
} else if (baseTypeName != undefined) {
|
|
160946
|
+
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_1__.SugarAttributeReadError("Unable to use currency editor for non numberic types", node, "currency");
|
|
160947
|
+
}
|
|
160948
|
+
}
|
|
160949
|
+
}
|
|
160950
|
+
|
|
161740
160951
|
buildRegularInput(context, node) {
|
|
161741
|
-
var _typeNode$
|
|
160952
|
+
var _typeNode$base2, _node$maskChar, _node$width;
|
|
161742
160953
|
|
|
161743
160954
|
const typeNode = context.getTypeNode(node.validationInfo);
|
|
161744
160955
|
const schemaTypeInfo = context.getSchemaTypeInfo(node.getFullPath());
|
|
161745
|
-
const typeBase = (_typeNode$
|
|
161746
|
-
const markupBuilder = (0,
|
|
160956
|
+
const typeBase = (_typeNode$base2 = typeNode === null || typeNode === void 0 ? void 0 : typeNode.base) !== null && _typeNode$base2 !== void 0 ? _typeNode$base2 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.baseType;
|
|
160957
|
+
const markupBuilder = (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_3__.componentMarkupBuilder)("Input");
|
|
161747
160958
|
|
|
161748
160959
|
if (node.visible != undefined) {
|
|
161749
160960
|
markupBuilder.prop(x => x.visible).set({
|
|
161750
160961
|
type: "Expression",
|
|
161751
|
-
expression: `{ type: "ModelDependentEvaluator", expression: (path
|
|
160962
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => ${node.visible} }`
|
|
161752
160963
|
});
|
|
161753
160964
|
}
|
|
161754
160965
|
|
|
161755
|
-
markupBuilder.prop(x => x.bindingPath).set((0,
|
|
160966
|
+
markupBuilder.prop(x => x.bindingPath).set((0,_getBindingPath__WEBPACK_IMPORTED_MODULE_6__.getNewBindingPathExpression)(node));
|
|
161756
160967
|
markupBuilder.prop(x => x.placeholder).set(node.placeholder);
|
|
161757
160968
|
markupBuilder.prop(x => x.disabled).set(node.disabled);
|
|
161758
160969
|
|
|
161759
160970
|
if (node.disabled2 != undefined) {
|
|
161760
|
-
markupBuilder.prop(x => x.disabled2).set((0,
|
|
160971
|
+
markupBuilder.prop(x => x.disabled2).set((0,_SugarNodes_SugarNodeUtils__WEBPACK_IMPORTED_MODULE_7__.buildExpressionPropValue)(node.disabled2));
|
|
161761
160972
|
|
|
161762
160973
|
if (this.getLegacyNode().getParent() != undefined) {
|
|
161763
160974
|
markupBuilder.prop(x => x.evaluatorsContextPath).set(this.getEvaluatorsContextPathExpression());
|
|
@@ -161769,18 +160980,16 @@ class InputConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Su
|
|
|
161769
160980
|
markupBuilder.prop(x => x.maskChar).set(node.mask ? (_node$maskChar = node.maskChar) !== null && _node$maskChar !== void 0 ? _node$maskChar : "_" : undefined);
|
|
161770
160981
|
markupBuilder.prop(x => x.formatChars).set(node.formatChars);
|
|
161771
160982
|
markupBuilder.prop(x => x.width).set((_node$width = node.width) !== null && _node$width !== void 0 ? _node$width : "100%");
|
|
161772
|
-
|
|
160983
|
+
this.setCurrencyProps(markupBuilder, context, node);
|
|
161773
160984
|
markupBuilder.prop(x => x.useMaskExtender).set(node.useMaskExtender);
|
|
161774
|
-
(0,
|
|
161775
|
-
const inputLimitations = (0,
|
|
160985
|
+
(0,_CommonNodeProperties_TooltipProperties_SetTooltipSettingsProps__WEBPACK_IMPORTED_MODULE_5__.setTooltipSettingsProps)(markupBuilder, node.tooltipSettings);
|
|
160986
|
+
const inputLimitations = (0,_InputLimitations__WEBPACK_IMPORTED_MODULE_8__.getInputLimitations)(typeNode, schemaTypeInfo);
|
|
161776
160987
|
|
|
161777
160988
|
if (inputLimitations !== null) {
|
|
161778
160989
|
markupBuilder.prop(x => x.inputLimit).set(inputLimitations);
|
|
161779
160990
|
}
|
|
161780
160991
|
|
|
161781
|
-
if (node.align
|
|
161782
|
-
markupBuilder.prop(x => x.align).set(node.align);
|
|
161783
|
-
} else if (typeBase === "integer" || typeBase === "decimal") {
|
|
160992
|
+
if ((typeBase === "integer" || typeBase === "decimal") && node.align !== "left" || node.align === "right") {
|
|
161784
160993
|
markupBuilder.prop(x => x.align).set("right");
|
|
161785
160994
|
}
|
|
161786
160995
|
|
|
@@ -161796,29 +161005,29 @@ class InputConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Su
|
|
|
161796
161005
|
}
|
|
161797
161006
|
|
|
161798
161007
|
buildFxInput(context, node) {
|
|
161799
|
-
var _typeNode$
|
|
161008
|
+
var _typeNode$base3, _node$width2;
|
|
161800
161009
|
|
|
161801
161010
|
const typeNode = context.getTypeNode(node.validationInfo);
|
|
161802
161011
|
const schemaTypeInfo = context.getSchemaTypeInfo(node.getFullPath());
|
|
161803
|
-
const typeBase = (_typeNode$
|
|
161804
|
-
const markupBuilder = (0,
|
|
161012
|
+
const typeBase = (_typeNode$base3 = typeNode === null || typeNode === void 0 ? void 0 : typeNode.base) !== null && _typeNode$base3 !== void 0 ? _typeNode$base3 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.baseType;
|
|
161013
|
+
const markupBuilder = (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_3__.componentMarkupBuilder)("FxInput");
|
|
161805
161014
|
|
|
161806
161015
|
if (node.visible != undefined) {
|
|
161807
161016
|
markupBuilder.prop(x => x.visible).set({
|
|
161808
161017
|
type: "Expression",
|
|
161809
|
-
expression: `{ type: "ModelDependentEvaluator", expression: (path
|
|
161018
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => ${node.visible} }`
|
|
161810
161019
|
});
|
|
161811
161020
|
}
|
|
161812
161021
|
|
|
161813
|
-
markupBuilder.prop(x => x.bindingPath).set((0,
|
|
161022
|
+
markupBuilder.prop(x => x.bindingPath).set((0,_getBindingPath__WEBPACK_IMPORTED_MODULE_6__.getNewBindingPathExpression)(node));
|
|
161814
161023
|
markupBuilder.prop(x => x.hint).set(this.getConverterResultFromAttributeWithMarkup(context, node.hint));
|
|
161815
161024
|
markupBuilder.prop(x => x.disabled).set(node.disabled);
|
|
161816
161025
|
markupBuilder.prop(x => x.disabledPure).set(node.deprecatedDisabledForRpn);
|
|
161817
161026
|
markupBuilder.prop(x => x.align).set(node.align);
|
|
161818
161027
|
markupBuilder.prop(x => x.width).set((_node$width2 = node.width) !== null && _node$width2 !== void 0 ? _node$width2 : "100%");
|
|
161819
|
-
|
|
161820
|
-
(0,
|
|
161821
|
-
const inputLimitations = (0,
|
|
161028
|
+
this.setCurrencyProps(markupBuilder, context, node);
|
|
161029
|
+
(0,_CommonNodeProperties_TooltipProperties_SetTooltipSettingsProps__WEBPACK_IMPORTED_MODULE_5__.setTooltipSettingsProps)(markupBuilder, node.tooltipSettings);
|
|
161030
|
+
const inputLimitations = (0,_InputLimitations__WEBPACK_IMPORTED_MODULE_8__.getInputLimitations)(typeNode, schemaTypeInfo);
|
|
161822
161031
|
|
|
161823
161032
|
if (inputLimitations !== null) {
|
|
161824
161033
|
markupBuilder.prop(x => x.inputLimit).set(inputLimitations);
|
|
@@ -161841,7 +161050,7 @@ class InputConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Su
|
|
|
161841
161050
|
if (node.formula != undefined && typeof node.formula === "string" && isTemplatedString(node.formula)) {
|
|
161842
161051
|
markupBuilder.prop(x => x.formula).set({
|
|
161843
161052
|
type: "Expression",
|
|
161844
|
-
expression: `{ type: "ModelDependentEvaluator", expression: (path
|
|
161053
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => \`${node.formula}\` }`
|
|
161845
161054
|
});
|
|
161846
161055
|
} else {
|
|
161847
161056
|
markupBuilder.prop(x => x.formula).set(this.getConverterResultFromAttributeWithMarkup(context, node.formula));
|
|
@@ -161851,7 +161060,7 @@ class InputConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_2__.Su
|
|
|
161851
161060
|
markupBuilder.prop(x => x.prefix).set(this.getConverterResultFromAttributeWithMarkup(context, node.prefix));
|
|
161852
161061
|
|
|
161853
161062
|
if (node.disabled2 != undefined) {
|
|
161854
|
-
markupBuilder.prop(x => x.disabled2).set((0,
|
|
161063
|
+
markupBuilder.prop(x => x.disabled2).set((0,_SugarNodes_SugarNodeUtils__WEBPACK_IMPORTED_MODULE_7__.buildExpressionPropValue)(node.disabled2));
|
|
161855
161064
|
|
|
161856
161065
|
if (this.getLegacyNode().getParent() != undefined) {
|
|
161857
161066
|
markupBuilder.prop(x => x.evaluatorsContextPath).set(this.getEvaluatorsContextPathExpression());
|
|
@@ -161966,8 +161175,7 @@ const regExps = {
|
|
|
161966
161175
|
return `^[+-]?((${intCase})|(${fractCase}))$`;
|
|
161967
161176
|
},
|
|
161968
161177
|
date: () => "^[0-9.]{0,10}$",
|
|
161969
|
-
gYear: () => "^\\d{0,4}$"
|
|
161970
|
-
gMonth: () => "^[\-\d]{0,4}$"
|
|
161178
|
+
gYear: () => "^\\d{0,4}$"
|
|
161971
161179
|
};
|
|
161972
161180
|
function getInputLimitations(typeNode, schemaTypeInfo) {
|
|
161973
161181
|
var _ref4, _typeNode$flattenType7, _typeNode$flattenType8, _ref5, _typeNode$flattenType9, _typeNode$flattenType10, _ref6, _typeNode$flattenType11, _typeNode$flattenType12, _typeNode$base;
|
|
@@ -162398,107 +161606,6 @@ let InputNode = (_dec = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_
|
|
|
162398
161606
|
|
|
162399
161607
|
/***/ }),
|
|
162400
161608
|
|
|
162401
|
-
/***/ "./Generator/src/generators/markupGenerator/ElementProcessors/ValueEditors/Input/SetCurrencyProps.ts":
|
|
162402
|
-
/*!***********************************************************************************************************!*\
|
|
162403
|
-
!*** ./Generator/src/generators/markupGenerator/ElementProcessors/ValueEditors/Input/SetCurrencyProps.ts ***!
|
|
162404
|
-
\***********************************************************************************************************/
|
|
162405
|
-
/***/ ((module, __webpack_exports__, __webpack_require__) => {
|
|
162406
|
-
|
|
162407
|
-
"use strict";
|
|
162408
|
-
__webpack_require__.r(__webpack_exports__);
|
|
162409
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
162410
|
-
/* harmony export */ "setCurrencyProps": () => (/* binding */ setCurrencyProps)
|
|
162411
|
-
/* harmony export */ });
|
|
162412
|
-
/* harmony import */ var _validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../../../validationGenerator/Nodes/TypeNode */ "./Generator/src/generators/validationGenerator/Nodes/TypeNode.ts");
|
|
162413
|
-
/* harmony import */ var _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../../../../../common/XmlParser/XmlNode */ "./Generator/src/common/XmlParser/XmlNode.ts");
|
|
162414
|
-
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
162415
|
-
(function () {
|
|
162416
|
-
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
162417
|
-
enterModule && enterModule(module);
|
|
162418
|
-
})();
|
|
162419
|
-
|
|
162420
|
-
var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default.signature : function (a) {
|
|
162421
|
-
return a;
|
|
162422
|
-
};
|
|
162423
|
-
|
|
162424
|
-
|
|
162425
|
-
|
|
162426
|
-
function setCurrencyProps(markupBuilder, context, node) {
|
|
162427
|
-
var _typeNode$base, _node$currency;
|
|
162428
|
-
|
|
162429
|
-
const typeNode = context.getTypeNode(node.validationInfo);
|
|
162430
|
-
const schemaTypeInfo = context.getSchemaTypeInfo(node.getFullPath());
|
|
162431
|
-
const baseTypeName = (_typeNode$base = typeNode === null || typeNode === void 0 ? void 0 : typeNode.base) !== null && _typeNode$base !== void 0 ? _typeNode$base : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.baseType;
|
|
162432
|
-
const currency = (_node$currency = node.currency) !== null && _node$currency !== void 0 ? _node$currency : baseTypeName === "integer" || baseTypeName === "decimal";
|
|
162433
|
-
markupBuilder.prop(x => x.currency).set(currency);
|
|
162434
|
-
|
|
162435
|
-
if (currency) {
|
|
162436
|
-
if (baseTypeName === "decimal") {
|
|
162437
|
-
var _typeNode$flattenType, _typeNode$flattenType2, _ref, _ref2, _ref3, _ref4, _typeNode$flattenType3, _typeNode$flattenType4, _typeNode$flattenType5, _typeNode$flattenType6, _typeNode$flattenType7, _typeNode$flattenType8, _typeNode$flattenType9, _typeNode$flattenType10;
|
|
162438
|
-
|
|
162439
|
-
const totalDigits = (_typeNode$flattenType = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType2 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.TotaldigitsTypeCheckNode))) === null || _typeNode$flattenType2 === void 0 ? void 0 : _typeNode$flattenType2.value) !== null && _typeNode$flattenType !== void 0 ? _typeNode$flattenType : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.totalDigits;
|
|
162440
|
-
const maxLength = (_ref = (_ref2 = (_ref3 = (_ref4 = (_typeNode$flattenType3 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType4 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.LengthTypeCheckNode))) === null || _typeNode$flattenType4 === void 0 ? void 0 : _typeNode$flattenType4.value) !== null && _typeNode$flattenType3 !== void 0 ? _typeNode$flattenType3 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.length) !== null && _ref4 !== void 0 ? _ref4 : typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType5 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.MaxlengthTypeCheckNode))) === null || _typeNode$flattenType5 === void 0 ? void 0 : _typeNode$flattenType5.value) !== null && _ref3 !== void 0 ? _ref3 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.maxLength) !== null && _ref2 !== void 0 ? _ref2 : typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType6 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.TotaldigitsTypeCheckNode))) === null || _typeNode$flattenType6 === void 0 ? void 0 : _typeNode$flattenType6.value) !== null && _ref !== void 0 ? _ref : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.totalDigits;
|
|
162441
|
-
const fractionDigits = (_typeNode$flattenType7 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType8 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.FractiondigitsTypeCheckNode))) === null || _typeNode$flattenType8 === void 0 ? void 0 : _typeNode$flattenType8.value) !== null && _typeNode$flattenType7 !== void 0 ? _typeNode$flattenType7 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.fractionDigits;
|
|
162442
|
-
const integerDigits = (_typeNode$flattenType9 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType10 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.IntegerdigitsTypeCheckNode))) === null || _typeNode$flattenType10 === void 0 ? void 0 : _typeNode$flattenType10.value) !== null && _typeNode$flattenType9 !== void 0 ? _typeNode$flattenType9 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.integerDigits;
|
|
162443
|
-
markupBuilder.prop(x => x.currencyIntegerDigits).set(integerDigits);
|
|
162444
|
-
markupBuilder.prop(x => x.currencyFractionDigits).set(fractionDigits);
|
|
162445
|
-
|
|
162446
|
-
if (maxLength != undefined && fractionDigits != undefined && integerDigits == undefined) {
|
|
162447
|
-
markupBuilder.prop(x => x.currencyIntegerDigits).set(maxLength - fractionDigits);
|
|
162448
|
-
markupBuilder.prop(x => x.currencyFractionDigits).set(fractionDigits);
|
|
162449
|
-
} else if (maxLength != undefined && fractionDigits == undefined && integerDigits != undefined) {
|
|
162450
|
-
markupBuilder.prop(x => x.currencyIntegerDigits).set(integerDigits);
|
|
162451
|
-
markupBuilder.prop(x => x.currencyFractionDigits).set(maxLength - integerDigits);
|
|
162452
|
-
} else if (maxLength == undefined && fractionDigits != undefined && integerDigits != undefined) {
|
|
162453
|
-
markupBuilder.prop(x => x.currencyIntegerDigits).set(integerDigits);
|
|
162454
|
-
markupBuilder.prop(x => x.currencyFractionDigits).set(fractionDigits);
|
|
162455
|
-
} else if (maxLength == undefined && fractionDigits != undefined && integerDigits == undefined) {
|
|
162456
|
-
markupBuilder.prop(x => x.currencyIntegerDigits).set(undefined);
|
|
162457
|
-
markupBuilder.prop(x => x.currencyFractionDigits).set(fractionDigits);
|
|
162458
|
-
} else if (maxLength == undefined && fractionDigits == undefined && integerDigits == undefined) {
|
|
162459
|
-
markupBuilder.prop(x => x.currencyIntegerDigits).set(undefined);
|
|
162460
|
-
markupBuilder.prop(x => x.currencyFractionDigits).set(2);
|
|
162461
|
-
} else if (maxLength != undefined && fractionDigits != undefined && integerDigits != undefined) {
|
|
162462
|
-
markupBuilder.prop(x => x.currencyIntegerDigits).set(integerDigits);
|
|
162463
|
-
markupBuilder.prop(x => x.currencyFractionDigits).set(fractionDigits);
|
|
162464
|
-
} else if (totalDigits != undefined && fractionDigits == undefined && integerDigits == undefined) {
|
|
162465
|
-
markupBuilder.prop(x => x.currencyIntegerDigits).set(totalDigits);
|
|
162466
|
-
markupBuilder.prop(x => x.currencyFractionDigits).set(0);
|
|
162467
|
-
} else {
|
|
162468
|
-
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_1__.SugarAttributeReadError(`Unable to use currency editor with decimal type with length, maxLength or totaldigits constraints (path: ${node.getFullPath().toString()})`, node, "currency");
|
|
162469
|
-
}
|
|
162470
|
-
} else if (baseTypeName === "integer") {
|
|
162471
|
-
var _ref5, _typeNode$flattenType11, _typeNode$flattenType12, _ref6, _typeNode$flattenType13, _typeNode$flattenType14, _ref7, _typeNode$flattenType15, _typeNode$flattenType16;
|
|
162472
|
-
|
|
162473
|
-
const maxLength = Math.max((_ref5 = (_typeNode$flattenType11 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType12 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.LengthTypeCheckNode))) === null || _typeNode$flattenType12 === void 0 ? void 0 : _typeNode$flattenType12.value) !== null && _typeNode$flattenType11 !== void 0 ? _typeNode$flattenType11 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.length) !== null && _ref5 !== void 0 ? _ref5 : -1, (_ref6 = (_typeNode$flattenType13 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType14 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.MaxlengthTypeCheckNode))) === null || _typeNode$flattenType14 === void 0 ? void 0 : _typeNode$flattenType14.value) !== null && _typeNode$flattenType13 !== void 0 ? _typeNode$flattenType13 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.maxLength) !== null && _ref6 !== void 0 ? _ref6 : -1, (_ref7 = (_typeNode$flattenType15 = typeNode === null || typeNode === void 0 ? void 0 : (_typeNode$flattenType16 = typeNode.flattenTypeCheckNodes().find((0,_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.ofType)(_validationGenerator_Nodes_TypeNode__WEBPACK_IMPORTED_MODULE_0__.TotaldigitsTypeCheckNode))) === null || _typeNode$flattenType16 === void 0 ? void 0 : _typeNode$flattenType16.value) !== null && _typeNode$flattenType15 !== void 0 ? _typeNode$flattenType15 : schemaTypeInfo === null || schemaTypeInfo === void 0 ? void 0 : schemaTypeInfo.totalDigits) !== null && _ref7 !== void 0 ? _ref7 : -1);
|
|
162474
|
-
markupBuilder.prop(x => x.currencyIntegerDigits).set(maxLength === -1 ? undefined : maxLength);
|
|
162475
|
-
markupBuilder.prop(x => x.currencyFractionDigits).set(0);
|
|
162476
|
-
} else if (baseTypeName != undefined) {
|
|
162477
|
-
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_1__.SugarAttributeReadError("Unable to use currency editor for non numberic types", node, "currency");
|
|
162478
|
-
}
|
|
162479
|
-
}
|
|
162480
|
-
}
|
|
162481
|
-
;
|
|
162482
|
-
|
|
162483
|
-
(function () {
|
|
162484
|
-
var reactHotLoader = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.default : undefined;
|
|
162485
|
-
|
|
162486
|
-
if (!reactHotLoader) {
|
|
162487
|
-
return;
|
|
162488
|
-
}
|
|
162489
|
-
|
|
162490
|
-
reactHotLoader.register(setCurrencyProps, "setCurrencyProps", "C:\\buildAgent\\work\\8df8f1edd755969c\\Generator\\src\\generators\\markupGenerator\\ElementProcessors\\ValueEditors\\Input\\SetCurrencyProps.ts");
|
|
162491
|
-
})();
|
|
162492
|
-
|
|
162493
|
-
;
|
|
162494
|
-
|
|
162495
|
-
(function () {
|
|
162496
|
-
var leaveModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.leaveModule : undefined;
|
|
162497
|
-
leaveModule && leaveModule(module);
|
|
162498
|
-
})();
|
|
162499
|
-
|
|
162500
|
-
/***/ }),
|
|
162501
|
-
|
|
162502
161609
|
/***/ "./Generator/src/generators/markupGenerator/ElementProcessors/ValueEditors/Kladr/KladrConverter.ts":
|
|
162503
161610
|
/*!*********************************************************************************************************!*\
|
|
162504
161611
|
!*** ./Generator/src/generators/markupGenerator/ElementProcessors/ValueEditors/Kladr/KladrConverter.ts ***!
|
|
@@ -164052,7 +163159,7 @@ class SelectConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_3__.S
|
|
|
164052
163159
|
if (node.disabled2 != undefined) {
|
|
164053
163160
|
markupBuilder.prop(x => x.disabled2).set({
|
|
164054
163161
|
type: "Expression",
|
|
164055
|
-
expression: `{ type: "ModelDependentEvaluator", expression: (path
|
|
163162
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => ${node.disabled2} }`
|
|
164056
163163
|
});
|
|
164057
163164
|
|
|
164058
163165
|
if (this.getLegacyNode().getParent() != undefined) {
|
|
@@ -166118,8 +165225,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
166118
165225
|
/* harmony import */ var _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../../../../../../Common/ModelPath/ModelPath */ "./Common/ModelPath/ModelPath.ts");
|
|
166119
165226
|
/* harmony import */ var _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../../../../common/XmlParser/XmlNode */ "./Generator/src/common/XmlParser/XmlNode.ts");
|
|
166120
165227
|
/* harmony import */ var _CommonNodeProperties_FontWeight__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(/*! ../../CommonNodeProperties/FontWeight */ "./Generator/src/generators/markupGenerator/ElementProcessors/CommonNodeProperties/FontWeight.ts");
|
|
166121
|
-
/* harmony import */ var
|
|
166122
|
-
/* harmony import */ var _TextNode__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(/*! ./TextNode */ "./Generator/src/generators/markupGenerator/ElementProcessors/ValueViewers/Text/TextNode.ts");
|
|
165228
|
+
/* harmony import */ var _TextNode__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(/*! ./TextNode */ "./Generator/src/generators/markupGenerator/ElementProcessors/ValueViewers/Text/TextNode.ts");
|
|
166123
165229
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
166124
165230
|
(function () {
|
|
166125
165231
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -166139,19 +165245,18 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
166139
165245
|
|
|
166140
165246
|
|
|
166141
165247
|
|
|
166142
|
-
|
|
166143
165248
|
class TextConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_3__.SugarNodeConverterBase {
|
|
166144
165249
|
static getAcceptNodeClass() {
|
|
166145
|
-
return
|
|
165250
|
+
return _TextNode__WEBPACK_IMPORTED_MODULE_8__.TextNode;
|
|
166146
165251
|
}
|
|
166147
165252
|
|
|
166148
165253
|
doBuildNodeValidations(validationGenerator) {
|
|
166149
|
-
const node = this.getCurrentNodeAs(
|
|
165254
|
+
const node = this.getCurrentNodeAs(_TextNode__WEBPACK_IMPORTED_MODULE_8__.TextNode);
|
|
166150
165255
|
validationGenerator.processValidations(this.getResolvedBindingPath(node), node.validationInfo.optional, validationGenerator.getTypeNode(node.validationInfo), undefined, node.validationInfo.emptydescription);
|
|
166151
165256
|
}
|
|
166152
165257
|
|
|
166153
165258
|
doBuildNormalizeRules() {
|
|
166154
|
-
const node = this.getCurrentNodeAs(
|
|
165259
|
+
const node = this.getCurrentNodeAs(_TextNode__WEBPACK_IMPORTED_MODULE_8__.TextNode);
|
|
166155
165260
|
const defaultValue = "";
|
|
166156
165261
|
const targetValueReference = new _ServerSideFLangNormalization_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_4__.ValueReferenceExpression(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_5__.ModelPath.createFromMask(this.getResolvedBindingPath(node), true, _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_5__.PathTokens.each), "value");
|
|
166157
165262
|
const currentValueReference = new _ServerSideFLangNormalization_FLang_FLangCodeDom__WEBPACK_IMPORTED_MODULE_4__.ValueReferenceExpression(_Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_5__.ModelPath.createFromMask(this.getResolvedBindingPath(node), true, _Common_ModelPath_ModelPath__WEBPACK_IMPORTED_MODULE_5__.PathTokens.current), "value");
|
|
@@ -166169,7 +165274,7 @@ class TextConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_3__.Sug
|
|
|
166169
165274
|
}
|
|
166170
165275
|
|
|
166171
165276
|
doBuildDataDeclaration(context) {
|
|
166172
|
-
const node = this.getCurrentNodeAs(
|
|
165277
|
+
const node = this.getCurrentNodeAs(_TextNode__WEBPACK_IMPORTED_MODULE_8__.TextNode);
|
|
166173
165278
|
|
|
166174
165279
|
if (!node.dataBinding.path) {
|
|
166175
165280
|
return _DataDeclarationGenerator_DataDeclarationGenerationContext__WEBPACK_IMPORTED_MODULE_0__.emptyDataDeclarationCollection;
|
|
@@ -166183,18 +165288,18 @@ class TextConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_3__.Sug
|
|
|
166183
165288
|
}
|
|
166184
165289
|
|
|
166185
165290
|
buildChildrenDataDeclaration(context) {
|
|
166186
|
-
const node = this.getCurrentNodeAs(
|
|
165291
|
+
const node = this.getCurrentNodeAs(_TextNode__WEBPACK_IMPORTED_MODULE_8__.TextNode);
|
|
166187
165292
|
return context.processChildrenDataDeclaration([...node.helpNodes, ...node.children]);
|
|
166188
165293
|
}
|
|
166189
165294
|
|
|
166190
165295
|
*doTraverseChildren() {
|
|
166191
|
-
const node = this.getCurrentNodeAs(
|
|
165296
|
+
const node = this.getCurrentNodeAs(_TextNode__WEBPACK_IMPORTED_MODULE_8__.TextNode);
|
|
166192
165297
|
yield* node.helpNodes;
|
|
166193
165298
|
yield* node.children;
|
|
166194
165299
|
}
|
|
166195
165300
|
|
|
166196
165301
|
get nodePaths() {
|
|
166197
|
-
const node = this.getCurrentNodeAs(
|
|
165302
|
+
const node = this.getCurrentNodeAs(_TextNode__WEBPACK_IMPORTED_MODULE_8__.TextNode);
|
|
166198
165303
|
let bindingPath;
|
|
166199
165304
|
|
|
166200
165305
|
if (node.path != undefined) {
|
|
@@ -166209,7 +165314,7 @@ class TextConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_3__.Sug
|
|
|
166209
165314
|
}
|
|
166210
165315
|
|
|
166211
165316
|
doConvert(context) {
|
|
166212
|
-
const node = this.getCurrentNodeAs(
|
|
165317
|
+
const node = this.getCurrentNodeAs(_TextNode__WEBPACK_IMPORTED_MODULE_8__.TextNode);
|
|
166213
165318
|
|
|
166214
165319
|
if (node.path != undefined) {
|
|
166215
165320
|
return this.buildTextWithPathAttribute(context, node);
|
|
@@ -166267,12 +165372,6 @@ class TextConverter extends _SugarNodeConverter__WEBPACK_IMPORTED_MODULE_3__.Sug
|
|
|
166267
165372
|
|
|
166268
165373
|
buildTextWithPathAttribute(context, node) {
|
|
166269
165374
|
const mb = (0,_ComponentMarkupBuilder_ComponentMarkupBuilder__WEBPACK_IMPORTED_MODULE_2__.componentMarkupBuilder)("Text");
|
|
166270
|
-
(0,_ValueEditors_Input_SetCurrencyProps__WEBPACK_IMPORTED_MODULE_8__.setCurrencyProps)(mb, context, node);
|
|
166271
|
-
|
|
166272
|
-
if (node.currency) {
|
|
166273
|
-
mb.prop(x => x.rouble).set(node.rouble);
|
|
166274
|
-
}
|
|
166275
|
-
|
|
166276
165375
|
mb.prop(x => x.showError).set(node.showError);
|
|
166277
165376
|
mb.prop(x => x.quotes).set(node.quotes);
|
|
166278
165377
|
mb.prop(x => x.hint).set(node.hint);
|
|
@@ -166345,7 +165444,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
166345
165444
|
/* harmony import */ var _Helpers_Help_HelpNode__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../../Helpers/Help/HelpNode */ "./Generator/src/generators/markupGenerator/ElementProcessors/Helpers/Help/HelpNode.ts");
|
|
166346
165445
|
/* harmony import */ var _Commons_DocumentationLinks__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ../../Commons/DocumentationLinks */ "./Generator/src/generators/markupGenerator/ElementProcessors/Commons/DocumentationLinks.ts");
|
|
166347
165446
|
/* module decorator */ module = __webpack_require__.hmd(module);
|
|
166348
|
-
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _dec11, _dec12, _dec13, _dec14, _dec15, _dec16, _dec17, _dec18, _dec19, _dec20, _dec21, _dec22, _dec23, _dec24, _dec25, _dec26, _dec27, _dec28, _dec29, _dec30, _dec31, _dec32, _dec33, _dec34, _dec35, _dec36, _dec37, _dec38, _dec39, _dec40,
|
|
165447
|
+
var _dec, _dec2, _dec3, _dec4, _dec5, _dec6, _dec7, _dec8, _dec9, _dec10, _dec11, _dec12, _dec13, _dec14, _dec15, _dec16, _dec17, _dec18, _dec19, _dec20, _dec21, _dec22, _dec23, _dec24, _dec25, _dec26, _dec27, _dec28, _dec29, _dec30, _dec31, _dec32, _dec33, _dec34, _dec35, _dec36, _dec37, _dec38, _dec39, _dec40, _class, _class2, _descriptor, _descriptor2, _descriptor3, _descriptor4, _descriptor5, _descriptor6, _descriptor7, _descriptor8, _descriptor9, _descriptor10, _descriptor11, _descriptor12, _descriptor13, _descriptor14, _descriptor15, _descriptor16, _descriptor17, _descriptor18, _descriptor19, _descriptor20, _descriptor21, _descriptor22, _descriptor23, _descriptor24, _descriptor25, _descriptor26, _descriptor27, _descriptor28, _descriptor29, _descriptor30, _descriptor31, _descriptor32, _descriptor33, _descriptor34, _descriptor35, _descriptor36, _descriptor37, _descriptor38, _descriptor39;
|
|
166349
165448
|
|
|
166350
165449
|
(function () {
|
|
166351
165450
|
var enterModule = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoaderGlobal.enterModule : undefined;
|
|
@@ -166369,7 +165468,7 @@ var __signature__ = typeof reactHotLoaderGlobal !== 'undefined' ? reactHotLoader
|
|
|
166369
165468
|
|
|
166370
165469
|
|
|
166371
165470
|
|
|
166372
|
-
let TextNode = (_dec = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.sugarNode)("text", `Текст с возможностью взять значение из модели`, __webpack_require__("./Generator/src/generators/markupGenerator/ElementProcessors/ValueViewers/Text sync recursive .md$")), _dec2 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrMixin)(_CommonNodeProperties_ValidationInfoNode__WEBPACK_IMPORTED_MODULE_1__.ValidationInfoNode), _dec3 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrMixin)(_CommonNodeProperties_DataBindingMixinNode__WEBPACK_IMPORTED_MODULE_0__.DataBindingMixinNode), _dec4 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("editable", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.Removed), _dec5 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("auto", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec6 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("offsetLeft", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec7 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("rngAttribute", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec8 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("autoResize", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec9 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("rows", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec10 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("textOverflow", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec11 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("title", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec12 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("description", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec13 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("font", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec14 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("gId", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.UntypedUsage), _dec15 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("showError", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, `Показывать ли ошибку, если она есть по соотв. binding path, вместо значения`), _dec16 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("field", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, `**Внутренне поле** Нелепое поле генерируемое препроцессором для кладра`), _dec17 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("disabled", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, `Поле не редактируемое`), _dec18 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("requisite", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, `(Проставляется c disabled="true" всегда!)\tэтот атрибут говорит о том, что поле должно каждый раз подтягиваться из реквизитов и поэтому нормализуется при каждом открытии черновика. Нужен, чтобы реквизиты подтягивались из реквизитов при каждом открытии формы и при загрузке ФУФа с пустым ИНН, а не только в первый раз.`), _dec19 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("line", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, `Режим отображения текста: блочный или текстовый. Если line="false", то текст будет отображаться в отдельной строке`), _dec20 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("quotes", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, `Поле состоящее из двух символов и соответвует кавычкам, в которые будет заключено значение. Например: \`quotes="<>"\``), _dec21 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("hint", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.localizedString, `Маленький статичный черный хинт над значением.`), _dec22 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("optional", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, ``), _dec23 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("valueName", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, `Из какого ${(0,_Commons_DocumentationLinks__WEBPACK_IMPORTED_MODULE_6__.docLink)(_Commons_DocumentationLinks__WEBPACK_IMPORTED_MODULE_6__.viewModelFieldLink, "поля ViewModel")} брать значение. По умолчанию: \`value\``), _dec24 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("for", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.bindingPath, ``), _dec25 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("tooltipWidth", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, `Ширина тултипа с ошибкой`), _dec26 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("color", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.color, "Цвет"), _dec27 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("marginTop", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Отступ сверху"), _dec28 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("marginBottom", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Отступ снизу"), _dec29 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("textalign", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType["enum"]("center", "justify", "left", "right", "start", "end"), "Выравнивание"), _dec30 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("width", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Ширина блока"), _dec31 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("marginLeft", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Отступ слева"), _dec32 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("marginRight", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Отступ справа"), _dec33 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("size", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Ширина блока"), _dec34 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("lineHeight", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, "Высота строки"), _dec35 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("fetchfn", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, "Указывается название функции, которая прокидывает реквизиты в форму"), _dec36 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("fontWeight", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType["enum"]("bold", "normal", "bolder", "lighter", "100", "200", "300", "400", "500", "600", "700"), "Толщина текста"), _dec37 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("align", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType["enum"]("baseline", "bottom", "middle", "sub", "super", "text-bottom", "text-top", "top"), "Выравнивание"), _dec38 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.children)(), _dec39 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("help", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, `Текст для отображения ${(0,_Commons_DocumentationLinks__WEBPACK_IMPORTED_MODULE_6__.docLink)(_Commons_DocumentationLinks__WEBPACK_IMPORTED_MODULE_6__.helpTooltipLink)}-а`), _dec40 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.children)("help", [_Helpers_Help_HelpNode__WEBPACK_IMPORTED_MODULE_5__.HelpNode]),
|
|
165471
|
+
let TextNode = (_dec = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.sugarNode)("text", `Текст с возможностью взять значение из модели`, __webpack_require__("./Generator/src/generators/markupGenerator/ElementProcessors/ValueViewers/Text sync recursive .md$")), _dec2 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrMixin)(_CommonNodeProperties_ValidationInfoNode__WEBPACK_IMPORTED_MODULE_1__.ValidationInfoNode), _dec3 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrMixin)(_CommonNodeProperties_DataBindingMixinNode__WEBPACK_IMPORTED_MODULE_0__.DataBindingMixinNode), _dec4 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("editable", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.Removed), _dec5 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("auto", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec6 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("offsetLeft", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec7 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("rngAttribute", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec8 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("autoResize", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec9 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("rows", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec10 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("textOverflow", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec11 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("title", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec12 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("description", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec13 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("font", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.InvalidUsage), _dec14 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.deprecatedAttr)("gId", _Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_2__.DeprecationReason.UntypedUsage), _dec15 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("showError", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, `Показывать ли ошибку, если она есть по соотв. binding path, вместо значения`), _dec16 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("field", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, `**Внутренне поле** Нелепое поле генерируемое препроцессором для кладра`), _dec17 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("disabled", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, `Поле не редактируемое`), _dec18 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("requisite", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, `(Проставляется c disabled="true" всегда!)\tэтот атрибут говорит о том, что поле должно каждый раз подтягиваться из реквизитов и поэтому нормализуется при каждом открытии черновика. Нужен, чтобы реквизиты подтягивались из реквизитов при каждом открытии формы и при загрузке ФУФа с пустым ИНН, а не только в первый раз.`), _dec19 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("line", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, `Режим отображения текста: блочный или текстовый. Если line="false", то текст будет отображаться в отдельной строке`), _dec20 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("quotes", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, `Поле состоящее из двух символов и соответвует кавычкам, в которые будет заключено значение. Например: \`quotes="<>"\``), _dec21 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("hint", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.localizedString, `Маленький статичный черный хинт над значением.`), _dec22 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("optional", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.boolean, ``), _dec23 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("valueName", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, `Из какого ${(0,_Commons_DocumentationLinks__WEBPACK_IMPORTED_MODULE_6__.docLink)(_Commons_DocumentationLinks__WEBPACK_IMPORTED_MODULE_6__.viewModelFieldLink, "поля ViewModel")} брать значение. По умолчанию: \`value\``), _dec24 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("for", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.bindingPath, ``), _dec25 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("tooltipWidth", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, `Ширина тултипа с ошибкой`), _dec26 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("color", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.color, "Цвет"), _dec27 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("marginTop", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Отступ сверху"), _dec28 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("marginBottom", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Отступ снизу"), _dec29 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("textalign", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType["enum"]("center", "justify", "left", "right", "start", "end"), "Выравнивание"), _dec30 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("width", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Ширина блока"), _dec31 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("marginLeft", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Отступ слева"), _dec32 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("marginRight", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Отступ справа"), _dec33 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("size", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.lengthUnit, "Ширина блока"), _dec34 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("lineHeight", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, "Высота строки"), _dec35 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("fetchfn", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, "Указывается название функции, которая прокидывает реквизиты в форму"), _dec36 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("fontWeight", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType["enum"]("bold", "normal", "bolder", "lighter", "100", "200", "300", "400", "500", "600", "700"), "Толщина текста"), _dec37 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("align", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType["enum"]("baseline", "bottom", "middle", "sub", "super", "text-bottom", "text-top", "top"), "Выравнивание"), _dec38 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.children)(), _dec39 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attr)("help", _Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.attrType.string, `Текст для отображения ${(0,_Commons_DocumentationLinks__WEBPACK_IMPORTED_MODULE_6__.docLink)(_Commons_DocumentationLinks__WEBPACK_IMPORTED_MODULE_6__.helpTooltipLink)}-а`), _dec40 = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4__.children)("help", [_Helpers_Help_HelpNode__WEBPACK_IMPORTED_MODULE_5__.HelpNode]), _dec(_class = (_class2 = class TextNode extends _Serializer_SugarNodeWithLegacyVisibility__WEBPACK_IMPORTED_MODULE_3__.SugarNodeWithLegacyVisibility {
|
|
166373
165472
|
constructor(...args) {
|
|
166374
165473
|
super(...args);
|
|
166375
165474
|
|
|
@@ -166450,10 +165549,6 @@ let TextNode = (_dec = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4
|
|
|
166450
165549
|
_initializerDefineProperty(this, "help", _descriptor38, this);
|
|
166451
165550
|
|
|
166452
165551
|
_initializerDefineProperty(this, "helpNodes", _descriptor39, this);
|
|
166453
|
-
|
|
166454
|
-
_initializerDefineProperty(this, "currency", _descriptor40, this);
|
|
166455
|
-
|
|
166456
|
-
_initializerDefineProperty(this, "rouble", _descriptor41, this);
|
|
166457
165552
|
}
|
|
166458
165553
|
|
|
166459
165554
|
get path() {
|
|
@@ -166665,16 +165760,6 @@ let TextNode = (_dec = (0,_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_4
|
|
|
166665
165760
|
enumerable: true,
|
|
166666
165761
|
writable: true,
|
|
166667
165762
|
initializer: null
|
|
166668
|
-
}), _descriptor40 = _applyDecoratedDescriptor(_class2.prototype, "currency", [_dec41], {
|
|
166669
|
-
configurable: true,
|
|
166670
|
-
enumerable: true,
|
|
166671
|
-
writable: true,
|
|
166672
|
-
initializer: null
|
|
166673
|
-
}), _descriptor41 = _applyDecoratedDescriptor(_class2.prototype, "rouble", [_dec42], {
|
|
166674
|
-
configurable: true,
|
|
166675
|
-
enumerable: true,
|
|
166676
|
-
writable: true,
|
|
166677
|
-
initializer: null
|
|
166678
165763
|
})), _class2)) || _class);
|
|
166679
165764
|
;
|
|
166680
165765
|
|
|
@@ -170745,15 +169830,10 @@ function strictCastNode(node, nodeClass) {
|
|
|
170745
169830
|
|
|
170746
169831
|
throw new Error();
|
|
170747
169832
|
}
|
|
170748
|
-
function buildExpressionPropValue(condition
|
|
170749
|
-
if (condition === undefined) {
|
|
170750
|
-
return undefined;
|
|
170751
|
-
}
|
|
170752
|
-
|
|
169833
|
+
function buildExpressionPropValue(condition) {
|
|
170753
169834
|
return {
|
|
170754
169835
|
type: "Expression",
|
|
170755
|
-
expression: `{ type: "ModelDependentEvaluator", expression: (path
|
|
170756
|
-
dependencies: deps
|
|
169836
|
+
expression: `{ type: "ModelDependentEvaluator", expression: (path) => ${condition} }`
|
|
170757
169837
|
};
|
|
170758
169838
|
}
|
|
170759
169839
|
;
|
|
@@ -171834,7 +170914,7 @@ let ForcedTypeChecksNode = (_dec40 = (0,_markupGenerator_Serializer_SugarSeriali
|
|
|
171834
170914
|
writable: true,
|
|
171835
170915
|
initializer: null
|
|
171836
170916
|
})), _class46)) || _class45);
|
|
171837
|
-
let TypeNode = (_dec42 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.sugarNode)("type", `Описание валидации для поля`, __webpack_require__("./Generator/src/generators/validationGenerator/Nodes sync recursive .md$")), _dec43 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attr)("base", _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attrType["enum"]("string", "pattern", "integer", "decimal", "date", "gYear"
|
|
170917
|
+
let TypeNode = (_dec42 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.sugarNode)("type", `Описание валидации для поля`, __webpack_require__("./Generator/src/generators/validationGenerator/Nodes sync recursive .md$")), _dec43 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attr)("base", _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attrType["enum"]("string", "pattern", "integer", "decimal", "date", "gYear"), `Базовый тип, для нового типа. Автоматически задаёт валидацию (число, дата, год) и исключает ввод неверных символов`), _dec44 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attr)("name", _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attrType.string, `Имя типа. Не требуется для анонимных типов. Имя типа в дальнейшем указывается в атрибуте type контрола.`), _dec45 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.deprecatedAttr)("requireDescription", _markupGenerator_Serializer_DeprecationReason__WEBPACK_IMPORTED_MODULE_0__.DeprecationReason.Typo), _dec46 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attr)("requiredDescription", _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attrType.localizedString, `Если значение в контроле является обязательным, то это сообщение будет отображается, если значение отсутствует. См. атрибут optional (Подсказка-всплывашка, когда поле пустое. Если не указать - будет стандартная подсказка. Появляется только для обязательного поля. Если не указан, то выводится значение из атр. description)`), _dec47 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attr)("description", _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attrType.localizedString, `Сообщение, которое будет отображатся если значение не отвечает заданным в типе валидациям и соотв. валидация не имеет атрибута description (Подсказка-всплывашка, когда поле заполнено неверно. Если не указать - то подсказка построится автоматически на основании base, length, enumeration (пока что на основании pattern автоматической подсказки нет. Более того, есть баг, что если description для типа с pattern-ом не указан, валидация по паттерну не работает))`), _dec48 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attr)("checkType", _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.attrType["enum"]("error", "warning"), `Тип валидации. При ошибке контрол будет отображаться либо оранжевым (warning), либо красным (error).`), _dec49 = (0,_markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.children)(undefined, [CustomValidationTypeCheckNode, PatternTypeCheckNode, EnumerationTypeCheckNode, AttachmentsTypeCheckNode, LengthTypeCheckNode, MinlengthTypeCheckNode, MaxlengthTypeCheckNode, TotaldigitsTypeCheckNode, IntegerdigitsTypeCheckNode, FractiondigitsTypeCheckNode, DigestcheckTypeCheckNode, DigestConditionTypeCheckNode, MininclusiveTypeCheckNode, MaxinclusiveTypeCheckNode, ForcedTypeChecksNode]), _dec42(_class48 = (_class49 = class TypeNode extends _markupGenerator_Serializer_SugarSerializer__WEBPACK_IMPORTED_MODULE_1__.SugarNodeBase {
|
|
171838
170918
|
constructor(...args) {
|
|
171839
170919
|
super(...args);
|
|
171840
170920
|
|
|
@@ -173386,13 +172466,6 @@ class ValidationGenerator {
|
|
|
173386
172466
|
return result;
|
|
173387
172467
|
}
|
|
173388
172468
|
|
|
173389
|
-
case "gMonth":
|
|
173390
|
-
{
|
|
173391
|
-
const result = (0,_common_CodeGeneration_ClassInstanceBuilder__WEBPACK_IMPORTED_MODULE_1__.instanceBuilder)("Validators.IsMonthValueValidator");
|
|
173392
|
-
result.set(0, description);
|
|
173393
|
-
return result;
|
|
173394
|
-
}
|
|
173395
|
-
|
|
173396
172469
|
default:
|
|
173397
172470
|
if (typeNode != undefined) {
|
|
173398
172471
|
throw new _common_XmlParser_XmlNode__WEBPACK_IMPORTED_MODULE_2__.SugarAttributeReadError("Unknown base type name", typeNode, "base");
|