commit
22e0013d00
|
@ -22,12 +22,6 @@
|
||||||
<form method="post">
|
<form method="post">
|
||||||
{{ form.csrf_token }}
|
{{ form.csrf_token }}
|
||||||
<div class="card-body p-6">
|
<div class="card-body p-6">
|
||||||
<div class="form-group">
|
|
||||||
<label class="form-label">How should we call you?</label>
|
|
||||||
{{ form.name(class="form-control") }}
|
|
||||||
{{ render_field_errors(form.name) }}
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="form-group">
|
<div class="form-group">
|
||||||
<label class="form-label">Email address</label>
|
<label class="form-label">Email address</label>
|
||||||
{{ form.email(class="form-control", type="email") }}
|
{{ form.email(class="form-control", type="email") }}
|
||||||
|
|
|
@ -17,7 +17,6 @@ class RegisterForm(FlaskForm):
|
||||||
password = StringField(
|
password = StringField(
|
||||||
"Password", validators=[validators.DataRequired(), validators.Length(min=8)]
|
"Password", validators=[validators.DataRequired(), validators.Length(min=8)]
|
||||||
)
|
)
|
||||||
name = StringField("Name", validators=[validators.DataRequired()])
|
|
||||||
|
|
||||||
|
|
||||||
@auth_bp.route("/register", methods=["GET", "POST"])
|
@auth_bp.route("/register", methods=["GET", "POST"])
|
||||||
|
@ -46,9 +45,7 @@ def register():
|
||||||
else:
|
else:
|
||||||
LOG.debug("create user %s", form.email.data)
|
LOG.debug("create user %s", form.email.data)
|
||||||
user = User.create(
|
user = User.create(
|
||||||
email=form.email.data.lower(),
|
email=form.email.data.lower(), name="", password=form.password.data,
|
||||||
name=form.name.data,
|
|
||||||
password=form.password.data,
|
|
||||||
)
|
)
|
||||||
db.session.commit()
|
db.session.commit()
|
||||||
|
|
||||||
|
|
|
@ -133,8 +133,12 @@
|
||||||
|
|
||||||
<nav aria-label="Alias log navigation">
|
<nav aria-label="Alias log navigation">
|
||||||
<ul class="pagination">
|
<ul class="pagination">
|
||||||
<li class="page-item {% if page_id == 0 %}disabled{% endif %}"><a class="page-link" href="{{ url_for('dashboard.alias_log', alias=alias, page_id=page_id-1) }}">Previous</a></li>
|
<li class="page-item {% if page_id == 0 %}disabled{% endif %}">
|
||||||
<li class="page-item {% if last_page %}disabled{% endif %}"><a class="page-link" href="{{ url_for('dashboard.alias_log', alias=alias, page_id=page_id+1) }}">Next</a></li>
|
<a class="page-link" href="{{ url_for('dashboard.alias_log', alias_id=alias_id, page_id=page_id-1) }}">Previous</a>
|
||||||
|
</li>
|
||||||
|
<li class="page-item {% if last_page %}disabled{% endif %}">
|
||||||
|
<a class="page-link" href="{{ url_for('dashboard.alias_log', alias_id=alias_id, page_id=page_id+1) }}">Next</a>
|
||||||
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</nav>
|
</nav>
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
|
@ -111,7 +111,7 @@
|
||||||
<span class="alias-activity">{{ alias_info.nb_forward }}</span> forwards,
|
<span class="alias-activity">{{ alias_info.nb_forward }}</span> forwards,
|
||||||
<span class="alias-activity">{{ alias_info.nb_blocked }}</span> blocks,
|
<span class="alias-activity">{{ alias_info.nb_blocked }}</span> blocks,
|
||||||
<span class="alias-activity">{{ alias_info.nb_reply }}</span> replies
|
<span class="alias-activity">{{ alias_info.nb_reply }}</span> replies
|
||||||
<a href="{{ url_for('dashboard.alias_log', alias=gen_email.email) }}"
|
<a href="{{ url_for('dashboard.alias_log', alias_id=gen_email.id) }}"
|
||||||
class="btn btn-sm btn-link">
|
class="btn btn-sm btn-link">
|
||||||
See All Activity →
|
See All Activity →
|
||||||
</a>
|
</a>
|
||||||
|
|
|
@ -22,11 +22,13 @@ class AliasLog:
|
||||||
setattr(self, k, v)
|
setattr(self, k, v)
|
||||||
|
|
||||||
|
|
||||||
@dashboard_bp.route("/alias_log/<alias>", methods=["GET"], defaults={"page_id": 0})
|
@dashboard_bp.route(
|
||||||
@dashboard_bp.route("/alias_log/<alias>/<int:page_id>")
|
"/alias_log/<int:alias_id>", methods=["GET"], defaults={"page_id": 0}
|
||||||
|
)
|
||||||
|
@dashboard_bp.route("/alias_log/<int:alias_id>/<int:page_id>")
|
||||||
@login_required
|
@login_required
|
||||||
def alias_log(alias, page_id):
|
def alias_log(alias_id, page_id):
|
||||||
gen_email = GenEmail.get_by(email=alias)
|
gen_email = GenEmail.get(alias_id)
|
||||||
|
|
||||||
# sanity check
|
# sanity check
|
||||||
if not gen_email:
|
if not gen_email:
|
||||||
|
|
|
@ -30,7 +30,7 @@ def _render(template_name, **kwargs) -> str:
|
||||||
def send_welcome_email(email, name):
|
def send_welcome_email(email, name):
|
||||||
send_email(
|
send_email(
|
||||||
email,
|
email,
|
||||||
f"{name}, welcome to SimpleLogin!",
|
f"Welcome to SimpleLogin {name}!",
|
||||||
_render("welcome.txt", name=name),
|
_render("welcome.txt", name=name),
|
||||||
_render("welcome.html", name=name),
|
_render("welcome.html", name=name),
|
||||||
)
|
)
|
||||||
|
@ -39,7 +39,7 @@ def send_welcome_email(email, name):
|
||||||
def send_activation_email(email, name, activation_link):
|
def send_activation_email(email, name, activation_link):
|
||||||
send_email(
|
send_email(
|
||||||
email,
|
email,
|
||||||
f"{name}, just one more step to join SimpleLogin",
|
f"Just one more step to join SimpleLogin {name}",
|
||||||
_render(
|
_render(
|
||||||
"activation.txt", name=name, activation_link=activation_link, email=email
|
"activation.txt", name=name, activation_link=activation_link, email=email
|
||||||
),
|
),
|
||||||
|
@ -52,7 +52,7 @@ def send_activation_email(email, name, activation_link):
|
||||||
def send_reset_password_email(email, name, reset_password_link):
|
def send_reset_password_email(email, name, reset_password_link):
|
||||||
send_email(
|
send_email(
|
||||||
email,
|
email,
|
||||||
f"{name}, reset your password on SimpleLogin",
|
f"Reset your password on SimpleLogin",
|
||||||
_render(
|
_render(
|
||||||
"reset-password.txt", name=name, reset_password_link=reset_password_link
|
"reset-password.txt", name=name, reset_password_link=reset_password_link
|
||||||
),
|
),
|
||||||
|
@ -65,7 +65,7 @@ def send_reset_password_email(email, name, reset_password_link):
|
||||||
def send_change_email(new_email, current_email, name, link):
|
def send_change_email(new_email, current_email, name, link):
|
||||||
send_email(
|
send_email(
|
||||||
new_email,
|
new_email,
|
||||||
f"{name}, confirm email update on SimpleLogin",
|
f"Confirm email update on SimpleLogin",
|
||||||
_render(
|
_render(
|
||||||
"change-email.txt",
|
"change-email.txt",
|
||||||
name=name,
|
name=name,
|
||||||
|
@ -86,7 +86,7 @@ def send_change_email(new_email, current_email, name, link):
|
||||||
def send_new_app_email(email, name):
|
def send_new_app_email(email, name):
|
||||||
send_email(
|
send_email(
|
||||||
email,
|
email,
|
||||||
f"{name}, any question/feedback for SimpleLogin?",
|
f"Any question/feedback for SimpleLogin {name}?",
|
||||||
_render("new-app.txt", name=name),
|
_render("new-app.txt", name=name),
|
||||||
_render("new-app.html", name=name),
|
_render("new-app.html", name=name),
|
||||||
)
|
)
|
||||||
|
@ -95,7 +95,7 @@ def send_new_app_email(email, name):
|
||||||
def send_test_email_alias(email, name):
|
def send_test_email_alias(email, name):
|
||||||
send_email(
|
send_email(
|
||||||
email,
|
email,
|
||||||
f"{name}, this email is sent to {email}",
|
f"This email is sent to {email}",
|
||||||
_render("test-email.txt", name=name, alias=email),
|
_render("test-email.txt", name=name, alias=email),
|
||||||
_render("test-email.html", name=name, alias=email),
|
_render("test-email.html", name=name, alias=email),
|
||||||
)
|
)
|
||||||
|
|
|
@ -1,8 +1,18 @@
|
||||||
{% extends "base.html" %}
|
{% extends "base.html" %}
|
||||||
|
|
||||||
{% block content %}
|
{% block content %}
|
||||||
{{ render_text("Welcome " + name + " 🎉!") }}
|
{{ render_text("Hi " + name) }}
|
||||||
{{ render_text("I really appreciate you signing up for SimpleLogin, and I'm sure you'll love it when you see how *simple* it is to use.") }}
|
|
||||||
{{ render_text("We built SimpleLogin to help people protecting their online identity, and I hope that we can achieve that for you.") }}
|
{{ render_text("My name is Son. I’m the founder of SimpleLogin and I wanted to be the first to welcome you on board.") }}
|
||||||
|
|
||||||
|
{{ render_text('To better secure your account, I recommend enabling Multi-Factor Authentication (MFA) on your <a href="https://app.simplelogin.io/dashboard/setting">Setting page</a>.') }}
|
||||||
|
|
||||||
|
{{ render_text('If you use Chrome or Firefox, SimpleLogin extension could be quite handy to quickly create aliases. Chrome extension can be installed on <a href="https://chrome.google.com/webstore/detail/simplelogin-your-anti-spa/dphilobhebphkdjbpfohgikllaljmgbn">Chrome Store</a> and Firefox on <a href="https://addons.mozilla.org/en-GB/firefox/addon/simplelogin/">Firefox Store</a>.') }}
|
||||||
|
|
||||||
|
{{ render_text('If you have a domain, for example for your business or your project, you can import your domain into SimpleLogin
|
||||||
|
and create your business emails backed by your personal email. This is cheaper and more convenient than buying a GSuite account. By the way, all our business emails are actually aliases :).') }}
|
||||||
|
|
||||||
|
{{ render_text('Importing domain is only available for Premium plan though, shoot me an email if you need a trial period.') }}
|
||||||
|
|
||||||
{% endblock %}
|
{% endblock %}
|
||||||
|
|
||||||
|
|
|
@ -1,9 +1,20 @@
|
||||||
Welcome {{name}} 🎉!
|
Hi {{name}}
|
||||||
|
|
||||||
I really appreciate you signing up for SimpleLogin, and I'm sure you'll love it when you see how *simple* it is to use.
|
My name is Son. I’m the founder of SimpleLogin and I wanted to be the first to welcome you on board.
|
||||||
|
|
||||||
We built SimpleLogin to help people protecting their online identity, and I hope that we can achieve that for you.
|
To better secure your account, I recommend enabling Multi-Factor Authentication (MFA) on your setting page at
|
||||||
|
https://app.simplelogin.io/dashboard/setting
|
||||||
|
|
||||||
|
If you use Chrome or Firefox, SimpleLogin extension could be quite handy to quickly create aliases.
|
||||||
|
You can install Chrome extension on
|
||||||
|
https://chrome.google.com/webstore/detail/simplelogin-your-anti-spa/dphilobhebphkdjbpfohgikllaljmgbn
|
||||||
|
|
||||||
|
and Firefox on
|
||||||
|
https://addons.mozilla.org/en-GB/firefox/addon/simplelogin/
|
||||||
|
|
||||||
|
If you have a domain, for example for your business or your project, you can import your domain into SimpleLogin
|
||||||
|
and create your business emails backed by your personal email! By the way, all our business emails are actually aliases 🤫.
|
||||||
|
Importing domain is only available for Premium plan though, shoot me an email if you need a trial period.
|
||||||
|
|
||||||
Thanks.
|
Thanks.
|
||||||
|
|
||||||
Son - SimpleLogin founder.
|
Son - SimpleLogin founder.
|
||||||
|
|
Loading…
Reference in a new issue