|
@@ -14,7 +14,12 @@
|
|
|
</Layout>
|
|
</Layout>
|
|
|
|
|
|
|
|
<!-- AI智能助手悬浮按钮(支持拖动,固定右侧) -->
|
|
<!-- AI智能助手悬浮按钮(支持拖动,固定右侧) -->
|
|
|
- <div class="ai-assistant-float" :style="{ right: aiBtnPosition.right, bottom: aiBtnPosition.bottom }" @mousedown="handleDragStart">
|
|
|
|
|
|
|
+ <div
|
|
|
|
|
+ v-if="hasPermission('show:ventAI')"
|
|
|
|
|
+ class="ai-assistant-float"
|
|
|
|
|
+ :style="{ right: aiBtnPosition.right, bottom: aiBtnPosition.bottom }"
|
|
|
|
|
+ @mousedown="handleDragStart"
|
|
|
|
|
+ >
|
|
|
<div class="ai-float-icon" @click="openAiAssistant"></div>
|
|
<div class="ai-float-icon" @click="openAiAssistant"></div>
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
|
@@ -40,6 +45,7 @@
|
|
|
import { useAppStore } from '/@/store/modules/app';
|
|
import { useAppStore } from '/@/store/modules/app';
|
|
|
|
|
|
|
|
import { useAppInject } from '/@/hooks/web/useAppInject';
|
|
import { useAppInject } from '/@/hooks/web/useAppInject';
|
|
|
|
|
+ import { usePermission } from '/@/hooks/web/usePermission';
|
|
|
import { antPrefixCls } from '/@/settings/designSetting';
|
|
import { antPrefixCls } from '/@/settings/designSetting';
|
|
|
|
|
|
|
|
export default defineComponent({
|
|
export default defineComponent({
|
|
@@ -58,6 +64,7 @@
|
|
|
const { prefixCls } = useDesign('default-layout');
|
|
const { prefixCls } = useDesign('default-layout');
|
|
|
const { getIsMobile } = useAppInject();
|
|
const { getIsMobile } = useAppInject();
|
|
|
const { getShowSidebar, getIsMixSidebar, getShowMenu } = useMenuSetting();
|
|
const { getShowSidebar, getIsMixSidebar, getShowMenu } = useMenuSetting();
|
|
|
|
|
+ const { hasPermission } = usePermission();
|
|
|
|
|
|
|
|
// Create a lock screen monitor
|
|
// Create a lock screen monitor
|
|
|
const lockEvents = useLockPage();
|
|
const lockEvents = useLockPage();
|
|
@@ -157,6 +164,7 @@
|
|
|
getIsMixSidebar,
|
|
getIsMixSidebar,
|
|
|
layoutClass,
|
|
layoutClass,
|
|
|
lockEvents,
|
|
lockEvents,
|
|
|
|
|
+ hasPermission,
|
|
|
aiAssistantVisible,
|
|
aiAssistantVisible,
|
|
|
aiBtnPosition,
|
|
aiBtnPosition,
|
|
|
openAiAssistant,
|
|
openAiAssistant,
|