Merge pull request #283 from indentlabs/rails5-upgrade

[WIP] `rake rails:update` & Rails 5 upgrade
This commit is contained in:
Andrew Brown 2018-08-15 17:51:27 -05:00 committed by GitHub
commit f2e10b0d6d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
427 changed files with 2151 additions and 2197 deletions

View File

@ -1 +1 @@
ruby 2.3.0
ruby 2.5.1

View File

@ -1,7 +1,7 @@
source 'https://rubygems.org'
ruby "~> 2.5"
gem 'rails', '~> 4.2'
gem 'rails', '~> 5.2'
gem 'puma', '~> 3.7'
gem 'puma-heroku'
gem 'rack-timeout'
@ -70,6 +70,9 @@ gem 'thredded'
gem 'rails-ujs'
gem 'delayed_job_active_record'
# Exports
gem 'csv'
# Tech debt & hacks
gem 'binding_of_caller' # see has_changelog.rb
@ -110,6 +113,7 @@ group :test do
gem 'rubocop', require: false
gem 'ruby-prof', '0.15.9'
gem 'shoulda-matchers', '~> 3.1'
gem 'rails-controller-testing'
end
group :test, :development do

View File

@ -7,45 +7,52 @@ GIT
GEM
remote: https://rubygems.org/
specs:
actionmailer (4.2.10)
actionpack (= 4.2.10)
actionview (= 4.2.10)
activejob (= 4.2.10)
actioncable (5.2.0)
actionpack (= 5.2.0)
nio4r (~> 2.0)
websocket-driver (>= 0.6.1)
actionmailer (5.2.0)
actionpack (= 5.2.0)
actionview (= 5.2.0)
activejob (= 5.2.0)
mail (~> 2.5, >= 2.5.4)
rails-dom-testing (~> 1.0, >= 1.0.5)
actionpack (4.2.10)
actionview (= 4.2.10)
activesupport (= 4.2.10)
rack (~> 1.6)
rack-test (~> 0.6.2)
rails-dom-testing (~> 1.0, >= 1.0.5)
rails-dom-testing (~> 2.0)
actionpack (5.2.0)
actionview (= 5.2.0)
activesupport (= 5.2.0)
rack (~> 2.0)
rack-test (>= 0.6.3)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.0.2)
actionview (4.2.10)
activesupport (= 4.2.10)
actionview (5.2.0)
activesupport (= 5.2.0)
builder (~> 3.1)
erubis (~> 2.7.0)
rails-dom-testing (~> 1.0, >= 1.0.5)
erubi (~> 1.4)
rails-dom-testing (~> 2.0)
rails-html-sanitizer (~> 1.0, >= 1.0.3)
active_record_union (1.3.0)
activerecord (>= 4.0)
activejob (4.2.10)
activesupport (= 4.2.10)
globalid (>= 0.3.0)
activemodel (4.2.10)
activesupport (= 4.2.10)
builder (~> 3.1)
activerecord (4.2.10)
activemodel (= 4.2.10)
activesupport (= 4.2.10)
arel (~> 6.0)
activesupport (4.2.10)
i18n (~> 0.7)
activejob (5.2.0)
activesupport (= 5.2.0)
globalid (>= 0.3.6)
activemodel (5.2.0)
activesupport (= 5.2.0)
activerecord (5.2.0)
activemodel (= 5.2.0)
activesupport (= 5.2.0)
arel (>= 9.0)
activestorage (5.2.0)
actionpack (= 5.2.0)
activerecord (= 5.2.0)
marcel (~> 0.3.1)
activesupport (5.2.0)
concurrent-ruby (~> 1.0, >= 1.0.2)
i18n (>= 0.7, < 2)
minitest (~> 5.1)
thread_safe (~> 0.3, >= 0.3.4)
tzinfo (~> 1.1)
addressable (2.5.2)
public_suffix (>= 2.0.2, < 4.0)
arel (6.0.4)
arel (9.0.0)
ast (2.4.0)
authority (3.3.0)
activesupport (>= 3.0.0)
@ -116,6 +123,7 @@ GEM
crack (0.4.3)
safe_yaml (~> 1.0.0)
crass (1.0.4)
csv (1.0.0)
cucumber (3.1.1)
builder (>= 2.1.2)
cucumber-core (~> 3.1.0)
@ -158,7 +166,6 @@ GEM
diff-lcs (1.3)
docile (1.1.5)
erubi (1.7.1)
erubis (2.7.0)
execjs (2.7.0)
factory_bot (4.10.0)
activesupport (>= 3.0.0)
@ -199,7 +206,7 @@ GEM
htmlentities (4.3.4)
httparty (0.16.2)
multi_xml (>= 0.5.2)
i18n (0.9.5)
i18n (1.0.1)
concurrent-ruby (~> 1.0)
inline_svg (1.3.1)
activesupport (>= 3.0)
@ -233,6 +240,8 @@ GEM
lumberjack (1.0.13)
mail (2.7.0)
mini_mime (>= 0.1.1)
marcel (0.3.2)
mimemagic (~> 0.3.2)
material_icons (2.2.1)
railties (>= 3.2)
medium-editor-rails (2.3.1)
@ -256,7 +265,8 @@ GEM
mustache (1.0.5)
nenv (0.3.0)
newrelic_rpm (5.2.0.345)
nokogiri (1.8.3)
nio4r (2.3.1)
nokogiri (1.8.4)
mini_portile2 (~> 2.3.0)
nokogumbo (1.5.0)
nokogiri
@ -293,27 +303,30 @@ GEM
puma (~> 3.0)
pundit (1.1.0)
activesupport (>= 3.0.0)
rack (1.6.10)
rack-test (0.6.3)
rack (>= 1.0)
rack (2.0.5)
rack-test (1.0.0)
rack (>= 1.0, < 3)
rack-timeout (0.5.1)
rails (4.2.10)
actionmailer (= 4.2.10)
actionpack (= 4.2.10)
actionview (= 4.2.10)
activejob (= 4.2.10)
activemodel (= 4.2.10)
activerecord (= 4.2.10)
activesupport (= 4.2.10)
bundler (>= 1.3.0, < 2.0)
railties (= 4.2.10)
sprockets-rails
rails-deprecated_sanitizer (1.0.3)
activesupport (>= 4.2.0.alpha)
rails-dom-testing (1.0.9)
activesupport (>= 4.2.0, < 5.0)
nokogiri (~> 1.6)
rails-deprecated_sanitizer (>= 1.0.1)
rails (5.2.0)
actioncable (= 5.2.0)
actionmailer (= 5.2.0)
actionpack (= 5.2.0)
actionview (= 5.2.0)
activejob (= 5.2.0)
activemodel (= 5.2.0)
activerecord (= 5.2.0)
activestorage (= 5.2.0)
activesupport (= 5.2.0)
bundler (>= 1.3.0)
railties (= 5.2.0)
sprockets-rails (>= 2.0.0)
rails-controller-testing (1.0.2)
actionpack (~> 5.x, >= 5.0.1)
actionview (~> 5.x, >= 5.0.1)
activesupport (~> 5.x)
rails-dom-testing (2.0.3)
activesupport (>= 4.2.0)
nokogiri (>= 1.6)
rails-html-sanitizer (1.0.4)
loofah (~> 2.2, >= 2.2.2)
rails-jquery-autocomplete (1.0.3)
@ -326,9 +339,10 @@ GEM
rails_stdout_logging
rails_serve_static_assets (0.0.5)
rails_stdout_logging (0.0.5)
railties (4.2.10)
actionpack (= 4.2.10)
activesupport (= 4.2.10)
railties (5.2.0)
actionpack (= 5.2.0)
activesupport (= 5.2.0)
method_source
rake (>= 0.8.7)
thor (>= 0.18.1, < 2.0)
rainbow (3.0.0)
@ -484,6 +498,9 @@ GEM
addressable (>= 2.3.6)
crack (>= 0.3.2)
hashdiff
websocket-driver (0.7.0)
websocket-extensions (>= 0.1.0)
websocket-extensions (0.1.3)
xpath (3.1.0)
nokogiri (~> 1.8)
@ -503,6 +520,7 @@ DEPENDENCIES
codeclimate-test-reporter
coffee-rails
coveralls
csv
cucumber-rails
database_cleaner
dateslices
@ -526,7 +544,8 @@ DEPENDENCIES
puma (~> 3.7)
puma-heroku
rack-timeout
rails (~> 4.2)
rails (~> 5.2)
rails-controller-testing
rails-jquery-autocomplete
rails-perftest
rails-ujs
@ -559,4 +578,4 @@ RUBY VERSION
ruby 2.5.1p57
BUNDLED WITH
1.16.2
1.16.3

