| | |
| | | </el-table-column> |
| | | <el-table-column prop="tname" sortable label="工艺名称"> |
| | | <template slot-scope="scope"> |
| | | <el-tag type="success" v-if="scope.row.tname != null">02</el-tag> |
| | | <el-tag type="success" v-if="scope.row.tname != null" |
| | | style="margin-left:20px;">02</el-tag> |
| | | <span style="color: #000000"> |
| | | {{ scope.row.tname }} |
| | | </span> |
| | |
| | | <el-table-column prop="num" label="数量"> |
| | | <template slot-scope="scope"> |
| | | <el-input v-model="scope.row.num" |
| | | v-if="scope.row.mname != null" |
| | | v-if="scope.row.mname != null" size="small" |
| | | @blur="updateVal(scope.row)"></el-input> |
| | | </template> |
| | | </el-table-column> |
| | |
| | | data() { |
| | | return { |
| | | hasChildren:true, |
| | | selects: [] |
| | | selects: [], |
| | | isAllSelect:false, |
| | | deleteList:[], |
| | | } |
| | | }, |
| | | props:['tableData','tableType'], |
| | |
| | | } |
| | | } |
| | | }, |
| | | handleSelectionChange(val) { |
| | | this.deleteList = []; |
| | | val.forEach((v) => { |
| | | if (v.id !== undefined) { |
| | | this.deleteList.push(v.id); |
| | | //改变选中 |
| | | toggleSelection(row, flag) { |
| | | this.$set(row, "isChecked", flag); |
| | | this.$nextTick(() => { |
| | | if (flag) { |
| | | this.$refs.multipleTable.toggleRowSelection(row, flag); |
| | | } else { |
| | | this.$refs.multipleTable.clearSelection(); |
| | | } |
| | | }); |
| | | }, |
| | | handleSelectionChange(val) { |
| | | this.deleteList = []; |
| | | val.forEach((v) => { |
| | | this.searchIdFun(v); |
| | | }); |
| | | this.$emit("childData",this.deleteList); |
| | | }, |
| | | //递归查找选中数据id |
| | | searchIdFun(data){ |
| | | let obj = data; |
| | | if(obj.children != undefined){ |
| | | this.searchIdFun(obj.children); |
| | | }else{ |
| | | this.deleteList.push(obj.id); |
| | | } |
| | | }, |
| | | // 表格树全部选中配置 结束 |
| | | } |
| | | } |