This commit is contained in:
wangjinlei
2023-07-07 09:24:05 +08:00
parent b989916102
commit a4c92e437a
3 changed files with 213 additions and 89 deletions

View File

@@ -59,7 +59,26 @@ class Publish extends Base
$pra['pageIndex'] = $data['pageIndex'];
$pra['pageSize'] = $data['pageSize'];
$res = object_to_array(json_decode(myPost($url, $pra)));
return jsonSuccess($res['data']);
$articles = $res['data']["articleList"];
foreach ($articles as $k => $v){
$a = explode('/',$v['doi']);
if(!isset($a[1])){
$articles[$k]['refers'] = [];
continue;
}
$pro_info = $this->production_article_obj->where('doi',$a[1])->where('state',2)->find();
if (!$pro_info){
$articles[$k]['refers'] = [];
continue;
}
$articles[$k]['refers'] = $this->production_article_refer_obj->where("p_article_id",$pro_info['p_article_id'])->where('state',0)->order("index")->select();
}
$re['count'] = $res['data']["count"];
$re['articleList'] = $articles;
return jsonSuccess($re);
}
/**