diff --git a/plugins/ahmadfatoni/apigenerator/controllers/api/postsController.php b/plugins/ahmadfatoni/apigenerator/controllers/api/postsController.php index 74d2f60b6..00a56ee27 100644 --- a/plugins/ahmadfatoni/apigenerator/controllers/api/postsController.php +++ b/plugins/ahmadfatoni/apigenerator/controllers/api/postsController.php @@ -38,7 +38,9 @@ class postsController extends Controller public function show($locale,$id){ - $post = $this->Post::find($id,['id','content_html','author']); + $post = $this->Post::find($id,['id','content_html','author','slug']); + + $post->url = $this->pageUrl('post',['id'=>$post->id,'slug'=>$post->slug]); if(!is_null($post)) { $obj = Db::table('vdomah_blogviews_views')