1
This commit is contained in:
@@ -203,7 +203,13 @@ class Article extends Controller {
|
|||||||
if($article_info['html_type']!=2){
|
if($article_info['html_type']!=2){
|
||||||
return jsonError("type error");
|
return jsonError("type error");
|
||||||
}
|
}
|
||||||
$re['mains'] = getArticleMainsFor2($data['article_id']);
|
|
||||||
|
$ree = getArticleMainsFor2($data['article_id']);
|
||||||
|
if($ree==[]){
|
||||||
|
return jsonError("not find");
|
||||||
|
}
|
||||||
|
|
||||||
|
$re['mains'] = $ree;
|
||||||
$re['refers'] = getArticleRefers($data['article_id']);
|
$re['refers'] = getArticleRefers($data['article_id']);
|
||||||
return jsonSuccess($re);
|
return jsonSuccess($re);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -233,7 +233,7 @@ function getArticleMainsFor2($article_id){
|
|||||||
$url = "http://api.tmrjournals.com/public/index.php/api/Web/getArticleMainsForJournal";
|
$url = "http://api.tmrjournals.com/public/index.php/api/Web/getArticleMainsForJournal";
|
||||||
$program['article_id'] = $article_id;
|
$program['article_id'] = $article_id;
|
||||||
$res = object_to_array(json_decode(myPost($url, $program)));
|
$res = object_to_array(json_decode(myPost($url, $program)));
|
||||||
$refers = isset($res['data']['refers']) ? $res['data']['refers'] : [];
|
$refers = isset($res['data']['list']) ? $res['data']['list'] : [];
|
||||||
return $refers;
|
return $refers;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user