fix bug
This commit is contained in:
@@ -80,6 +80,9 @@ class Article
|
||||
$article_id = $GLOBALS['data']['data']['article_id'];
|
||||
$info = Db::name('app_article')->where("id",$article_id)->find();
|
||||
if(empty($info)) return show("找不到该动态信息!");
|
||||
if(!empty($info['imgs'])) {
|
||||
$info['imgs'] = json_decode(str_replace(['{', '}'], ['[', ']'], imgs['imgs']), true);
|
||||
}
|
||||
$info['other_list'] = [];
|
||||
$lists = Db::name('app_article')
|
||||
->where("userid",$info["userid"])
|
||||
@@ -88,8 +91,9 @@ class Article
|
||||
->limit(env("page_count"))
|
||||
->select();
|
||||
foreach($lists as $vo){
|
||||
|
||||
$vo['imgs'] = json_decode(str_replace(['{','}'],['[',']'],$vo['imgs']),true);
|
||||
if(!empty($vo['imgs'])) {
|
||||
$vo['imgs'] = json_decode(str_replace(['{', '}'], ['[', ']'], $vo['imgs']), true);
|
||||
}
|
||||
$info['other_list'][] = $vo;
|
||||
}
|
||||
$info['userinfo']=[];
|
||||
|
||||
Reference in New Issue
Block a user