repo
stringlengths
5
92
file_url
stringlengths
80
287
file_path
stringlengths
5
197
content
stringlengths
0
32.8k
language
stringclasses
1 value
license
stringclasses
7 values
commit_sha
stringlengths
40
40
retrieved_at
stringdate
2026-01-04 15:37:27
2026-01-04 17:58:21
truncated
bool
2 classes
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/restricted_team.rb
spec/dummy_app/app/active_record/restricted_team.rb
# frozen_string_literal: true class RestrictedTeam < Team has_many :players, foreign_key: :team_id, dependent: :restrict_with_error end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/deeply_nested_field_test.rb
spec/dummy_app/app/active_record/deeply_nested_field_test.rb
# frozen_string_literal: true class DeeplyNestedFieldTest < ActiveRecord::Base belongs_to :nested_field_test, inverse_of: :deeply_nested_field_tests end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/managed_team.rb
spec/dummy_app/app/active_record/managed_team.rb
# frozen_string_literal: true class ManagedTeam < Team belongs_to :user, class_name: 'ManagingUser', foreign_key: :manager, primary_key: :email, optional: true, inverse_of: :teams end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/read_only_comment.rb
spec/dummy_app/app/active_record/read_only_comment.rb
# frozen_string_literal: true class ReadOnlyComment < Comment def readonly? true end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/managing_user.rb
spec/dummy_app/app/active_record/managing_user.rb
# frozen_string_literal: true class ManagingUser < User has_one :team, class_name: 'ManagedTeam', foreign_key: :manager, primary_key: :email, inverse_of: :user has_many :teams, class_name: 'ManagedTeam', foreign_key: :manager, primary_key: :email, inverse_of: :user end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/nested_fan.rb
spec/dummy_app/app/active_record/nested_fan.rb
# frozen_string_literal: true if ActiveRecord.gem_version >= Gem::Version.new('7.1') || defined?(CompositePrimaryKeys) class NestedFan < Fan accepts_nested_attributes_for :fanships accepts_nested_attributes_for :fanship end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/division.rb
spec/dummy_app/app/active_record/division.rb
# frozen_string_literal: true class Division < ActiveRecord::Base self.primary_key = :custom_id belongs_to :league, foreign_key: 'custom_league_id', optional: true has_many :teams validates_numericality_of(:custom_league_id, only_integer: true) validates_presence_of(:name) end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/carrierwave_uploader.rb
spec/dummy_app/app/active_record/carrierwave_uploader.rb
# frozen_string_literal: true require 'mini_magick' class CarrierwaveUploader < CarrierWave::Uploader::Base # Include RMagick or ImageScience support: # include CarrierWave::RMagick include CarrierWave::MiniMagick # include CarrierWave::ImageScience # Choose what kind of storage to use for this uploader: ...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/league.rb
spec/dummy_app/app/active_record/league.rb
# frozen_string_literal: true class League < ActiveRecord::Base has_many :divisions, foreign_key: 'custom_league_id' has_many :teams, -> { readonly }, through: :divisions has_many :players, through: :teams has_one :division, foreign_key: 'custom_league_id' validates_presence_of(:name) def custom_name ...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/category.rb
spec/dummy_app/app/active_record/category.rb
# frozen_string_literal: true class Category < ActiveRecord::Base belongs_to :parent_category, class_name: 'Category', optional: true end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/player.rb
spec/dummy_app/app/active_record/player.rb
# frozen_string_literal: true class Player < ActiveRecord::Base belongs_to :team, optional: true, inverse_of: :players has_one :draft, dependent: :destroy has_many :comments, as: :commentable validates_presence_of(:name) validates_numericality_of(:number, only_integer: true) validates_uniqueness_of(:numbe...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/trail.rb
spec/dummy_app/app/active_record/trail.rb
# frozen_string_literal: true class Trail < PaperTrail::Version self.table_name = :custom_versions end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/hardball.rb
spec/dummy_app/app/active_record/hardball.rb
# frozen_string_literal: true class Hardball < Ball end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/comment.rb
spec/dummy_app/app/active_record/comment.rb
# frozen_string_literal: true class Comment < ActiveRecord::Base include Taggable belongs_to :commentable, polymorphic: true, optional: true end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/paper_trail_test_subclass.rb
spec/dummy_app/app/active_record/paper_trail_test_subclass.rb
# frozen_string_literal: true class PaperTrailTestSubclass < PaperTrailTest end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/without_table.rb
spec/dummy_app/app/active_record/without_table.rb
# frozen_string_literal: true class WithoutTable < ActiveRecord::Base end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/favorite_player.rb
spec/dummy_app/app/active_record/favorite_player.rb
# frozen_string_literal: true if ActiveRecord.gem_version >= Gem::Version.new('7.1') || defined?(CompositePrimaryKeys) class FavoritePlayer < ActiveRecord::Base if defined?(CompositePrimaryKeys) self.primary_keys = :fan_id, :team_id, :player_id else self.primary_key = :fan_id, :team_id, :player_i...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/draft.rb
spec/dummy_app/app/active_record/draft.rb
# frozen_string_literal: true class Draft < ActiveRecord::Base belongs_to :team belongs_to :player validates_numericality_of(:player_id, only_integer: true) validates_numericality_of(:team_id, only_integer: true) validates_presence_of(:date) validates_numericality_of(:round, only_integer: true) validate...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/fan.rb
spec/dummy_app/app/active_record/fan.rb
# frozen_string_literal: true class Fan < ActiveRecord::Base has_and_belongs_to_many :teams if ActiveRecord.gem_version >= Gem::Version.new('7.1') || defined?(CompositePrimaryKeys) has_many :fanships, inverse_of: :fan has_one :fanship, inverse_of: :fan end validates_presence_of(:name) end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/shrine_uploader.rb
spec/dummy_app/app/active_record/shrine_uploader.rb
# frozen_string_literal: true class ShrineUploader < Shrine plugin :activerecord plugin :cached_attachment_data plugin :determine_mime_type plugin :pretty_location plugin :remove_attachment end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/team.rb
spec/dummy_app/app/active_record/team.rb
# frozen_string_literal: true class Team < ActiveRecord::Base has_many :players, -> { order :id }, inverse_of: :team has_and_belongs_to_many :fans has_many :comments, as: :commentable validates_numericality_of :division_id, only_integer: true validates_presence_of :manager validates_numericality_of :found...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/abstract.rb
spec/dummy_app/app/active_record/abstract.rb
# frozen_string_literal: true class Abstract < ActiveRecord::Base self.abstract_class = true end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/paper_trail_test_with_custom_association.rb
spec/dummy_app/app/active_record/paper_trail_test_with_custom_association.rb
# frozen_string_literal: true class PaperTrailTestWithCustomAssociation < ActiveRecord::Base self.table_name = :paper_trail_tests has_paper_trail versions: {class_name: 'Trail'} end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/nested_field_test.rb
spec/dummy_app/app/active_record/nested_field_test.rb
# frozen_string_literal: true class NestedFieldTest < ActiveRecord::Base belongs_to :field_test, optional: true, inverse_of: :nested_field_tests belongs_to :another_field_test, optional: true, inverse_of: :nested_field_tests has_one :comment, as: :commentable has_many :deeply_nested_field_tests, inverse_of: :n...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/ball.rb
spec/dummy_app/app/active_record/ball.rb
# frozen_string_literal: true class Ball < ActiveRecord::Base has_one :comment, as: :commentable validates_presence_of :color, on: :create def to_param color.present? ? color.downcase.tr(' ', '-') : id end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/another_field_test.rb
spec/dummy_app/app/active_record/another_field_test.rb
# frozen_string_literal: true class AnotherFieldTest < ActiveRecord::Base has_many :nested_field_tests, inverse_of: :another_field_test end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/shrine_versioning_uploader.rb
spec/dummy_app/app/active_record/shrine_versioning_uploader.rb
# frozen_string_literal: true class ShrineVersioningUploader < Shrine plugin :activerecord plugin :cached_attachment_data plugin :determine_mime_type plugin :pretty_location plugin :remove_attachment if Gem.loaded_specs['shrine'].version >= Gem::Version.create('3') plugin :derivatives Attacher.d...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/image.rb
spec/dummy_app/app/active_record/image.rb
# frozen_string_literal: true class Image < ActiveRecord::Base has_attached_file :file, styles: {medium: '300x300>', thumb: '100x100>'} validates_attachment_presence :file end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/field_test.rb
spec/dummy_app/app/active_record/field_test.rb
# frozen_string_literal: true class FieldTest < ActiveRecord::Base has_many :nested_field_tests, dependent: :destroy, inverse_of: :field_test accepts_nested_attributes_for :nested_field_tests, allow_destroy: true has_one :comment, as: :commentable accepts_nested_attributes_for :comment, allow_destroy: true ...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/user.rb
spec/dummy_app/app/active_record/user.rb
# frozen_string_literal: true class User < ActiveRecord::Base # Include default devise modules. Others available are: # :token_authenticatable, :confirmable, :lockable and :timeoutable devise :database_authenticatable, :registerable, :recoverable, :rememberable, :trackable, :validatable if ActiveRecord.gem_ve...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/concerns/taggable.rb
spec/dummy_app/app/active_record/concerns/taggable.rb
# frozen_string_literal: true module Taggable extend ActiveSupport::Concern # dummy end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/user/confirmed.rb
spec/dummy_app/app/active_record/user/confirmed.rb
# frozen_string_literal: true class User class Confirmed < User end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/comment/confirmed.rb
spec/dummy_app/app/active_record/comment/confirmed.rb
# frozen_string_literal: true class Comment class Confirmed < Comment default_scope { where(content: 'something') } end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/paper_trail_test/subclass_in_namespace.rb
spec/dummy_app/app/active_record/paper_trail_test/subclass_in_namespace.rb
# frozen_string_literal: true class PaperTrailTest < ActiveRecord::Base class SubclassInNamespace < self end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/two_level/namespaced.rb
spec/dummy_app/app/active_record/two_level/namespaced.rb
# frozen_string_literal: true module TwoLevel module Namespaced def self.table_name_prefix 'two_level_namespaced_' end end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/two_level/namespaced/polymorphic_association_test.rb
spec/dummy_app/app/active_record/two_level/namespaced/polymorphic_association_test.rb
# frozen_string_literal: true module TwoLevel module Namespaced class PolymorphicAssociationTest < ActiveRecord::Base has_many :comments, as: :commentable end end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/app/active_record/cms/basic_page.rb
spec/dummy_app/app/active_record/cms/basic_page.rb
# frozen_string_literal: true module Cms class BasicPage < ActiveRecord::Base self.table_name = :cms_basic_pages validates :title, :content, presence: true end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/seeds.rb
spec/dummy_app/db/seeds.rb
# frozen_string_literal: true require 'mlb' user_model = RailsAdmin::AbstractModel.new(User) league_model = RailsAdmin::AbstractModel.new(League) division_model = RailsAdmin::AbstractModel.new(Division) team_model = RailsAdmin::AbstractModel.new(Team) player_model = RailsAdmin::AbstractModel.new(Player) ...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/schema.rb
spec/dummy_app/db/schema.rb
# This file is auto-generated from the current state of the database. Instead # of editing this file, please use the migrations feature of Active Record to # incrementally modify your database, and then regenerate this schema definition. # # This file is the source Rails uses to define your schema when running `bin/rai...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000001_create_divisions_migration.rb
spec/dummy_app/db/migrate/00000000000001_create_divisions_migration.rb
# frozen_string_literal: true class CreateDivisionsMigration < ActiveRecord::Migration[5.0] def self.up create_table :divisions do |t| t.timestamps null: false t.integer :league_id t.string :name, limit: 50, null: false end end def self.down drop_table(:divisions) end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110329183136_remove_league_id_from_teams.rb
spec/dummy_app/db/migrate/20110329183136_remove_league_id_from_teams.rb
# frozen_string_literal: true class RemoveLeagueIdFromTeams < ActiveRecord::Migration[5.0] def self.up remove_column :teams, :league_id end def self.down add_column :teams, :league_id, :integer end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20120118122004_add_categories.rb
spec/dummy_app/db/migrate/20120118122004_add_categories.rb
# frozen_string_literal: true class AddCategories < ActiveRecord::Migration[5.0] def change create_table :categories do |t| t.integer :parent_category_id end end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110224184303_create_field_tests.rb
spec/dummy_app/db/migrate/20110224184303_create_field_tests.rb
# frozen_string_literal: true class CreateFieldTests < ActiveRecord::Migration[5.0] def self.up create_table :field_tests do |t| t.string :string_field t.text :text_field t.integer :integer_field t.float :float_field t.decimal :decimal_field t.datetime :datetime_field t....
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110901150912_set_primary_key_not_null_for_divisions.rb
spec/dummy_app/db/migrate/20110901150912_set_primary_key_not_null_for_divisions.rb
# frozen_string_literal: true class SetPrimaryKeyNotNullForDivisions < ActiveRecord::Migration[5.0] def up drop_table :divisions create_table :divisions, id: false do |t| t.timestamps null: false t.primary_key :custom_id t.integer :custom_league_id t.string :name, limit: 50, null: fal...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110103205808_create_comments.rb
spec/dummy_app/db/migrate/20110103205808_create_comments.rb
# frozen_string_literal: true class CreateComments < ActiveRecord::Migration[5.0] def self.up create_table :comments do |t| t.integer :commentable_id t.string :commentable_type t.text :content t.timestamps null: false end end def self.down drop_table :comments end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000012_add_avatar_columns_to_user.rb
spec/dummy_app/db/migrate/00000000000012_add_avatar_columns_to_user.rb
# frozen_string_literal: true class AddAvatarColumnsToUser < ActiveRecord::Migration[5.0] def self.up add_column :users, :avatar_file_name, :string add_column :users, :avatar_content_type, :string add_column :users, :avatar_file_size, :integer add_column :users, :avatar_updated_at, :datetime ...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20151027181550_change_field_test_id_to_nested_field_tests.rb
spec/dummy_app/db/migrate/20151027181550_change_field_test_id_to_nested_field_tests.rb
# frozen_string_literal: true class ChangeFieldTestIdToNestedFieldTests < ActiveRecord::Migration[5.0] def change change_column :nested_field_tests, :field_test_id, :integer, null: false end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20150815102450_add_refile_to_field_tests.rb
spec/dummy_app/db/migrate/20150815102450_add_refile_to_field_tests.rb
# frozen_string_literal: true class AddRefileToFieldTests < ActiveRecord::Migration[5.0] def change add_column :field_tests, :refile_asset_id, :string add_column :field_tests, :refile_asset_filename, :string add_column :field_tests, :refile_asset_size, :string add_column :field_tests, :refile_asset_c...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20140412075608_create_deeply_nested_field_tests.rb
spec/dummy_app/db/migrate/20140412075608_create_deeply_nested_field_tests.rb
# frozen_string_literal: true class CreateDeeplyNestedFieldTests < ActiveRecord::Migration[5.0] def change create_table :deeply_nested_field_tests do |t| t.belongs_to :nested_field_test t.string :title t.timestamps null: false end end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20171229220713_add_enum_fields_to_field_tests.rb
spec/dummy_app/db/migrate/20171229220713_add_enum_fields_to_field_tests.rb
# frozen_string_literal: true class AddEnumFieldsToFieldTests < ActiveRecord::Migration[5.0] def change add_column :field_tests, :string_enum_field, :string add_column :field_tests, :integer_enum_field, :integer end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20120928075608_create_images.rb
spec/dummy_app/db/migrate/20120928075608_create_images.rb
# frozen_string_literal: true class CreateImages < ActiveRecord::Migration[5.0] def change create_table :images do |t| t.string :file_file_name t.string :file_content_type t.bigint :file_file_size t.datetime :file_updated_at t.timestamps null: false end end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20111123092549_create_nested_field_tests.rb
spec/dummy_app/db/migrate/20111123092549_create_nested_field_tests.rb
# frozen_string_literal: true class CreateNestedFieldTests < ActiveRecord::Migration[5.0] def change create_table :nested_field_tests do |t| t.string :title t.integer :field_test_id t.timestamps null: false end end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000002_create_drafts_migration.rb
spec/dummy_app/db/migrate/00000000000002_create_drafts_migration.rb
# frozen_string_literal: true class CreateDraftsMigration < ActiveRecord::Migration[5.0] def self.up create_table :drafts do |t| t.timestamps null: false t.integer :player_id t.integer :team_id t.date :date t.integer :round t.integer :pick t.integer :overall t.stri...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000013_add_roles_to_user.rb
spec/dummy_app/db/migrate/00000000000013_add_roles_to_user.rb
# frozen_string_literal: true class AddRolesToUser < ActiveRecord::Migration[5.0] def self.up add_column :users, :roles, :string end def self.down remove_column :users, :roles end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20140826093552_create_versions.rb
spec/dummy_app/db/migrate/20140826093552_create_versions.rb
# frozen_string_literal: true class CreateVersions < ActiveRecord::Migration[5.0] def change create_table :versions do |t| t.string :item_type, null: false t.integer :item_id, null: false t.string :event, null: false t.string :whodunnit t.text :object t.datetime :created_at ...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000003_create_leagues_migration.rb
spec/dummy_app/db/migrate/00000000000003_create_leagues_migration.rb
# frozen_string_literal: true class CreateLeaguesMigration < ActiveRecord::Migration[5.0] def self.up create_table :leagues do |t| t.timestamps null: false t.string :name, limit: 50, null: false end end def self.down drop_table :leagues end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000005_create_teams_migration.rb
spec/dummy_app/db/migrate/00000000000005_create_teams_migration.rb
# frozen_string_literal: true class CreateTeamsMigration < ActiveRecord::Migration[5.0] def self.up create_table :teams do |t| t.timestamps null: false t.integer :league_id t.integer :division_id t.string :name, limit: 50 t.string :logo_url, limit: 255 t.string :manager, limit...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110901142530_rename_league_id_foreign_key_on_divisions.rb
spec/dummy_app/db/migrate/20110901142530_rename_league_id_foreign_key_on_divisions.rb
# frozen_string_literal: true class RenameLeagueIdForeignKeyOnDivisions < ActiveRecord::Migration[5.0] def change rename_column :divisions, :league_id, :custom_league_id end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000006_devise_create_users.rb
spec/dummy_app/db/migrate/00000000000006_devise_create_users.rb
# frozen_string_literal: true class DeviseCreateUsers < ActiveRecord::Migration[5.0] def self.up create_table :users do |t| ## Database authenticatable t.string :email, null: false, default: '' t.string :encrypted_password, null: false, default: '' ## Recoverable t.str...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110328193014_create_cms_basic_pages.rb
spec/dummy_app/db/migrate/20110328193014_create_cms_basic_pages.rb
# frozen_string_literal: true class CreateCmsBasicPages < ActiveRecord::Migration[5.0] def self.up create_table :cms_basic_pages do |t| t.string :title t.text :content t.timestamps null: false end end def self.down drop_table :cms_basic_pages end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20160728152942_add_main_sponsor_to_teams.rb
spec/dummy_app/db/migrate/20160728152942_add_main_sponsor_to_teams.rb
# frozen_string_literal: true class AddMainSponsorToTeams < ActiveRecord::Migration[5.0] def change add_column :teams, :main_sponsor, :integer, default: 0, null: false end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110901131551_change_division_primary_key.rb
spec/dummy_app/db/migrate/20110901131551_change_division_primary_key.rb
# frozen_string_literal: true class ChangeDivisionPrimaryKey < ActiveRecord::Migration[5.0] def up drop_table :divisions create_table :divisions, primary_key: 'custom_id' do |t| t.timestamps null: false t.integer :league_id t.string :name, limit: 50, null: false end end def down ...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20201127111952_update_active_storage_tables.rb
spec/dummy_app/db/migrate/20201127111952_update_active_storage_tables.rb
# frozen_string_literal: true class UpdateActiveStorageTables < ActiveRecord::Migration[5.0] def change add_column :active_storage_blobs, :service_name, :string, null: false, default: 'local' create_table :active_storage_variant_records do |t| t.belongs_to :blob, null: false, index: false t.strin...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20210811121027_create_two_level_namespaced_polymorphic_association_tests.rb
spec/dummy_app/db/migrate/20210811121027_create_two_level_namespaced_polymorphic_association_tests.rb
# frozen_string_literal: true class CreateTwoLevelNamespacedPolymorphicAssociationTests < ActiveRecord::Migration[5.0] def change create_table :two_level_namespaced_polymorphic_association_tests do |t| t.string :name t.timestamps end end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20211011235734_add_bool_field_open.rb
spec/dummy_app/db/migrate/20211011235734_add_bool_field_open.rb
# frozen_string_literal: true class AddBoolFieldOpen < ActiveRecord::Migration[6.0] def change add_column :field_tests, :open, :boolean end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000010_add_revenue_to_team_migration.rb
spec/dummy_app/db/migrate/00000000000010_add_revenue_to_team_migration.rb
# frozen_string_literal: true class AddRevenueToTeamMigration < ActiveRecord::Migration[5.0] def self.up add_column :teams, :revenue, :decimal, precision: 18, scale: 2 end def self.down remove_column :teams, :revenue end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110123042530_rename_histories_to_rails_admin_histories.rb
spec/dummy_app/db/migrate/20110123042530_rename_histories_to_rails_admin_histories.rb
# frozen_string_literal: true class RenameHistoriesToRailsAdminHistories < ActiveRecord::Migration[5.0] def self.up rename_table :histories, :rails_admin_histories end def self.down rename_table :rails_admin_histories, :histories end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000007_create_histories_table.rb
spec/dummy_app/db/migrate/00000000000007_create_histories_table.rb
# frozen_string_literal: true class CreateHistoriesTable < ActiveRecord::Migration[5.0] def self.up create_table :histories do |t| t.string :message # title, name, or object_id t.string :username t.integer :item t.string :table t.timestamps null: false end add_index(:histori...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20240921171953_add_non_nullable_boolean_field.rb
spec/dummy_app/db/migrate/20240921171953_add_non_nullable_boolean_field.rb
# frozen_string_literal: true class AddNonNullableBooleanField < ActiveRecord::Migration[6.0] def change add_column :field_tests, :non_nullable_boolean_field, :boolean, null: false, default: false end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20220416102741_create_composite_key_tables.rb
spec/dummy_app/db/migrate/20220416102741_create_composite_key_tables.rb
# frozen_string_literal: true class CreateCompositeKeyTables < ActiveRecord::Migration[6.0] def change add_column :fans_teams, :since, :date create_table :favorite_players, primary_key: %i[fan_id team_id player_id] do |t| t.integer :fan_id, null: false t.integer :team_id, null: false t.int...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110831090841_add_protected_field_and_restricted_field_to_field_tests.rb
spec/dummy_app/db/migrate/20110831090841_add_protected_field_and_restricted_field_to_field_tests.rb
# frozen_string_literal: true class AddProtectedFieldAndRestrictedFieldToFieldTests < ActiveRecord::Migration[5.0] def change add_column :field_tests, :restricted_field, :string add_column :field_tests, :protected_field, :string end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20190531065324_create_action_text_tables.action_text.rb
spec/dummy_app/db/migrate/20190531065324_create_action_text_tables.action_text.rb
# frozen_string_literal: true class CreateActionTextTables < ActiveRecord::Migration[5.0] def change create_table :action_text_rich_texts do |t| t.string :name, null: false t.text :body, size: :long t.references :record, null: false, polymorphic: true, index: false t.timestamps...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000004_create_players_migration.rb
spec/dummy_app/db/migrate/00000000000004_create_players_migration.rb
# frozen_string_literal: true class CreatePlayersMigration < ActiveRecord::Migration[5.0] def self.up create_table :players do |t| t.timestamps null: false t.datetime :deleted_at t.integer :team_id t.string :name, limit: 100, null: false t.string :position, limit: 50 t.integer...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20210812115908_create_custom_versions.rb
spec/dummy_app/db/migrate/20210812115908_create_custom_versions.rb
# frozen_string_literal: true class CreateCustomVersions < ActiveRecord::Migration[5.0] def change create_table :custom_versions do |t| t.string :item_type, null: false t.integer :item_id, null: false t.string :event, null: false t.string :whodunnit t.text :object t.datetime :...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20101223222233_create_rel_tests.rb
spec/dummy_app/db/migrate/20101223222233_create_rel_tests.rb
# frozen_string_literal: true class CreateRelTests < ActiveRecord::Migration[5.0] def self.up create_table :rel_tests do |t| t.integer :league_id t.integer :division_id, null: false t.integer :player_id t.timestamps null: false end end def self.down drop_table :rel_tests e...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20140826093220_create_paper_trail_tests.rb
spec/dummy_app/db/migrate/20140826093220_create_paper_trail_tests.rb
# frozen_string_literal: true class CreatePaperTrailTests < ActiveRecord::Migration[5.0] def change create_table :paper_trail_tests do |t| t.string :name t.timestamps null: false end end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000011_add_suspended_to_player_migration.rb
spec/dummy_app/db/migrate/00000000000011_add_suspended_to_player_migration.rb
# frozen_string_literal: true class AddSuspendedToPlayerMigration < ActiveRecord::Migration[5.0] def self.up add_column :players, :suspended, :boolean, default: false end def self.down remove_column :players, :suspended end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20111130075338_add_dragonfly_asset_name_to_field_tests.rb
spec/dummy_app/db/migrate/20111130075338_add_dragonfly_asset_name_to_field_tests.rb
# frozen_string_literal: true class AddDragonflyAssetNameToFieldTests < ActiveRecord::Migration[5.0] def change add_column :field_tests, :dragonfly_asset_name, :string end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20180707101855_add_carrierwave_assets_to_field_tests.rb
spec/dummy_app/db/migrate/20180707101855_add_carrierwave_assets_to_field_tests.rb
# frozen_string_literal: true class AddCarrierwaveAssetsToFieldTests < ActiveRecord::Migration[5.0] def change add_column :field_tests, :carrierwave_assets, :string, after: :carrierwave_asset end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000014_add_color_to_team_migration.rb
spec/dummy_app/db/migrate/00000000000014_add_color_to_team_migration.rb
# frozen_string_literal: true class AddColorToTeamMigration < ActiveRecord::Migration[5.0] def self.up add_column :teams, :color, :string end def self.down remove_column :teams, :color end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20181029101829_add_shrine_data_to_field_tests.rb
spec/dummy_app/db/migrate/20181029101829_add_shrine_data_to_field_tests.rb
# frozen_string_literal: true class AddShrineDataToFieldTests < ActiveRecord::Migration[5.0] def change add_column :field_tests, :shrine_asset_data, :text add_column :field_tests, :shrine_versioning_asset_data, :text end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20120117151733_add_custom_field_to_teams.rb
spec/dummy_app/db/migrate/20120117151733_add_custom_field_to_teams.rb
# frozen_string_literal: true class AddCustomFieldToTeams < ActiveRecord::Migration[5.0] def change add_column :teams, :custom_field, :string end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20111115041025_add_type_to_balls.rb
spec/dummy_app/db/migrate/20111115041025_add_type_to_balls.rb
# frozen_string_literal: true class AddTypeToBalls < ActiveRecord::Migration[5.0] def change add_column :balls, :type, :string end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20111215083258_create_foo_bars.rb
spec/dummy_app/db/migrate/20111215083258_create_foo_bars.rb
# frozen_string_literal: true class CreateFooBars < ActiveRecord::Migration[5.0] def change create_table :foo_bars do |t| t.string :title t.timestamps null: false end end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20111108143642_add_dragonfly_and_carrierwave_to_field_tests.rb
spec/dummy_app/db/migrate/20111108143642_add_dragonfly_and_carrierwave_to_field_tests.rb
# frozen_string_literal: true class AddDragonflyAndCarrierwaveToFieldTests < ActiveRecord::Migration[5.0] def change add_column :field_tests, :paperclip_asset_file_name, :string add_column :field_tests, :dragonfly_asset_uid, :string add_column :field_tests, :carrierwave_asset, :string end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000009_create_fans_teams_migration.rb
spec/dummy_app/db/migrate/00000000000009_create_fans_teams_migration.rb
# frozen_string_literal: true class CreateFansTeamsMigration < ActiveRecord::Migration[5.0] def self.up create_table :fans_teams, id: false do |t| t.integer :fan_id, :team_id end end def self.down drop_table :fans_teams end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110714095433_create_balls.rb
spec/dummy_app/db/migrate/20110714095433_create_balls.rb
# frozen_string_literal: true class CreateBalls < ActiveRecord::Migration[5.0] def self.up create_table :balls, force: true do |t| t.string :color t.timestamps null: false end end def self.down drop_table :balls end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20180701084251_create_active_storage_tables.active_storage.rb
spec/dummy_app/db/migrate/20180701084251_create_active_storage_tables.active_storage.rb
# frozen_string_literal: true # This migration comes from active_storage (originally 20170806125915) class CreateActiveStorageTables < ActiveRecord::Migration[5.0] def change create_table :active_storage_blobs do |t| t.string :key, null: false t.string :filename, null: false t.stri...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20160728153058_add_formation_to_players.rb
spec/dummy_app/db/migrate/20160728153058_add_formation_to_players.rb
# frozen_string_literal: true class AddFormationToPlayers < ActiveRecord::Migration[5.0] def change add_column :players, :formation, :string, default: 'substitute', null: false end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20120319041705_drop_rel_tests.rb
spec/dummy_app/db/migrate/20120319041705_drop_rel_tests.rb
# frozen_string_literal: true class DropRelTests < ActiveRecord::Migration[5.0] def self.up drop_table :rel_tests end def self.down create_table :rel_tests do |t| t.integer :league_id t.integer :division_id, null: false t.integer :player_id t.timestamps null: false end end...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110607152842_add_format_to_field_test.rb
spec/dummy_app/db/migrate/20110607152842_add_format_to_field_test.rb
# frozen_string_literal: true class AddFormatToFieldTest < ActiveRecord::Migration[5.0] def self.up add_column :field_tests, :format, :string end def self.down remove_column :field_tests, :format end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/00000000000008_create_fans_migration.rb
spec/dummy_app/db/migrate/00000000000008_create_fans_migration.rb
# frozen_string_literal: true class CreateFansMigration < ActiveRecord::Migration[5.0] def self.up create_table :fans do |t| t.timestamps null: false t.string :name, limit: 100, null: false end end def self.down drop_table :fans end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20110901154834_change_length_for_rails_admin_histories.rb
spec/dummy_app/db/migrate/20110901154834_change_length_for_rails_admin_histories.rb
# frozen_string_literal: true class ChangeLengthForRailsAdminHistories < ActiveRecord::Migration[5.0] def up change_column :rails_admin_histories, :message, :text end def down change_column :rails_admin_histories, :message, :string end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/db/migrate/20120720075608_create_another_field_tests.rb
spec/dummy_app/db/migrate/20120720075608_create_another_field_tests.rb
# frozen_string_literal: true class CreateAnotherFieldTests < ActiveRecord::Migration[5.0] def change create_table :another_field_tests do |t| t.timestamps null: false end add_column :nested_field_tests, :another_field_test_id, :integer end end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/lib/does_not_load_autoload_paths_not_in_eager_load.rb
spec/dummy_app/lib/does_not_load_autoload_paths_not_in_eager_load.rb
# frozen_string_literal: true module DoesNotLoadAutoloadPathsNotInEagerLoad raise 'This file is in app.paths.autoload but not app.paths.eager_load and ' \ ' should not be autoloaded by rails_admin' end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/config/application.rb
spec/dummy_app/config/application.rb
# frozen_string_literal: true require File.expand_path('boot', __dir__) require 'action_controller/railtie' require 'action_mailer/railtie' begin require CI_ORM.to_s require "#{CI_ORM}/railtie" rescue LoadError # ignore errors end require 'active_storage/engine' if CI_ORM == :active_record require 'action_tex...
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/config/environment.rb
spec/dummy_app/config/environment.rb
# frozen_string_literal: true # Load the Rails application. require File.expand_path('application', __dir__) # Initialize the Rails application. DummyApp::Application.initialize!
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/config/puma.rb
spec/dummy_app/config/puma.rb
# frozen_string_literal: true threads 0, ENV.fetch('RAILS_MAX_THREADS', 3) port ENV.fetch('PORT', 3000)
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/config/routes.rb
spec/dummy_app/config/routes.rb
# frozen_string_literal: true DummyApp::Application.routes.draw do # Needed for :show_in_app tests resources :players, only: [:show] devise_for :users mount RailsAdmin::Engine => '/admin', as: 'rails_admin' root to: 'rails_admin/main#dashboard' end
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false
railsadminteam/rails_admin
https://github.com/railsadminteam/rails_admin/blob/d8e0809ea4b38415ace5b0d038fca317d805a3c1/spec/dummy_app/config/importmap.rb
spec/dummy_app/config/importmap.rb
# frozen_string_literal: true # Pin npm packages by running ./bin/importmap pin 'application', preload: true pin '@hotwired/turbo-rails', to: 'https://ga.jspm.io/npm:@hotwired/turbo-rails@7.1.3/app/javascript/turbo/index.js' pin '@rails/ujs', to: 'https://ga.jspm.io/npm:@rails/ujs@6.0.5/lib/assets/compiled/rails-ujs....
ruby
MIT
d8e0809ea4b38415ace5b0d038fca317d805a3c1
2026-01-04T15:39:16.877032Z
false