Class: Taskgration::TaskMigration

Inherits:
ApplicationRecord show all
Defined in:
app/models/taskgration/task_migration.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.current_versionObject



11
12
13
# File 'app/models/taskgration/task_migration.rb', line 11

def current_version
  newest.first&.version
end

Instance Method Details

#newestObject

Scopes



6
# File 'app/models/taskgration/task_migration.rb', line 6

scope :newest, -> { order(version: :desc) }