|
@@ -1,7 +1,7 @@
|
|
|
<template>
|
|
|
<div class='app-container'>
|
|
|
<div class="left">
|
|
|
- <el-button type="primary" plain icon="Plus" @click="getDialog()"
|
|
|
+ <el-button type="primary" plain icon="Plus" @click="getAddDialog()"
|
|
|
v-hasPermi="['scene:presets:addScene']">新增场景</el-button>
|
|
|
<el-input class="search" v-model="data.form.takeName" placeholder="搜索场景名称" clearable>
|
|
|
<template #append>
|
|
@@ -129,15 +129,16 @@ function onEnd(params) {
|
|
|
const dialogVisible = ref(false)
|
|
|
// 弹窗标题
|
|
|
const title = ref('')
|
|
|
+const getAddDialog = () => {
|
|
|
+ dialogVisible.value = true
|
|
|
+ title.value = '新增'
|
|
|
+}
|
|
|
// 打开弹窗
|
|
|
function getDialog(row) {
|
|
|
if (row.auditStatus === 2) {
|
|
|
if (checkPermi(['scene:presets:editScene'])) {
|
|
|
dialogVisible.value = true
|
|
|
- title.value = '新增'
|
|
|
- if (row.takeId) {
|
|
|
- getDetail(row.takeId)
|
|
|
- }
|
|
|
+ getDetail(row.takeId)
|
|
|
}
|
|
|
}
|
|
|
}
|