Compare commits
13 Commits
63a89b4af7
...
master
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8319777d3e | ||
|
|
71ec3c2ccd | ||
|
|
56dd707f9b | ||
|
|
d2fe34a7a3 | ||
|
|
2f921a4ea2 | ||
|
|
e109a84eff | ||
|
|
31da31b252 | ||
|
|
7c54b4f518 | ||
|
|
8fe397ff50 | ||
|
|
f9e29ad876 | ||
|
|
875d486ab5 | ||
|
|
a80897644e | ||
|
|
d518097f18 |
@@ -129,6 +129,12 @@ class Article extends Base
|
||||
}
|
||||
}
|
||||
$res[$key]['proof'] = $proof_state;
|
||||
//新增是否是草稿删除 20260204 start
|
||||
$res[$key]['is_draft'] = 2;
|
||||
if(!empty($val['accept_sn']) && substr($val['accept_sn'], 0, 5) === 'Draft'){
|
||||
$res[$key]['is_draft'] = 1;
|
||||
}
|
||||
//新增是否是草稿删除 20260204 end
|
||||
}
|
||||
|
||||
//返回数据
|
||||
@@ -585,6 +591,14 @@ class Article extends Base
|
||||
}
|
||||
}
|
||||
//查询终审意见 chengxiaoling 20250828 end
|
||||
//新增是否是草稿删除 20260204 start
|
||||
if(!empty($article_res)){
|
||||
$article_res['is_draft'] = 2;
|
||||
if(!empty($article_res['accept_sn']) && substr($article_res['accept_sn'], 0, 5) === 'Draft'){
|
||||
$article_res['is_draft'] = 1;
|
||||
}
|
||||
}
|
||||
//新增是否是草稿删除 20260204 end
|
||||
return json(['article' => $article_res, 'msg' => $article_msg, 'authors' => $author_res, 'suggest' => $suggest, 'transfer' => $transfer_res, 'transinfo' => $transfer_info, "major" => $major,'suggest_final' => $aFinal]);
|
||||
}
|
||||
|
||||
|
||||
@@ -1167,9 +1167,17 @@ class Finalreview extends Base
|
||||
if(empty($aReviewerFinal)){
|
||||
return json_encode(['status' => 3,'msg' => 'Review record does not exist or review has been completed']);
|
||||
}
|
||||
//查询审稿人基本信息
|
||||
$aWhere = ['user_id' => $iReviewerId];
|
||||
$aUser = Db::name('user')->field('realname')->where($aWhere)->find();
|
||||
$aUser = Db::name('user')->field('realname,email')->where($aWhere)->find();
|
||||
$aReviewerFinal['realname'] = empty($aUser['realname']) ? '' : $aUser['realname'];
|
||||
$aReviewerFinal['email'] = empty($aUser['email']) ? '' : $aUser['email'];
|
||||
//查询审稿人机构
|
||||
if(!empty($aUser)){
|
||||
$aWhere = ['reviewer_id' => $iReviewerId,'state' => 0];
|
||||
$aReviewerInfo = Db::name('user_reviewer_info')->field('company')->where($aWhere)->find();
|
||||
$aReviewerFinal['company'] = empty($aReviewerInfo['company']) ? '' : $aReviewerInfo['company'];
|
||||
}
|
||||
return json_encode(['status' => 1,'msg' => 'success','data' => $aReviewerFinal]);
|
||||
}
|
||||
|
||||
|
||||
@@ -45,6 +45,12 @@ class Preaccept extends Base
|
||||
}else{
|
||||
$list[$k]['is_repeat'] = 0;
|
||||
}
|
||||
if(strpos($v['refer_content'],'retraction')!==false||strpos($v['refer_content'],'retracted')!==false){
|
||||
$list[$k]['retract'] = 1;
|
||||
}else{
|
||||
$list[$k]['retract'] = 0;
|
||||
}
|
||||
|
||||
}
|
||||
$re["refers"] = $list;
|
||||
$re['repeat'] = empty($aRepeat) ? [] : $aRepeat;
|
||||
|
||||
@@ -260,22 +260,24 @@ class Production extends Base
|
||||
*/
|
||||
public function getProductionMains()
|
||||
{
|
||||
die("stop service!");
|
||||
// $data = $this->request->post();
|
||||
// $rule = new Validate([
|
||||
// "p_article_id" => "require"
|
||||
// ]);
|
||||
// if (!$rule->check($data)) {
|
||||
// return jsonError($rule->getError());
|
||||
// }
|
||||
// $p_info = $this->production_article_obj->where('p_article_id', $data['p_article_id'])->find();
|
||||
// die("stop service!");
|
||||
$data = $this->request->post();
|
||||
$rule = new Validate([
|
||||
"p_article_id" => "require"
|
||||
]);
|
||||
if (!$rule->check($data)) {
|
||||
return jsonError($rule->getError());
|
||||
}
|
||||
$p_info = $this->production_article_obj->where('p_article_id', $data['p_article_id'])->find();
|
||||
$frag = getArticleMains($p_info['article_id']);
|
||||
|
||||
// $frag = $this->getProductionMainImgs($data['p_article_id']);
|
||||
// if (count($frag) == 0) {
|
||||
// return jsonError("create error");
|
||||
// }
|
||||
// $re['mains'] = $frag;
|
||||
// $re['production'] = $p_info;
|
||||
// return jsonSuccess($re);
|
||||
$re['mains'] = $frag;
|
||||
$re['production'] = $p_info;
|
||||
return jsonSuccess($re);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -630,6 +632,11 @@ class Production extends Base
|
||||
} else {
|
||||
$list[$k]['is_repeat'] = 0;
|
||||
}
|
||||
if(strpos($v['refer_content'],'retraction')!==false||strpos($v['refer_content'],'retracted')!==false){
|
||||
$list[$k]['retract'] = 1;
|
||||
}else{
|
||||
$list[$k]['retract'] = 0;
|
||||
}
|
||||
}
|
||||
$re['refers'] = $list;
|
||||
$re['repeat'] = empty($aRepeat) ? [] : $aRepeat;
|
||||
@@ -815,6 +822,7 @@ class Production extends Base
|
||||
$pra['authors'] = json_encode($authors);
|
||||
$pra['organs'] = json_encode($organs);
|
||||
$res = object_to_array(json_decode(myPost($url, $pra)));
|
||||
|
||||
if ($res['code'] == 0) {
|
||||
$r_update['state'] = 2;
|
||||
$r_update['w_article_id'] = isset($res['data']['article_id']) ? $res['data']['article_id'] : 0;
|
||||
@@ -2240,9 +2248,15 @@ class Production extends Base
|
||||
return jsonError($rule->getError());
|
||||
}
|
||||
$info = $this->article_main_obj->where("am_id",$data['id'])->find();
|
||||
if(isset($data["code"])){
|
||||
$content = $data['code'];
|
||||
}else{
|
||||
$content = $info['content'];
|
||||
}
|
||||
|
||||
$production_info = $this->production_article_obj->where("article_id",$info['article_id'])->find();
|
||||
$refers = $this->production_article_refer_obj->where("p_article_id",$production_info['p_article_id'])->where('state',0)->order("index")->select();
|
||||
$res = $this->convertToLatex($info['content'],$refers);
|
||||
$res = $this->convertToLatex($content,$refers);
|
||||
echo $res;
|
||||
// return jsonSuccess([$res]);
|
||||
}
|
||||
@@ -2256,9 +2270,9 @@ class Production extends Base
|
||||
return '';
|
||||
}
|
||||
//单行处理公式内容
|
||||
$pattern = '/^<wmath\s+data-latex="([^"]*)">.*<\/wmath>$/';
|
||||
$pattern = '/^<wmath[^>]*?\s+data-latex="([^"]*)"[^>]*?>.*?<\/wmath>$/';
|
||||
if(preg_match($pattern, $content) === 1){
|
||||
$pattern1 = '/<wmath\s+data-latex="([^"]*)">/';
|
||||
$pattern1 = '/<wmath[^>]*?\s+data-latex="([^"]*)">/';
|
||||
if (preg_match($pattern1, $content, $matches)) {
|
||||
$latexContent = $matches[1];
|
||||
// 将 $$ 转换为 $,因为equation环境不需要$$
|
||||
@@ -3653,7 +3667,14 @@ class Production extends Base
|
||||
// 方法1: 使用pdflatex命令(推荐)
|
||||
// $command = "{$sLatexDir}pdflatex -include-directory=" . dirname($texFilePath) .
|
||||
// " -output-directory=" . $pdfDir . " " . escapeshellarg($texFilePath);
|
||||
$command = "pdflatex -output-directory=" . $pdfDir . " " . escapeshellarg($texFilePath);
|
||||
// $command = "pdflatex -output-directory=" . $pdfDir . " " . escapeshellarg($texFilePath);
|
||||
$sLatexDir = '/usr/bin/';//latex执行目录
|
||||
$command = sprintf(
|
||||
'%slualatex -interaction=nonstopmode -output-directory=%s %s 2>&1',
|
||||
rtrim($sLatexDir, '/') . '/', // /usr/bin/lualatex
|
||||
escapeshellarg($pdfDir), // 转义输出目录(含空格/特殊字符)
|
||||
escapeshellarg($texFilePath) // 转义tex文件路径
|
||||
);
|
||||
|
||||
$output = [];
|
||||
$returnVar = 0;
|
||||
@@ -4324,10 +4345,8 @@ class Production extends Base
|
||||
$queue = Queue::push('app\api\job\ArticleCreatePdf@fire', ['p_article_id' => $iPArticleId], 'ArticleCreatePdf');
|
||||
//生成长表格PDF
|
||||
$aLongTableId = empty($aResult['long_table_id']) ? [] : $aResult['long_table_id'];
|
||||
var_dump($aLongTableId);
|
||||
if(!empty($aLongTableId)){ //调用生成长表格队列
|
||||
$longtablequeue = Queue::push('app\api\job\ArticleCreateLongTable@fire', ['p_article_id' => $iPArticleId,'long_table_id' => $aLongTableId], 'ArticleCreateLongTable');
|
||||
var_dump($longtablequeue);
|
||||
}
|
||||
return json_encode(array('status' => 1,'msg' => 'tex file generated successfully'));
|
||||
}
|
||||
@@ -4438,4 +4457,54 @@ class Production extends Base
|
||||
Db::commit();
|
||||
return json_encode(array('status' => 1,'msg' => 'PDF generated successfully'));
|
||||
}
|
||||
/**
|
||||
* 获取排版生成PDF历史版本
|
||||
* @param p_article_id 文章ID
|
||||
*/
|
||||
public function getProductionArticlePdf($aParam = []){
|
||||
|
||||
//获取参数
|
||||
$aParam = empty($aParam) ? $this->request->post() : $aParam;
|
||||
|
||||
//必填值验证
|
||||
$iPArticleId = empty($aParam['p_article_id']) ? '' : $aParam['p_article_id'];
|
||||
if(empty($iPArticleId)){
|
||||
return json_encode(array('status' => 2,'msg' => 'Please select an article' ));
|
||||
}
|
||||
|
||||
//查询文章
|
||||
$aWhere = ['p_article_id' => $iPArticleId,'state' => ['in',[0,2]]];
|
||||
$aProductionArticle = Db::name('production_article')->field('article_id,pdf_id')->where($aWhere)->find();
|
||||
if(empty($aProductionArticle)){
|
||||
return json_encode(array('status' => 3,'msg' => 'No articles found' ));
|
||||
}
|
||||
$iArticleId = empty($aProductionArticle['article_id']) ? 0 : $aProductionArticle['article_id'];
|
||||
if(empty($iArticleId)){
|
||||
return json_encode(array('status' => 4,'msg' => 'Unbound article' ));
|
||||
}
|
||||
//日志查询
|
||||
$aWhere = ['article_id' => $iArticleId,'p_article_id' => $iPArticleId,'state' => 2];
|
||||
$aPdf = Db::name('production_article_pdf')->field('pdf_id,url,create_time')->where($aWhere)->select();
|
||||
return json_encode(array('status' => 1,'msg' => 'success','data' => $aPdf));
|
||||
}
|
||||
/**
|
||||
* 获取生产文章信息
|
||||
* @param p_article_id 文章ID
|
||||
*/
|
||||
public function getProductionArticle($aParam = []){
|
||||
|
||||
//获取参数
|
||||
$aParam = empty($aParam) ? $this->request->post() : $aParam;
|
||||
|
||||
//必填值验证
|
||||
$iPArticleId = empty($aParam['p_article_id']) ? '' : $aParam['p_article_id'];
|
||||
if(empty($iPArticleId)){
|
||||
return json_encode(array('status' => 2,'msg' => 'Please select an article' ));
|
||||
}
|
||||
|
||||
//查询文章
|
||||
$aWhere = ['p_article_id' => $iPArticleId,'state' => ['in',[0,2]]];
|
||||
$aProductionArticle = Db::name('production_article')->field('pdf_id,file_sub_table')->where($aWhere)->find();
|
||||
return json_encode(array('status' => 1,'msg' => 'success','data' => $aPdf));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -199,48 +199,48 @@ class Typeset extends Base
|
||||
/**
|
||||
* 推送文章到官网系统
|
||||
*/
|
||||
public function pushArticleToSystem(){
|
||||
die('Service suspension!');
|
||||
$data = $this->request->post();
|
||||
$rule = new Validate([
|
||||
'on_id'=>'require'
|
||||
]);
|
||||
if(!$rule->check($data)){
|
||||
return jsonError($rule->getError());
|
||||
}
|
||||
$on_info = $this->online_obj->where('on_id',$data['on_id'])->find();
|
||||
$ts_info = $this->ts_obj->where('article_id',$on_info['article_id'])->where('ts_state',0)->find();
|
||||
$article_info = $this->article_obj->where('article_id',$on_info['article_id'])->find();
|
||||
$journal_info = $this->journal_obj->where('journal_id',$article_info['journal_id'])->find();
|
||||
$authors = $this->article_author_obj->where('article_id',$article_info['article_id'])->where('state',0)->select();
|
||||
//check信息是否完整
|
||||
if($on_info['journal_stage_id']==''||$on_info['on_doi']==''||$on_info['abstract']==''||$on_info['npp']==''){
|
||||
return jsonError('信息不全!');
|
||||
}
|
||||
//发送推送请求
|
||||
// $url = "http://www.journal.com/master/Article/addArticleForSubmission";
|
||||
$url = 'http://journalapi.tmrjournals.com/public/index.php/master/Article/addArticleForSubmission';
|
||||
$pra = [];
|
||||
$pra['title'] = $ts_info['ts_title'];
|
||||
$pra['journal_stage_id'] = $on_info['journal_stage_id'];
|
||||
$pra['issn'] = $journal_info['issn'];
|
||||
$pra['type'] = translateType($article_info['type']);
|
||||
$pra['doi'] = $on_info['on_doi'];
|
||||
$pra['abstract'] = $on_info['abstract'];
|
||||
$pra['pub_date'] = $ts_info['online_date'];
|
||||
$pra['file_pdf'] = $article_info['pdf_url'];
|
||||
$pra['keywords'] = $ts_info['keywords'];
|
||||
$pra['npp'] = $on_info['npp'];
|
||||
$pra['authors'] = json_encode($authors);
|
||||
|
||||
$res = object_to_array(json_decode(myPost($url, $pra)));
|
||||
if($res['code']==0){
|
||||
$this->online_obj->where('on_id',$data['on_id'])->update(['has_push'=>1]);
|
||||
return jsonSuccess([]);
|
||||
}else{
|
||||
return jsonError('system error:'.$res['msg']);
|
||||
}
|
||||
}
|
||||
// public function pushArticleToSystem(){
|
||||
// die('Service suspension!');
|
||||
// $data = $this->request->post();
|
||||
// $rule = new Validate([
|
||||
// 'on_id'=>'require'
|
||||
// ]);
|
||||
// if(!$rule->check($data)){
|
||||
// return jsonError($rule->getError());
|
||||
// }
|
||||
// $on_info = $this->online_obj->where('on_id',$data['on_id'])->find();
|
||||
// $ts_info = $this->ts_obj->where('article_id',$on_info['article_id'])->where('ts_state',0)->find();
|
||||
// $article_info = $this->article_obj->where('article_id',$on_info['article_id'])->find();
|
||||
// $journal_info = $this->journal_obj->where('journal_id',$article_info['journal_id'])->find();
|
||||
// $authors = $this->article_author_obj->where('article_id',$article_info['article_id'])->where('state',0)->select();
|
||||
// //check信息是否完整
|
||||
// if($on_info['journal_stage_id']==''||$on_info['on_doi']==''||$on_info['abstract']==''||$on_info['npp']==''){
|
||||
// return jsonError('信息不全!');
|
||||
// }
|
||||
// //发送推送请求
|
||||
// // $url = "http://www.journal.com/master/Article/addArticleForSubmission";
|
||||
// $url = 'http://journalapi.tmrjournals.com/public/index.php/master/Article/addArticleForSubmission';
|
||||
// $pra = [];
|
||||
// $pra['title'] = $ts_info['ts_title'];
|
||||
// $pra['journal_stage_id'] = $on_info['journal_stage_id'];
|
||||
// $pra['issn'] = $journal_info['issn'];
|
||||
// $pra['type'] = translateType($article_info['type']);
|
||||
// $pra['doi'] = $on_info['on_doi'];
|
||||
// $pra['abstract'] = $on_info['abstract'];
|
||||
// $pra['pub_date'] = $ts_info['online_date'];
|
||||
// $pra['file_pdf'] = $article_info['pdf_url'];
|
||||
// $pra['keywords'] = $ts_info['keywords'];
|
||||
// $pra['npp'] = $on_info['npp'];
|
||||
// $pra['authors'] = json_encode($authors);
|
||||
//
|
||||
// $res = object_to_array(json_decode(myPost($url, $pra)));
|
||||
// if($res['code']==0){
|
||||
// $this->online_obj->where('on_id',$data['on_id'])->update(['has_push'=>1]);
|
||||
// return jsonSuccess([]);
|
||||
// }else{
|
||||
// return jsonError('system error:'.$res['msg']);
|
||||
// }
|
||||
// }
|
||||
|
||||
/**
|
||||
* 编辑online信息
|
||||
|
||||
@@ -105,6 +105,7 @@ page={{stage_page}},%号
|
||||
}
|
||||
}
|
||||
//子刊信息
|
||||
$aJournalStage = [];
|
||||
$iJournalStageId = empty($aProductionArticle['journal_stage_id']) ? 0 : $aProductionArticle['journal_stage_id'];
|
||||
if(!empty($iJournalStageId)){
|
||||
$aJournalStage = $this->getJournalStage(['journal_stage_id' => $iJournalStageId]);
|
||||
@@ -195,21 +196,23 @@ page={{stage_page}},%号
|
||||
//文章图片地址
|
||||
$sIcon = empty($aProductionArticle['icon']) ? '' : $aProductionArticle['icon'];
|
||||
if(!empty($sIcon)){
|
||||
// $sIconUrl = rtrim(ROOT_PATH).$this->sArticleIcon.'/'.$sIcon;
|
||||
// if(file_exists($sIconUrl)){
|
||||
// $sIcon = '\KeywordImage{'.$sIconUrl.'}';
|
||||
// }else{
|
||||
// $sIcon = '';
|
||||
// }
|
||||
//下载图片
|
||||
$sImagePath = trim($this->sSubmissionUrl,'/').$this->sArticleIcon.'/'.$sIcon;
|
||||
$aImageInfo = $this->getImage($sImagePath,$aProductionArticle['article_id']);
|
||||
if(!empty($aImageInfo['data'])){
|
||||
$aImageInfo['data'] = './image/'.basename($aImageInfo['data']);
|
||||
$sIcon = '\KeywordImage{'.$aImageInfo['data'].'}';
|
||||
$sIconUrl = ROOT_PATH.trim($this->sArticleIcon,'/').'/'.$sIcon;
|
||||
if(file_exists($sIconUrl)){
|
||||
$sIconUrl = str_replace(ROOT_PATH.'public/', '', $sIconUrl);
|
||||
$sIconUrl = '../../'.$sIconUrl;
|
||||
$sIcon = '\KeywordImage{'.$sIconUrl.'}';
|
||||
}else{
|
||||
$sIcon = '';
|
||||
}
|
||||
// //下载图片
|
||||
// $sImagePath = trim($this->sSubmissionUrl,'/').$this->sArticleIcon.'/'.$sIcon;
|
||||
// $aImageInfo = $this->getImage($sImagePath,$aProductionArticle['article_id']);
|
||||
// if(!empty($aImageInfo['data'])){
|
||||
// $aImageInfo['data'] = './image/'.basename($aImageInfo['data']);
|
||||
// $sIcon = '\KeywordImage{'.$aImageInfo['data'].'}';
|
||||
// }else{
|
||||
// $sIcon = '';
|
||||
// }
|
||||
}
|
||||
$aSearch['{{article_icon}}'] = $sIcon;
|
||||
$aSearch['{{keywords}}'] = $sKeywords;
|
||||
@@ -255,6 +258,7 @@ page={{stage_page}},%号
|
||||
//查询正文信息
|
||||
$aWhere = ['article_id' => $aProductionArticle['article_id'],'state' => 0];
|
||||
$aArticleMain = Db::name('article_main')->field('am_id,article_id,type,content,ami_id,amt_id,is_h1,is_h2,is_h3,sort')->where($aWhere)->order('sort')->select();
|
||||
|
||||
if(!empty($aArticleMain)){
|
||||
|
||||
//查询图片
|
||||
@@ -305,7 +309,13 @@ page={{stage_page}},%号
|
||||
}
|
||||
if($value['is_h1'] == 0 && $value['is_h2'] == 0 && $value['is_h3'] == 0){
|
||||
if($value['type'] == 0 ){
|
||||
$sMain .= $this->dealContent($value['content'],$aReferences)."\\par\n";
|
||||
//处理内容
|
||||
$sMainContent = $this->dealContent($value['content'],$aReferences);
|
||||
//替换myh3标签
|
||||
$contentpattern = '/<myh3>(.*?)<\/myh3>/is';
|
||||
$contentreplacement = '\\subsubsection{$1}';
|
||||
$sMainContent = preg_replace($contentpattern, $contentreplacement, $sMainContent);
|
||||
$sMain .= $sMainContent."\\par\n";
|
||||
}
|
||||
if($value['type'] == 1 ){//图片
|
||||
$aImageInfo = empty($aArticleMainImage[$value['ami_id']]) ? [] : $aArticleMainImage[$value['ami_id']];
|
||||
@@ -313,21 +323,20 @@ page={{stage_page}},%号
|
||||
continue;
|
||||
}
|
||||
|
||||
// $sIconUrl = rtrim(ROOT_PATH).$this->sArticleIcon.'/'.$sIcon;
|
||||
// if(file_exists($sIconUrl)){
|
||||
// $sIcon = '\KeywordImage{'.$sIconUrl.'}';
|
||||
// }else{
|
||||
// $sIcon = '';
|
||||
// }
|
||||
//下载图片
|
||||
$sImagePath = trim($this->sSubmissionUrl,'/').$this->sArticleMainImage.'/'.$aImageInfo['url'];
|
||||
$aResult = $this->getImage($sImagePath,$aProductionArticle['p_article_id']);
|
||||
if(empty($aResult['data'])){
|
||||
$sMainImageUrl = ROOT_PATH.trim($this->sArticleMainImage,'/').'/'.$aImageInfo['url'];
|
||||
if(!file_exists($sMainImageUrl)){
|
||||
continue;
|
||||
}
|
||||
// //下载图片
|
||||
// $sImagePath = trim($this->sSubmissionUrl,'/').$this->sArticleMainImage.'/'.$aImageInfo['url'];
|
||||
// $aResult = $this->getImage($sImagePath,$aProductionArticle['article_id']);
|
||||
// if(empty($aResult['data'])){
|
||||
// continue;
|
||||
// }
|
||||
// $aImageSearch = ['{{img_url}}' => $aResult['data'],'{{img_title}}' => $aImageInfo['note'],'{{img_fig_sim}}' => 'img_fig_sim_'.$value['ami_id']];
|
||||
// $sImageTempalteInfo = str_replace(array_keys($aImageSearch), array_values($aImageSearch), $sImageTempalte);
|
||||
$aImageInfo['image_url'] = $aResult['data'];
|
||||
// $aImageInfo['image_url'] = $aResult['data'];
|
||||
$aImageInfo['image_url'] = $sMainImageUrl;
|
||||
$aDealImage = $this->dealImage($aImageInfo);
|
||||
if(empty($aDealImage['data'])){
|
||||
continue;
|
||||
@@ -353,7 +362,6 @@ page={{stage_page}},%号
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
$aSearch['{{article_main}}'] = empty($sMain) ? '' : $sMain."\n";
|
||||
//模版内容替换
|
||||
$sTemplateInfo = str_replace(array_keys($aSearch), array_values($aSearch), $sTemplateInfo);
|
||||
@@ -641,7 +649,8 @@ page={{stage_page}},%号
|
||||
$isWideImage = $imageWidth > $wideImageThreshold;
|
||||
|
||||
// 生成LaTeX图片代码
|
||||
$sImageUrl = './image/'.basename($sImageUrl);
|
||||
$sImageUrl = str_replace(ROOT_PATH.'public/', '', $sImageUrl);
|
||||
$sImageUrl = '../../'.$sImageUrl;
|
||||
if ($isWideImage) {
|
||||
$latexLines[] = "\\begin{figure*}[htbp]"; // 使用figure*环境实现两栏
|
||||
$latexLines[] = " \\centering";
|
||||
|
||||
Reference in New Issue
Block a user