|
@@ -58,29 +58,43 @@
|
|
|
save() {
|
|
|
console.log(this.renderData,'renderData')
|
|
|
// let data = this.hotArr[this.activeName - 1].getSourceData()
|
|
|
- // data = data.map(item => {
|
|
|
- // return {
|
|
|
- // EquipmentMark: item.own || null,
|
|
|
- // Id: item.Id,
|
|
|
- // }
|
|
|
- // })
|
|
|
- // updatePoint({
|
|
|
- // data: {
|
|
|
- // Content: data
|
|
|
- // },
|
|
|
- // type: this.protocolType
|
|
|
- // }, res => {
|
|
|
- // this.$emit("saved")
|
|
|
- // this.$message.success("保存成功")
|
|
|
- // })
|
|
|
+ let data = []
|
|
|
+ this.renderData.map(item => {
|
|
|
+ if(!!item.PointList){
|
|
|
+ item.PointList.map(child => {
|
|
|
+ data.push(child)
|
|
|
+ })
|
|
|
+ }
|
|
|
+ })
|
|
|
+ console.log(data)
|
|
|
+ data = data.map(item => {
|
|
|
+ return {
|
|
|
+ EquipmentMark: item.own || null,
|
|
|
+ Id: item.Id,
|
|
|
+ }
|
|
|
+ })
|
|
|
+ updatePoint({
|
|
|
+ data: {
|
|
|
+ Content: data
|
|
|
+ },
|
|
|
+ type: this.protocolType
|
|
|
+ }, res => {
|
|
|
+ this.$emit("saved")
|
|
|
+ this.$message.success("保存成功")
|
|
|
+ })
|
|
|
},
|
|
|
fillClick(){
|
|
|
- let data = this.hotArr[this.activeName - 1].getSourceData()
|
|
|
+ // let data = this.hotArr[this.activeName - 1].getSourceData()
|
|
|
// data.own = this.fillData
|
|
|
- data.map(item => {
|
|
|
- item.own = this.fillData
|
|
|
+ // data.map(item => {
|
|
|
+ // item.own = this.fillData
|
|
|
+ // })
|
|
|
+ this.renderData[this.activeName - 1].PointList.map(item => {
|
|
|
+ item.own = item.own || this.fillData
|
|
|
})
|
|
|
- console.log(data,'data')
|
|
|
+ console.log(this.renderData[this.activeName - 1].PointList)
|
|
|
+ this.handleChange(true)
|
|
|
+ // console.log(data,'data')
|
|
|
},
|
|
|
handleChange(val) {
|
|
|
if (!val) {
|