View File

@ -19,7 +19,7 @@ class ContentController < ApplicationController
end
end
@content = @content.flatten.uniq.sort_by(&:name)
@content = @content.to_a.flatten.uniq.sort_by(&:name)
@questioned_content = @content.sample
@question = @questioned_content.question unless @questioned_content.nil?

View File

@ -1,5 +1,5 @@
class RegistrationsController < Devise::RegistrationsController
after_filter :add_account, only: [:create]
after_action :add_account, only: [:create]
def new
super

View File

@ -0,0 +1,3 @@
class ApplicationRecord < ActiveRecord::Base
self.abstract_class = true
end

View File

@ -1,4 +1,4 @@
class Attribute < ActiveRecord::Base
class Attribute < ApplicationRecord
belongs_to :user
belongs_to :attribute_field
belongs_to :entity, polymorphic: true

View File

@ -1,4 +1,4 @@
class AttributeCategory < ActiveRecord::Base
class AttributeCategory < ApplicationRecord
validates :name, presence: true
belongs_to :user

View File

@ -1,4 +1,4 @@
class AttributeField < ActiveRecord::Base
class AttributeField < ApplicationRecord
validates :name, presence: true
belongs_to :user

View File

@ -1,3 +1,3 @@
class BillingPlan < ActiveRecord::Base
class BillingPlan < ApplicationRecord
PREMIUM_IDS = [2, 3, 4, 5, 6]
end

