Module: RailsConsolePro::ActiveRecordExtensions::ClassMethods
- Defined in:
- lib/rails_console_pro/active_record_extensions.rb
Instance Method Summary collapse
-
#export_schema_to_file(file_path, format: nil) ⇒ Object
Export schema to file.
-
#schema_to_html(style: :default) ⇒ Object
Export schema to HTML.
-
#schema_to_json(pretty: true) ⇒ Object
Export schema to JSON.
-
#schema_to_yaml ⇒ Object
Export schema to YAML.
Instance Method Details
#export_schema_to_file(file_path, format: nil) ⇒ Object
Export schema to file
10 11 12 13 |
# File 'lib/rails_console_pro/active_record_extensions.rb', line 10 def export_schema_to_file(file_path, format: nil) result = Commands.schema(self) result&.export_to_file(file_path, format: format) end |
#schema_to_html(style: :default) ⇒ Object
Export schema to HTML
28 29 30 31 |
# File 'lib/rails_console_pro/active_record_extensions.rb', line 28 def schema_to_html(style: :default) result = Commands.schema(self) result&.to_html(style: style) end |