dtable-ui-component 6.0.110-ame.2 → 6.0.110-zlp.2

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.
@@ -16,10 +16,11 @@ class MultipleSelectFormatter extends _react.default.PureComponent {
16
16
  this.getOptions = () => {
17
17
  const {
18
18
  value,
19
- options
19
+ options,
20
+ isLink
20
21
  } = this.props;
21
22
  if (!Array.isArray(value) || !Array.isArray(options)) return [];
22
- let selectedOptions = options.filter(option => value.includes(option.id) || value.includes(option.name));
23
+ let selectedOptions = isLink ? options.filter(option => value.includes(option.id) || value.includes(option.name)) : value.map(val => options.find(option => option.id === val || option.name === val)).filter(Boolean);
23
24
  if (selectedOptions.length === 0) return [];
24
25
  return selectedOptions.map(option => {
25
26
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_SelectItem.default, {
@@ -275,8 +275,6 @@ class RowExpandFormatter extends _react.default.Component {
275
275
  })
276
276
  });
277
277
  }
278
- console.log('cellValue', cellValue);
279
- console.log('column', column);
280
278
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(Formatter, {
281
279
  value: cellValue,
282
280
  column: column,
@@ -132,6 +132,7 @@ class RowExpandLinkFormatter extends _react.Component {
132
132
  const options = displayColumnData && Array.isArray(displayColumnData.options) ? displayColumnData.options : [];
133
133
  return /*#__PURE__*/(0, _jsxRuntime.jsx)(_MultipleSelectFormatter.default, {
134
134
  value: cellValue,
135
+ isLink: true,
135
136
  options: options || []
136
137
  });
137
138
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dtable-ui-component",
3
- "version": "6.0.110ame.2",
3
+ "version": "6.0.110zlp.2",
4
4
  "main": "./lib/index.js",
5
5
  "dependencies": {
6
6
  "@seafile/react-image-lightbox": "^5.0.4",