add archived template and submission pages

This commit is contained in:
Alex Turchyn committed 2023-09-15 00:47:35 +03:00
1 parent 3faec9d174
commit 7f6c0af0e8
15 files changed
+190 -66

No files matched your search

@@ -0,0 +1,9 @@
# frozen_string_literal: true
class TemplatesArchivedController < ApplicationController
def index
templates = current_account.templates.where.not(deleted_at: nil).preload(:author).order(id: :desc)
@pagy, @templates = pagy(templates, items: 12)
end
end