From 9252f6b831a95f365feb8ae885b74b24fb709aa2 Mon Sep 17 00:00:00 2001
From: wangjinlei <751475802@qq.com>
Date: Wed, 24 Mar 2021 14:45:06 +0800
Subject: [PATCH] 20201112
---
application/api/controller/Article.php | 36 ++++++++++++++++++++++++-
application/api/controller/Reviewer.php | 7 +++++
application/api/controller/User.php | 10 ++++---
3 files changed, 49 insertions(+), 4 deletions(-)
diff --git a/application/api/controller/Article.php b/application/api/controller/Article.php
index b32afce..6e07593 100644
--- a/application/api/controller/Article.php
+++ b/application/api/controller/Article.php
@@ -529,7 +529,7 @@ class Article extends Controller {
$tt .= '
Yours sincerely,
';
$tt .= 'Sincerely,
Editorial Office
';
}
- }else if($data['state']==5){//录用
+ }else if($data['state']==5&&$journal_info['journal_id']==9){//录用
$tt = 'Manuscript ID: '.$article_info['accept_sn'].'
';
$tt .= 'Manuscript Title: '.$article_info['title'].'
';
$tt .= 'Authors’ Name: '.self::getArticleAuthors($article_info['article_id']).'
';
@@ -808,6 +808,25 @@ class Article extends Controller {
$tt .= 'Please check the new manuscript in the submission system.';
sendEmail($editor_info['email'], $journal_info['title'], $journal_info['title'], $tt,$journal_info['email'],$journal_info['epassword']);
+ //发送邮件给作者,表示感谢
+ $tt1 = 'Dear '.($user_res['realname']==''?'Authors':$user_res['realname']).',
';
+ $tt1 .= 'Thank you for submitting your manuscript entitled "'.$data['title'].'". Your submission has been assigned the following tracking number:'.$inset_data['accept_sn'].'. We will be in touch again as soon as we have reached a decision. Please quote the tracking number in any communication. This e-mail simply acknowledges receipt of your submission. If the editors decide for editorial reasons that the paper is unsuitable for publication in '.$journal_info['title'].', you will be informed as soon as possible.
';
+ if($journal_info['journal_id']==9){//life research 期刊发送收到文章邮件
+ $tt1 .= 'Life Research applies the CC BY-NC 4.0 license. Full details of the policy can be found at https://www.tmrjournals.com/notice.html?J_num=14&footer_id=123. Authors should read Guide to Authors carefully before submitting.
';
+ $tt1 .= 'You may check on the status of this manuscript in the Submission System. If you encounter any problems, please contact liferes@tmrjournals.com.
';
+ $tt1 .= 'Thank you for choosing to submit your manuscript to Life Research.
';
+ $tt1 .= 'Yours sincerely,
Haoran Zhang
';
+ $tt1 .= 'Manuscript Administration, Life Research
https://www.tmrjournals.com/lr/';
+ }else{//其他期刊发送邮件
+ $tt1 .= 'You may check on the status of this manuscript in the Submission System. If you encounter any problems, please contact '.$journal_info['email'].'.
';
+ $tt1 .= 'Thank you for choosing to submit your manuscript to '.$journal_info['title'].'.
';
+ $tt1 .= 'Sincerely,
Editorial Office
';
+ $tt1 .= $journal_info['title'].'
';
+ $tt1 .= 'Email: '.$journal_info['email'].'
';
+ $tt1 .= 'Website: '.$journal_info['website'];
+ }
+ sendEmail($user_res['email'],$journal_info['title'], $journal_info['title'], $tt1,$journal_info['email'],$journal_info['epassword']);
+
//增加用户操作log
$log_data['user_id'] = $user_res['user_id'];
$log_data['type'] = 0;
@@ -939,6 +958,21 @@ class Article extends Controller {
return json(['code' => 1]);
}
}
+
+ /**
+ * 获取文章数通过期刊issn号
+ */
+ public function getArticleForJournal(){
+ $data = $this->request->post();
+ $journal_info = $this->journal_obj->where('issn',$data['issn'])->find();
+ $list = $this->article_obj
+ ->where('journal_id',$journal_info['journal_id'])
+ ->where('ctime','>',$data['ctime'])
+ ->select();
+
+ $re['articles'] = $list;
+ return jsonSuccess($re);
+ }
/**
* 存储article文件历史信息
diff --git a/application/api/controller/Reviewer.php b/application/api/controller/Reviewer.php
index baa045d..bb6b392 100644
--- a/application/api/controller/Reviewer.php
+++ b/application/api/controller/Reviewer.php
@@ -163,6 +163,13 @@ class Reviewer extends Controller {
$file_list = $this->article_file_obj->where('article_id',$article_rev_info['article_id'])->where('type_name','manuscirpt')->order('file_id desc')->limit(1)->select();
return json(['data'=>$file_list]);
}
+
+ public function getBFilelistByID(){
+ $rev_id = $this->request->post('revid');
+ $article_rev_info = $this->article_reviewer_obj->where('art_rev_id',$rev_id)->find();
+ $file_list = $this->article_file_obj->where('article_id',$article_rev_info['article_id'])->where('type_name','picturesAndTables')->order('file_id desc')->limit(1)->select();
+ return json(['data'=>$file_list]);
+ }
/**
* 获取文章审稿实例详情(审稿人,编辑)
diff --git a/application/api/controller/User.php b/application/api/controller/User.php
index e8c5e80..27fbf99 100644
--- a/application/api/controller/User.php
+++ b/application/api/controller/User.php
@@ -112,9 +112,13 @@ class User extends Controller {
$inser_data['ctime'] = time();
$this->user_obj->insert($inser_data);
//发送注册成功邮件
- $tt = "Dear author,You have successfully registered
";
- $content = $tt . '
Username:' . $account . '
Password:' . $data['password'] . '
Username:' . $account . '
Password:' . $data['password'] . '