20201112
This commit is contained in:
@@ -95,6 +95,21 @@ class Article extends Controller {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @title 删除文章
|
||||
* @description 删除文章
|
||||
* @author wangjinleichang
|
||||
* @url /master/Article/delArticle
|
||||
* @method POST
|
||||
*
|
||||
* @param name:article_id type:int require:1 desc:文章id
|
||||
*/
|
||||
public function delArticle(){
|
||||
$data = $this->request->post();
|
||||
$res = $this->article_obj->where('article_id',$data['article_id'])->update(['state'=>1]);
|
||||
return json(['code'=>0,'msg'=>'success']);
|
||||
}
|
||||
|
||||
/**
|
||||
* @title 添加文章作者
|
||||
* @description 添加文章作者
|
||||
|
||||
@@ -269,7 +269,12 @@ class Journal extends Controller {
|
||||
*/
|
||||
public function editTopic(){
|
||||
$data = $this->request->post();
|
||||
$res = $this->journal_topic_obj->update($data);
|
||||
$update['journal_topic_id'] = $data['journal_topic_id'];
|
||||
$update['title'] = $data['title'];
|
||||
$update['icon'] = $data['icon'];
|
||||
$update['is_final'] = $data['is_final'];
|
||||
$update['sort'] = $data['sort'];
|
||||
$res = $this->journal_topic_obj->update($update);
|
||||
if($res){
|
||||
return json(['code'=>0,'msg'=>'success']);
|
||||
}else{
|
||||
|
||||
Reference in New Issue
Block a user