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 d0e0630..2038279 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 b6c43d3..e829cd5 100644 --- a/src/components/page/articleDetailEditor.vue +++ b/src/components/page/articleDetailEditor.vue @@ -1859,19 +1859,14 @@ export default { // 算终审分 finalCount(arry) { + var ratedLength = arry.map(item => item.rated).filter(rated => rated&&rated>0).length; let str = 0; - let sgr = 0; let all = 0; - let j = 0; // null 评分人数 + let sgr = 0; for (let i = 0; i < arry.length; i++) { - if (arry[i].rated == null) { - j += 1; - continue; - } else { - all += Number(arry[i].rated); - } + all += Number(arry[i].rated); } - str = (all / (arry.length - j)).toFixed(1); + str = (all / ratedLength).toFixed(1); sgr = ((Number(str) + Number(this.form.scoring)) / 2).toFixed(1); return sgr; }, diff --git a/src/components/page/editPublicRefRdit.vue b/src/components/page/editPublicRefRdit.vue index 0e486bb..f23f935 100644 --- a/src/components/page/editPublicRefRdit.vue +++ b/src/components/page/editPublicRefRdit.vue @@ -1,434 +1,432 @@