diff --git a/.env.development b/.env.development index d4989df..df0b713 100644 --- a/.env.development +++ b/.env.development @@ -10,6 +10,7 @@ VITE_APP_BASE_API = '/dev-api' VITE_APP_DOMAIN = 'file.ysaix.com' VITE_APP_UPLOAD_API = 'https://file.ysaix.com:7868/prod-api' +#VITE_APP_UPLOAD_API = 'http://192.168.2.52:7863' VITE_APP_RES_FILE_PATH = 'https://file.ysaix.com:7868/src/assets/textbook/booktxt/' diff --git a/package.json b/package.json index b71641a..4e45559 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "aix-win", - "version": "1.1.6", + "version": "1.1.8", "description": "An Electron application with Vue", "main": "./out/main/index.js", "author": "example.com", @@ -28,6 +28,7 @@ "@vueuse/core": "^10.11.0", "cropperjs": "^1.6.2", "crypto-js": "^4.2.0", + "echarts": "^5.5.1", "electron-dl-manager": "^3.0.0", "electron-log": "^5.1.7", "electron-store": "8.0.0", diff --git a/src/renderer/src/api/education/entpCourseWork.js b/src/renderer/src/api/education/entpCourseWork.js new file mode 100644 index 0000000..0ba694c --- /dev/null +++ b/src/renderer/src/api/education/entpCourseWork.js @@ -0,0 +1,111 @@ +import request from '@/utils/request' + +// 查询entpcoursework列表 +export function listEntpcoursework(query) { + return request({ + url: '/education/entpcoursework/list', + method: 'get', + params: query + }) +} + +// 查询entpcoursework详细 +export function getEntpcoursework(id) { + return request({ + url: '/education/entpcoursework/' + id, + method: 'get' + }) +} + +// 新增entpcoursework +export function addEntpcoursework(data) { + return request({ + url: '/education/entpcoursework', + method: 'post', + data: data + }) +} + +// 修改entpcoursework +export function updateEntpcoursework(data) { + return request({ + url: '/education/entpcoursework', + method: 'put', + data: data + }) +} + +// 删除entpcoursework +export function delEntpcoursework(id) { + return request({ + url: '/education/entpcoursework/' + id, + method: 'delete' + }) +} + + +// xuekubaoapi +export function xuekubaoAPI(data) { + return request({ + url: '/education/entpcoursework/xuekubaoapi', + method: 'post', + data: data + }) +} + +// PPT文件上传 +export function uploadEntpcourseworkFile(data) { + return request({ + url: '/education/entpcoursework/uploadWord', + method: 'post', + data: data + }) +} + + +// 查询entpcoursework列表 +export function listEntpcourseworkNew(query) { + return request({ + url: '/education/entpcoursework/new/list', + method: 'get', + params: query + }) +} + + +/** + * @desc: 学科网接口api + * @return: {*} + * @param {*} path 请求路径 /xopqbm/questions(无需全拼, 后端学科网sdk自动处理) + * @param {*} method 请求方式 post/get + * @param {*} params 请求参数 {key: value,} + */ +export function xkwAPI(path, method, isPostBody, params) { + return request({ + url: '/xkw/post', + method: 'post', + data: { + path: path, + method: method, + isPostBody: isPostBody, + params: params, + } + }) +} + +/** + * @desc: 图文识别接口 python_OCR_api + * @return: {*} + * @param {*} path 请求路径 /ocrApi/data + * @param {*} method 请求方式 post + * @param {*} params 请求参数 {key: value,} + */ +export function pyOCRAPI(path) { + return request({ + url: '/ocrApi/data', + method: 'post', + data: { + imageBas64: path, + } + }) +} \ No newline at end of file diff --git a/src/renderer/src/assets/iconfont/iconfont.css b/src/renderer/src/assets/iconfont/iconfont.css index c1fab69..623c98c 100644 --- a/src/renderer/src/assets/iconfont/iconfont.css +++ b/src/renderer/src/assets/iconfont/iconfont.css @@ -1,9 +1,9 @@ @font-face { font-family: "iconfont"; /* Project id 2794390 */ - src: url('iconfont.woff2?t=1724212790213') format('woff2'), - url('iconfont.woff?t=1724212790213') format('woff'), - url('iconfont.ttf?t=1724212790213') format('truetype'), - url('iconfont.svg?t=1724212790213#iconfont') format('svg'); + src: url('iconfont.woff2?t=1725691484835') format('woff2'), + url('iconfont.woff?t=1725691484835') format('woff'), + url('iconfont.ttf?t=1725691484835') format('truetype'), + url('iconfont.svg?t=1725691484835#iconfont') format('svg'); } .iconfont { @@ -14,6 +14,34 @@ -moz-osx-font-smoothing: grayscale; } +.icon-saoyisao:before { + content: "\e691"; +} + +.icon-jiaoxuezhiliangfenxi:before { + content: "\e690"; +} + +.icon-jiaoxuejihua:before { + content: "\e7e9"; +} + +.icon-tongji:before { + content: "\e68f"; +} + +.icon-pigai:before { + content: "\e68d"; +} + +.icon-jiaoxuefansi:before { + content: "\e6b2"; +} + +.icon-kaoshi:before { + content: "\e68a"; +} + .icon-yiwen:before { content: "\e687"; } diff --git a/src/renderer/src/assets/iconfont/iconfont.js b/src/renderer/src/assets/iconfont/iconfont.js index 2ad9df4..ec85b94 100644 --- a/src/renderer/src/assets/iconfont/iconfont.js +++ b/src/renderer/src/assets/iconfont/iconfont.js @@ -1 +1 @@ -window._iconfont_svg_string_2794390='',(c=>{var h=(l=(l=document.getElementsByTagName("script"))[l.length-1]).getAttribute("data-injectcss"),l=l.getAttribute("data-disable-injectsvg");if(!l){var a,t,z,p,i,v=function(h,l){l.parentNode.insertBefore(h,l)};if(h&&!c.__iconfont__svg__cssinject__){c.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(h){console&&console.log(h)}}a=function(){var h,l=document.createElement("div");l.innerHTML=c._iconfont_svg_string_2794390,(l=l.getElementsByTagName("svg")[0])&&(l.setAttribute("aria-hidden","true"),l.style.position="absolute",l.style.width=0,l.style.height=0,l.style.overflow="hidden",l=l,(h=document.body).firstChild?v(l,h.firstChild):h.appendChild(l))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(a,0):(t=function(){document.removeEventListener("DOMContentLoaded",t,!1),a()},document.addEventListener("DOMContentLoaded",t,!1)):document.attachEvent&&(z=a,p=c.document,i=!1,d(),p.onreadystatechange=function(){"complete"==p.readyState&&(p.onreadystatechange=null,M())})}function M(){i||(i=!0,z())}function d(){try{p.documentElement.doScroll("left")}catch(h){return void setTimeout(d,50)}M()}})(window); \ No newline at end of file +window._iconfont_svg_string_2794390='',(l=>{var h=(c=(c=document.getElementsByTagName("script"))[c.length-1]).getAttribute("data-injectcss"),c=c.getAttribute("data-disable-injectsvg");if(!c){var a,t,z,i,p,v=function(h,c){c.parentNode.insertBefore(h,c)};if(h&&!l.__iconfont__svg__cssinject__){l.__iconfont__svg__cssinject__=!0;try{document.write("")}catch(h){console&&console.log(h)}}a=function(){var h,c=document.createElement("div");c.innerHTML=l._iconfont_svg_string_2794390,(c=c.getElementsByTagName("svg")[0])&&(c.setAttribute("aria-hidden","true"),c.style.position="absolute",c.style.width=0,c.style.height=0,c.style.overflow="hidden",c=c,(h=document.body).firstChild?v(c,h.firstChild):h.appendChild(c))},document.addEventListener?~["complete","loaded","interactive"].indexOf(document.readyState)?setTimeout(a,0):(t=function(){document.removeEventListener("DOMContentLoaded",t,!1),a()},document.addEventListener("DOMContentLoaded",t,!1)):document.attachEvent&&(z=a,i=l.document,p=!1,d(),i.onreadystatechange=function(){"complete"==i.readyState&&(i.onreadystatechange=null,M())})}function M(){p||(p=!0,z())}function d(){try{i.documentElement.doScroll("left")}catch(h){return void setTimeout(d,50)}M()}})(window); \ No newline at end of file diff --git a/src/renderer/src/assets/iconfont/iconfont.json b/src/renderer/src/assets/iconfont/iconfont.json index 30d5f43..872d803 100644 --- a/src/renderer/src/assets/iconfont/iconfont.json +++ b/src/renderer/src/assets/iconfont/iconfont.json @@ -5,6 +5,55 @@ "css_prefix_text": "icon-", "description": "", "glyphs": [ + { + "icon_id": "12657402", + "name": "资源库", + "font_class": "saoyisao", + "unicode": "e691", + "unicode_decimal": 59025 + }, + { + "icon_id": "6513175", + "name": "教学质量分析", + "font_class": "jiaoxuezhiliangfenxi", + "unicode": "e690", + "unicode_decimal": 59024 + }, + { + "icon_id": "38447338", + "name": "教学计划", + "font_class": "jiaoxuejihua", + "unicode": "e7e9", + "unicode_decimal": 59369 + }, + { + "icon_id": "8455509", + "name": "统计", + "font_class": "tongji", + "unicode": "e68f", + "unicode_decimal": 59023 + }, + { + "icon_id": "5969226", + "name": "批改", + "font_class": "pigai", + "unicode": "e68d", + "unicode_decimal": 59021 + }, + { + "icon_id": "36295514", + "name": "教学反思", + "font_class": "jiaoxuefansi", + "unicode": "e6b2", + "unicode_decimal": 59058 + }, + { + "icon_id": "21088705", + "name": "考试", + "font_class": "kaoshi", + "unicode": "e68a", + "unicode_decimal": 59018 + }, { "icon_id": "20574719", "name": "疑问", diff --git a/src/renderer/src/assets/iconfont/iconfont.svg b/src/renderer/src/assets/iconfont/iconfont.svg index 8201a34..0be4660 100644 --- a/src/renderer/src/assets/iconfont/iconfont.svg +++ b/src/renderer/src/assets/iconfont/iconfont.svg @@ -14,6 +14,20 @@ /> + + + + + + + + + + + + + + diff --git a/src/renderer/src/assets/iconfont/iconfont.ttf b/src/renderer/src/assets/iconfont/iconfont.ttf index 43f8dc3..9e198f4 100644 Binary files a/src/renderer/src/assets/iconfont/iconfont.ttf and b/src/renderer/src/assets/iconfont/iconfont.ttf differ diff --git a/src/renderer/src/assets/iconfont/iconfont.woff b/src/renderer/src/assets/iconfont/iconfont.woff index 9fc1445..8185a5b 100644 Binary files a/src/renderer/src/assets/iconfont/iconfont.woff and b/src/renderer/src/assets/iconfont/iconfont.woff differ diff --git a/src/renderer/src/assets/iconfont/iconfont.woff2 b/src/renderer/src/assets/iconfont/iconfont.woff2 index e1759ea..acbf5ae 100644 Binary files a/src/renderer/src/assets/iconfont/iconfont.woff2 and b/src/renderer/src/assets/iconfont/iconfont.woff2 differ diff --git a/src/renderer/src/assets/images/logo.png b/src/renderer/src/assets/images/logo.png new file mode 100644 index 0000000..45f6e65 Binary files /dev/null and b/src/renderer/src/assets/images/logo.png differ diff --git a/src/renderer/src/assets/styles/JYStyle.css b/src/renderer/src/assets/styles/JYStyle.css new file mode 100644 index 0000000..f44e280 --- /dev/null +++ b/src/renderer/src/assets/styles/JYStyle.css @@ -0,0 +1,99 @@ +body{font-family: "微软雅黑", Arial,"宋体"; color: #333;} +a{ text-decoration: none; color: #2489f6;} +dl, ul, ol, ul { list-style: none; padding: 0; margin: 0; } +.wrapper{ width: 1200px; margin: 0 auto; } +.ques-detail{} +.ques-detail ul li{margin-bottom: 20px;border: 1px solid #dadada;background: #fff;border-radius: 10px;} +.ques-detail ul li:last-child{ margin-bottom: 0; } + +table.edittable{ border-collapse: collapse; text-align: center; margin: 2px; } +table.edittable th, table.edittable td{ line-height: 30px; padding: 5px; white-space: normal; word-break: break-all; border: 1px solid #000; vertical-align: middle; } +table.composition{ border-collapse: collapse; text-align: left; margin: 2px; width: 98%; } +table.composition th, table.composition td{ line-height: 30px; white-space: normal; word-break: break-all; border-width: 0px; vertical-align: middle; } +table.composition2{ border-collapse: collapse;width:auto } +table.composition2 th, table.composition2 td{text-align:left;line-height:30px; white-space:normal;word-break:break-all;border:none;border-width: 0px;vertical-align: middle; } +.MathJye{ border: 0 none; direction: ltr; line-height: normal; display: inline-block; float: none; font-family: 'Times New Roman','宋体'; font-size: 15px; font-style: normal; font-weight: normal; letter-spacing: 1px; line-height: normal; margin: 0; padding: 0; text-align: left; text-indent: 0; text-transform: none; white-space: nowrap; word-spacing: normal; word-wrap: normal; -webkit-text-size-adjust: none; } +.MathJye div, .MathJye span{ border: 0 none; margin: 0; padding: 0; line-height: normal; text-align: left; height: auto; _height: auto; white-space: normal; } +.MathJye table{ border-collapse: collapse; margin: 0; padding: 0; text-align: center; vertical-align: middle; line-height: normal; font-size: inherit; *font-size: 100%; _font-size: 100%; font-style: normal; font-weight: normal; border: 0; float: none; display: inline-block; *display: inline; zoom: 0; } +.MathJye table td{ padding: 0; font-size: inherit; line-height: normal; white-space: nowrap; border: 0 none; width: auto; _height: auto; } +.MathJye_mi{ font-style: italic; } +.flipv{-ms-transform: scaleX(-1);-moz-transform: scaleX(-1);-webkit-transform: scaleX(-1);-o-transform: scaleX(-1);transform: scaleX(-1);filter: FlipH;} +.fliph{-ms-transform: scaleY(-1);-moz-transform: scaleY(-1);-webkit-transform: scaleY(-1);-o-transform: scaleY(-1);transform: scaleY(-1);filter: FlipV;} +.mathjye-bold{font-weight:800} +.mathjye-del{text-decoration:line-through} +.mathjye-underline{border-bottom:1px solid #000;padding-bottom:2px;} +@-moz-document url-prefix() {.mathjye-underline{padding-bottom:0px;}} +.mathjye-underpline{border-bottom:2px dotted #000; padding-bottom:3px;} +@-moz-document url-prefix() {.mathjye-underpline {padding-bottom:1px;}} +.mathjye-underpoint{background: url(http://img.jyeoo.net/images/formula/point.png) no-repeat center bottom; padding-bottom:4px;} +.mathjye-underpoint2{border-bottom:2px dotted #000; padding-bottom:3px;} +@-moz-document url-prefix() {.mathjye-underpoint{padding-bottom:1px;}} +.mathjye-underwave{background: url(http://img.jyeoo.net/images/formula/wave.png) bottom repeat-x; padding-bottom:4px;} +@-moz-document url-prefix() {.mathjye-underwave {padding-bottom:1px;}} +.mathjye-alignleft{display:block;text-align:left;} +.mathjye-aligncenter{display:block;text-align:center;} +.mathjye-alignright{display:block;text-align:right;} + + +/*试题*/ +.artpreview fieldset { padding-top: 10px; font-size: 14px; clear: both; overflow: hidden; zoom: 1; line-height: 24px; font-family: 'Times New Roman',宋体,sans-serif; position: relative; } +.artpreview fieldset legend { padding: 5px 0; display: block; margin: 5px; background: #f1f1f1; color: #000; overflow: hidden; zoom: 1; } +.queserror { border: 1px dotted #f00; padding: 2px; } +fieldset.quesborder {display: block;padding: 0;line-height: 25px;letter-spacing: 1px;word-break: break-all;margin: 0;} +fieldset.queserror { border: 1px solid #f00; font-size: 12px; padding: 2px; margin-bottom: 1px; } +fieldset.quesborder td, fieldset.queserror td { line-height: 16px; } +fieldset.quesborder em, fieldset.queserror em { font-style: normal; font-weight: bold; position: absolute; left: 20px; } +fieldset.thiserror1 { border: 1px solid #f00; } +fieldset.thiserror1 legend { border: 4px solid #f00; } +fieldset.thiserror2 { border: 1px solid #ADCD3C; } +fieldset.thiserror2 legend { border: 4px solid #ADCD3C; } +fieldset.thisques { border: 1px solid blue; } +fieldset.thison { border: 1px solid #A9C9E2; } +fieldset.thison div.border { border: 1px solid #ADCD3C; background-color: #F2FDDB; } +fieldset, img { border: 0 none; } +table.thison { border: 1px solid #00F; } +table.thiserr { border: 1px solid #F00; } +fieldset.thisvip1 { border: 1px solid #00F; } +fieldset.thisvip1 legend { border: 4px solid #00F; } +fieldset.status17 { border: 1px solid #ff00ff; } +fieldset.status17 legend { border: 4px solid #ff00ff; } +.selectoption { vertical-align: middle; font-size: 14px; padding: 2px; } +.selectoption:hover { color: #EA8511; } +.selectoption label { padding: 4px; line-height: 24px; } +fieldset.quesbordere { border: 2px dotted #f00; } +.answer { border: 1px dotted #ffffff; } +ol.answer li, ul.answer li { padding: 1px; font-size: 14px; } +ol.answer li:hover { background: #f2f2f2; } +.collapseContainerPanel { border: 0; } +.collapsePanelHeader { height: 30px; font-weight: bold; padding: 6px 0 0 0; } +.collapseHeaderContent { float: left; padding-left: 5px; } +.collapseContent { margin: 0; padding: 0; border: 1px solid #ccc; border-top: 0; } +.pt0 { padding: 2px 0 5px 0; font-size: 14px; font-family: "黑体",sans-serif; font-weight: 700; } +.pt1 {overflow: hidden;zoom: 1;clear: both;line-height: 25px;font-size: 14px;padding: 20px;position: relative;word-break: break-word;} +fieldset.quesborder .pt1 em { position: static; } +.pt1 img { position: relative; } +.pt2 {padding: 20px;padding-top: 0;} +.pt3, .pt4, .pt5, .pt6, .pt7 { clear: both; zoom: 1; position: relative; padding: 0px 20px 20px 80px; } +.pt8 a:link, .pt8 a:visited { margin-right: 10px; padding: 2px 5px; } +.pt8 a:hover { background: #fc0; } +.pt9 { padding: 20px; border: 0 none; color: #999999; font-size: 12px; } +.fieldtip {height: 36px;line-height: 36px;background-color: #f4f4f4;border-top: 1px solid #dadada;padding: 0 20px;color: #666666;position: relative;font-size: 12px;border-radius: 0 0 10px 10px;} +.newFieldtip .pt1, .newFieldtip .pt2, .newFieldtip .pt3, .newFieldtip .pt4, .newFieldtip .pt5, .newFieldtip .pt6, .newFieldtip .pt7, .newFieldtip .pt8, .newFieldtip.pt9, .newFieldtip + .fieldtip { padding: 0; } +fieldset img { max-width: 100%; } + +.fieldtip-left {float: left;} +.fieldtip-left >* {margin-right: 20px;} +.fieldtip-right { float: right; } +.fieldtip-right>* { margin-left: 20px; display: inline-block; color: #666666; } +.fieldtip .btn {display: inline-block;margin-bottom: 0;font-weight: normal;text-align: center;vertical-align: middle;-ms-touch-action: manipulation;touch-action: manipulation;cursor: pointer;background-image: none;border: 1px solid transparent;-webkit-user-select: none;-moz-user-select: none;-ms-user-select: none;user-select: none;font-size: 14px;border-radius: 4px;color: #ffffff;background-color: #ff8a00;line-height: 18px;min-width: 28px;padding: 0 5px;} +.fieldtip .btn:hover, .fieldtip .btn:active, .fieldtip .btn:active:hover, .fieldtip .btn:hover { color: #ffffff; background-color: #faad4a; } + +/*填空题*/ +div.quizPutTag { display: inline-block; *display: inline; padding: 3px 10px 1px 10px; margin: 0 3px; font-size: 14px; min-width: 1em; min-height: 16px; line-height: 18px; height: auto; border-bottom: 1px solid #0033FF; text-decoration: none; zoom: 1; color: #127176; word-break: break-all; } +div.quizPutTag:hover { color: #f60; } +div.quizPutTag img { cursor: pointer; width: 200px; margin-left: 10px; } +.sanwser { padding: 4px 10px; margin: 0px; border: 1px solid #ADCD3C; background-color: #F2FDDB; color: #000; display: none; } +/*答案*/ +.selectoption label.s, div.s { border: 1px solid #91cbed; background-color: #deeeff; display: inline-block; } +.selectoption label.s.sh, div.s.sh { margin: 1px; border: none; background: none; } +del { text-decoration: none; color: #f00; font-style: normal; font-weight: normal; } \ No newline at end of file diff --git a/src/renderer/src/components/choose-textbook/index.vue b/src/renderer/src/components/choose-textbook/index.vue index 3c2a18c..38fd5e1 100644 --- a/src/renderer/src/components/choose-textbook/index.vue +++ b/src/renderer/src/components/choose-textbook/index.vue @@ -100,7 +100,7 @@ const getSubjectContent = async () => { edustage, // entpcourseedituserid: userId, itemgroup: 'textbook', - pageSize: 500 + pageSize: 10000 } let data; @@ -263,7 +263,7 @@ const transData = (data) => { //获取教材 const getSubject = async () => { - const { rows } = await listEvaluation({ itemkey: "version", edusubject, edustage, pageSize: 500 }) + const { rows } = await listEvaluation({ itemkey: "version", edusubject, edustage, pageSize: 10000 }) // subjectList.value = rows.filter(item => item.edustage == edustage && item.edusubject == edusubject) subjectList.value = rows diff --git a/src/renderer/src/components/file-preview/index.vue b/src/renderer/src/components/file-preview/index.vue index 350695b..9b2326d 100644 --- a/src/renderer/src/components/file-preview/index.vue +++ b/src/renderer/src/components/file-preview/index.vue @@ -1,5 +1,5 @@ diff --git a/src/renderer/src/layout/components/Header.vue b/src/renderer/src/layout/components/Header.vue index e7a4e04..8501952 100644 --- a/src/renderer/src/layout/components/Header.vue +++ b/src/renderer/src/layout/components/Header.vue @@ -1,10 +1,19 @@