main #258

Merged
qinqing merged 12 commits from main into qinqing_dev 2024-09-24 15:36:44 +08:00
6 changed files with 29 additions and 10 deletions
Showing only changes of commit d1ae68d184 - Show all commits

View File

@ -115,7 +115,7 @@ const outerAi = [
title: '生成图片',
secondTit: '文生图大模型',
img: new URL('../../../src/assets/images/ai-01.png', import.meta.url).href,
path: '/ais/aisd3'
path: '/ais/aiwenxinyige'
},
{
id: 2,

View File

@ -235,6 +235,7 @@ onMounted( async () => {
}
else{
curBook.data = useSubject.subjectList[0]
localStorage.setItem('curBook', JSON.stringify(curBook.data))
treeData.value = useSubject.treeData
}
//

View File

@ -65,7 +65,7 @@
<script setup>
import { ref, watch, onMounted } from 'vue'
import { useRouter } from 'vue-router'
import { ElMessageBox } from 'element-plus'
import { ElMessageBox, ElMessage } from 'element-plus'
import { ArrowDown } from '@element-plus/icons-vue'
import WindowTools from '@/components/window-tools/index.vue'
import useUserStore from '@/store/modules/user'
@ -74,6 +74,10 @@ import outLink from '@/utils/linkConfig'
import logoIco from '@/assets/images/logo.png'
import { listEvaluation } from '@/api/classManage/index'
import { clearBookInfo } from '@/utils/ruoyi'
import { sessionStore } from '@/utils/store'
import { useToolState } from '@/store/modules/tool'
const toolState = useToolState();
let homeTitle = ref(import.meta.env.VITE_APP_TITLE)
const { ipcRenderer } = window.electron || {}
const userStore = useUserStore()
@ -166,6 +170,8 @@ function handleCommand(command) {
}
function logout() {
const hasClass = sessionStore.has('activeClass.id')
if (hasClass || toolState.isToolWin) return ElMessage.warning('当前正在上课,请先结结束上课')
ElMessageBox.confirm('确认退出系统吗?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',

View File

@ -23,11 +23,12 @@ export const useToolState = defineStore('tool', {
}),
actions: {
async resetDef() { // 重置数据-下课
this.model = 'select' // 悬浮球-当前模式
await sleep(20) // 休眠20ms
// this.model = 'select' // 悬浮球-当前模式
await sleep(50) // 休眠50ms
this.showBoardAll = false // 全屏画板-是否显示
await sleep(20) // 休眠20ms
await sleep(50) // 休眠50ms
this.isToolWin = false // 工具窗口是否打开
await sleep(50) // 休眠50ms
}
}
})

View File

@ -243,6 +243,7 @@ const sideChange = async o => {
// === ===
watchEffect(() => {
if (isOver.value) return // ,
// , : -
const show = !toolStore.isPdfWin && toolStore.showBoardAll
if (show != isShow.value) isShow.value = show

View File

@ -1,9 +1,15 @@
<template>
<canvas ref="canvasRef" />
<button @click="eraseTo">橡皮擦
<i class="iconfont icon-xiangpica"></i>
</button>
<button @click="close">销毁</button>
<canvas ref="canvasRef" style="pointer-events: none;" />
<div style="position: absolute;top: 0;" @click="test('click')"
@mouseenter="test('mouseenter')" @mousemove="test('mousemove')" @mouseleave="test('mouseleave')"
@touchstart="test('touchstart')" @touchmove="test('touchmove')" @touchend="test('touchend')"
@touchcancel="test('touchcancel')" @mousedown="test('mousedown')" @mouseup="test('mouseup')"
@mouseout="test('mouseout')" @mouseover="test('mouseover')" @mousewheel="test('mousewheel')">
<!-- <button @click="eraseTo">橡皮擦</button> -->
<!-- <i class="iconfont icon-xiangpica"></i> -->
<!-- <button @click="close">销毁</button> -->
<div style="width: 100px;height: 100px;background: #ffbcbc;">小星星</div>
</div>
</template>
<script setup>
@ -43,6 +49,10 @@ const eraseTo = () => { // 橡皮擦
// canvas.dispose()
}
const close = () => { FabricVue.removeCanvas() }
const test = (key, e) => {
console.log('event: ', key)
}
</script>
<style lang="scss" scoped>