View File

@ -1,4 +1,4 @@
class ContentChangeEvent < ActiveRecord::Base
class ContentChangeEvent < ApplicationRecord
belongs_to :user
serialize :changed_fields, Hash

View File

@ -1,4 +1,4 @@
class Archenemyship < ActiveRecord::Base
class Archenemyship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,8 +1,8 @@
class Artifactship < ActiveRecord::Base
class Artifactship < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :religion
belongs_to :artifact, class_name: 'Item'
end
end

View File

@ -1,4 +1,4 @@
class BestFriendship < ActiveRecord::Base
class BestFriendship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class Birthing < ActiveRecord::Base
class Birthing < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,6 +1,6 @@
# Defines a relation between a location and any capital cities within it,
# and a reverse relation for all locations in which they are the capital of.
class CapitalCitiesRelationship < ActiveRecord::Base
class CapitalCitiesRelationship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class CharacterBirthtown < ActiveRecord::Base
class CharacterBirthtown < ApplicationRecord
belongs_to :user
belongs_to :character
belongs_to :birthtown, class_name: Town.name

View File

@ -1,4 +1,4 @@
class CharacterCompanion < ActiveRecord::Base
class CharacterCompanion < ApplicationRecord
belongs_to :user
belongs_to :character
belongs_to :companion, class_name: Creature.name

View File

@ -1,4 +1,4 @@
class CharacterEnemy < ActiveRecord::Base
class CharacterEnemy < ApplicationRecord
belongs_to :character
belongs_to :user
belongs_to :enemy, class_name: Character.name

View File

@ -1,4 +1,4 @@
class CharacterFlora < ActiveRecord::Base
class CharacterFlora < ApplicationRecord
belongs_to :user
belongs_to :character
belongs_to :flora

View File

@ -1,4 +1,4 @@
class CharacterFriend < ActiveRecord::Base
class CharacterFriend < ApplicationRecord
belongs_to :user
belongs_to :character
belongs_to :friend, class_name: Character.name

View File

@ -1,4 +1,4 @@
class CharacterItem < ActiveRecord::Base
class CharacterItem < ApplicationRecord
belongs_to :user
belongs_to :character
belongs_to :item

View File

@ -1,4 +1,4 @@
class CharacterLoveInterest < ActiveRecord::Base
class CharacterLoveInterest < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class CharacterMagic < ActiveRecord::Base
class CharacterMagic < ApplicationRecord
belongs_to :character
belongs_to :magic
belongs_to :user

View File

@ -1,4 +1,4 @@
class CharacterTechnology < ActiveRecord::Base
class CharacterTechnology < ApplicationRecord
belongs_to :user
belongs_to :character
belongs_to :technology

View File

@ -1,4 +1,4 @@
class Childrenship < ActiveRecord::Base
class Childrenship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class CountryCreature < ActiveRecord::Base
class CountryCreature < ApplicationRecord
belongs_to :user
belongs_to :country
belongs_to :creature

View File

@ -1,4 +1,4 @@
class CountryFlora < ActiveRecord::Base
class CountryFlora < ApplicationRecord
belongs_to :user
belongs_to :country
belongs_to :flora

View File

