|
@@ -4,7 +4,7 @@
|
|
|
<template #toolbar>
|
|
|
<a-button
|
|
|
type="primary"
|
|
|
- v-show="!getCheckRole(['host', 'tourist', 'company_viewer']) && permList.includes(1)"
|
|
|
+ v-show="!getCheckRole(['host', 'tourist', 'company_viewer']) && getEquity([1, 2])"
|
|
|
@click="handleAddLiveScene"
|
|
|
>
|
|
|
新增</a-button
|
|
@@ -25,26 +25,30 @@
|
|
|
|
|
|
<template #action="{ record }">
|
|
|
<TableAction
|
|
|
- :actions="[
|
|
|
- {
|
|
|
- label: t('routes.scenes.bindAnchor'),
|
|
|
- color: 'success',
|
|
|
- onClick: handleBindAnchor.bind(null, record),
|
|
|
- },
|
|
|
- {
|
|
|
- color: 'warning',
|
|
|
- label: '编辑',
|
|
|
- onClick: handleEditLiveScene.bind(null, record),
|
|
|
- },
|
|
|
- {
|
|
|
- color: 'error',
|
|
|
- label: '删除',
|
|
|
- popConfirm: {
|
|
|
- title: '是否确认删除',
|
|
|
- confirm: handleDeleteLiveScene.bind(null, record),
|
|
|
- },
|
|
|
- },
|
|
|
- ]"
|
|
|
+ :actions="
|
|
|
+ permList.includes(2)
|
|
|
+ ? [
|
|
|
+ {
|
|
|
+ label: t('routes.scenes.bindAnchor'),
|
|
|
+ color: 'success',
|
|
|
+ onClick: handleBindAnchor.bind(null, record),
|
|
|
+ },
|
|
|
+ {
|
|
|
+ color: 'warning',
|
|
|
+ label: '编辑',
|
|
|
+ onClick: handleEditLiveScene.bind(null, record),
|
|
|
+ },
|
|
|
+ {
|
|
|
+ color: 'error',
|
|
|
+ label: '删除',
|
|
|
+ popConfirm: {
|
|
|
+ title: '是否确认删除',
|
|
|
+ confirm: handleDeleteLiveScene.bind(null, record),
|
|
|
+ },
|
|
|
+ },
|
|
|
+ ]
|
|
|
+ : []
|
|
|
+ "
|
|
|
/>
|
|
|
</template>
|
|
|
</BasicTable>
|
|
@@ -81,7 +85,7 @@
|
|
|
setup() {
|
|
|
const { createMessage } = useMessage();
|
|
|
const userStore = useUserStore();
|
|
|
- const { getCheckRole } = userStore;
|
|
|
+ const { getCheckRole, getEquity } = userStore;
|
|
|
const { t } = useI18n();
|
|
|
const [registerBindModal, { openModal: openBindModal }] = useModal();
|
|
|
|
|
@@ -153,7 +157,7 @@
|
|
|
title: t('common.operation'),
|
|
|
dataIndex: '',
|
|
|
slots: { customRender: 'action' },
|
|
|
- ifShow: !getCheckRole(['host', 'tourist']),
|
|
|
+ ifShow: !getCheckRole(['host', 'tourist']) && getEquity(2),
|
|
|
width: 220,
|
|
|
fixed: 'right',
|
|
|
},
|
|
@@ -305,6 +309,7 @@
|
|
|
handleDeleteLiveScene,
|
|
|
handleEditLiveScene,
|
|
|
getCheckRole,
|
|
|
+ getEquity,
|
|
|
};
|
|
|
},
|
|
|
});
|