cnhis-design-vue 3.1.28-beta.0 → 3.1.28-beta.1

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.
@@ -1138,6 +1138,10 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
1138
1138
  };
1139
1139
  const colspanMethod = (payload) => {
1140
1140
  var _a;
1141
+ const defaultSpan = {
1142
+ rowspan: 1,
1143
+ colspan: 1
1144
+ };
1141
1145
  const {
1142
1146
  row,
1143
1147
  column
@@ -1147,36 +1151,32 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
1147
1151
  if (isFunction(attr["span-method"]))
1148
1152
  return attr["span-method"](payload);
1149
1153
  if (state.isTree != 3) {
1150
- return {
1151
- rowspan: 1,
1152
- colspan: 1
1153
- };
1154
+ return defaultSpan;
1154
1155
  }
1155
- let xTree = xGrid.value;
1156
- let fristKeyIndex = xTree.getTableColumn().tableColumn.findIndex((column2) => {
1157
- return !!column2.property;
1158
- });
1159
- let colspan = xTree.getTableColumn().tableColumn.length - fristKeyIndex;
1160
- if (xTree) {
1161
- const isOldVxeTree = row.childrenList && row.childrenList.length;
1162
- const isTransformVxeTree = ((_a = props.tableParams) == null ? void 0 : _a.isTransform) && !row.qianduan_parent_id;
1163
- if (isOldVxeTree || isTransformVxeTree) {
1164
- if (column.treeNode) {
1165
- return {
1166
- rowspan: 1,
1167
- colspan
1168
- };
1169
- } else if (!column.property) {
1170
- return {
1171
- rowspan: 1,
1172
- colspan: 1
1173
- };
1174
- } else {
1175
- return {
1176
- rowspan: 0,
1177
- colspan: 0
1178
- };
1179
- }
1156
+ const xTree = xGrid.value;
1157
+ if (!xTree)
1158
+ return defaultSpan;
1159
+ const {
1160
+ tableColumn = []
1161
+ } = (xTree == null ? void 0 : xTree.getTableColumn()) || {};
1162
+ const fristKeyIndex = tableColumn.findIndex((column2) => !!column2.property);
1163
+ const fixedRightColsSpan = tableColumn.filter((column2) => column2.fixed === "right").length;
1164
+ const colspan = tableColumn.length - fristKeyIndex - fixedRightColsSpan;
1165
+ const isOldVxeTree = row.childrenList && row.childrenList.length;
1166
+ const isTransformVxeTree = ((_a = props.tableParams) == null ? void 0 : _a.isTransform) && !row.qianduan_parent_id;
1167
+ if (isOldVxeTree || isTransformVxeTree) {
1168
+ if (column.treeNode) {
1169
+ return {
1170
+ rowspan: 1,
1171
+ colspan
1172
+ };
1173
+ } else if (!column.property || column.fixed === "right") {
1174
+ return defaultSpan;
1175
+ } else {
1176
+ return {
1177
+ rowspan: 0,
1178
+ colspan: 0
1179
+ };
1180
1180
  }
1181
1181
  }
1182
1182
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cnhis-design-vue",
3
- "version": "3.1.28-beta.0",
3
+ "version": "3.1.28-beta.1",
4
4
  "license": "ISC",
5
5
  "module": "./es/components/index.js",
6
6
  "main": "./es/components/index.js",
@@ -61,5 +61,5 @@
61
61
  "iOS 7",
62
62
  "last 3 iOS versions"
63
63
  ],
64
- "gitHead": "694e0b5356152587734f7ca08aaa6c7fbfe5060e"
64
+ "gitHead": "0539d078909e5911ab63a2c4fbac874e11012a15"
65
65
  }