| | |
| | | <div class="YunweiBlockForm-wrap"> |
| | | <el-dialog |
| | | custom-class="YunweiBlockForm-dialog" |
| | | title="运维详情" |
| | | title="主机详情" |
| | | :visible.sync="dialogVisible" |
| | | width="600px" |
| | | :close-on-click-modal="false" |
| | |
| | | </template> |
| | | |
| | | <script> |
| | | import {getTaskInfoById} from '@/api/daping' |
| | | import {getHostInfo} from '@/api/daping' |
| | | export default { |
| | | name: "YunweiBlockForm", |
| | | data() { |
| | |
| | | } |
| | | }, |
| | | methods: { |
| | | init(id) { |
| | | init() { |
| | | this.dialogVisible = true |
| | | //this.getTaskInfoById(id) |
| | | }, |
| | | getTaskInfoById(id) { |
| | | getTaskInfoById({id:id}).then(res => { |
| | | getTaskInfoById() { |
| | | getHostInfo().then(res => { |
| | | if(res.code == 0) { |
| | | this.tableData = res.data |
| | | } |
| | | }) |
| | | }, |
| | | isRunformat(row) { |
| | | if(row.isRun == 0 || row.isRun == null) { |
| | | if(row.isRun == 1 || row.isRun == null) { |
| | | return '正常' |
| | | }else if(row.isRun == 1){ |
| | | }else if(row.isRun == 2){ |
| | | return '异常' |
| | | } |
| | | }, |
| | | handleClickRowName({row, column, rowIndex, columnIndex}) { |
| | | if(row.isRun == 1 && column.label == '是否正常运行') { |
| | | if(row.isRun == 2 && column.label == '是否正常运行') { |
| | | return 'yichangStyle' |
| | | }else { |
| | | return '' |