Эх сурвалжийг харах

超管不再允许创建机构

zhangjie 2 жил өмнө
parent
commit
3694439ccc

+ 6 - 1
src/features/system/OrgManagement/OrgManagement.vue

@@ -22,7 +22,11 @@
           </el-form-item>
         </el-form>
         <div class="part-filter-form-action">
-          <el-button type="primary" icon="icon icon-add" @click="add"
+          <el-button
+            v-if="!IS_SUPER_ADMIN"
+            type="primary"
+            icon="icon icon-add"
+            @click="add"
             >新增</el-button
           >
           <!-- <el-button>导入</el-button> -->
@@ -118,6 +122,7 @@ export default {
       pageSize: 10,
       total: 10,
       selectedOrg: {},
+      IS_SUPER_ADMIN: this.$store.state.user.roleCodes.includes("SUPER_ADMIN"),
     };
   },
   async created() {