ztxkui 3.9.4 → 3.9.5

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.
@@ -61,7 +61,7 @@ var FormDemo = function () {
61
61
  React.createElement(Form, { name: "test-list", form: form },
62
62
  React.createElement(SearchContainer, { dark: true },
63
63
  React.createElement(SearchLeft, { configInfo: configInfoMemo, isDynamic: true, dynamicStorageKey: "symbol-key-00001", isToggle: true, handleRef: handleRef },
64
- React.createElement(SearchItem, { width: "half", name: "pwNo", configname: "pwNoCopy", label: "\u5165\u5E93\u5355\u53F7", rules: [
64
+ React.createElement(SearchItem, { width: "half", name: "pwNo", configname: "pwNoCopy", label: "\u5165\u5E93\u5355\u53F7", disabled: true, rules: [
65
65
  {
66
66
  required: true,
67
67
  message: '采购基本数据-请选择入库单号',
@@ -70,7 +70,7 @@ var FormDemo = function () {
70
70
  React.createElement(Input.TextArea, { autoSize: true, allowClear: true, disabled: true, onChange: function (e) {
71
71
  console.log(e.target.value);
72
72
  } })),
73
- React.createElement(SearchItem, { width: "half", name: "pwNo1", label: "\u5165\u5E93\u5355\u53F71", rules: [
73
+ React.createElement(SearchItem, { width: "half", name: "pwNo1", label: "\u5165\u5E93\u5355\u53F71", dynamicdisabled: "1", rules: [
74
74
  {
75
75
  required: false,
76
76
  message: '采购基本数据-请选择入库单号1',
@@ -5,6 +5,7 @@ export interface ISearchLayout {
5
5
  show?: boolean;
6
6
  disabled?: boolean;
7
7
  hiddenLabelName?: string;
8
+ dynamicDisabled?: any;
8
9
  [props: string]: any;
9
10
  }
10
11
  /**
@@ -135,13 +135,14 @@ dynamicStorageKey // 动态列配置的key值
135
135
  // 遍历当前子元素
136
136
  React.Children.forEach(children, function (item) {
137
137
  if (item === null || item === void 0 ? void 0 : item.props) {
138
- var _a = item.props, name_2 = _a.name, label_1 = _a.label, hiddenLabelName_1 = _a.hiddenLabelName, disabled = _a.disabled;
138
+ var _a = item.props, name_2 = _a.name, label_1 = _a.label, hiddenLabelName_1 = _a.hiddenLabelName, disabled = _a.disabled, dynamicDisabled_1 = _a.dynamicdisabled;
139
139
  _initDynamicList_1.push({
140
140
  name: name_2,
141
141
  label: label_1,
142
142
  hiddenLabelName: hiddenLabelName_1,
143
143
  show: true,
144
144
  disabled: disabled,
145
+ dynamicDisabled: dynamicDisabled_1,
145
146
  });
146
147
  if (!dynamicList_1 || dynamicList_1.length === 0) {
147
148
  _currentDynamicList_1.push({
@@ -150,6 +151,7 @@ dynamicStorageKey // 动态列配置的key值
150
151
  hiddenLabelName: hiddenLabelName_1,
151
152
  show: true,
152
153
  disabled: disabled,
154
+ dynamicDisabled: dynamicDisabled_1,
153
155
  });
154
156
  }
155
157
  else {
@@ -160,6 +162,7 @@ dynamicStorageKey // 动态列配置的key值
160
162
  currentData.forEach(function (item) {
161
163
  item.label = label_1;
162
164
  item.hiddenLabelName = hiddenLabelName_1;
165
+ item.dynamicDisabled = dynamicDisabled_1;
163
166
  });
164
167
  if (currentData.length > 1) {
165
168
  var index = _currentDynamicList_1.findIndex(function (currentDynamic) { return currentDynamic.name === name_2; });
@@ -180,6 +183,7 @@ dynamicStorageKey // 动态列配置的key值
180
183
  hiddenLabelName: item.hiddenLabelName,
181
184
  show: true,
182
185
  disabled: item.disabled,
186
+ dynamicDisabled: item.dynamicdisabled,
183
187
  }); }));
184
188
  // 将删除的数据剔除出去
185
189
  _currentDynamicList_1 = _currentDynamicList_1.filter(function (item) {
@@ -65,6 +65,6 @@ var SearchDrawer = function (_a) {
65
65
  React.createElement("span", null, "\uFF08\u62D6\u62FD\u6392\u5E8F\uFF09"))), width: 290, placement: "right", visible: visible, closable: false, maskClosable: false, footer: renderFooter() },
66
66
  React.createElement(DndProvider, { backend: HTML5Backend, context: window },
67
67
  React.createElement(Checkbox.Group, { value: checkedValues, onChange: onCheckboxChange }, dynamicList.map(function (item, index) { return (React.createElement(Sortable, { key: item.name, type: "search-drawer", index: index, onMoveItem: onMoveItem },
68
- React.createElement(Checkbox, { value: item.name }, item.label || item.hiddenLabelName || item.name))); })))));
68
+ React.createElement(Checkbox, { value: item.name, disabled: item.disabled || item.dynamicDisabled }, item.label || item.hiddenLabelName || item.name))); })))));
69
69
  };
70
70
  export default memo(SearchDrawer);
@@ -18,6 +18,8 @@ export interface ISearchItem extends FormItemProps {
18
18
  hiddenLabelName?: string;
19
19
  /** 没有lable显示边框 */
20
20
  noLabelShowBg?: boolean;
21
+ /** 动态列禁用隐藏 */
22
+ dynamicdisabled?: any;
21
23
  }
22
24
  declare const SearchItem: React.FC<ISearchItem>;
23
25
  export default SearchItem;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ztxkui",
3
- "version": "3.9.4",
3
+ "version": "3.9.5",
4
4
  "private": false,
5
5
  "description": "React components library",
6
6
  "author": "zt-front-end",