@handaotech-design/bom 0.0.44 → 0.0.45

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.
@@ -46,7 +46,6 @@ export function convertBomDataToTree(treeData, nodeConfigRule) {
46
46
  firstSelectableNodeKey = node.key;
47
47
  }
48
48
  const isLeafObj = {
49
- PROCESS_PLAN: false,
50
49
  OPERATION: true
51
50
  };
52
51
  Object.assign(node, {
@@ -54,7 +53,7 @@ export function convertBomDataToTree(treeData, nodeConfigRule) {
54
53
  title: finalTitle,
55
54
  selectable: boolSelectable,
56
55
  icon,
57
- isLeaf: node?.children?.length ? false : isLeafObj[node.businessType],
56
+ isLeaf: isLeafObj[node.businessType] ?? !node.children?.length,
58
57
  ...rest
59
58
  });
60
59
  const { children, ...restProps } = node;
@@ -55,7 +55,6 @@ function convertBomDataToTree(treeData, nodeConfigRule) {
55
55
  firstSelectableNodeKey = node.key;
56
56
  }
57
57
  const isLeafObj = {
58
- PROCESS_PLAN: false,
59
58
  OPERATION: true
60
59
  };
61
60
  Object.assign(node, {
@@ -63,7 +62,7 @@ function convertBomDataToTree(treeData, nodeConfigRule) {
63
62
  title: finalTitle,
64
63
  selectable: boolSelectable,
65
64
  icon,
66
- isLeaf: node?.children?.length ? false : isLeafObj[node.businessType],
65
+ isLeaf: isLeafObj[node.businessType] ?? !node.children?.length,
67
66
  ...rest
68
67
  });
69
68
  const {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@handaotech-design/bom",
3
- "version": "0.0.44",
3
+ "version": "0.0.45",
4
4
  "license": "MIT",
5
5
  "sideEffects": false,
6
6
  "exports": {