@farris/jit-engine 1.3.321 → 1.3.323
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/README.md +8 -0
- package/bin/index.js +0 -0
- package/lib/domstructure/ui/approve-comments/approval-comments.js +56 -53
- package/lib/domstructure/ui/approve-comments/approval-comments.js.map +1 -1
- package/lib/domstructure/ui/approve-comments/index.js +13 -13
- package/lib/domstructure/ui/approve-logs/approval-logs.js +33 -33
- package/lib/domstructure/ui/approve-logs/approval-logs.js.map +1 -1
- package/lib/domstructure/ui/approve-logs/index.js +13 -13
- package/lib/domstructure/ui/commands/button.js +63 -63
- package/lib/domstructure/ui/commands/button.js.map +1 -1
- package/lib/domstructure/ui/data/collection/hierarchy/tree_grid.js +170 -155
- package/lib/domstructure/ui/data/collection/hierarchy/tree_grid.js.map +1 -1
- package/lib/domstructure/ui/data/fields/form/combo-list.js +126 -121
- package/lib/domstructure/ui/data/fields/form/combo-list.js.map +1 -1
- package/lib/task/recursiveGenerateDevkit.js +6 -5
- package/lib/task/recursiveGenerateDevkit.js.map +1 -1
- package/lib/template/ui/kendo/approval-comments.pug +18 -16
- package/lib/template/ui/kendo/approve-logs.pug +1 -1
- package/lib/template/ui/kendo/farris-combo-lookup.pug +98 -98
- package/lib/template/ui/kendo/multi-select.pug +18 -17
- package/lib/template/ui/kendo/treegrid.pug +40 -16
- package/lib/utility/devkit/component-parameter-collector/farris-datagrid-collector.js +392 -390
- package/lib/utility/devkit/component-parameter-collector/farris-datagrid-collector.js.map +1 -1
- package/lib/utility/farris-datagrid/combo-lookup-editor.js +192 -192
- package/lib/utility/farris-datagrid/combo-lookup-editor.js.map +1 -1
- package/lib/utility/farris-datagrid/lookup-editor.js +253 -235
- package/lib/utility/farris-datagrid/lookup-editor.js.map +1 -1
- package/package.json +1 -1
- package/lib/mobileapp/vue/static/.gitignore +0 -13
package/README.md
CHANGED
package/bin/index.js
CHANGED
|
File without changes
|
|
@@ -1,54 +1,57 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ApprovalComments = void 0;
|
|
4
|
-
const utility_1 = require("../../../utility");
|
|
5
|
-
const data_1 = require("../data");
|
|
6
|
-
class ApprovalComments extends data_1.FormField {
|
|
7
|
-
constructor(param) {
|
|
8
|
-
super(param);
|
|
9
|
-
let obj;
|
|
10
|
-
if (typeof param === 'string') {
|
|
11
|
-
obj = utility_1.ToolHelper.convertToJsonOrDefault(param);
|
|
12
|
-
}
|
|
13
|
-
else {
|
|
14
|
-
obj = param;
|
|
15
|
-
}
|
|
16
|
-
if (!obj) {
|
|
17
|
-
return;
|
|
18
|
-
}
|
|
19
|
-
this.domains = [];
|
|
20
|
-
const keys = 'sortOrder,procInstId,displayType,domains,';
|
|
21
|
-
Object.keys(obj).forEach(key => {
|
|
22
|
-
if (keys.includes(key)) {
|
|
23
|
-
if (key
|
|
24
|
-
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
25
|
-
obj[key].forEach((item) => {
|
|
26
|
-
this.domains.push({
|
|
27
|
-
domainName: item.domainName,
|
|
28
|
-
domainCode: item.domainCode,
|
|
29
|
-
activityDefinedIds: item.activityDefinedIds
|
|
30
|
-
});
|
|
31
|
-
});
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
else {
|
|
35
|
-
this[key] = obj[key];
|
|
36
|
-
}
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ApprovalComments = void 0;
|
|
4
|
+
const utility_1 = require("../../../utility");
|
|
5
|
+
const data_1 = require("../data");
|
|
6
|
+
class ApprovalComments extends data_1.FormField {
|
|
7
|
+
constructor(param) {
|
|
8
|
+
super(param);
|
|
9
|
+
let obj;
|
|
10
|
+
if (typeof param === 'string') {
|
|
11
|
+
obj = utility_1.ToolHelper.convertToJsonOrDefault(param);
|
|
12
|
+
}
|
|
13
|
+
else {
|
|
14
|
+
obj = param;
|
|
15
|
+
}
|
|
16
|
+
if (!obj) {
|
|
17
|
+
return;
|
|
18
|
+
}
|
|
19
|
+
this.domains = [];
|
|
20
|
+
const keys = 'sortOrder,procInstId,displayType,domains,hideAddSignComments';
|
|
21
|
+
Object.keys(obj).forEach(key => {
|
|
22
|
+
if (keys.includes(key)) {
|
|
23
|
+
if (key === 'domains') {
|
|
24
|
+
if (utility_1.ToolHelper.isArray(obj[key], false)) {
|
|
25
|
+
obj[key].forEach((item) => {
|
|
26
|
+
this.domains.push({
|
|
27
|
+
domainName: item.domainName,
|
|
28
|
+
domainCode: item.domainCode,
|
|
29
|
+
activityDefinedIds: item.activityDefinedIds
|
|
30
|
+
});
|
|
31
|
+
});
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
else if (key === 'hideAddSignComments') {
|
|
35
|
+
this[key] = utility_1.ToolHelper.createBinding(obj[key], false, this.externalComponentNameSpace, this.id);
|
|
36
|
+
}
|
|
37
|
+
else {
|
|
38
|
+
this[key] = obj[key];
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
if (this.path) {
|
|
43
|
+
this.procInstId = "this.viewModel.bindingData." + this.path;
|
|
44
|
+
}
|
|
45
|
+
this.placeHolderResourceId = utility_1.I18nResourceManager.generatePlaceHolderResourceId("ApprovalComments", this.id, this.resourcePrefix);
|
|
46
|
+
}
|
|
47
|
+
toJSON() {
|
|
48
|
+
return Object.assign({}, super.toJSON(), {
|
|
49
|
+
"type": "ApprovalComments",
|
|
50
|
+
});
|
|
51
|
+
}
|
|
52
|
+
toString() {
|
|
53
|
+
return JSON.stringify(this.toJSON());
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
exports.ApprovalComments = ApprovalComments;
|
|
54
57
|
//# sourceMappingURL=approval-comments.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"approval-comments.js","sourceRoot":"","sources":["../../../../src/domstructure/ui/approve-comments/approval-comments.ts"],"names":[],"mappings":";;;AAAA,8CAAmE;AAEnE,kCAAoC;AAKpC,MAAa,gBAAiB,SAAQ,gBAAS;
|
|
1
|
+
{"version":3,"file":"approval-comments.js","sourceRoot":"","sources":["../../../../src/domstructure/ui/approve-comments/approval-comments.ts"],"names":[],"mappings":";;;AAAA,8CAAmE;AAEnE,kCAAoC;AAKpC,MAAa,gBAAiB,SAAQ,gBAAS;IAM3C,YAAY,KAAmB;QAC3B,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,GAAQ,CAAC;QACb,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;YAC3B,GAAG,GAAG,oBAAU,CAAC,sBAAsB,CAAC,KAAK,CAAC,CAAC;SAClD;aAAM;YACH,GAAG,GAAG,KAAK,CAAC;SACf;QAED,IAAI,CAAC,GAAG,EAAE;YACN,OAAO;SACV;QAED,IAAI,CAAC,OAAO,GAAG,EAAE,CAAC;QAClB,MAAM,IAAI,GAAG,8DAA8D,CAAC;QAC5E,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE;YAC3B,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE;gBACpB,IAAI,GAAG,KAAK,SAAS,EAAE;oBACnB,IAAI,oBAAU,CAAC,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,KAAK,CAAC,EAAE;wBACrC,GAAG,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,CAAC,IAAS,EAAE,EAAE;4BAC3B,IAAI,CAAC,OAAO,CAAC,IAAI,CAAC;gCACd,UAAU,EAAE,IAAI,CAAC,UAAU;gCAC3B,UAAU,EAAE,IAAI,CAAC,UAAU;gCAC3B,kBAAkB,EAAE,IAAI,CAAC,kBAAkB;6BAC9C,CAAC,CAAA;wBACN,CAAC,CAAC,CAAC;qBACN;iBACJ;qBAAM,IAAI,GAAG,KAAK,qBAAqB,EAAE;oBACtC,IAAI,CAAC,GAAG,CAAC,GAAG,oBAAU,CAAC,aAAa,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,KAAK,EAAE,IAAI,CAAC,0BAA0B,EAAE,IAAI,CAAC,EAAE,CAAC,CAAC;iBACnG;qBAAM;oBACH,IAAI,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC,CAAC;iBACxB;aACJ;QACL,CAAC,CAAC,CAAC;QACH,IAAI,IAAI,CAAC,IAAI,EAAE;YACX,IAAI,CAAC,UAAU,GAAG,6BAA6B,GAAG,IAAI,CAAC,IAAI,CAAC;SAC/D;QACD,IAAI,CAAC,qBAAqB,GAAG,6BAAmB,CAAC,6BAA6B,CAAC,kBAAkB,EAAE,IAAI,CAAC,EAAE,EAAE,IAAI,CAAC,cAAc,CAAC,CAAC;IACrI,CAAC;IAED,MAAM;QACF,OAAO,MAAM,CAAC,MAAM,CAAC,EAAE,EAAE,KAAK,CAAC,MAAM,EAAE,EAAE;YACrC,MAAM,EAAE,kBAAkB;SAC7B,CAAC,CAAC;IACP,CAAC;IAED,QAAQ;QACJ,OAAO,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,MAAM,EAAE,CAAC,CAAC;IACzC,CAAC;CACJ;AAvDD,4CAuDC"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
-
};
|
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
__exportStar(require("./approval-comments"), exports);
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./approval-comments"), exports);
|
|
14
14
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,34 +1,34 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ApprovalLogs = void 0;
|
|
4
|
-
const utility_1 = require("../../../utility");
|
|
5
|
-
const data_1 = require("../data");
|
|
6
|
-
class ApprovalLogs extends data_1.FormField {
|
|
7
|
-
constructor(param) {
|
|
8
|
-
super(param);
|
|
9
|
-
let obj;
|
|
10
|
-
if (typeof param === 'string') {
|
|
11
|
-
obj = utility_1.ToolHelper.convertToJsonOrDefault(param);
|
|
12
|
-
}
|
|
13
|
-
else {
|
|
14
|
-
obj = param;
|
|
15
|
-
}
|
|
16
|
-
if (!obj) {
|
|
17
|
-
return;
|
|
18
|
-
}
|
|
19
|
-
const keys = `displayType`;
|
|
20
|
-
Object.keys(obj).forEach(key => {
|
|
21
|
-
if (keys.includes(key)) {
|
|
22
|
-
this[key] = obj[key];
|
|
23
|
-
}
|
|
24
|
-
});
|
|
25
|
-
if (this.path) {
|
|
26
|
-
this.procInstId = "this.viewModel.bindingData." + this.path;
|
|
27
|
-
}
|
|
28
|
-
}
|
|
29
|
-
static getType() {
|
|
30
|
-
return "ApprovalLogs";
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
exports.ApprovalLogs = ApprovalLogs;
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ApprovalLogs = void 0;
|
|
4
|
+
const utility_1 = require("../../../utility");
|
|
5
|
+
const data_1 = require("../data");
|
|
6
|
+
class ApprovalLogs extends data_1.FormField {
|
|
7
|
+
constructor(param) {
|
|
8
|
+
super(param);
|
|
9
|
+
let obj;
|
|
10
|
+
if (typeof param === 'string') {
|
|
11
|
+
obj = utility_1.ToolHelper.convertToJsonOrDefault(param);
|
|
12
|
+
}
|
|
13
|
+
else {
|
|
14
|
+
obj = param;
|
|
15
|
+
}
|
|
16
|
+
if (!obj) {
|
|
17
|
+
return;
|
|
18
|
+
}
|
|
19
|
+
const keys = `displayType`;
|
|
20
|
+
Object.keys(obj).forEach(key => {
|
|
21
|
+
if (keys.includes(key)) {
|
|
22
|
+
this[key] = obj[key];
|
|
23
|
+
}
|
|
24
|
+
});
|
|
25
|
+
if (this.path) {
|
|
26
|
+
this.procInstId = "this.viewModel.bindingData." + this.path;
|
|
27
|
+
}
|
|
28
|
+
}
|
|
29
|
+
static getType() {
|
|
30
|
+
return "ApprovalLogs";
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
exports.ApprovalLogs = ApprovalLogs;
|
|
34
34
|
//# sourceMappingURL=approval-logs.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"approval-logs.js","sourceRoot":"","sources":["../../../../src/domstructure/ui/approve-logs/approval-logs.ts"],"names":[],"mappings":";;;AAAA,8CAA8C;AAC9C,kCAAoC;AAKpC,MAAa,YAAa,SAAQ,gBAAS;
|
|
1
|
+
{"version":3,"file":"approval-logs.js","sourceRoot":"","sources":["../../../../src/domstructure/ui/approve-logs/approval-logs.ts"],"names":[],"mappings":";;;AAAA,8CAA8C;AAC9C,kCAAoC;AAKpC,MAAa,YAAa,SAAQ,gBAAS;IAKvC,YAAY,KAAmB;QAC3B,KAAK,CAAC,KAAK,CAAC,CAAC;QACb,IAAI,GAAQ,CAAC;QACb,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;YAC3B,GAAG,GAAG,oBAAU,CAAC,sBAAsB,CAAC,KAAK,CAAC,CAAC;SAClD;aAAM;YACH,GAAG,GAAG,KAAK,CAAC;SACf;QAED,IAAI,CAAC,GAAG,EAAE;YACN,OAAO;SACV;QAED,MAAM,IAAI,GAAG,aAAa,CAAC;QAC3B,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,OAAO,CAAC,GAAG,CAAC,EAAE;YAC3B,IAAI,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,EAAE;gBACpB,IAAI,CAAC,GAAG,CAAC,GAAG,GAAG,CAAC,GAAG,CAAC,CAAC;aACxB;QACL,CAAC,CAAC,CAAC;QAGH,IAAI,IAAI,CAAC,IAAI,EAAE;YACX,IAAI,CAAC,UAAU,GAAG,6BAA6B,GAAG,IAAI,CAAC,IAAI,CAAC;SAC/D;IACL,CAAC;IAMD,MAAM,CAAC,OAAO;QACV,OAAO,cAAc,CAAC;IAC1B,CAAC;CACJ;AAtCD,oCAsCC"}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
-
};
|
|
12
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
-
__exportStar(require("./approval-logs"), exports);
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
+
}) : (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
o[k2] = m[k];
|
|
8
|
+
}));
|
|
9
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
10
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
11
|
+
};
|
|
12
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
13
|
+
__exportStar(require("./approval-logs"), exports);
|
|
14
14
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,64 +1,64 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Button = void 0;
|
|
4
|
-
const utility_1 = require("../../../utility");
|
|
5
|
-
const component_button_parameter_1 = require("../../../utility/devkit/component-button-parameter");
|
|
6
|
-
const command_1 = require("./command");
|
|
7
|
-
class Button extends command_1.Command {
|
|
8
|
-
constructor(param) {
|
|
9
|
-
super(param);
|
|
10
|
-
let obj;
|
|
11
|
-
if (typeof param === 'string') {
|
|
12
|
-
obj = utility_1.ToolHelper.convertToJsonOrDefault(param);
|
|
13
|
-
}
|
|
14
|
-
else {
|
|
15
|
-
obj = param;
|
|
16
|
-
}
|
|
17
|
-
if (!obj) {
|
|
18
|
-
return;
|
|
19
|
-
}
|
|
20
|
-
const keys = 'bindDataSource,dataSourceType,icon';
|
|
21
|
-
Object.keys(obj).forEach(key => {
|
|
22
|
-
if (keys.includes(key)) {
|
|
23
|
-
if (key == "bindDataSource") {
|
|
24
|
-
if (obj[key]) {
|
|
25
|
-
this.bindDataSource = utility_1.ToolHelper.createBinding(obj[key], null, this.externalComponentNameSpace, this.id);
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
else {
|
|
29
|
-
this[key] = obj[key];
|
|
30
|
-
}
|
|
31
|
-
}
|
|
32
|
-
});
|
|
33
|
-
if (utility_1.ToolHelper.isNullOrUndefinedOrEmpty(this.disable.value)) {
|
|
34
|
-
this.disabled = utility_1.ToolHelper.createBindingWithoutDefaultValue('special', this.externalComponentNameSpace, this.id);
|
|
35
|
-
}
|
|
36
|
-
else {
|
|
37
|
-
this.disabled = this.disable;
|
|
38
|
-
}
|
|
39
|
-
this.visibleButtonPipeSuffix = `|buttonVisibility:'${this.id}':tracker['${this.id}']`;
|
|
40
|
-
this.disableButtonPipeSuffix = `|buttonUsability:'${this.id}':tracker['${this.id}']`;
|
|
41
|
-
if (!this.dataSourceType) {
|
|
42
|
-
this.dataSourceType = "static";
|
|
43
|
-
}
|
|
44
|
-
if (this.dataSourceType == "dynamic") {
|
|
45
|
-
if (this.bindDataSource) {
|
|
46
|
-
this.bindingName = this.bindDataSource.value;
|
|
47
|
-
}
|
|
48
|
-
else {
|
|
49
|
-
this.bindingName = "";
|
|
50
|
-
}
|
|
51
|
-
}
|
|
52
|
-
else if (this.dataSourceType == "static") {
|
|
53
|
-
this.bindingName = component_button_parameter_1.ComponentButtonCreator.createBindingName(this.id);
|
|
54
|
-
}
|
|
55
|
-
}
|
|
56
|
-
toJSON() {
|
|
57
|
-
return Object.assign({}, super.toJSON(), { "type": "Button", "bindDataSource": this.bindDataSource });
|
|
58
|
-
}
|
|
59
|
-
toString() {
|
|
60
|
-
return JSON.stringify(this.toJSON());
|
|
61
|
-
}
|
|
62
|
-
}
|
|
63
|
-
exports.Button = Button;
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Button = void 0;
|
|
4
|
+
const utility_1 = require("../../../utility");
|
|
5
|
+
const component_button_parameter_1 = require("../../../utility/devkit/component-button-parameter");
|
|
6
|
+
const command_1 = require("./command");
|
|
7
|
+
class Button extends command_1.Command {
|
|
8
|
+
constructor(param) {
|
|
9
|
+
super(param);
|
|
10
|
+
let obj;
|
|
11
|
+
if (typeof param === 'string') {
|
|
12
|
+
obj = utility_1.ToolHelper.convertToJsonOrDefault(param);
|
|
13
|
+
}
|
|
14
|
+
else {
|
|
15
|
+
obj = param;
|
|
16
|
+
}
|
|
17
|
+
if (!obj) {
|
|
18
|
+
return;
|
|
19
|
+
}
|
|
20
|
+
const keys = 'bindDataSource,dataSourceType,icon';
|
|
21
|
+
Object.keys(obj).forEach(key => {
|
|
22
|
+
if (keys.includes(key)) {
|
|
23
|
+
if (key == "bindDataSource") {
|
|
24
|
+
if (obj[key]) {
|
|
25
|
+
this.bindDataSource = utility_1.ToolHelper.createBinding(obj[key], null, this.externalComponentNameSpace, this.id);
|
|
26
|
+
}
|
|
27
|
+
}
|
|
28
|
+
else {
|
|
29
|
+
this[key] = obj[key];
|
|
30
|
+
}
|
|
31
|
+
}
|
|
32
|
+
});
|
|
33
|
+
if (!this.disable || utility_1.ToolHelper.isNullOrUndefinedOrEmpty(this.disable.value)) {
|
|
34
|
+
this.disabled = utility_1.ToolHelper.createBindingWithoutDefaultValue('special', this.externalComponentNameSpace, this.id);
|
|
35
|
+
}
|
|
36
|
+
else {
|
|
37
|
+
this.disabled = this.disable;
|
|
38
|
+
}
|
|
39
|
+
this.visibleButtonPipeSuffix = `|buttonVisibility:'${this.id}':tracker['${this.id}']`;
|
|
40
|
+
this.disableButtonPipeSuffix = `|buttonUsability:'${this.id}':tracker['${this.id}']`;
|
|
41
|
+
if (!this.dataSourceType) {
|
|
42
|
+
this.dataSourceType = "static";
|
|
43
|
+
}
|
|
44
|
+
if (this.dataSourceType == "dynamic") {
|
|
45
|
+
if (this.bindDataSource) {
|
|
46
|
+
this.bindingName = this.bindDataSource.value;
|
|
47
|
+
}
|
|
48
|
+
else {
|
|
49
|
+
this.bindingName = "";
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
else if (this.dataSourceType == "static") {
|
|
53
|
+
this.bindingName = component_button_parameter_1.ComponentButtonCreator.createBindingName(this.id);
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
toJSON() {
|
|
57
|
+
return Object.assign({}, super.toJSON(), { "type": "Button", "bindDataSource": this.bindDataSource });
|
|
58
|
+
}
|
|
59
|
+
toString() {
|
|
60
|
+
return JSON.stringify(this.toJSON());
|
|
61
|
+
}
|
|
62
|
+
}
|
|
63
|
+
exports.Button = Button;
|
|
64
64
|
//# sourceMappingURL=button.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"button.js","sourceRoot":"","sources":["../../../../src/domstructure/ui/commands/button.ts"],"names":[],"mappings":";;;AAAA,8CAA8C;AAC9C,mGAA4F;AAE5F,uCAAoC;AAEpC,MAAa,MAAO,SAAQ,iBAAO;IAQjC,YAAY,KAAmB;QAC7B,KAAK,CAAC,KAAK,CAAC,CAAC;QAEb,IAAI,GAAQ,CAAC;QACb,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE;YAC7B,GAAG,GAAG,oBAAU,CAAC,sBAAsB,CAAC,KAAK,CAAC,CAAC;SAChD;aAAM;YACL,GAAG,GAAG,KAAK,CAAC;SACb;QAED,IAAI,CAAC,GAAG,EAAE;YACR,OAAO;SACR;QAED,MAAM,IAAI,GAAG,oCAAoC,CAAC;QAClD,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAA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