Skip to content

Commit

Permalink
export csv with column order expected for decryption (#16)
Browse files Browse the repository at this point in the history
  • Loading branch information
salimhb authored May 14, 2020
1 parent 7e3f06f commit 3d5f0f5
Showing 1 changed file with 21 additions and 1 deletion.
22 changes: 21 additions & 1 deletion app/models/concerns/rails_admin_config/for_ticket.rb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,27 @@ module ForTicket

included do
rails_admin do
fields :id, :entered_at, :left_at, :area, :encrypted_data
field :id
field :area, :string do
formatted_value do
bindings[:view].link_to(
value&.name,
bindings[:view].show_path(model_name: 'area', id: value&.id)
)
end
export_value do
value&.name
end
end
field :entered_at
field :left_at
field :encrypted_data

export do
configure :id do
hide
end
end
end
end
end
Expand Down

0 comments on commit 3d5f0f5

Please sign in to comment.