doway-coms 2.10.0 → 2.10.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.
- package/package.json +1 -1
- package/packages/BaseGrid/src/index.vue +30 -18
- package/packages/index.js +1 -1
package/package.json
CHANGED
|
@@ -2787,24 +2787,36 @@ export default {
|
|
|
2787
2787
|
tempRows.push(tempRow)
|
|
2788
2788
|
}
|
|
2789
2789
|
|
|
2790
|
-
|
|
2791
|
-
|
|
2792
|
-
|
|
2793
|
-
|
|
2794
|
-
|
|
2795
|
-
|
|
2796
|
-
}
|
|
2797
|
-
//判断子项
|
|
2798
|
-
// if(tempRow.children && tempRow.children.length>0){
|
|
2799
|
-
// //添加子项数据
|
|
2800
|
-
// XEUtils.arrayEach(tempRow.children,loopChild=>{
|
|
2801
|
-
// if (this.$refs.baseGrid.isInsertByRow(loopChild) === true){
|
|
2802
|
-
// loopChild["sysRowState"] = "add";
|
|
2803
|
-
// tempRows.push(loopChild);
|
|
2804
|
-
// }
|
|
2805
|
-
// })
|
|
2806
|
-
// }
|
|
2790
|
+
|
|
2791
|
+
let tempInsertRows = this.$refs.baseGrid.getInsertRecords()
|
|
2792
|
+
for (let i = 0; i < tempInsertRows.length; i++) {
|
|
2793
|
+
let tempRow = tempInsertRows[i]
|
|
2794
|
+
tempRow['sysRowState'] = 'add'
|
|
2795
|
+
tempRows.push(tempRow)
|
|
2807
2796
|
}
|
|
2797
|
+
// console.debug('davis', (1 && null))
|
|
2798
|
+
|
|
2799
|
+
// let tempTableData = this.$refs.baseGrid.getTableData().fullData
|
|
2800
|
+
// for (let i = 0; i < tempTableData.length; i++) {
|
|
2801
|
+
// let tempRow = tempTableData[i]
|
|
2802
|
+
// // console.debug('232',this.$refs.baseGrid.isInsertByRow(tempRow))
|
|
2803
|
+
// //注意,isInsertByRow 返回的不是Boolean的值,官方文档有错误,所以不能用于Boolean判断,返回的是一个对象
|
|
2804
|
+
// //也可以采用替换方案用getInsertRecords方法获取改变的值
|
|
2805
|
+
// if (this.$refs.baseGrid.isInsertByRow(tempRow)) {
|
|
2806
|
+
// tempRow['sysRowState'] = 'add'
|
|
2807
|
+
// tempRows.push(tempRow)
|
|
2808
|
+
// }
|
|
2809
|
+
// //判断子项
|
|
2810
|
+
// // if(tempRow.children && tempRow.children.length>0){
|
|
2811
|
+
// // //添加子项数据
|
|
2812
|
+
// // XEUtils.arrayEach(tempRow.children,loopChild=>{
|
|
2813
|
+
// // if (this.$refs.baseGrid.isInsertByRow(loopChild) === true){
|
|
2814
|
+
// // loopChild["sysRowState"] = "add";
|
|
2815
|
+
// // tempRows.push(loopChild);
|
|
2816
|
+
// // }
|
|
2817
|
+
// // })
|
|
2818
|
+
// // }
|
|
2819
|
+
// }
|
|
2808
2820
|
|
|
2809
2821
|
let tempUpdateRows = this.$refs.baseGrid.getUpdateRecords()
|
|
2810
2822
|
for (let i = 0; i < tempUpdateRows.length; i++) {
|
|
@@ -2994,7 +3006,7 @@ export default {
|
|
|
2994
3006
|
if (this.gridEdit !== true) {
|
|
2995
3007
|
return
|
|
2996
3008
|
}
|
|
2997
|
-
if (this.$refs.baseGrid.
|
|
3009
|
+
if (this.$refs.baseGrid.isEditByRow(row) === true) {
|
|
2998
3010
|
//判断当前行是否是编辑行
|
|
2999
3011
|
return
|
|
3000
3012
|
}
|
package/packages/index.js
CHANGED