Class: ActiveRecord::Dbt::Seed::Enum::Csv
- Inherits:
-
Object
- Object
- ActiveRecord::Dbt::Seed::Enum::Csv
- Includes:
- Base
- Defined in:
- lib/active_record/dbt/seed/enum/csv.rb
Defined Under Namespace
Classes: DoesNotExistColumnError, NotEnumColumnError
Instance Attribute Summary
Attributes included from Base
#enum_column_name, #table_name
Instance Method Summary collapse
Methods included from Base
Instance Method Details
#dump ⇒ Object
18 19 20 21 22 |
# File 'lib/active_record/dbt/seed/enum/csv.rb', line 18 def dump CSV.generate(headers: true) do |csv| rows.each { |row| csv << row } end end |
#export_path ⇒ Object
14 15 16 |
# File 'lib/active_record/dbt/seed/enum/csv.rb', line 14 def export_path "#{basename}.csv" end |