| | |
| | | </div> |
| | | </div> |
| | | <div class="table-box"> |
| | | <el-table ref="equipmentTable" node-key="father_name" :cell-style="{ textAlign: 'center' }" |
| | | :header-cell-style="{ border: '0px', background: '#f5f7fa', color: '#606266', boxShadow: 'inset 0 1px 0 #ebeef5', textAlign: 'center' }" |
| | | <el-table ref="equipmentTable" node-key="father_name" :cell-style="{ textAlign: 'left' }" |
| | | :header-cell-style="{ border: '0px', background: '#f5f7fa', color: '#606266', boxShadow: 'inset 0 1px 0 #ebeef5', textAlign: 'left' }" |
| | | :data="equipmentTable" style="width: 100%;"> |
| | | <el-table-column type="index" label="序号" min-width="90" /> |
| | | <el-table-column prop="equipment_code" label="仪器设备编号" min-width="200" /> |
| | |
| | | // 节点点击处理 |
| | | nodeClickHandler(data, node, element) { |
| | | this.nodeclicked = data |
| | | // console.log(data) |
| | | console.log(data) |
| | | // 只有数据中携带id才能发送查询请求 |
| | | if (data.id) { |
| | | this.getEquipmentTable({ classifyId: data.id, pageSize: this.pageSize, pageNo: this.currentPage, whetherWhether: this.isOut }) |
| | |
| | | this.deletedialogVisible = true |
| | | }, |
| | | async deleteInstrument() { |
| | | let up = await deleteInstrument({ instrumentId: this.instrumentId }) |
| | | if (up.data) { |
| | | this.$message({ |
| | | message: '操作成功!', |
| | | type: 'success' |
| | | }); |
| | | await deleteInstrument({ instrumentId: this.instrumentId }).then(res=>{ |
| | | this.$message.error('删除成功!'); |
| | | let d = this.nodeclicked |
| | | console.log(d); |
| | | this.nodeClickHandler(d); |
| | | } |
| | | }).catch(()=>{ |
| | | this.$message.error('删除失败!'); |
| | | }); |
| | | this.deletedialogVisible = false |
| | | }, |
| | | async submitTreeForm(formName) { |