ns-base-module 1.1.69 → 1.1.71
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.
|
@@ -156,6 +156,13 @@ var ColumnsToolbarRender = /*#__PURE__*/memo(function (props) {
|
|
|
156
156
|
dragNode = _ref2.dragNode;
|
|
157
157
|
var nextColumns = cloneDeep(columnsTree);
|
|
158
158
|
|
|
159
|
+
// 禁止跨层级拖拽 模板 和更新的数据匹配渲染问题, 渲染时也只匹配同级增删改
|
|
160
|
+
// 修复 模板存储 a下的b, 新表头b在c下面 并改名d
|
|
161
|
+
if (node.parentCode !== dragNode.parentCode) {
|
|
162
|
+
message.warning("不允许改变层级");
|
|
163
|
+
return;
|
|
164
|
+
}
|
|
165
|
+
|
|
159
166
|
// 找到 旧位置 删除自己
|
|
160
167
|
var delDom = null;
|
|
161
168
|
function _loopFind(tree, dom, command) {
|
|
@@ -485,8 +492,9 @@ var ColumnsToolbarRender = /*#__PURE__*/memo(function (props) {
|
|
|
485
492
|
title: d.customizable === false ? d.title : /*#__PURE__*/React.createElement(Dustbin, {
|
|
486
493
|
item: d,
|
|
487
494
|
onChange: changeTableHeader,
|
|
488
|
-
onFixed: onFixed
|
|
489
|
-
|
|
495
|
+
onFixed: onFixed
|
|
496
|
+
// showArrows={showArrows}
|
|
497
|
+
,
|
|
490
498
|
onDrop: d.customizable === false ? null : onDrop // 子动态列 不能拖拽
|
|
491
499
|
}),
|
|
492
500
|
children: titleChildren(d.children, showArrows)
|
|
@@ -80,6 +80,7 @@ var updateTemplateFilds = function updateTemplateFilds(JsonPares, _columns) {
|
|
|
80
80
|
if (_findItem) {
|
|
81
81
|
JsonPares[r] = _objectSpread(_objectSpread({}, _findItem), {}, {
|
|
82
82
|
title: _findItem.title || JsonPares[r].title,
|
|
83
|
+
label: _findItem.label || JsonPares[r].label,
|
|
83
84
|
fixed: JsonPares[r].fixed,
|
|
84
85
|
width: JsonPares[r].width,
|
|
85
86
|
checked: JsonPares[r].checked,
|
|
@@ -113,7 +114,7 @@ export function adapterColumns(customColumns, columns) {
|
|
|
113
114
|
var _code = arr[j].code ? "code" : "dataIndex";
|
|
114
115
|
if (commad === "del") {
|
|
115
116
|
if (!find(_columns, function (o) {
|
|
116
|
-
return o[_code] === arr[j][_code];
|
|
117
|
+
return o[_code] === arr[j][_code] && o.parentCode === arr[j].parentCode;
|
|
117
118
|
})) {
|
|
118
119
|
arr.splice(j, 1);
|
|
119
120
|
_k -= 1;
|
|
@@ -151,7 +152,7 @@ export function adapterColumns(customColumns, columns) {
|
|
|
151
152
|
var _loop3 = function _loop3(j) {
|
|
152
153
|
var _code = _columns[j].code ? "code" : "dataIndex";
|
|
153
154
|
if (!find(flaJsonPares, function (o) {
|
|
154
|
-
return o[_code] === _columns[j][_code];
|
|
155
|
+
return o[_code] === _columns[j][_code] && o.parentCode === _columns[j].parentCode;
|
|
155
156
|
})) {
|
|
156
157
|
var _item = initColumns([_columns[j]], null)[0];
|
|
157
158
|
if (_item.customizable !== false) {
|