-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create a pdf base template to support local url's
In order to be able to view pdf's in production a template with only local urls' had to be created. (cherry picked from commit 49e009b)
- Loading branch information
1 parent
fce6dfd
commit 9c0d421
Showing
6 changed files
with
204 additions
and
123 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,58 @@ | ||
{% extends 'MopaBootstrapBundle::base.html.twig' %} | ||
|
||
{% block title %} | ||
{% if block('page_title') is not empty %}{{ block('page_title') }} — {% endif %} | ||
{{ 'app.name'|trans }} | ||
{% endblock title %} | ||
|
||
{% block head_style %} | ||
|
||
<style type="text/css"> | ||
body { | ||
font-family: "Helvetica Neue", Helvetica, Arial, sans-serif; | ||
} | ||
.registration-print-options { | ||
display: none !important; | ||
} | ||
.pull-right { | ||
float: right; | ||
} | ||
.clearfix { | ||
float: none; | ||
} | ||
.page-header { | ||
height: 100px; | ||
} | ||
.page-header h1 { | ||
padding-top: 14px; | ||
} | ||
</style> | ||
|
||
{% endblock head_style %} | ||
{% block head_bottom %} | ||
{% endblock head_bottom %} | ||
|
||
{% block navbar %} | ||
{% endblock navbar %} | ||
|
||
{% block header %} | ||
{% endblock header %} | ||
|
||
{% block page_header %} | ||
<div class="page-header clearfix"> | ||
<img src="file://{{ root_path }}/../web/images/header-logo.png" class="pull-right logo" alt="OpenConext Stepup" style="width:55mm;"> | ||
<h1>{{ 'app.name'|trans }}</h1> | ||
</div> | ||
{% endblock page_header %} | ||
|
||
{% block content_row %} | ||
{% block content %} | ||
{% endblock content %} | ||
{% endblock content_row %} | ||
|
||
{% block footer %} | ||
{% endblock footer %} | ||
|
||
{% block foot_script %} | ||
|
||
{% endblock foot_script %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
90 changes: 90 additions & 0 deletions
90
...ce/SelfServiceBundle/Resources/views/Registration/partial/registrationEmailSent.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,90 @@ | ||
<p>{{ 'ss.registration.registration_email_sent.text.thank_you_for_registration'|trans }}</p> | ||
|
||
<p>{{ 'ss.registration.registration_email_sent.text.activation_instructions'|trans }}</p> | ||
|
||
<ul> | ||
<li>{{ 'ss.registration.registration_email_sent.text.activation_instructions_item_1'|trans }}</li> | ||
<li>{{ 'ss.registration.registration_email_sent.text.activation_instructions_item_2'|trans }}</li> | ||
<li>{{ 'ss.registration.registration_email_sent.text.activation_instructions_item_3'|trans }}</li> | ||
</ul> | ||
|
||
<br /> | ||
|
||
<p> | ||
{{ 'ss.registration.registration_email_sent.label.expiration_date' | ||
|trans({'%expirationDate%': expirationDate|localizeddate('full', 'none', locale)}) }} | ||
</p> | ||
|
||
<div class="row"> | ||
<div class="col-xs-12 col-sm-6 col-md-6"> | ||
<table class="table table-bordered table-hover table-responsive"> | ||
<tbody> | ||
<tr> | ||
<th scope="row">{{ 'ss.registration.registration_email_sent.label.registration_code'|trans }}</th> | ||
<td>{{ registrationCode }}</td> | ||
</tr> | ||
</tbody> | ||
</table> | ||
</div> | ||
</div> | ||
|
||
<br /> | ||
|
||
<p>{{ 'ss.registration.registration_email_sent.text.registration_code_has_been_sent'|trans({'%email%': email}) }}</p> | ||
|
||
<div class="registration-print-options"> | ||
{% if not verifyEmail %} | ||
<p>{{ 'ss.registration.registration_email_sent.text.registration_code_has_been_sent_no_email'|trans }}</p> | ||
{% endif %} | ||
|
||
<br /> | ||
|
||
<a href="#" class="registration-print"> | ||
<i class="fa fa-print fa-2x"></i> | ||
{{ 'ss.registration.registration_email_sent.text.registration_code_has_been_sent_print'|trans }} | ||
</a> | ||
<a href="{{ path('ss_registration_registration_pdf', {'secondFactorId': secondFactorId}) }}" class="registration-pdf"> | ||
<i class="fa fa-download fa-2x"></i> | ||
{{ 'ss.registration.registration_email_sent.text.registration_code_has_been_sent_pdf'|trans }} | ||
</a> | ||
</div> | ||
|
||
<hr> | ||
|
||
{% if raLocations is defined %} | ||
<h3>{{ 'ss.registration.registration_email_sent.title.list_of_ra_locations'|trans }}</h3> | ||
|
||
{% if raLocations.elements is empty %} | ||
<p>{{ 'ss.registration.registration_email_sent.text.no_ra_locations_for_your_institution'|trans }}</p> | ||
{% else %} | ||
<ul class="list-ras"> | ||
{% for raLocation in raLocations.elements %} | ||
<li> | ||
<address> | ||
<strong>{{ raLocation.name }}</strong><br> | ||
{{ raLocation.location }}<br> | ||
{{ raLocation.contactInformation }} | ||
</address> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
{% endif %} | ||
{% else %} | ||
<h3>{{ 'ss.registration.registration_email_sent.title.list_of_ras'|trans }}</h3> | ||
|
||
{% if ras.elements is empty %} | ||
<p>{{ 'ss.registration.registration_email_sent.text.no_ras_for_your_institution'|trans }}</p> | ||
{% else %} | ||
<ul class="list-ras"> | ||
{% for ra in ras.elements %} | ||
<li> | ||
<address> | ||
<strong>{{ ra.commonName }}</strong><br> | ||
{{ ra.location }}<br> | ||
{{ ra.contactInformation }} | ||
</address> | ||
</li> | ||
{% endfor %} | ||
</ul> | ||
{% endif %} | ||
{% endif %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
8 changes: 8 additions & 0 deletions
8
...Service/SelfServiceBundle/Resources/views/Registration/registrationEmailSentPdf.html.twig
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
{% extends "::pdf.html.twig" %} | ||
|
||
{% block page_title %}{{ 'ss.registration.registration_email_sent.title'|trans }}{% endblock %} | ||
|
||
{% block content %} | ||
<h2>{{ block('page_title') }}</h2> | ||
{% include 'SurfnetStepupSelfServiceSelfServiceBundle:Registration/partial:registrationEmailSent.html.twig' %} | ||
{% endblock %} |