Sha256: 5c429c095fa199f23bdb5055504ccec1e62c7b78f8cde8ea95fc7431d01bfee2

Contents?: true

Size: 522 Bytes

Versions: 16

Compression:

Stored size: 522 Bytes

Contents

class ExtendPagePartContentLimit < ActiveRecord::Migration[5.1]
  def self.up
    if ActiveRecord::Base.connection.adapter_name =~ /m[sy]sql/i
      # Make sure text longer than 64kB is not cropped in MySQL and MSSQL
      # See https://github.com/radiant/radiant-sheets-extension/issues/10
      change_column :page_parts, :content, :text, :limit => 1048575
    end
  end

  def self.down
    if ActiveRecord::Base.connection.adapter_name =~ /m[sy]sql/i
      change_column :page_parts, :content, :text
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
trusty-cms-3.3.2 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.3.1 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.2.1 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.3.0 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.2.0 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.11 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.10 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.9 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.8 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.7 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.6 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.5 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.3 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.2 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.1 db/migrate/20111016150725_extend_page_part_content_limit.rb
trusty-cms-3.1.0 db/migrate/20111016150725_extend_page_part_content_limit.rb