wt-enjoy-link-antd-repack 4.1.63 → 4.1.64

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.
@@ -1 +1 @@
1
- {"version":3,"file":"base.d.ts","sourceRoot":"","sources":["base.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAqE,MAAM,OAAO,CAAA;;;;;;;;;;;;AAMzF,wBAqIC"}
1
+ {"version":3,"file":"base.d.ts","sourceRoot":"","sources":["base.tsx"],"names":[],"mappings":"AAIA,OAAO,KAAqE,MAAM,OAAO,CAAA;;;;;;;;;;;;AAMzF,wBA8IC"}
@@ -32,7 +32,7 @@ export default /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(function (props,
32
32
  initialValue = props.initialValue,
33
33
  initSelectValue = props.initSelectValue,
34
34
  dataSource = props.dataSource,
35
- onChange = props.onChange,
35
+ _onChange = props.onChange,
36
36
  onChangeData = props.onChangeData,
37
37
  loading = props.loading,
38
38
  exProps = _objectWithoutProperties(props, _excluded);
@@ -69,8 +69,8 @@ export default /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(function (props,
69
69
  useUpdateLayoutEffect(function () {
70
70
  if (selectValue === undefined || selectValue === null) {
71
71
  setOperDataSource([]);
72
- if (onChange) {
73
- onChange(undefined, undefined);
72
+ if (_onChange) {
73
+ _onChange(undefined, undefined);
74
74
  }
75
75
  if (onChangeData) {
76
76
  onChangeData(undefined, {});
@@ -114,39 +114,47 @@ export default /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(function (props,
114
114
  style: {
115
115
  maxWidth: '400px'
116
116
  },
117
- children: /*#__PURE__*/_jsx(BiuCustomTable, {
117
+ children: exProps.mode === 'multiple' ? /*#__PURE__*/_jsx(BiuCustomTable, {
118
118
  loading: loading,
119
119
  bordered: false,
120
120
  scroll: {
121
121
  y: 300,
122
122
  x: true
123
- }
124
- // rowSelection={{
125
- // checkStrictly: exProps.mode === 'multiple' ? true : false,
126
- // selectedRowKeys: selectValue,
127
- // onChange: (selectedRowKeys: any[], selectedRows: any) => {
128
- // setSelectValue(selectedRowKeys)
129
- // const selectKeys: any[] = []
130
- // selectedRows.forEach((item: any) => {
131
- // selectKeys.push(item[rowKey])
132
- // })
133
- // if (onChange) {
134
- // onChange(selectKeys, selectedRows)
135
- // }
136
- // if (onChangeData) {
137
- // onChangeData(selectKeys, selectedRows)
138
- // }
139
- // }
140
- // }}
141
- ,
123
+ },
124
+ rowSelection: {
125
+ selectedRowKeys: selectValue,
126
+ onChange: function onChange(selectedRowKeys, selectedRows) {
127
+ setSelectValue(selectedRowKeys);
128
+ var selectKeys = [];
129
+ selectedRows.forEach(function (item) {
130
+ selectKeys.push(item[rowKey]);
131
+ });
132
+ if (_onChange) {
133
+ _onChange(selectKeys, selectedRows);
134
+ }
135
+ if (onChangeData) {
136
+ onChangeData(selectKeys, selectedRows);
137
+ }
138
+ }
139
+ },
140
+ rowKey: exProps.mode === 'multiple' ? "".concat(rowLabel) : rowKey,
141
+ pagination: false,
142
+ columns: columns,
143
+ dataSource: operDataSource
144
+ }) : /*#__PURE__*/_jsx(BiuCustomTable, {
145
+ loading: loading,
146
+ bordered: false,
147
+ scroll: {
148
+ y: 300,
149
+ x: true
150
+ },
142
151
  onRow: function onRow(record) {
143
152
  return {
144
153
  onDoubleClick: function onDoubleClick() {
145
154
  var _formRef$current;
146
- // if (exProps.mode === 'multiple') return
147
155
  setSelectValue(record[rowLabel]);
148
- if (onChange) {
149
- onChange(record[rowKey], record);
156
+ if (_onChange) {
157
+ _onChange(record[rowKey], record);
150
158
  }
151
159
  if (onChangeData) {
152
160
  onChangeData(record[rowKey], record);
@@ -154,9 +162,7 @@ export default /*#__PURE__*/React.memo( /*#__PURE__*/forwardRef(function (props,
154
162
  (_formRef$current = formRef.current) === null || _formRef$current === void 0 || _formRef$current.blur();
155
163
  }
156
164
  };
157
- }
158
- // rowKey={exProps.mode === 'multiple' ? `${rowLabel}` : rowKey}
159
- ,
165
+ },
160
166
  rowKey: rowKey,
161
167
  pagination: false,
162
168
  columns: columns,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wt-enjoy-link-antd-repack",
3
- "version": "4.1.63",
3
+ "version": "4.1.64",
4
4
  "description": "万通业务组件",
5
5
  "sideEffects": false,
6
6
  "main": "dist/esm/index.js",