fix order

This commit is contained in:
byte[] 2019-12-15 18:35:56 -05:00
parent 299e0cf923
commit f5996dc084
2 changed files with 2 additions and 1 deletions

View file

@ -26,6 +26,7 @@ defmodule PhilomenaWeb.Admin.ModNoteController do
mod_notes = mod_notes =
queryable queryable
|> preload(:moderator) |> preload(:moderator)
|> order_by(desc: :id)
|> Repo.paginate(conn.assigns.scrivener) |> Repo.paginate(conn.assigns.scrivener)
bodies = Renderer.render_collection(mod_notes, conn) bodies = Renderer.render_collection(mod_notes, conn)

View file

@ -17,5 +17,5 @@ defmodule PhilomenaWeb.Admin.ModNoteView do
def link_to_noted_thing(conn, %User{} = user), def link_to_noted_thing(conn, %User{} = user),
do: link("User #{user.name}", to: Routes.profile_path(conn, :show, user)) do: link("User #{user.name}", to: Routes.profile_path(conn, :show, user))
def link_to_noted_thing(_conn, notable), do: "Item permanently deleted" def link_to_noted_thing(_conn, _notable), do: "Item permanently deleted"
end end