浏览代码

no message

DESKTOP-SVI9JE1\muzen 1 年之前
父节点
当前提交
851bb8779d
共有 1 个文件被更改,包括 10 次插入7 次删除
  1. 10 7
      src/views/content/scene/index.vue

+ 10 - 7
src/views/content/scene/index.vue

@@ -13,7 +13,8 @@
         v-loading="loading">
         <template #item="{ element, index }">
           <div class="item" @click="getDialog(element.takeId)">
-            <el-icon class="close" size="18" @click.stop="getDelete(element)">
+            <el-icon class="close" size="18" @click.stop="getDelete(element)"
+              v-hasPermi="['content:scene:deleteScene']">
               <CircleClose />
             </el-icon>
             <img src="@/assets/icons/svg/file.svg" width="50" height="50" />
@@ -109,9 +110,9 @@ function onEnd(params) {
     if (params.from.className !== params.to.className) {
       proxy.$modal.confirm(`是否要添加?`).then(() => {
         getRouter({ audioList: JSON.stringify(params.item.__draggable_context.element), disabled: true })
-      }).catch(() => {})
+      }).catch(() => { })
     }
-  }else{
+  } else {
     proxy.$modal.msgError('暂无权限')
   }
 }
@@ -122,10 +123,12 @@ const dialogVisible = ref(false)
 const title = ref('')
 // 打开弹窗
 function getDialog(id) {
-  dialogVisible.value = true
-  title.value = '新增'
-  if (id) {
-    getDetail(id)
+  if (checkPermi(['content:scene:editScene'])) {
+    dialogVisible.value = true
+    title.value = '新增'
+    if (id) {
+      getDetail(id)
+    }
   }
 }
 // 详情