Fixed #126
This commit is contained in:
parent
bf96cc0e28
commit
eb78266bee
@ -570,12 +570,11 @@ class PostController extends ApplicationController
|
|||||||
}
|
}
|
||||||
|
|
||||||
$this->post_params = $this->params()->all();
|
$this->post_params = $this->params()->all();
|
||||||
$end = time();
|
|
||||||
$this->start = strtotime('-'.$period);
|
$this->start = strtotime('-'.$period);
|
||||||
|
|
||||||
$this->set_title('Exploring ' . $this->period_name);
|
$this->set_title('Exploring ' . $this->period_name);
|
||||||
|
|
||||||
$this->posts = Post::where("status <> 'deleted' AND posts.index_timestamp >= ? AND posts.index_timestamp <= ? ", date('Y-m-d', $this->start), date('Y-m-d', $end))->order("score DESC")->limit(20)->take();
|
$this->posts = Post::where("status <> 'deleted' AND posts.index_timestamp >= ? AND posts.index_timestamp <= ? ", date('Y-m-d', $this->start), date('Y-m-d H:i:s'))->order("score DESC")->limit(20)->take();
|
||||||
|
|
||||||
$this->respond_to_list("posts");
|
$this->respond_to_list("posts");
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user