Class: PaperTrailHistory::RecordsController

Inherits:
ApplicationController show all
Defined in:
app/controllers/paper_trail_history/records_controller.rb

Overview

Controller for managing individual record operations and their version histories

Instance Method Summary collapse

Instance Method Details

#showObject



6
7
8
9
10
11
12
# File 'app/controllers/paper_trail_history/records_controller.rb', line 6

def show
  @trackable_model = find_trackable_model_or_redirect
  return unless @trackable_model

  load_record_data
  load_recent_versions
end

#versionsObject



14
15
16
17
18
19
20
21
# File 'app/controllers/paper_trail_history/records_controller.rb', line 14

def versions
  @trackable_model = find_trackable_model_or_redirect
  return unless @trackable_model

  load_record_data
  load_versions_with_filters
  load_available_events
end