activeadmin-selleo-cms 0.0.59 → 0.0.60
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -21,7 +21,7 @@ class FormsController < ApplicationController
|
|
21
21
|
def deliver
|
22
22
|
respond_to do |format|
|
23
23
|
format.html do
|
24
|
-
if ActiveadminSelleoCms::FormMailer.respond_to? :delay
|
24
|
+
if ActiveadminSelleoCms::FormMailer.respond_to? :delay and !Rails.env.development?
|
25
25
|
ActiveadminSelleoCms::FormMailer.delay.form_submission(@form, params[:form_uuid])
|
26
26
|
else
|
27
27
|
ActiveadminSelleoCms::FormMailer.form_submission(@form, params[:form_uuid]).deliver
|
@@ -4,15 +4,18 @@
|
|
4
4
|
<meta content='text/html; charset=UTF-8' http-equiv='Content-Type' />
|
5
5
|
</head>
|
6
6
|
<body>
|
7
|
-
<h3
|
7
|
+
<h3><%= t("active_admin.cms.forms.new_form_email.header", form_title: @form.title) %></h3>
|
8
8
|
<p>
|
9
|
-
<%=
|
9
|
+
<%= t("active_admin.cms.forms.new_form_email.body") %>
|
10
10
|
</p>
|
11
11
|
<p>
|
12
|
-
<%= link_to "
|
12
|
+
<%= link_to t("active_admin.cms.forms.new_form_email.preview_link"), "http://#{ActionMailer::Base.default_url_options[:host]}/forms/#{@form.id}/download?form_uuid=#{@form_uuid}" %>
|
13
13
|
</p>
|
14
14
|
<p>
|
15
|
-
<%= link_to "
|
15
|
+
<%= link_to t("active_admin.cms.forms.new_form_email.print_link"), "http://#{ActionMailer::Base.default_url_options[:host]}/forms/#{@form.id}/download?form_uuid=#{@form_uuid}&print=true" %>
|
16
|
+
</p>
|
17
|
+
<p>
|
18
|
+
<%= link_to t("active_admin.cms.forms.new_form_email.pdf_link"), "http://#{ActionMailer::Base.default_url_options[:host]}/forms/#{@form.id}/download.pdf?form_uuid=#{@form_uuid}" %>
|
16
19
|
</p>
|
17
20
|
</body>
|
18
21
|
</html>
|
data/config/locales/cms.en.yml
CHANGED
@@ -42,8 +42,15 @@ en:
|
|
42
42
|
other: "Other"
|
43
43
|
required: " (required)"
|
44
44
|
email: "Delivery email"
|
45
|
-
email_subject: "New form has been submitted"
|
46
45
|
upload: "Upload"
|
47
46
|
upload_new_file: "Upload new file"
|
48
47
|
uploaded_files: "Uploaded files"
|
49
48
|
delete: "(delete)"
|
49
|
+
new_form_email:
|
50
|
+
subject: "New form has been submitted"
|
51
|
+
header: "A new form %{form_title} has been submitted!"
|
52
|
+
body: "You can preview, print or download the form as PDF by clicking one of the following links:"
|
53
|
+
preview_link: "Preview"
|
54
|
+
print_link: "Print"
|
55
|
+
pdf_link: "Download PDF"
|
56
|
+
|