-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/newsletter history #492
Conversation
a10838d
to
54397f4
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks great!
column :short_description | ||
column I18n.t("active_admin.operator_documents_page.attachment") do |n| | ||
link_to n.attachment.identifier, n.attachment.url if n.attachment.present? | ||
end |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
we can also add a column of type image with the activeadmin_addons
(in case it's useful).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nah, we don't need it ;)
app/admin/newsletter.rb
Outdated
f.inputs I18n.t("active_admin.shared.translated_fields") do | ||
f.input :force_translations_from, label: I18n.t("active_admin.shared.translate_from"), | ||
as: :select, | ||
collection: I18n.available_locales, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe sort them (I should do it in the observations as well).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok.
I18n.with_locale locale do | ||
# Some UTF charactes returned by google API are HTML encoded |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👀
@@ -59,17 +59,44 @@ | |||
|
|||
$stdout.puts "Syncing test data..." | |||
|
|||
sample_file_base64 = "data:application/pdf;base64,#{Base64.encode64(File.read(File.join(Rails.root, "spec", "support", "files", "doc.pdf")))}" | |||
sample_pdf_file = "data:application/pdf;base64,#{Base64.encode64(File.read(File.join(Rails.root, "spec", "support", "files", "doc.pdf")))}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the seeds file still used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Of course, most of the test data are fixtures dumped from production. That is used to have some initial data for E2E tests.
54397f4
to
167e1f7
Compare
Adding option to save previous newsletters in the database.