From 5edf128cfb8dc7ad2df98d6a1dff1f77a3e4847d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A7=8B=E4=BA=8E=E5=88=9D=E8=A7=81?= <752204717@qq.com> Date: Tue, 10 Feb 2026 09:36:35 +0800 Subject: [PATCH] =?UTF-8?q?1=E3=80=81=E5=AE=A1=E7=A8=BF=E4=BA=BA14?= =?UTF-8?q?=E5=A4=A9=E8=B6=85=E6=97=B6=20=E9=87=8D=E6=96=B0=E5=AE=A1?= =?UTF-8?q?=E7=A8=BF=E9=82=80=E8=AF=B7=202=E3=80=81nbsp=20=E8=BD=AC?= =?UTF-8?q?=E6=8D=A2=203=E3=80=81H3=E6=A0=87=E8=AE=B0=E4=B8=BAmyh3=204?= =?UTF-8?q?=E3=80=81=E6=96=87=E7=AB=A0=E8=AF=A6=E6=83=85=E5=AE=A1=E7=A8=BF?= =?UTF-8?q?=E5=92=8C=E7=BC=96=E5=A7=94=E9=82=AE=E7=AE=B1=E6=9C=BA=E6=9E=84?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=205=E3=80=81=E7=A8=BF=E5=8F=B7=E5=BC=80?= =?UTF-8?q?=E5=A4=B4=E4=B8=BADraft=20=E7=8A=B6=E6=80=81=E4=B8=BAReject->Aw?= =?UTF-8?q?aiting=20Submission=206=E3=80=81=E4=BD=9C=E8=80=85=E7=AB=AF?= =?UTF-8?q?=E7=A8=BF=E4=BB=B6=E9=87=8D=E5=A4=8D=EF=BC=88=E6=A0=87=E9=A2=98?= =?UTF-8?q?=EF=BC=89=207=E3=80=81produce=20=E5=A2=9E=E5=8A=A0=20=E9=80=9A?= =?UTF-8?q?=E8=AE=AF=E4=BD=9C=E8=80=85=E8=AF=A6=E7=BB=86=E5=9C=B0=E5=9D=80?= =?UTF-8?q?=208=E3=80=81produce=20=E5=A2=9E=E5=8A=A0=20=E6=98=AF=E5=90=A6?= =?UTF-8?q?=E6=98=BE=E7=A4=BA=E5=9B=BE=E6=96=87=E6=91=98=E8=A6=811?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/index.js | 4 +- src/components/common/common.vue | 4 +- src/components/common/langs/en.js | 3 +- src/components/common/langs/zh.js | 1 + src/components/page/GenerateCharts.vue | 74 ++- src/components/page/articleDetailEditor.vue | 17 +- src/components/page/articleList.vue | 8 +- src/components/page/articleListEditor_A.vue | 5 +- src/components/page/articleListEditor_B1.vue | 491 +++++++++------ src/components/page/articleProcess.vue | 2 +- .../OnlineProofreading/catalogue.vue | 2 +- .../page/components/Tinymce/index.vue | 596 +++++++++--------- src/components/page/components/table/word.vue | 8 +- .../components/table/wordHtmlTypesetting.vue | 2 +- src/components/page/per_text.vue | 5 +- vue.config.js | 4 +- 16 files changed, 680 insertions(+), 546 deletions(-) diff --git a/src/api/index.js b/src/api/index.js index 487fb66..525753d 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/components/common/common.vue b/src/components/common/common.vue index d0b6e1c..9bac70a 100644 --- a/src/components/common/common.vue +++ b/src/components/common/common.vue @@ -13,9 +13,7 @@ const baseUrl = '/'; //测试环境 -// const mediaUrl = 'http://tougaotest.tmrjournals.com/public/'; -// // const mediaUrl = 'http://zmzm.tougao.dev.com/public/'; -// const baseUrl = '/api'; + ////新正式环境 // const mediaUrl = 'http://mytest.tmrjournals.com/public/'; diff --git a/src/components/common/langs/en.js b/src/components/common/langs/en.js index 237e068..1773b4b 100644 --- a/src/components/common/langs/en.js +++ b/src/components/common/langs/en.js @@ -290,12 +290,13 @@ const en = { state1: 'With editor', state2: 'Under review', state3: 'Reject', + stateDraft: 'Awaiting Submission', state4: 'Revision', state5: 'Accept', state6: 'Pre-accept', state8: 'Final Decision', act1: 'Dealing', - act2: 'Finished' + act2: 'Finished', }, evaluationsis: { EmploymentRate: 'Employment Rate', diff --git a/src/components/common/langs/zh.js b/src/components/common/langs/zh.js index 40ce74e..cc1c374 100644 --- a/src/components/common/langs/zh.js +++ b/src/components/common/langs/zh.js @@ -276,6 +276,7 @@ const zh = { state1: '已受理', state2: '送审中', state3: '拒稿', + stateDraft: '待提交', state4: '退修', state5: '接收', state6: '预接收', diff --git a/src/components/page/GenerateCharts.vue b/src/components/page/GenerateCharts.vue index 67e1a05..b08fb99 100644 --- a/src/components/page/GenerateCharts.vue +++ b/src/components/page/GenerateCharts.vue @@ -780,9 +780,8 @@ export default { var that = this; var str = content.replace(/^
\s*(.*?)\s*<\/p>$/, '$1').trim();
- if (str.replace(/
/gi, '').trim() === '') {
- str = '';
- }
+ str = str.replace(/
/gi, '');
+
str = await that.$commonJS.decodeHtml(str);
await that.$api
@@ -1138,7 +1137,7 @@ export default {
});
},
async addCommentSetting(content) {
-
+
await this.$api
.post(this.urlList.addComment, {
am_id: content.am_id,
@@ -1161,8 +1160,10 @@ export default {
});
},
async addComment(content) {
-
- var str = content.replace(/^
(.*?)<\/p>$/, '$1') ? content.replace(/^
(.*?)<\/p>$/, '$1') : '';
+
+ var str= this.$commonJS.transformHtmlString(content)
+ str=str.replace(/
/gi, '');
+ console.log("🚀 ~ addComment ~ content:", str);
if (str == '') {
this.$message({
type: 'warning',
@@ -1884,6 +1885,9 @@ export default {
// 确定保存图片
async savePic() {
var str = this.picStyle1.note ? await this.$commonJS.decodeHtml(this.picStyle1.note) : '';
+
+
+
var titleStr = this.picStyle1.title ? await this.$commonJS.decodeHtml(this.picStyle1.title) : '';
if (!this.picStyle.picUrl) {
@@ -1894,6 +1898,8 @@ export default {
this.$message.error('Please enter a title');
return;
}
+ str = str.replace(/
/gi, '');
+ titleStr = titleStr.replace(/
/gi, '');
const loading = this.$loading({
lock: true,
text: 'Loading...',
@@ -1969,28 +1975,42 @@ export default {
},
async saveTable(content) {
const cleanTableData = (tableList) => {
- if (tableList.length == 0) {
- return [];
- } else {
- // 假设第一行是表头,保存表头
- const header = tableList[0];
+ if (tableList.length == 0) {
+ return [];
+ } else {
+ // 定义清理函数:去掉所有 br 标签和 TinyMCE 占位符
+ const cleanText = (text) => {
+ if (!text) return "";
+ return text.replace(/
/gi, '').trim();
+ };
- // 从第二行开始,移除与表头相同的行
- const cleanedTable = tableList.filter((row, index) => {
- // 如果是第一行,则保留
- if (index === 0) return true;
+ // 1. 获取处理后的干净表头
+ const header = tableList[0].map(cell => ({
+ ...cell,
+ text: cleanText(cell.text)
+ }));
- // 比较当前行的每个单元格与表头是否相同
- const isHeaderRow = row.every((cell, cellIndex) => {
- return cell.text === header[cellIndex].text;
- });
+ // 2. 过滤逻辑
+ const cleanedTable = tableList.map((row) => {
+ // 首先:把每一行里的每个 cell.text 里的
都去掉
+ return row.map(cell => ({
+ ...cell,
+ text: cleanText(cell.text)
+ }));
+ }).filter((row, index) => {
+ if (index === 0) return true;
- return !isHeaderRow; // 只保留与表头不同的行
- });
+ // 3. 此时比较的就是没有
的文本了
+ const isHeaderRow = row.every((cell, cellIndex) => {
+ return cell.text === header[cellIndex].text;
+ });
- return cleanedTable;
- }
- };
+ return !isHeaderRow;
+ });
+
+ return cleanedTable;
+ }
+};
var cleanedTableList = content.table ? content.table : [];
cleanedTableList = cleanTableData(content.table);
@@ -2014,11 +2034,15 @@ export default {
spinner: 'el-icon-loading',
background: 'rgba(0, 0, 0, 0.7)'
});
+ strNote = strNote.replace(/
/gi, '');
+ strTitle = strTitle.replace(/
/gi, '');
+ var tableStr=JSON.stringify(cleanedTableList)
+
if (this.lineStyle.visiTitle == 'Edit Table') {
this.$api
.post(this.urlList.editTable, {
amt_id: this.lineStyle.amt_id,
- table_data: JSON.stringify(cleanedTableList),
+ table_data: tableStr,
html_data: content.html_data,
note: strNote,
title: strTitle
diff --git a/src/components/page/articleDetailEditor.vue b/src/components/page/articleDetailEditor.vue
index 694d4b0..965be5d 100644
--- a/src/components/page/articleDetailEditor.vue
+++ b/src/components/page/articleDetailEditor.vue
@@ -928,7 +928,7 @@
\s*(.*?)\s*<\/p>$/, '$1').trim(); - + content = await this.$commonJS.decodeHtml(content); content = content.replace(/ |\u00A0/g, ' '); - + return content; }, // 1----保存稿件信息 async ZsSaveMes() { - var abstractStr = ''; var mhooStr = ''; var traditionStr = ''; if (this.detailMes.journal_stage_id == 0) { this.$message.error('Please select an installment!'); return; - } if (this.tradition!='') { + } + if (this.tradition != '') { traditionStr = await this.abstractFormat(this.tradition); - } - if (this.mhooStr!='') { + } + if (this.mhooStr != '') { mhooStr = await this.abstractFormat(this.mhooStr); } - + if (this.abstract == '') { this.$message.error('Please input abstract!'); return false; } else { abstractStr = await this.abstractFormat(this.abstract); } - + this.$refs.Mes_Form.validate((valid) => { if (valid) { this.$api - .post('api/Production/editProduction', { ...this.detailMes, abstract: abstractStr, mhoo: mhooStr, tradition: traditionStr }) + .post('api/Production/editProduction', { + ...this.detailMes, + abstract: abstractStr, + mhoo: mhooStr, + tradition: traditionStr + }) .then((res) => { if (res.code == 0) { this.$message.success(`Successfully save the article!`); @@ -2025,6 +2092,10 @@ export default { // 2----添加作者操作 add_Authorclick(index, row) { + if (this.schoolData.length == 0) { + this.$message.error('Please provide at least one institutional affiliation.'); + return; + } this.aid = index; this.addFomauthor = { is_first: '0', @@ -2035,7 +2106,6 @@ export default { this.addAuthor = true; }, authorAdd(addFomauthor) { - console.log(this.addFomauthor); this.$refs.add_Author.validate((valid) => { if (valid) { this.$api @@ -2982,7 +3052,6 @@ export default { // 获取文章信息 this.$api .post('api/Preaccept/getArticleMains', { - article_id: this.detailMes.article_id }) .then((res) => { @@ -3171,35 +3240,43 @@ export default { min-height: 60px; } .left-panel { - flex: 1; /* 左侧占据剩余空间 */ - margin-right: 40px; - border-right: 1px dashed #eee; /* 加一条虚线分隔线 */ - padding-right: 20px; + flex: 1; /* 左侧占据剩余空间 */ + margin-right: 40px; + border-right: 1px dashed #eee; /* 加一条虚线分隔线 */ + padding-right: 20px; } .right-panel { - width: 48%; /* 右侧固定宽度 */ + width: 48%; /* 右侧固定宽度 */ } .right-panel h5 { font-weight: normal; } .console-card { - background: #f9f9f9; - border-radius: 8px; - padding: 20px; - border: 1px solid #ebeef5; + background: #f9f9f9; + border-radius: 8px; + padding: 20px; + border: 1px solid #ebeef5; } .load_pdf { - display: flex; - align-items: center; - margin-bottom: 15px; - padding: 10px; - transition: background 0.3s; + display: flex; + align-items: center; + margin-bottom: 15px; + padding: 10px; + transition: background 0.3s; } .load_pdf:hover { - background: #f5f7fa; + background: #f5f7fa; +} +.loadTinymceBox { + height: 160px; line-height: 160px; text-align: center; border: 2px solid #eee; + border-radius: 10px; + color: #c0c4cc !important; +} +.loadTinymceBox *{ + color: #c0c4cc !important; }