| | |
| | | <el-row :gutter="20"> |
| | | <el-col :span="showMap ? 12 : 24" :xs="24"> |
| | | <AppTable ref="AppTable" selection :showDeptSearch="false" :url="'tower/point/list'" :tableColumns="tableColumns" |
| | | :tableFilter="tableFilter" @clickRow="clickRow"> |
| | | :tableFilter="tableFilter"> |
| | | <template #operatorBox="{ row }"> |
| | | <el-button type="primary" plain icon="el-icon-plus" size="mini" |
| | | @click="handleAdd">新增模型</el-button> |
| | | @click="handleAdd">新增模板</el-button> |
| | | </template> |
| | | <template #operator="{ row }"> |
| | | <el-button size="mini" type="text" icon="el-icon-edit" |
| | | @click="handleUpdate(row)">修改</el-button> |
| | | <el-button size="mini" type="text" icon="el-icon-view" |
| | | @click="preview(row)">预览</el-button> |
| | | <el-button size="mini" type="text" icon="el-icon-delete" |
| | | @click="handleDelete(row)">删除</el-button> |
| | | </template> |
| | |
| | | </el-col> |
| | | </el-row> |
| | | |
| | | <shootPointDialog v-if="showDialog" @close="close"></shootPointDialog> |
| | | <shootPointDialog @on-submit="$refs.AppTable.getData()" v-if="showDialog" @close="close" :templateId="templateId"></shootPointDialog> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | multiple: true, |
| | | tableColumns: [ |
| | | { |
| | | label: '模型名称', |
| | | prop: 'name' |
| | | label: '模板名称', |
| | | prop: 'templateName' |
| | | }, |
| | | { |
| | | label: '模型类型', |
| | | prop: 'createBy' |
| | | }, |
| | | { |
| | | label: '模型路径', |
| | | prop: 'createTime' |
| | | label: '模型ID', |
| | | prop: 'modelId' |
| | | }, |
| | | { |
| | | label: '操作', |
| | |
| | | } |
| | | ], |
| | | showMap:false, |
| | | showDialog:false |
| | | showDialog:false, |
| | | templateId:null |
| | | }; |
| | | }, |
| | | watch: { |
| | |
| | | methods: { |
| | | // 添加数据 |
| | | handleAdd() { |
| | | this.templateId = null |
| | | this.showMap = false |
| | | this.showDialog = true |
| | | // this.$refs.shootPointDialog.show() |
| | |
| | | // 删除数据 |
| | | handleDelete(row) { |
| | | const ids = row.id || this.ids |
| | | const name = row.name || '' |
| | | this.$api.deleteByName('/work/tower', ids,name).then(res => { |
| | | // const name = row.name || '' |
| | | const name = ids |
| | | this.$api.deleteByName('/tower/point', ids,name).then(res => { |
| | | this.$refs.AppTable.getData() |
| | | }) |
| | | }, |
| | |
| | | // }, |
| | | close(){ |
| | | this.showDialog =false |
| | | }, |
| | | preview(row){ |
| | | console.log(row) |
| | | this.templateId = row.id |
| | | this.showDialog = true |
| | | } |
| | | }, |
| | | }; |