doughnut-wedding/app/Resources/HWIOAuthBundle/views/Connect/registration.html.twig

83 lines
4.3 KiB
Twig
Raw Permalink Normal View History

2017-04-22 12:43:30 -07:00
{% extends 'base.html.twig' %}
2017-04-26 21:32:43 -07:00
{% block title %}Register with {{ userInformation.resourceOwner.name|capitalize }}{% endblock title %}
2017-04-22 12:43:30 -07:00
{% block body %}
2017-04-25 15:45:32 -07:00
2017-04-26 21:32:43 -07:00
<div class="uk-width-1-1">
{% if userInformation.response.name is defined %}
{% set name = userInformation.response.name %}
{% elseif userInformation.response.data.username is defined %}
{% set name = userInformation.response.data.username %}
{% elseif userInformation.resourceOwner.name == 'yahoo' %}
2017-04-25 15:45:32 -07:00
{% set name = userInformation.nickname %}
2017-04-22 12:43:30 -07:00
{% else %}
2017-04-25 15:45:32 -07:00
{% set name = userInformation.email %}
2017-04-22 12:43:30 -07:00
{% endif %}
2017-04-26 21:32:43 -07:00
<div class="uk-card uk-card-default uk-margin-small-bottom uk-width-1-1">
<div class="uk-card-header">
<div class="uk-grid-small uk-flex-middle" uk-grid>
<div class="uk-width-auto">
{% if userInformation.profilePicture is not empty %}
<img class="" width="40" height="40" src="{{ userInformation.profilePicture }}">
{% endif %}
</div>
<div class="uk-width-expand">
<p class="uk-text-large uk-card-title uk-margin-remove-bottom">Register with {{ userInformation.resourceOwner.name|capitalize }} account?</p>
</div>
</div>
</div>
<div class="uk-card-footer">
<p class="uk-margin-remove-top">
{{ 'header.register' | trans({'%name%': name }, 'HWIOAuthBundle') }}?
</p>
</div>
</div>
2017-04-22 12:43:30 -07:00
2017-04-25 15:45:32 -07:00
{{ form_start(form, {'action': path('hwi_oauth_connect_registration', {'key': key}), 'attr': {'class': 'hwi_oauth_registration_register uk-form uk-form-horizontal'}}) }}
{{ form_label(form.name, 'Name', {'label_attr':{'class':'uk-form-label uk-visible@m'}}) }}
<div class="uk-form-controls uk-form-controls-text uk-margin-small-bottom">
2017-05-05 22:49:54 -07:00
{{ form_errors(form.name) }}
{{ form_widget(form.name, {'value': name,'attr':{'class':'uk-input uk-form-large', 'placeholder':'Your name'}}) }}
2017-04-25 15:45:32 -07:00
</div>
{{ form_label(form.email, 'Email address', {'label_attr':{'class':'uk-form-label uk-visible@m'}}) }}
<div class="uk-form-controls uk-form-controls-text uk-margin-small-bottom">
2017-05-05 22:49:54 -07:00
{{ form_errors(form.email) }}
{{ form_widget(form.email, {'attr':{'class':'uk-input uk-form-large', 'placeholder':'Email address'}}) }}
2017-04-25 15:45:32 -07:00
</div>
{{ form_label(form.plainPassword.first, 'Password', {'label_attr':{'class':'uk-form-label uk-visible@m'}}) }}
<div class="uk-form-controls uk-form-controls-text uk-margin-small-bottom">
2017-05-05 22:49:54 -07:00
{{ form_errors(form.plainPassword.first) }}
{{ form_widget(form.plainPassword.first, {'attr':{'class':'uk-input uk-form-large', 'placeholder':'Create password'}}) }}
2017-04-25 15:45:32 -07:00
</div>
{{ form_label(form.plainPassword.second, 'Repeat password', {'label_attr':{'class':'uk-form-label uk-visible@m'}}) }}
<div class="uk-form-controls uk-form-controls-text uk-margin-small-bottom">
2017-05-05 22:49:54 -07:00
{{ form_errors(form.plainPassword.second) }}
2017-04-25 15:45:32 -07:00
{{ form_widget(form.plainPassword.second, {'attr':{'class':'uk-input uk-form-large', 'placeholder':'Repeat password'}}) }}
</div>
{{ form_label(form.rsvp, 'Number of guests? (including yourself)', {'label_attr':{'class':'uk-form-label uk-visible@m'}}) }}
<div class="uk-form-controls uk-form-controls-text uk-margin-small-bottom">
2017-05-05 22:49:54 -07:00
{{ form_errors(form.rsvp) }}
{{ form_widget(form.rsvp, {'attr':{'placeholder':'Number of guests including yourself.'}}) }}
2017-04-25 15:45:32 -07:00
</div>
{{ form_label(form.comment) }}
<div class="uk-form-controls uk-form-controls-text">
2017-05-05 22:49:54 -07:00
{{ form_errors(form.comment) }}
{{ form_widget(form.comment) }}
2017-04-25 15:45:32 -07:00
</div>
<div class="uk-child-width-1-2@m uk-child-width-1-1@s uk-grid uk-grid-divider uk-margin-medium-top" uk-grid>
<div>
<input type="submit" class="uk-width-1-1 uk-button-primary uk-button uk-button-large"
value="{{ 'connect.registration.submit'|trans({}, 'HWIOAuthBundle') }}"/>
</div>
<div>
<a href="{{ path('hwi_oauth_connect') }}"
class="uk-width-1-1 uk-button uk-button-large uk-button-danger">{{ 'connect.registration.cancel' | trans({}, 'HWIOAuthBundle') }}</a>
</div>
</div>
{{ form_end(form) }}
2017-04-22 12:43:30 -07:00
2017-04-25 15:45:32 -07:00
</div>
2017-04-09 18:08:01 -07:00
2017-04-22 12:43:30 -07:00
{% endblock body %}