@ -1,4 +1,4 @@
class CountryGovernment < ActiveRecord::Base
class CountryGovernment < ApplicationRecord
belongs_to :country
belongs_to :government
belongs_to :user

View File

@ -1,4 +1,4 @@
class CountryLandmark < ActiveRecord::Base
class CountryLandmark < ApplicationRecord
belongs_to :user
belongs_to :country
belongs_to :landmark

View File

@ -1,4 +1,4 @@
class CountryLanguage < ActiveRecord::Base
class CountryLanguage < ApplicationRecord
belongs_to :user
belongs_to :country
belongs_to :language

View File

@ -1,4 +1,4 @@
class CountryLocation < ActiveRecord::Base
class CountryLocation < ApplicationRecord
belongs_to :user
belongs_to :country
belongs_to :location

View File

@ -1,4 +1,4 @@
class CountryReligion < ActiveRecord::Base
class CountryReligion < ApplicationRecord
belongs_to :user
belongs_to :country
belongs_to :religion

View File

@ -1,4 +1,4 @@
class CountryTown < ActiveRecord::Base
class CountryTown < ApplicationRecord
belongs_to :user
belongs_to :country
belongs_to :town

View File

@ -1,4 +1,4 @@
class CreatureRelationship < ActiveRecord::Base
class CreatureRelationship < ApplicationRecord
include HasContentLinking
LINK_TYPE = :two_way

View File

@ -1,6 +1,6 @@
# Defines a relation from an Item to the Character that currently owns it
# and an inverse relationship from a Character to all items it currently owns
class CurrentOwnership < ActiveRecord::Base
class CurrentOwnership < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class DeityAbility < ActiveRecord::Base
class DeityAbility < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :ability, class_name: Magic.name

View File

@ -1,4 +1,4 @@
class DeityCharacterChild < ActiveRecord::Base
class DeityCharacterChild < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :character_child, class_name: Character.name

View File

@ -1,4 +1,4 @@
class DeityCharacterParent < ActiveRecord::Base
class DeityCharacterParent < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :character_parent, class_name: Character.name

View File

@ -1,4 +1,4 @@
class DeityCharacterPartner < ActiveRecord::Base
class DeityCharacterPartner < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :character_partner, class_name: Character.name

View File

@ -1,4 +1,4 @@
class DeityCharacterSibling < ActiveRecord::Base
class DeityCharacterSibling < ApplicationRecord
include HasContentLinking
belongs_to :deity

View File

@ -1,4 +1,4 @@
class DeityCreature < ActiveRecord::Base
class DeityCreature < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :creature

View File

@ -1,4 +1,4 @@
class DeityDeityChild < ActiveRecord::Base
class DeityDeityChild < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :deity_child, class_name: Deity.name

View File

@ -1,4 +1,4 @@
class DeityDeityParent < ActiveRecord::Base
class DeityDeityParent < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :deity_parent, class_name: Deity.name

View File

@ -1,4 +1,4 @@
class DeityDeityPartner < ActiveRecord::Base
class DeityDeityPartner < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :deity_partner, class_name: Deity.name

View File

@ -1,4 +1,4 @@
class DeityDeitySibling < ActiveRecord::Base
class DeityDeitySibling < ApplicationRecord
include HasContentLinking
belongs_to :deity

View File

@ -1,4 +1,4 @@
class DeityFlora < ActiveRecord::Base
class DeityFlora < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :flora

View File

@ -1,4 +1,4 @@
class DeityRace < ActiveRecord::Base
class DeityRace < ApplicationRecord
belongs_to :deity
belongs_to :race
belongs_to :user

View File

@ -1,4 +1,4 @@
class DeityRelatedLandmark < ActiveRecord::Base
class DeityRelatedLandmark < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :related_landmark, class_name: Landmark.name

View File

@ -1,4 +1,4 @@
class DeityRelatedTown < ActiveRecord::Base
class DeityRelatedTown < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :related_town, class_name: Town.name

View File

@ -1,4 +1,4 @@
class DeityRelic < ActiveRecord::Base
class DeityRelic < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :relic, class_name: Item.name

View File

@ -1,4 +1,4 @@
class DeityReligion < ActiveRecord::Base
class DeityReligion < ApplicationRecord
belongs_to :user
belongs_to :deity
belongs_to :religion

View File

