Bundle update and ApplicationRecord as required in rails 5.1+
This commit is contained in:
parent
bdd522a5ff
commit
26a718a90c
@ -7,7 +7,3 @@ BlockLength:
|
||||
- config/routes.rb
|
||||
Rails/HttpPositionalArguments:
|
||||
Enabled: false
|
||||
# https://github.com/bbatsov/rubocop/issues/4189
|
||||
# TODO remove once rubocopy has changed beyond 0.48.1
|
||||
Lint/AmbiguousBlockAssociation:
|
||||
Enabled: false
|
||||
|
16
Gemfile.lock
16
Gemfile.lock
@ -1,6 +1,6 @@
|
||||
GIT
|
||||
remote: git://github.com/activeadmin/activeadmin.git
|
||||
revision: 8f7f58016802cd5a7f663fbc80b90b884252f939
|
||||
revision: d941aaa88c6e9011f7e9d1c7d85b2cd871160f0f
|
||||
specs:
|
||||
activeadmin (1.0.0)
|
||||
arbre (>= 1.1.1)
|
||||
@ -72,8 +72,8 @@ GEM
|
||||
minitest (~> 5.1)
|
||||
thread_safe (~> 0.3, >= 0.3.4)
|
||||
tzinfo (~> 1.1)
|
||||
acts-as-taggable-on (4.0.0)
|
||||
activerecord (>= 4.0)
|
||||
acts-as-taggable-on (5.0.0)
|
||||
activerecord (>= 4.2.8)
|
||||
addressable (2.5.1)
|
||||
public_suffix (~> 2.0, >= 2.0.2)
|
||||
arbre (1.1.1)
|
||||
@ -92,9 +92,9 @@ GEM
|
||||
thor (~> 0.18)
|
||||
byebug (9.0.6)
|
||||
coderay (1.1.1)
|
||||
coffee-rails (4.2.1)
|
||||
coffee-rails (4.2.2)
|
||||
coffee-script (>= 2.2.0)
|
||||
railties (>= 4.0.0, < 5.2.x)
|
||||
railties (>= 4.0.0)
|
||||
coffee-script (2.4.1)
|
||||
coffee-script-source
|
||||
execjs
|
||||
@ -268,6 +268,7 @@ GEM
|
||||
paper_trail (7.0.2)
|
||||
activerecord (>= 4.0, < 5.2)
|
||||
request_store (~> 1.1)
|
||||
parallel (1.11.2)
|
||||
parser (2.4.0.0)
|
||||
ast (~> 2.2)
|
||||
piwik_analytics (1.0.2)
|
||||
@ -338,7 +339,8 @@ GEM
|
||||
responders (2.4.0)
|
||||
actionpack (>= 4.2.0, < 5.3)
|
||||
railties (>= 4.2.0, < 5.3)
|
||||
rubocop (0.48.1)
|
||||
rubocop (0.49.0)
|
||||
parallel (~> 1.10)
|
||||
parser (>= 2.3.3.1, < 3.0)
|
||||
powerpack (~> 0.1)
|
||||
rainbow (>= 1.99.1, < 3.0)
|
||||
@ -389,7 +391,7 @@ GEM
|
||||
thor (0.19.4)
|
||||
thread_safe (0.3.6)
|
||||
tilt (2.0.7)
|
||||
tinymce-rails (4.6.1)
|
||||
tinymce-rails (4.6.2)
|
||||
railties (>= 3.1.1)
|
||||
tinymce-rails-langs (4.20160310)
|
||||
tinymce-rails (~> 4.1, >= 4.1.10)
|
||||
|
@ -1,5 +1,5 @@
|
||||
# The new agenda moderators, from active_admin
|
||||
class AdminUser < ActiveRecord::Base
|
||||
class AdminUser < ApplicationRecord
|
||||
# Include default devise modules. Others available are:
|
||||
# :confirmable, :lockable, :timeoutable and :omniauthable
|
||||
devise :database_authenticatable,
|
||||
|
4
app/models/application_record.rb
Normal file
4
app/models/application_record.rb
Normal file
@ -0,0 +1,4 @@
|
||||
# Base domain class
|
||||
class ApplicationRecord < ActiveRecord::Base
|
||||
self.abstract_class = true
|
||||
end
|
@ -2,7 +2,7 @@
|
||||
#
|
||||
# It is mainly used to manage coordinates
|
||||
#
|
||||
class City < ActiveRecord::Base
|
||||
class City < ApplicationRecord
|
||||
has_many :events, foreign_key: :city, primary_key: :name
|
||||
has_many :orgas, foreign_key: :city, primary_key: :name
|
||||
end
|
||||
|
@ -1,7 +1,7 @@
|
||||
require 'schedule'
|
||||
|
||||
# This is the central ADL class, where are managed all events
|
||||
class Event < ActiveRecord::Base
|
||||
class Event < ApplicationRecord
|
||||
extend SimpleCalendar
|
||||
include Schedule
|
||||
acts_as_taggable
|
||||
|
@ -1,4 +1,4 @@
|
||||
# Gives the possibility to organise organisations! :)
|
||||
class Kind < ActiveRecord::Base
|
||||
class Kind < ApplicationRecord
|
||||
has_many :orgas
|
||||
end
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Manages data related to events' moderation
|
||||
class Note < ActiveRecord::Base
|
||||
class Note < ApplicationRecord
|
||||
belongs_to :event
|
||||
belongs_to :author, class_name: User
|
||||
|
||||
|
@ -1,5 +1,5 @@
|
||||
# Organisations related to this agenda
|
||||
class Orga < ActiveRecord::Base
|
||||
class Orga < ApplicationRecord
|
||||
acts_as_taggable
|
||||
strip_attributes
|
||||
has_paper_trail ignore: %i[last_updated secret submitter decision_time
|
||||
|
@ -1,5 +1,5 @@
|
||||
# This is mostly to group events around a region
|
||||
class Region < ActiveRecord::Base
|
||||
class Region < ApplicationRecord
|
||||
belongs_to :region
|
||||
has_many :regions
|
||||
|
||||
|
@ -2,7 +2,7 @@ require 'digest/md5'
|
||||
|
||||
# Moderators, but using a failed pwd mechanism
|
||||
# TODO, migrate to full active_admin
|
||||
class User < ActiveRecord::Base
|
||||
class User < ApplicationRecord
|
||||
# Include default devise modules. Others available are:
|
||||
# :confirmable, :lockable, :timeoutable and :omniauthable
|
||||
devise :database_authenticatable, authentication_keys: [:login]
|
||||
|
Loading…
Reference in New Issue
Block a user