Skip invite page after project creation

- Replace ``The project identifier is demo, remember it!``
by ``Invite other people to join this project!``
(linking to the invite page)
- Encourage users to share the project password via other
communication means in the reminder email
This commit is contained in:
0livd 2017-11-13 18:08:39 +01:00
parent e52fbbd239
commit 2933ebdfd8
8 changed files with 24 additions and 35 deletions

View file

@ -20,7 +20,7 @@ Changed
- Simpler and safer authentication logic (#270) - Simpler and safer authentication logic (#270)
- Use token based auth to reset passwords (#269) - Use token based auth to reset passwords (#269)
- Better install doc (#275) - Better install doc (#275)
- Use token based auth in invitation e-mails - Use token based auth in invitation e-mails (#280)
Added Added
===== =====

View file

@ -92,7 +92,7 @@
{% endblock %} {% endblock %}
{% block content %} {% block content %}
<div class="identifier">{{ _("The project identifier is") }} <a href="{{ url_for(".list_bills") }}">{{ g.project.id }}</a>, {{ _("remember it!") }}</div> <div class="identifier"><a href="{{ url_for(".invite") }}">{{ _("Invite people to join this project!") }}</a></div>
<a id="new-bill" href="{{ url_for(".add_bill") }}" class="btn btn-primary" data-toggle="modal" data-target="#bill-form">{{ _("Add a new bill") }}</a> <a id="new-bill" href="{{ url_for(".add_bill") }}" class="btn btn-primary" data-toggle="modal" data-target="#bill-form">{{ _("Add a new bill") }}</a>
<div id="bill-form" class="modal fade show" role="dialog"> <div id="bill-form" class="modal fade show" role="dialog">

View file

@ -3,7 +3,9 @@ Hi,
You have just (or someone else using your email address) created the project "{{ g.project.name }}" to share your expenses. You have just (or someone else using your email address) created the project "{{ g.project.name }}" to share your expenses.
You can access it here: {{ url_for(".list_bills", _external=True) }} (the identifier is {{ g.project.id }}), You can access it here: {{ url_for(".list_bills", _external=True) }} (the identifier is {{ g.project.id }}),
and the private code is "{{ g.project.password }}". and the shared password is "{{ g.project.password }}".
If you want to share this project with your friends, you can share the identifier and the shared password with them or send them invitations with the following link:
{{ url_for(".invite", _external=True) }}
Enjoy, Enjoy,
Some weird guys (with beards) Some weird guys (with beards)

View file

@ -4,5 +4,7 @@ Vous venez de créer le projet "{{ g.project.name }}" pour partager vos dépense
Vous pouvez y accéder ici: {{ url_for(".list_bills", _external=True) }} (l'identifieur est {{ g.project.id }}), Vous pouvez y accéder ici: {{ url_for(".list_bills", _external=True) }} (l'identifieur est {{ g.project.id }}),
et le code d'accès "{{ g.project.password }}". et le code d'accès "{{ g.project.password }}".
Si vous voulez partager ce projet avec vos amis, vous pouvez partager son identifiant et son code d'accès avec eux ou leur envoyer une invitation avec le lien suivant :
{{ url_for(".invite", _external=True) }}
Faites en bon usage ! Faites en bon usage !

View file

@ -1,17 +1,15 @@
{% extends "layout.html" %} {% extends "layout.html" %}
{% block sidebar %}
<ol>
<li>{{ _("Create the project") }}</li>
<li><strong>{{ _("Invite people") }}</strong></li>
<li><a href="{{ url_for(".list_bills") }}">{{ _("Use it!") }}</a></li>
</ol>
{% endblock %}
{% block content %} {% block content %}
<h2>{{ _("Invite people to join this project") }}</h2> <h2>{{ _("Invite people to join this project") }}</h2>
<p>{{ _("Specify a (comma separated) list of email adresses you want to notify about the <p>{{ _("Specify a (comma separated) list of email adresses you want to notify about the
creation of this budget management project and we will send them an email for you.") }}</p> creation of this budget management project and we will send them an email for you.") }}</p>
<p>{{ _("If you prefer, you can") }} <a href="{{ url_for(".list_bills") }}">{{ _("skip this step") }}</a> {{ _("and notify them yourself") }}</p> <p>{{ _("If you prefer, you can share the project identifier and the shared
password by other communication means. Or even directly share the following link:") }}</br>
<a href="{{ url_for(".authenticate", _external=True, token=g.project.generate_token()) }}">
{{ url_for(".authenticate", _external=True, token=g.project.generate_token()) }}
</a>
</p>
{% include "display_errors.html" %} {% include "display_errors.html" %}
<form class="invites form-horizontal" method="post" accept-charset="utf-8"> <form class="invites form-horizontal" method="post" accept-charset="utf-8">

View file

@ -480,12 +480,12 @@ msgid "reactivate"
msgstr "ré-activer" msgstr "ré-activer"
#: templates/list_bills.html:88 #: templates/list_bills.html:88
msgid "The project identifier is" msgid "Invite"
msgstr "L'identifiant de ce projet est" msgstr "Invitez"
#: templates/list_bills.html:88 #: templates/list_bills.html:88
msgid "remember it!" msgid "Invite people to join this project!"
msgstr "souvenez vous en !" msgstr "Invitez d'autres personnes à rejoindre ce projet !"
#: templates/list_bills.html:89 #: templates/list_bills.html:89
msgid "Add a new bill" msgid "Add a new bill"
@ -539,14 +539,6 @@ msgstr "Vos projets"
msgid "Reset your password" msgid "Reset your password"
msgstr "Changez votre mot de passe" msgstr "Changez votre mot de passe"
#: templates/send_invites.html:6
msgid "Invite people"
msgstr "Invitez des gens"
#: templates/send_invites.html:7
msgid "Use it!"
msgstr "Utilisez le !"
#: templates/send_invites.html:11 #: templates/send_invites.html:11
msgid "Invite people to join this project" msgid "Invite people to join this project"
msgstr "Invitez des personnes à rejoindre ce projet" msgstr "Invitez des personnes à rejoindre ce projet"
@ -562,16 +554,11 @@ msgstr ""
"par des virgules. On s'occupe de leur envoyer un email." "par des virgules. On s'occupe de leur envoyer un email."
#: templates/send_invites.html:14 #: templates/send_invites.html:14
msgid "If you prefer, you can" msgid "If you prefer, you can share the project identifier and the shared\n"
msgstr "Si vous préférez vous pouvez" "password by other communication means. Or even directly share the following link:"
msgstr "Si vous préférez vous pouvez partager l'identifiant du projet et son mot "
#: templates/send_invites.html:14 "de passe par un autre moyen de communication. Ou directement partager le lien "
msgid "skip this step" "suivant :"
msgstr "sauter cette étape"
#: templates/send_invites.html:14
msgid "and notify them yourself"
msgstr "et les avertir vous même"
#: templates/settle_bills.html:31 #: templates/settle_bills.html:31
msgid "Who pays?" msgid "Who pays?"

View file

@ -260,7 +260,7 @@ def create_project():
# redirect the user to the next step (invite) # redirect the user to the next step (invite)
flash(_("%(msg_compl)sThe project identifier is %(project)s", flash(_("%(msg_compl)sThe project identifier is %(project)s",
msg_compl=msg_compl, project=project.id)) msg_compl=msg_compl, project=project.id))
return redirect(url_for(".invite", project_id=project.id)) return redirect(url_for(".list_bills", project_id=project.id))
return render_template("create_project.html", form=form) return render_template("create_project.html", form=form)