Skip to content

Commit

Permalink
theme and send forgot password email
Browse files Browse the repository at this point in the history
  • Loading branch information
jbouzekri committed Jun 8, 2014
1 parent 09082d4 commit 50c46bb
Show file tree
Hide file tree
Showing 8 changed files with 88 additions and 38 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,8 @@ fos_user_change_password:
profile:
show:
language: Language
timezone: Timezone
timezone: Timezone

form:
new_password: New password
new_password_confirmation: Confirm new password
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,8 @@ fos_user_change_password:
profile:
show:
language: Langue
timezone: Fuseau horaire
timezone: Fuseau horaire

form:
new_password: Nouveau mot de passe
new_password_confirmation: Confirmation nouveau mot de passe
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ registration:
title: Register New Membership
submit: Sign me up
has_account: I already have a membership
start_betting: Start Betting

"Bad credentials": Invalid login or password

Expand All @@ -32,4 +33,7 @@ resetting:

fos_user_registration_confirmed.title: Register New Membership
fos_user_resetting_send_email.title: Resetting password
fos_user_resetting_check_email.title: Email sent
fos_user_resetting_check_email.title: Email sent
fos_user_resetting_reset.title: Forgot password
reset.title: Forgot password
reset.request.submit: Save
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ registration:
title: Créer un compte
submit: Enregistrer
has_account: Retour à l'écran de connexion
start_betting: Commencer à parier

"Bad credentials": Login ou mot de passe invalide

Expand All @@ -32,4 +33,7 @@ resetting:

fos_user_registration_confirmed.title: Créer un compte
fos_user_resetting_send_email.title: Mot de passe oublié
fos_user_resetting_check_email.title: Email envoyé
fos_user_resetting_check_email.title: Email envoyé
fos_user_resetting_reset.title: Mot de passe oublié
reset.title: Mot de passe oublié
reset.request.submit: Enregistrer
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{% block form_widget_compound %}
{% spaceless %}
<div class="body bg-gray">
{% if form.parent is empty %}
{{ form_errors(form) }}
{% endif %}
{{ block('form_rows') }}
{{ form_rest(form) }}
</div>
{% endspaceless %}
{% endblock form_widget_compound %}

{% block form_row %}
{% spaceless %}
<div class="form-group">
{{ form_errors(form) }}
{{ form_widget(form, { 'attr': {'class': 'form-control', 'placeholder': form.vars.label|trans({},'security') } }) }}
</div>
{% endspaceless %}
{% endblock %}

{% block form_errors %}
{% spaceless %}
{% if errors|length > 0 %}
<div class="alert flat-alert alert-danger">
{% for error in errors %}
<p>{{ error.message }}</p>
{% endfor %}
</div>
{% endif %}
{% endspaceless %}
{% endblock form_errors %}
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{% extends "FOSUserBundle::layout.html.twig" %}

{% block fos_user_content %}
<p>{{ 'registration.confirmed'|trans({'%username%': user.username}, 'FOSUserBundle') }}</p>

<a href="{{ path('event_next_list') }}" class="btn btn-primary btn-block">
{{ "registration.start_betting"|trans({},'security') }}
</a>
{% endblock fos_user_content %}
Original file line number Diff line number Diff line change
Expand Up @@ -5,40 +5,7 @@

{% block title %}{{ 'registration.title'|trans({}, 'security') }}{% endblock %}

{% form_theme form _self %}

{% block form_widget_compound %}
{% spaceless %}
<div class="body bg-gray">
{% if form.parent is empty %}
{{ form_errors(form) }}
{% endif %}
{{ block('form_rows') }}
{{ form_rest(form) }}
</div>
{% endspaceless %}
{% endblock form_widget_compound %}

{% block form_row %}
{% spaceless %}
<div class="form-group">
{{ form_errors(form) }}
{{ form_widget(form, { 'attr': {'class': 'form-control', 'placeholder': form.vars.label|trans({},'security') } }) }}
</div>
{% endspaceless %}
{% endblock %}

{% block form_errors %}
{% spaceless %}
{% if errors|length > 0 %}
<div class="alert flat-alert alert-danger">
{% for error in errors %}
<p>{{ error.message }}</p>
{% endfor %}
</div>
{% endif %}
{% endspaceless %}
{% endblock form_errors %}
{% form_theme form "FreeBetUserBundle:Form:FOSFormTheme.html.twig" %}

{% block body %}
<div class="form-box" id="login-box">
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{% extends "FreeBetUserBundle::layout.html.twig" %}

{% block htmlclass %} class="bg-black"{% endblock %}
{% block bodyclass %}bg-black{% endblock %}

{% block title %}{{ 'reset.title'|trans({}, 'security') }}{% endblock %}

{% form_theme form "FreeBetUserBundle:Form:FOSFormTheme.html.twig" %}

{% block body %}
<div class="form-box" id="login-box">
<div class="header">{{ 'reset.title'|trans({}, 'security') }}</div>
<form action="{{ path('fos_user_resetting_reset', {'token': token}) }}" method="POST">
<div class="body bg-gray">
{{ form_widget(form) }}
</div>
<div class="footer">
<button type="submit" value="{{ 'reset.request.submit'|trans({}, 'security') }}" class="btn bg-olive btn-block">
{{ 'reset.request.submit'|trans({}, 'security') }}
</button>
<a href="{{ path('fos_user_security_login') }}" class="text-center">{{ 'login.back'|trans({}, 'security') }}</a>
</div>
</form>
</div>
</div>
{% endblock %}

0 comments on commit 50c46bb

Please sign in to comment.