Add feedback link QR code to confirmation emails
This commit is contained in:
parent
3dfdbad313
commit
49b85190f2
|
@ -1,11 +1,10 @@
|
|||
class Public::EventFeedbackQrcodesController < Public::ApplicationController
|
||||
def show
|
||||
event = current_conference.events.joins(:proposition).approved.find(params[:event_id])
|
||||
@qr = RQRCode::QRCode.new(new_event_feedback_url(event_id: event.id), level: :l)
|
||||
|
||||
respond_to do |format|
|
||||
format.svg do
|
||||
render(inline: @qr.as_svg(shape_rendering: "crispEdges", module_size: 11, fill: "ffffff", offset: 10),
|
||||
render(inline: helpers.feedback_qr_code_as_svg(event.id),
|
||||
filename: "feedback_qr_code_#{event.id}.svg")
|
||||
end
|
||||
end
|
||||
|
|
|
@ -85,4 +85,12 @@ module ApplicationHelper
|
|||
when 6 then t('ratings.excellent')
|
||||
end
|
||||
end
|
||||
|
||||
def feedback_qr_code(event_id)
|
||||
RQRCode::QRCode.new(new_event_feedback_url(event_id: event_id), level: :l)
|
||||
end
|
||||
|
||||
def feedback_qr_code_as_svg(event_id)
|
||||
feedback_qr_code(event_id).as_svg(shape_rendering: "crispEdges", module_size: 11, fill: "ffffff", offset: 10)
|
||||
end
|
||||
end
|
||||
|
|
|
@ -2,7 +2,10 @@ class EventMailer < ActionMailer::Base
|
|||
def confirmation_request(event)
|
||||
@event = event
|
||||
I18n.locale = @event.proposer.language
|
||||
|
||||
attachments['feedback-link-qr-code.svg'] = {
|
||||
mime_type: 'image/svg+xml',
|
||||
content: helpers.feedback_qr_code_as_svg(@event.id)
|
||||
}
|
||||
mail to: @event.proposer.email,
|
||||
from: "program@openfest.org",
|
||||
subject: I18n.t("event_mailer.acceptance_notification.subject",
|
||||
|
|
|
@ -9,6 +9,9 @@
|
|||
Моля, потвърдете участието си възможно най-скоро като кликнете на следния линк:
|
||||
<%= confirm_event_url @event, host: @event.conference.host_name, protocol: 'https' %>
|
||||
|
||||
Моля, добавете прикаченият към този e-mail QR код в презентацията си. Той
|
||||
съдържа връзка към формуляра за обратна връзка за предложеното от Вас събитие.
|
||||
|
||||
Моля пишете на ofvideo@openfest.org, ако имате специфични изисквания, например:
|
||||
|
||||
* да ви осигурим лаптоп за презентация;
|
||||
|
|
|
@ -9,8 +9,10 @@ It has not been scheduled yet.
|
|||
Please confirm your participation as soon as you can by following the following link:
|
||||
<%= confirm_event_url @event, host: @event.conference.host_name, protocol: 'https' %>
|
||||
|
||||
Please make sure you include the QR code attached to this email in your
|
||||
presentation. It contains a link to the feedback form for your <%= @event.event_type.name.downcase %>.
|
||||
|
||||
Please email ofvideo@openfest.org if you hav any specific requirements, for example:
|
||||
Please email ofvideo@openfest.org if you have any specific requirements, for example:
|
||||
|
||||
* You need us to provide you with a laptop for your presentation;
|
||||
* You need to play sound for your presentation;
|
||||
|
|
Loading…
Reference in New Issue