instance method
remove_timestamps
Ruby on Rails 4.2.9
Since v2.2.3Signature
remove_timestamps(table_name, options = {})
Removes the timestamp columns (created_at and updated_at) from the table definition.
remove_timestamps(:suppliers)
Parameters
-
table_namereq -
optionsopt = {}
Source
# File activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb, line 917
def remove_timestamps(table_name, options = {})
remove_column table_name, :updated_at
remove_column table_name, :created_at
end
Defined in activerecord/lib/active_record/connection_adapters/abstract/schema_statements.rb line 917
· View on GitHub
· Improve this page
· Find usages on GitHub
Defined in ActiveRecord::ConnectionAdapters::SchemaStatements