@ -1,4 +1,4 @@
class Deityship < ActiveRecord::Base
class Deityship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class FamousFigureship < ActiveRecord::Base
class FamousFigureship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class Fathership < ActiveRecord::Base
class Fathership < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class FloraEatenBy < ActiveRecord::Base
class FloraEatenBy < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class FloraLocation < ActiveRecord::Base
class FloraLocation < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class FloraMagicalEffect < ActiveRecord::Base
class FloraMagicalEffect < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class FloraRelationship < ActiveRecord::Base
class FloraRelationship < ApplicationRecord
include HasContentLinking
LINK_TYPE = :two_way

View File

@ -1,4 +1,4 @@
class GovernmentCreature < ActiveRecord::Base
class GovernmentCreature < ApplicationRecord
belongs_to :user
belongs_to :government
belongs_to :creature

View File

@ -1,4 +1,4 @@
class GovernmentGroup < ActiveRecord::Base
class GovernmentGroup < ApplicationRecord
belongs_to :user
belongs_to :government
belongs_to :group

View File

@ -1,4 +1,4 @@
class GovernmentItem < ActiveRecord::Base
class GovernmentItem < ApplicationRecord
belongs_to :user
belongs_to :government
belongs_to :item

View File

@ -1,4 +1,4 @@
class GovernmentLeader < ActiveRecord::Base
class GovernmentLeader < ApplicationRecord
belongs_to :user
belongs_to :government
belongs_to :leader, class_name: Character.name

View File

@ -1,4 +1,4 @@
class GovernmentPoliticalFigure < ActiveRecord::Base
class GovernmentPoliticalFigure < ApplicationRecord
belongs_to :user
belongs_to :government
belongs_to :political_figure, class_name: Character.name

View File

@ -1,4 +1,4 @@
class GovernmentTechnology < ActiveRecord::Base
class GovernmentTechnology < ApplicationRecord
belongs_to :user
belongs_to :government
belongs_to :technology

View File

@ -1,4 +1,4 @@
class GroupAllyship < ActiveRecord::Base
class GroupAllyship < ApplicationRecord
include HasContentLinking
belongs_to :user
@ -17,4 +17,4 @@ class GroupAllyship < ActiveRecord::Base
other_object.allies.delete this_object
end
end
end

View File

@ -1,8 +1,8 @@
class GroupClientship < ActiveRecord::Base
class GroupClientship < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :group
belongs_to :client, class_name: 'Group'
end
end

View File

@ -1,4 +1,4 @@
class GroupCreature < ActiveRecord::Base
class GroupCreature < ApplicationRecord
belongs_to :group
belongs_to :creature
belongs_to :user

View File

@ -1,4 +1,4 @@
class GroupEnemyship < ActiveRecord::Base
class GroupEnemyship < ApplicationRecord
include HasContentLinking
belongs_to :user
@ -17,4 +17,4 @@ class GroupEnemyship < ActiveRecord::Base
other_object.enemies.delete this_object
end
end
end

View File

@ -1,8 +1,8 @@
class GroupEquipmentship < ActiveRecord::Base
class GroupEquipmentship < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :group
belongs_to :equipment, class_name: 'Item'
end
end

View File

@ -1,8 +1,8 @@
class GroupLeadership < ActiveRecord::Base
class GroupLeadership < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :group
belongs_to :leader, class_name: 'Character'
end
end

View File

@ -1,8 +1,8 @@
class GroupLocationship < ActiveRecord::Base
class GroupLocationship < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :group
belongs_to :location
end
end

View File

@ -1,8 +1,8 @@
class GroupMembership < ActiveRecord::Base
class GroupMembership < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :group
belongs_to :member, class_name: 'Character'
end
end

View File

@ -1,4 +1,4 @@
class GroupRivalship < ActiveRecord::Base
class GroupRivalship < ApplicationRecord
include HasContentLinking
belongs_to :user
@ -17,4 +17,4 @@ class GroupRivalship < ActiveRecord::Base
other_object.rivals.delete this_object
end
end
end

View File

@ -1,8 +1,8 @@
class GroupSuppliership < ActiveRecord::Base
class GroupSuppliership < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :group
belongs_to :supplier, class_name: 'Group'
end
end

View File

@ -1,8 +1,8 @@
class Headquartership < ActiveRecord::Base
class Headquartership < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :group
belongs_to :headquarter, class_name: 'Location'
end
end

View File

@ -1,4 +1,4 @@
class ItemMagic < ActiveRecord::Base
class ItemMagic < ApplicationRecord
belongs_to :item
belongs_to :magic
belongs_to :user

View File

