From: Aidan Cornelius-Bell Date: Mon, 23 Sep 2024 02:29:05 +0000 (+0930) Subject: order of pages shown X-Git-Url: https://gitweb.mndrdr.org/?a=commitdiff_plain;h=bdfc5d4c77e1c440e909c80518b6ca004c40ef19;p=arelpe.git order of pages shown --- diff --git a/app/controllers/pubview_controller.rb b/app/controllers/pubview_controller.rb index be512d5..3eabad2 100644 --- a/app/controllers/pubview_controller.rb +++ b/app/controllers/pubview_controller.rb @@ -1,6 +1,6 @@ class PubviewController < ApplicationController def index - @pages = Page.where(visibility: :visible).order(created_at: :asc).limit(2) + @pages = Page.where(visibility: :visible).order(created_at: :desc).limit(2) @per_page = 15 @page = params[:page].to_i || 1 @@ -66,4 +66,4 @@ class PubviewController < ApplicationController word_count = content.split.size (word_count / 200.0).ceil end -end \ No newline at end of file +end