diff --git a/src/api/index.js b/src/api/index.js index 525753d..487fb66 100644 --- a/src/api/index.js +++ b/src/api/index.js @@ -19,8 +19,8 @@ const service = axios.create({ // baseURL: 'https://submission.tmrjournals.com/', //正式 记得切换 // baseURL: 'http://www.tougao.com/', //测试本地 记得切换 // baseURL: 'http://192.168.110.110/tougao/public/index.php/', - // baseURL: '/api', //本地 - baseURL: '/', //正式 + baseURL: '/api', //本地 + // baseURL: '/', //正式 }); diff --git a/src/assets/css/main.css b/src/assets/css/main.css index 66e9d7c..4a6f778 100644 --- a/src/assets/css/main.css +++ b/src/assets/css/main.css @@ -24,7 +24,9 @@ a { text-decoration: none } - +.page-container { + min-width: 1200px; +} .content-box { position: absolute; left: 260px; diff --git a/src/components/common/common.vue b/src/components/common/common.vue index 2038279..d0e0630 100644 --- a/src/components/common/common.vue +++ b/src/components/common/common.vue @@ -2,12 +2,12 @@ //记得切换 //正式 -const mediaUrl = '/public/'; -const baseUrl = '/'; +// const mediaUrl = '/public/'; +// const baseUrl = '/'; -// const mediaUrl = 'https://submission.tmrjournals.com/public/'; -// // const mediaUrl = 'http://zmzm.tougao.dev.com/public/'; -// const baseUrl = '/api' +const mediaUrl = 'https://submission.tmrjournals.com/public/'; +// const mediaUrl = 'http://zmzm.tougao.dev.com/public/'; +const baseUrl = '/api' // const mediaUrl = 'http://tougaotest.tmrjournals.com/public/'; // // const mediaUrl = 'http://zmzm.tougao.dev.com/public/'; diff --git a/src/components/page/articleDetailEditor.vue b/src/components/page/articleDetailEditor.vue index 2ded828..b6c43d3 100644 --- a/src/components/page/articleDetailEditor.vue +++ b/src/components/page/articleDetailEditor.vue @@ -1,7 +1,7 @@ - + @@ -504,6 +505,40 @@ export default { } }, methods: { + reinviteReview(row) { + console.log(row); + this.$confirm('Are you sure you want to resend the review invitation to this reviewer?', 'Tips', { + confirmButtonText: 'Sure', + cancelButtonText: 'Cancel', + type: 'warning' + }).then(() => { + const loading = this.$loading({ + lock: true, + text: 'please wait', + spinner: 'el-icon-loading', + background: 'rgba(0, 0, 0, 0.7)' + }); + this.$api + .post('api/Workbench/updateReviewerState', { + + account: localStorage.getItem('U_name'), + art_rev_id: row.art_rev_id, + + }) + .then((res) => { + loading.close(); + if (res.status == 1) { + this.$message.success('Email sent successfully!'); + } else { + this.$message.error(res.msg); + } + }) + .catch((err) => { + loading.close(); + }); + }); + + }, initArticle() { this.$api .post('api/Article/getArticleDetail', { diff --git a/src/components/page/components/articleDetail/reviewerdetail.vue b/src/components/page/components/articleDetail/reviewerdetail.vue index 869e1a3..6cc85e1 100644 --- a/src/components/page/components/articleDetail/reviewerdetail.vue +++ b/src/components/page/components/articleDetail/reviewerdetail.vue @@ -33,7 +33,7 @@ {{ formatDate(detailDate.ctime) }} - + Disclose name Remain anonymous diff --git a/src/components/page/components/pendingPayment/success.vue b/src/components/page/components/pendingPayment/success.vue index e15aa3b..6692952 100644 --- a/src/components/page/components/pendingPayment/success.vue +++ b/src/components/page/components/pendingPayment/success.vue @@ -1,5 +1,6 @@ diff --git a/src/components/page/components/table/word.vue b/src/components/page/components/table/word.vue index 42a4a58..9345118 100644 --- a/src/components/page/components/table/word.vue +++ b/src/components/page/components/table/word.vue @@ -529,7 +529,7 @@ class="rightTabs" type="border-card" :style="rightW ? `width:${rightW + 1}px` : ''" - style="width: 310px; position: fixed; top: 58px; box-sizing: border-box; right: 14px" + style="width: 310px; position: fixed; top: 40px; box-sizing: border-box; right: 14px" > @@ -547,7 +547,7 @@ v-loading="proofreadingLoading" v-if="!isPreview" :style="rightW ? `width:${rightW}px` : ''" - style="width: 310px; position: fixed; top: 104px; box-sizing: border-box; right: 14px; bottom: 0" + style="width: 310px; position: fixed; top: 90px; box-sizing: border-box; right: 14px; bottom: 0" class="commentList" >
  • -
    - + - - +

    {{ txt_mess.article_title }}

    @@ -23,7 +21,7 @@ Manuscript ID: {{ txt_mess.accept_sn }}

    Type : {{ txt_mess.atype }}

    -

    Submitted time : {{ txt_mess.ctime }}

    +

    Submitted time : {{ txt_mess.ctime | formatDatehms}}

    Abstract :
    {{ txt_mess.abstrart }}

    @@ -51,52 +49,107 @@
    -

    Download failed?

    - + It seems like you're encountering a download issue with Google Chrome version 86. Here are the steps you can follow to resolve or bypass the issue:
    1. Right-click on the download link: Instead of clicking the link normally, right-click on it and select "save link as". This should allow the download to start.
    2. Try a different browser: If you're still having trouble with Chrome, you could use other browsers to complete your downloads. Browsers like Firefox, Internet Explorer, Brave, Vivaldi, the new Edge, or Opera are known to work well for downloads without this issue. - -

    -
    - - + -
    +
    +
    + +
    +
    + + {{ txt_mess.title }} + >> + Manuscript ID: {{ txt_mess.accept_sn }} + + Type : {{ txt_mess.atype }} + Submitted time : {{ txt_mess.ctime |formatDatehms }} +
    +

    {{ txt_mess.article_title }}

    +
    + +
    + + +

    Review Invitation Expired

    + +

    + The review link has expired. If you would like to review the manuscript again,
    please click the 'Apply to Review Manuscript' button. +

    + +
    + Apply to Review Manuscript +
    +
    + +
    + + +

    Manuscript Review Completed

    + +

    Thank you for your time and consideration on the manuscript. We are sorry that this manuscript has went through peer + review and the final review has been obtained according to the timetable. Accordingly, your review process has + been discontinued. Your comments do not need to be submitted now. We would like to express our sincere gratitude for + your contributions as well. +

    + + +
    + +
    + + +

    Manuscript review canceled

    + + + +
    +
    + + +

    Review Record Unavailable

    + +

    Inquiries regarding the manuscript status and subsequent handling, please feel free to reach out to {{ txt_mess.journal_email }}. +

    + + +
    + +
    +
    +
    @@ -209,8 +262,24 @@ export default { localStorage.setItem('U_name', res.data.user.account); localStorage.setItem('U_id', res.data.user.user_id); localStorage.setItem('U_relname', res.data.user.realname); - this.$bus.$emit('user-name-updated'); + + if (res.data.user.account == 'superadmin' || res.data.user.account == + 'wuxiongzhi2') { + localStorage.setItem('U_status', '0'); //超级管理员 + + + } else if (res.data.roles.includes('editor')) { + localStorage.setItem('U_status', '1'); //编辑 + + + } else { + localStorage.setItem('U_status', '2'); //其余的身份 + + } + + + this.$bus.$emit('user-name-updated'); this.CheckReviewerPermissions() } else { this.$message.error(res.msg); @@ -222,13 +291,52 @@ export default { } }, methods: { + applyReview() { + + this.$confirm('Are you sure you want to send an email to the Editor?', 'Tips', { + confirmButtonText: 'Sure', + cancelButtonText: 'Cancel', + type: 'warning' + }).then(() => { + const loading = this.$loading({ + lock: true, + text: 'please wait', + spinner: 'el-icon-loading', + background: 'rgba(0, 0, 0, 0.7)' + }); + this.$api + .post('api/Workbench/applySendEmail', { + + account: localStorage.getItem('U_name'), + art_rev_id: this.$route.query.Art_id, + + }) + .then((res) => { + loading.close(); + if (res.status == 1) { + this.$message.success('Email sent successfully!'); + } else { + this.$message.error(res.msg); + } + }) + .catch((err) => { + loading.close(); + }); + }); + + }, //审稿人权限判断 CheckReviewerPermissions() { + const loading = this.$loading({ + lock: true, + text: 'Loading...', + spinner: 'el-icon-loading', + background: 'rgba(0, 0, 0, 0.7)' + }); let params = { art_rev_id: this.Art_id, account: localStorage.getItem('U_name'), }; - if (this.Direct_log) { params.act = this.Direct_log; } @@ -236,22 +344,45 @@ export default { this.$api .post('api/Workbench/getReviewerAuth', params) .then((res) => { - //是否有审稿权限1是2否 - if(res.data.is_review_auth==1){ - that.add_apply = 0; - that.getData() - }else{ + loading.close(); + if(res.status==1){ + + that.getData() + }else{ + this.txt_mess={...res.data.article,title:res.data.article.journal_name,ctime:res.data.review.ctime,atype:res.data.article.type_name}; - this.txt_mess={...res.data.article,title:res.data.article.journal_name,ctime:res.data.review.ctime,atype:res.data.article.type_name}; - this.add_apply = 1; - } + } + + switch (res.status) { + + case 1: + // 有权限操作 + this.add_apply = 0; + + break; + case 7||16: + // 7文章状态不在审稿中 16同意审稿后14天未进行审稿 + this.add_apply = 1; + break; + case 8: + //拒绝审稿 + this.add_apply = -1; + break; + case 13: + //13 邀请审稿超过5天未同意邀请 + this.add_apply = 2; + break; + default: + this.add_apply = 3; + break; + } + }) - .catch((err) => { + .catch((err) => {loading this.$message.error(err); }); }, - getData() { const loading = this.$loading({ lock: true, @@ -270,7 +401,6 @@ export default { if (res.state != 0) { this.btn_submit = 1; } - let date = new Date(parseInt(res.ctime) * 1000); let Y = date.getFullYear() + '-'; let M = date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) + '-' : date.getMonth() + 1 + '-'; @@ -278,16 +408,12 @@ export default { res.ctime = Y + M + D; this.txt_mess = res; this.journal_id = res.journal_id; - - - loading.close(); }) .catch((err) => { loading.close(); this.$message.error(err); }); - this.$api .post('api/Reviewer/getAFilelistByID ', { revid: this.Art_id @@ -301,10 +427,8 @@ export default { res.data[i].ctime = Y + M + D; } this.fileList = res.data; - // 获取格式 let pdfOut = this.fileList[this.fileList.length - 1].file_url; - if (pdfOut.substring(pdfOut.lastIndexOf('.') + 1) == 'docx') { this.pdfUrl = 'https://view.officeapps.live.com/op/view.aspx?src=https://submission.tmrjournals.com/public/' + pdfOut+`&ui=en-US`; @@ -318,7 +442,6 @@ export default { .catch((err) => { this.$message.error(err); }); - this.$api .post('api/Reviewer/getBFilelistByID', { revid: this.Art_id @@ -353,7 +476,6 @@ export default { .catch((err) => { this.$message.error(err); }); - //初始化问卷 this.$api .post('api/Reviewer/getQuestion', { @@ -361,8 +483,6 @@ export default { }) .then((res) => { if (res.code == 0) { - - this.questionform.rev_qu_id = res.data.rev_qu_id; this.questionform.qu1 = res.data.qu1; this.questionform.qu2 = res.data.qu2; @@ -400,7 +520,6 @@ export default { questionSubmit() { if (this.questionform.is_anonymous == '' && this.questionform.is_anonymous != '0') { this.$message.error('Please choose disclose your name or remain anonymous.'); - return false; } const regex = /[\u4E00-\u9FA5\uF900-\uFA2D]{1,}/; @@ -408,7 +527,6 @@ export default { if (regex.test(this.questionform.comment)) { // 如果输入的是中文,则清空输入框 this.$message.error('Comments for the Authors cannot use Chinese.'); - return false; } } @@ -416,7 +534,6 @@ export default { if (regex.test(this.questionform.confident)) { // 如果输入的是中文,则清空输入框 this.$message.error('Confidential Comments to the Editor cannot be in Chinese.'); - return false; } } @@ -445,7 +562,6 @@ export default { wenziCount++; } } - if (blankCount + wenziCount <= 60) { this.$message.error('We encourage you to enrich your comment further to help improve the peer paper.'); this.$message({ @@ -627,4 +743,114 @@ export default { .css-138 { display: none; } */ + .invitation-expired-box{ + width: 100%; + height: 100%; + display: flex; + justify-content: center; + align-items: center; + } + .invitation-expired-card { + max-width: 1000px; + margin-bottom: 10%; + background-color: #fff; + padding: 30px; + border-radius: 8px; /* 轻微圆角 */ + box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); /* 柔和阴影 */ + } + + /* --- 稿件信息样式 --- */ + .manuscript-header { + border-bottom: 1px solid #eee; + padding-bottom: 15px; + margin-bottom: 25px; + } + + .manuscript-header h1 { + color: #303133; /* 深蓝色/专业色 */ + font-size: 20px; + margin: 0 0 5px 0; + font-weight: 700; + margin-top: 12px; + } + + .manuscript-meta { + color: #7f8c8d; /* 浅灰色元数据 */ + font-size: 0.9em; + margin-top: 5px; + } + + /* --- 提示框样式 --- */ + .notification-card { + border: 1px solid #e0e0e0; + padding: 30px; + text-align: center; + border-radius: 6px; + background-color: #fff; + margin-top: 30px; + padding-bottom: 50px; + } + + .icon { + font-size: 3.5em; + color: #f39c12; /* 橙色,表示过期/警告 */ + margin-bottom: 15px; + display: block; + font-weight: bold; + } + .notification-card-success .icon{ + color: #67c23a; + } + .notification-card-grey .icon{ + color: #d3d4d6; + margin-bottom: 25px; + } + + .notification-card h2 { + color: #e67e22; /* 稍深的橙色 */ + margin-top: 0; + margin-bottom: 30px; + font-weight: 700; + } + .notification-card-success h2 { + color: #67c23a; /* 稍深的橙色 */ + + } + .notification-card-grey h2 { + color: #909399; /* 稍深的橙色 */ + + } + + .notification-card p { + color: #555; + line-height: 1.6; + margin-bottom: 30px; + max-width: 600px; + margin-left: auto; + margin-right: auto; + } + + /* --- 按钮样式 (CTA) --- */ + .cta-button { + display: inline-block; + background-color: #006699; /* 专业深蓝色 */ + color: white; + padding: 12px 25px; + border-radius: 4px; + text-decoration: none; + font-size: 1.1em; + font-weight: 700; + transition: background-color 0.3s ease; + box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2); + border: none; + cursor: pointer; + } + + .cta-button:hover { + background-color: #00c286; /* 鼠标悬停时变浅 */ + } + + .cta-button i { + margin-right: 8px; + } diff --git a/src/main.js b/src/main.js index 27d88c6..bae5663 100644 --- a/src/main.js +++ b/src/main.js @@ -53,43 +53,60 @@ import 'quill/dist/quill.bubble.css' // 注册富文本编辑器组件为全局组件 Vue.use(VueQuillEditor) - - - async function loadJournalType() { - const localData = localStorage.getItem('journalType'); // 尝试从 localStorage 获取数据 - - if (!localData) { - try { - await api - .post('api/Articletype/getArticleType', {}) - .then((res) => { - - if (res.status == 1) { - localStorage.setItem('journalTypeData', JSON.stringify(res.data.base)); // 将数据存储到 localStorage - localStorage.setItem('journalTypeDataAll', JSON.stringify([...res.data.base, ...res.data.supplement])); // 将数据存储到 localStorage - - } - }) - await api - .post('api/Articletype/getMedicalType', {}) - .then((res) => { - - if (res.status == 1) { - localStorage.setItem('opMedicalListData', JSON.stringify(res.data)); // 将数据存储到 localStorage - - - } - }) - - - } catch (error) { - - } - } else { + // 1. 获取并尝试解析缓存数据 + const cachedString = localStorage.getItem('journalTypeData'); + let parsedData = null; + if (cachedString) { + try { + // 必须先解析 JSON 字符串 + parsedData = JSON.parse(cachedString); + } catch (e) { + console.error("缓存数据解析失败,将重新请求 API:", e); + } } + + // 2. 检查解析后的数据是否有效(是数组且长度大于 0) + if (parsedData && Array.isArray(parsedData) && parsedData.length > 0) { + // 缓存有效,直接返回缓存数据 + return parsedData; + } + + // 3. 如果缓存无效或不存在,执行 API 调用 + try { + // 第一个 API 调用,使用 await 接收结果 + const journalRes = await api.post('api/Articletype/getArticleType', {}); + if (journalRes.status === 1) { + // 存储 journal data + localStorage.setItem('journalTypeData', JSON.stringify(journalRes.data.base)); + localStorage.setItem('journalTypeDataAll', JSON.stringify([...journalRes.data.base, ...journalRes.data.supplement])); + } + + // 第二个 API 调用,串行执行 + const medicalRes = await api.post('api/Articletype/getMedicalType', {}); + if (medicalRes.status === 1) { + // 存储 medical data + localStorage.setItem('opMedicalListData', JSON.stringify(medicalRes.data)); + } + + // 4. 返回第一个 API 调用的主要数据 + if (journalRes.status === 1) { + return journalRes.data.base; + } + + } catch (error) { + // 集中处理 API 调用失败 + console.error('Error loading data:', error); + return []; // 失败时返回一个默认的空数组,避免程序崩溃 + } + + // 如果所有流程都没有返回,默认返回空数组 + return []; } + + + async function loadJournalList() { try { const localData = store.state.journalList; diff --git a/src/router/index.js b/src/router/index.js index cc136ec..384f533 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -24,7 +24,8 @@ export default new Router({ component: () => import( /* webpackChunkName: "dashboard" */ '../components/page/Dashboard_.vue'), meta: { - title: 'Personal Center' + title: 'Personal Center', + hideJournal: true } }, // { @@ -355,7 +356,8 @@ export default new Router({ component: () => import('../components/page/components/pendingPayment/success.vue'), meta: { title: 'Success', - hideJournal: true + hideJournal: true, + hideSidebar: true, } }, {