TMP commit
This commit is contained in:
@@ -12,14 +12,19 @@ module CsvExportable
|
||||
APPEARANCE_HEADERS = %i[name contact_info].freeze + COMMON_HEADERS
|
||||
APPEARANCE_VALUES = %w[name contact_info].freeze + COMMON_VALUES
|
||||
|
||||
LOCATION_HEADERS = %i[name address].freeze + COMMON_HEADERS
|
||||
LOCATION_VALUES = %w[name address].freeze + COMMON_VALUES
|
||||
|
||||
HEADERS = {
|
||||
acquired_media_release: ACQUIRED_MEDIA_HEADERS,
|
||||
appearance_release: APPEARANCE_HEADERS
|
||||
appearance_release: APPEARANCE_HEADERS,
|
||||
location_release: LOCATION_HEADERS
|
||||
}.freeze
|
||||
|
||||
VALUES = {
|
||||
acquired_media_release: ACQUIRED_MEDIA_VALUES,
|
||||
appearance_release: APPEARANCE_VALUES
|
||||
appearance_release: APPEARANCE_VALUES,
|
||||
location_release: LOCATION_VALUES
|
||||
}.freeze
|
||||
|
||||
included do
|
||||
@@ -35,9 +40,11 @@ module CsvExportable
|
||||
end
|
||||
|
||||
def to_csv_row
|
||||
VALUES[self.class.name.underscore.to_sym].map do |function|
|
||||
v = VALUES[self.class.name.underscore.to_sym].map do |function|
|
||||
send(function)
|
||||
end
|
||||
puts v
|
||||
v
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
@@ -744,6 +744,7 @@ en:
|
||||
search: Search
|
||||
empty: Location Releases will appear here
|
||||
table_headers:
|
||||
name: Name
|
||||
address: Address
|
||||
notes: Notes
|
||||
signed_at: Date Signed
|
||||
|
||||
@@ -302,6 +302,12 @@ es:
|
||||
form:
|
||||
photos:
|
||||
dropzone_label: Tap to take a photo of the Property (optional) (ES)
|
||||
index:
|
||||
table_headers:
|
||||
address: Address (ES)
|
||||
notes: Notes (ES)
|
||||
tags: Tags (ES)
|
||||
signed_at: Date Signed (ES)
|
||||
material_releases:
|
||||
form:
|
||||
photos:
|
||||
|
||||
Reference in New Issue
Block a user