diff --git a/package.json b/package.json
index c1e7e1c..0fc3692 100644
--- a/package.json
+++ b/package.json
@@ -17,7 +17,7 @@
"build:test": "electron-vite build --mode test && electron-builder --win --config ./electron-builder.yml",
"build:prod": "electron-vite build --mode production && electron-builder --win --config ./electron-builder-prod.yml",
"build:lt": "electron-vite build --mode lt && electron-builder --win --config ./electron-builder-lt.yml",
- "build:mac": "npm run build && electron-builder --mac",
+ "build:mac": "electron-vite build --mode production && electron-builder --mac --config ./electron-builder-prod.yml",
"build:linux": "npm run build && electron-builder --linux"
},
"dependencies": {
diff --git a/src/renderer/public/pdfjs-dist/web/viewer.css b/src/renderer/public/pdfjs-dist/web/viewer.css
index edd6bf0..19bb070 100644
--- a/src/renderer/public/pdfjs-dist/web/viewer.css
+++ b/src/renderer/public/pdfjs-dist/web/viewer.css
@@ -3144,7 +3144,7 @@ body{
background-color:var(--toolbar-bg-color);
box-shadow:var(--toolbar-box-shadow);
border-bottom:var(--toolbar-border-bottom);
- z-index: 9;
+ z-index: 99999;
}
#toolbarViewer{
diff --git a/src/renderer/src/components/PdfJs/index.vue b/src/renderer/src/components/PdfJs/index.vue
index 58dc927..50e7e8e 100644
--- a/src/renderer/src/components/PdfJs/index.vue
+++ b/src/renderer/src/components/PdfJs/index.vue
@@ -6,6 +6,7 @@
diff --git a/src/renderer/src/hooks/useGetSubject.js b/src/renderer/src/hooks/useGetSubject.js
index 07bbb5e..f7882a2 100644
--- a/src/renderer/src/hooks/useGetSubject.js
+++ b/src/renderer/src/hooks/useGetSubject.js
@@ -63,7 +63,6 @@ export const useGetSubject = async () =>{
}
sessionStore.set('subject.curNode', curNode)
}
-
}
// 单元章节数据转为“树”结构
@@ -73,9 +72,7 @@ export const useGetSubject = async () =>{
data.forEach( item => {
item.children = unitList.value.filter( item2 => item2.parentid == item.id && item2.level == 2)
})
- sessionStore.set('subject.subjectTree', data)
return data
-
}
await getSubjectUnit()
diff --git a/src/renderer/src/layout/components/AppMain.vue b/src/renderer/src/layout/components/AppMain.vue
index 67c3d6b..22cc830 100644
--- a/src/renderer/src/layout/components/AppMain.vue
+++ b/src/renderer/src/layout/components/AppMain.vue
@@ -67,7 +67,7 @@ const title = reactive([
},
{
name: '教材分析',
- url: '/teaching/chatwithtextbook',
+ url: '/textbookAnalysis',
img: 'iconfont icon-yanjiushi',
child1: []
},
diff --git a/src/renderer/src/layout/components/Header.vue b/src/renderer/src/layout/components/Header.vue
index 710c338..de4788c 100644
--- a/src/renderer/src/layout/components/Header.vue
+++ b/src/renderer/src/layout/components/Header.vue
@@ -175,7 +175,13 @@ function setLayout() {
}
// 切换学科
const changeSubject = async (command) =>{
- clearBookInfo()
+ let sessionSubject = {
+ bookList: null,
+ curBook: null,
+ curNode: null,
+ defaultExpandedKeys: [],
+ }
+ sessionStore.set( 'subject', sessionSubject)
const { userId, userName, phonenumber, plainpwd } = userStore.user
const data = {
userId,
@@ -184,7 +190,7 @@ const changeSubject = async (command) =>{
edusubject: command.edusubject
}
await updateUserInfo(data)
- await userStore.login({username: phonenumber, password: plainpwd})
+ await userStore.login({username: phonenumber ? phonenumber : userName, password: plainpwd})
await userStore.getInfo()
router.go()
}
diff --git a/src/renderer/src/router/index.js b/src/renderer/src/router/index.js
index 2fa6890..8796063 100644
--- a/src/renderer/src/router/index.js
+++ b/src/renderer/src/router/index.js
@@ -54,7 +54,13 @@ export const constantRoutes = [
path: '/standardanalysis',
component: () => import('@/views/teach/standardAnalysis/index.vue'),
name: 'standardanalysis',
- meta: {title: '课标分析'},
+ meta: {title: '课标分析'}
+ },
+ {
+ path: '/textbookAnalysis',
+ component: () => import('@/views/textbookAnalysis/index.vue'),
+ name: 'textbookAnalysis',
+ meta: {title: '教材分析'}
},
{
path: '/profile',
diff --git a/src/renderer/src/utils/tool.js b/src/renderer/src/utils/tool.js
index 608ae32..641a45b 100644
--- a/src/renderer/src/utils/tool.js
+++ b/src/renderer/src/utils/tool.js
@@ -49,6 +49,18 @@ export const getStaticUrl = (url = '', type = 'app', exitPath = '', isFile = fal
}
}
}
+
+export const getAppInstallUrl = (url = '', type = 'app', exitPath = '', isFile = false) => {
+ if (isDev) return url
+ else { // 生产环境获取-url
+ switch(type) {
+ case 'app': return path.join(__dirname, url) // 应用目录
+ case 'user': return (isFile?'file://':'')+path.join(Remote.app.getAppPath(),exitPath, url) // 用户目录
+ // case 'user': return (isFile?'file://':'')+path.join(Remote.app.getPath('userData'),exitPath, url) // 用户目录
+ default: return ''
+ }
+ }
+}
/**
* @description 消息发送-nodejs 消息发送
* @form src/main/tool.js 来源
@@ -137,7 +149,7 @@ export const createWindow = async (type, data) => {
winPdf.focus();
// toolState.isPdfWin=true
}
-
+
return
}
const option = data.option||{}
@@ -272,7 +284,7 @@ const eventHandles = (type, win) => {
winPdf=null
win&&win.destroy()
})
-
+
// 监听窗口的激活事件
win.on('focus', async () => {
console.log('激活窗口')
@@ -299,8 +311,8 @@ const eventHandles = (type, win) => {
/**
* @description 外部跳转-web网页
- * @param {*} path
- * @param {*} params
+ * @param {*} path
+ * @param {*} params
*/
export const toLinkWeb = (path) => {
const config = baseConfig()
diff --git a/src/renderer/src/views/classTask/classTaskAssign.vue b/src/renderer/src/views/classTask/classTaskAssign.vue
index 7af3e3a..9ae1560 100644
--- a/src/renderer/src/views/classTask/classTaskAssign.vue
+++ b/src/renderer/src/views/classTask/classTaskAssign.vue
@@ -26,9 +26,9 @@
- 设计新作业
- 一键推送
- 删除
+ 设计新作业
+ 一键推送
+ 删除
@@ -71,14 +71,14 @@
@@ -112,19 +112,19 @@
-
+
- 删除
+ 删除
@@ -133,9 +133,9 @@
@@ -143,10 +143,10 @@
-
+
@@ -154,9 +154,12 @@
+
\ No newline at end of file