| | |
| | | <el-row style="width:100%;z-index: 10;height:50px;" v-if="resultVal==null"> |
| | | <el-col :span="12"></el-col> |
| | | <el-col :span="12" style="text-align: right;"> |
| | | <el-button v-if="resultVal==null || dataForm.id==null" size="small" |
| | | type="primary" |
| | | @click="saveTable()">保存</el-button> |
| | | <el-button v-if="dataForm.id==null" size="small" @click="clickAddLine()">添加检验项目</el-button> |
| | | <el-button class="pad-addcol-btn" v-if="resultVal==null || dataForm.id==null" size="small" @click="addTeatValueColumn()">添加检测值列</el-button> |
| | | <el-button v-if="resultVal==null || dataForm.id==null" size="small" @click="delTeatValueColumn()">删除检测值列</el-button> |
| | |
| | | height="400" |
| | | row-key="iid" |
| | | default-expand-all |
| | | highlight-current-row |
| | | @row-click="handleTable" |
| | | :tree-props="{children: 'children', hasChildren: 'hasChildren'}"> |
| | | <el-table-column type="index" prop="parentIndex" label="序号" width="60"> |
| | | <template scope="scope"> |
| | |
| | | // startTime: [{ required: true, message: '请选择报检日期', trigger: 'blur' }] |
| | | }, |
| | | deviceList: [], |
| | | currentTable:null |
| | | } |
| | | }, |
| | | beforeUpdate(){ |
| | |
| | | if(!isTrue){ |
| | | return |
| | | } |
| | | this.changeState(row) |
| | | // this.changeState(row) |
| | | } |
| | | }, |
| | | changeState(row) { |
| | |
| | | this.deviceList = res.data.data |
| | | }) |
| | | }, |
| | | handleTable(row){ |
| | | this.currentTable = row |
| | | }, |
| | | saveTable(){ |
| | | if(this.currentTable){}else{ |
| | | this.$message.error("请选择一个项目") |
| | | } |
| | | } |
| | | }, |
| | | } |
| | | </script> |