@xatlas/rainbow-core 2.4.3 → 2.4.4
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/core.common.js +25 -15
- package/dist/core.common.js.map +1 -1
- package/dist/core.umd.js +25 -15
- package/dist/core.umd.js.map +1 -1
- package/dist/core.umd.min.js +1 -1
- package/dist/core.umd.min.js.map +1 -1
- package/package.json +1 -1
package/dist/core.common.js
CHANGED
|
@@ -3151,7 +3151,8 @@ function list_toPrimitive(t, r) { if ("object" != list_typeof(t) || !t) return t
|
|
|
3151
3151
|
var _this = this;
|
|
3152
3152
|
var h = this.$createElement;
|
|
3153
3153
|
var idName = this.idName,
|
|
3154
|
-
hide = this.hide
|
|
3154
|
+
hide = this.hide,
|
|
3155
|
+
action = this.action;
|
|
3155
3156
|
var columns = this.model.attrs.filter(function (attr) {
|
|
3156
3157
|
return !['all', 'list'].includes(attr.hidden) && !hide.includes(attr.name) && attr.name !== idName && attr.metaType !== 'model' && attr.type !== 'link';
|
|
3157
3158
|
}).map(function (attr) {
|
|
@@ -3181,7 +3182,7 @@ function list_toPrimitive(t, r) { if ("object" != list_typeof(t) || !t) return t
|
|
|
3181
3182
|
"value": text,
|
|
3182
3183
|
"row": record,
|
|
3183
3184
|
"schema": attr,
|
|
3184
|
-
"editable": _this.
|
|
3185
|
+
"editable": _this.editable(record, action, attr),
|
|
3185
3186
|
"idName": _this.idName,
|
|
3186
3187
|
"rowIndex": index
|
|
3187
3188
|
}
|
|
@@ -3615,6 +3616,14 @@ function list_toPrimitive(t, r) { if ("object" != list_typeof(t) || !t) return t
|
|
|
3615
3616
|
onFileChange: function onFileChange(action, files) {
|
|
3616
3617
|
var key = action.list ? action.list : 'file';
|
|
3617
3618
|
this.handleAction(action, null, list_defineProperty({}, key, files));
|
|
3619
|
+
},
|
|
3620
|
+
editable: function editable(record, action, attr) {
|
|
3621
|
+
var editable = this.configs['list.actionRowNotEditing.key'] && this.configs['list.actionRowNotEditing.value'] ? this.actionRowEditing && !this.configs['list.actionRowNotEditing.value'].split(',').includes(record[this.configs['list.actionRowNotEditing.key']]) : this.actionRowEditing;
|
|
3622
|
+
if (action !== null && action !== void 0 && action.list) {
|
|
3623
|
+
var list = action.list.split(',');
|
|
3624
|
+
return editable && list.includes(attr.name);
|
|
3625
|
+
}
|
|
3626
|
+
return editable;
|
|
3618
3627
|
}
|
|
3619
3628
|
}
|
|
3620
3629
|
});
|
|
@@ -5138,8 +5147,9 @@ var SHOW_RULES = {
|
|
|
5138
5147
|
}];
|
|
5139
5148
|
},
|
|
5140
5149
|
settingActions: function settingActions() {
|
|
5150
|
+
var _this$action;
|
|
5141
5151
|
var actions = [{
|
|
5142
|
-
key: '',
|
|
5152
|
+
key: ((_this$action = this.action) === null || _this$action === void 0 ? void 0 : _this$action.key) || '',
|
|
5143
5153
|
name: '保存',
|
|
5144
5154
|
icon: 'save',
|
|
5145
5155
|
method: 'PUT',
|
|
@@ -5399,18 +5409,18 @@ var SHOW_RULES = {
|
|
|
5399
5409
|
actionModel = this.actionModel,
|
|
5400
5410
|
idName = this.idName,
|
|
5401
5411
|
editions = this.editions,
|
|
5402
|
-
_this$
|
|
5403
|
-
key = _this$
|
|
5404
|
-
method = _this$
|
|
5405
|
-
_this$
|
|
5406
|
-
_this$
|
|
5407
|
-
_this$
|
|
5408
|
-
_this$
|
|
5409
|
-
type = _this$
|
|
5410
|
-
redirectProfile = _this$
|
|
5411
|
-
autofill = _this$
|
|
5412
|
-
_this$
|
|
5413
|
-
confirmActionDialog = _this$
|
|
5412
|
+
_this$action2 = this.action,
|
|
5413
|
+
key = _this$action2.key,
|
|
5414
|
+
method = _this$action2.method,
|
|
5415
|
+
_this$action2$params = _this$action2.params,
|
|
5416
|
+
_this$action2$params2 = _this$action2$params === void 0 ? {} : _this$action2$params,
|
|
5417
|
+
_this$action2$params3 = _this$action2$params2.commit,
|
|
5418
|
+
_this$action2$params4 = _this$action2$params3 === void 0 ? {} : _this$action2$params3,
|
|
5419
|
+
type = _this$action2$params4.type,
|
|
5420
|
+
redirectProfile = _this$action2$params4.redirectProfile,
|
|
5421
|
+
autofill = _this$action2$params2.autofill,
|
|
5422
|
+
_this$action2$params5 = _this$action2$params2.confirmActionDialog,
|
|
5423
|
+
confirmActionDialog = _this$action2$params5 === void 0 ? null : _this$action2$params5,
|
|
5414
5424
|
schema = this.schema;
|
|
5415
5425
|
var submit = /*#__PURE__*/function () {
|
|
5416
5426
|
var _ref2 = action_asyncToGenerator( /*#__PURE__*/action_regeneratorRuntime().mark(function _callee3() {
|