@ -1,8 +1,8 @@
class KeyItemship < ActiveRecord::Base
class KeyItemship < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :group
belongs_to :key_item, class_name: 'Item'
end
end

View File

@ -1,4 +1,4 @@
class LandmarkCountry < ActiveRecord::Base
class LandmarkCountry < ApplicationRecord
belongs_to :user
belongs_to :landmark
belongs_to :country

View File

@ -1,4 +1,4 @@
class LandmarkCreature < ActiveRecord::Base
class LandmarkCreature < ApplicationRecord
belongs_to :user
belongs_to :landmark
belongs_to :creature

View File

@ -1,4 +1,4 @@
class LandmarkFlora < ActiveRecord::Base
class LandmarkFlora < ApplicationRecord
belongs_to :user
belongs_to :landmark
belongs_to :flora

View File

@ -1,4 +1,4 @@
class LandmarkNearbyTown < ActiveRecord::Base
class LandmarkNearbyTown < ApplicationRecord
belongs_to :user
belongs_to :landmark

View File

@ -1,4 +1,4 @@
class LargestCitiesRelationship < ActiveRecord::Base
class LargestCitiesRelationship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,8 +1,8 @@
class Lingualism < ActiveRecord::Base
class Lingualism < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :character
belongs_to :spoken_language, class_name: 'Language'
end
end

View File

@ -1,4 +1,4 @@
class LocationCapitalTown < ActiveRecord::Base
class LocationCapitalTown < ApplicationRecord
belongs_to :location
belongs_to :user
belongs_to :capital_town, class_name: Town.name

View File

@ -1,4 +1,4 @@
class LocationLandmark < ActiveRecord::Base
class LocationLandmark < ApplicationRecord
belongs_to :location
belongs_to :landmark
belongs_to :user

View File

@ -1,4 +1,4 @@
class LocationLanguageship < ActiveRecord::Base
class LocationLanguageship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class LocationLargestTown < ActiveRecord::Base
class LocationLargestTown < ApplicationRecord
belongs_to :location
belongs_to :user
belongs_to :largest_town, class_name: Town.name

View File

@ -1,4 +1,4 @@
class LocationLeadership < ActiveRecord::Base
class LocationLeadership < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class LocationNotableTown < ActiveRecord::Base
class LocationNotableTown < ApplicationRecord
belongs_to :location
belongs_to :user
belongs_to :notable_town, class_name: Town.name

View File

@ -1,8 +1,8 @@
class MagicDeityship < ActiveRecord::Base
class MagicDeityship < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :magic
belongs_to :deity, class_name: 'Character'
end
end

View File

@ -1,6 +1,6 @@
# Defines a relation from an Item to the Character that created it
# and an inverse relationship from a Character to all items it created
class MakerRelationship < ActiveRecord::Base
class MakerRelationship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class Marriage < ActiveRecord::Base
class Marriage < ApplicationRecord
include HasContentLinking
LINK_TYPE = :two_way

View File

@ -1,4 +1,4 @@
class Mothership < ActiveRecord::Base
class Mothership < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,6 +1,6 @@
# Defines a relation between a location and any notable cities within it,
# and a reverse relation for all locations in which a given location is notable within.
class NotableCitiesRelationship < ActiveRecord::Base
class NotableCitiesRelationship < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,8 +1,8 @@
class Officeship < ActiveRecord::Base
class Officeship < ApplicationRecord
include HasContentLinking
belongs_to :user
belongs_to :group
belongs_to :office, class_name: 'Location'
end
end

View File

@ -1,6 +1,6 @@
# Defines a relation from an Item to the Character that first owned it
# and an inverse relationship from a Character to all items it first owned
class OriginalOwnership < ActiveRecord::Base
class OriginalOwnership < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,6 +1,6 @@
# Defines a relation from an Item to a Character that previously owned it
# and an inverse relationship from an Item to all Characters it has been owned by
class PastOwnership < ActiveRecord::Base
class PastOwnership < ApplicationRecord
include HasContentLinking
belongs_to :user

View File

@ -1,4 +1,4 @@
class PlanetCountry < ActiveRecord::Base
class PlanetCountry < ApplicationRecord
belongs_to :user
belongs_to :planet
belongs_to :country

View File

@ -1,4 +1,4 @@
class PlanetCreature < ActiveRecord::Base
class PlanetCreature < ApplicationRecord
belongs_to :user
belongs_to :planet
belongs_to :creature

Some files were not shown because too many files have changed in this diff Show More