Make stuff sortable

This commit is contained in:
david 2024-11-11 04:04:13 +01:00
parent 50e853098b
commit ee5dbcf33e
21 changed files with 161 additions and 28 deletions

View file

@ -1,7 +1,7 @@
# frozen_string_literal: true
class Report < ApplicationRecord
has_many :pages, dependent: :destroy
has_many :pages, -> { order(:position) }, dependent: :destroy
has_many :elements, through: :pages, dependent: :destroy
has_rich_text :comment