mirror of
https://github.com/lkddi/nexusphp.git
synced 2026-04-03 14:10:57 +08:00
merge 1.9
This commit is contained in:
@@ -17,7 +17,7 @@ class CommentResource extends JsonResource
|
||||
{
|
||||
return [
|
||||
'id' => $this->id,
|
||||
'text' => $this->text,
|
||||
'text' => bbcode_attach_to_img($this->text),
|
||||
'updated_at' => format_datetime($this->editdate),
|
||||
'created_at' => format_datetime($this->added),
|
||||
'create_user' => new UserResource($this->whenLoaded('create_user')),
|
||||
|
||||
@@ -28,7 +28,7 @@ class CommentRepository extends BaseRepository
|
||||
if (!empty($request->request_id)) {
|
||||
$query->where('request', $request->request_id);
|
||||
}
|
||||
$query->orderBy('id', 'desc');
|
||||
$query->orderBy('id', 'asc');
|
||||
return $query->paginate($this->getPerPageFromRequest($request));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user