add setting for include_website_in_one_click_alias
This commit is contained in:
parent
6cd8e45d21
commit
4cea47cc27
|
@ -294,6 +294,15 @@ def setting():
|
||||||
Session.commit()
|
Session.commit()
|
||||||
flash("Your preference has been updated", "success")
|
flash("Your preference has been updated", "success")
|
||||||
return redirect(url_for("dashboard.setting"))
|
return redirect(url_for("dashboard.setting"))
|
||||||
|
elif request.form.get("form-name") == "include_website_in_one_click_alias":
|
||||||
|
choose = request.form.get("enable")
|
||||||
|
if choose == "on":
|
||||||
|
current_user.include_website_in_one_click_alias = True
|
||||||
|
else:
|
||||||
|
current_user.include_website_in_one_click_alias = False
|
||||||
|
Session.commit()
|
||||||
|
flash("Your preference has been updated", "success")
|
||||||
|
return redirect(url_for("dashboard.setting"))
|
||||||
|
|
||||||
elif request.form.get("form-name") == "export-data":
|
elif request.form.get("form-name") == "export-data":
|
||||||
return redirect(url_for("api.export_data"))
|
return redirect(url_for("api.export_data"))
|
||||||
|
|
|
@ -400,27 +400,52 @@
|
||||||
</div>
|
</div>
|
||||||
<!-- END Always expand alias info -->
|
<!-- END Always expand alias info -->
|
||||||
|
|
||||||
|
<!-- Include website address in alias -->
|
||||||
|
<div class="card" id="include_website_in_one_click_alias">
|
||||||
|
<div class="card-body">
|
||||||
|
<div class="card-title">
|
||||||
|
Include website address in one-click alias creation on browser extension
|
||||||
|
</div>
|
||||||
|
<div class="mb-3">
|
||||||
|
If enabled, the website name will be used as alias prefix
|
||||||
|
when you create an alias via SimpleLogin browser extension via the email input field <br>
|
||||||
|
<img src="https://simplelogin.io/images/one-click-alias.gif" class="my-2"
|
||||||
|
style="max-width: 40%">
|
||||||
|
</div>
|
||||||
|
<form method="post" action="#include_website_in_one_click_alias">
|
||||||
|
<input type="hidden" name="form-name" value="include_website_in_one_click_alias">
|
||||||
|
<div class="form-check">
|
||||||
|
<input type="checkbox" id="include-website-in-alias" name="enable"
|
||||||
|
{% if current_user.include_website_in_one_click_alias %} checked {% endif %} class="form-check-input">
|
||||||
|
<label for="include-website-in-alias">Include website address in alias</label>
|
||||||
|
</div>
|
||||||
|
<button type="submit" class="btn btn-outline-primary">Update</button>
|
||||||
|
</form>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<!-- END Include website address in alias -->
|
||||||
|
|
||||||
<!-- Ignore Loop Email -->
|
<!-- Ignore Loop Email -->
|
||||||
{# <div class="card" id="ignore-loop-email-section">#}
|
{# <div class="card" id="ignore-loop-email-section">#}
|
||||||
{# <div class="card-body">#}
|
{# <div class="card-body">#}
|
||||||
{# <div class="card-title">Ignore Loop Emails</div>#}
|
{# <div class="card-title">Ignore Loop Emails</div>#}
|
||||||
{# <div class="mb-3">#}
|
{# <div class="mb-3">#}
|
||||||
{# On some email clients, "Reply All" automatically includes your alias that#}
|
{# On some email clients, "Reply All" automatically includes your alias that#}
|
||||||
{# would send the same email to your mailbox.#}
|
{# would send the same email to your mailbox.#}
|
||||||
{# <br>#}
|
{# <br>#}
|
||||||
{# You can disable these "loop" emails by enabling this option.#}
|
{# You can disable these "loop" emails by enabling this option.#}
|
||||||
{# </div>#}
|
{# </div>#}
|
||||||
{# <form method="post" action="#ignore-loop-email-section">#}
|
{# <form method="post" action="#ignore-loop-email-section">#}
|
||||||
{# <input type="hidden" name="form-name" value="ignore-loop-email">#}
|
{# <input type="hidden" name="form-name" value="ignore-loop-email">#}
|
||||||
{# <div class="form-check">#}
|
{# <div class="form-check">#}
|
||||||
{# <input type="checkbox" id="ignore-loop-email" name="enable"#}
|
{# <input type="checkbox" id="ignore-loop-email" name="enable"#}
|
||||||
{# {% if current_user.ignore_loop_email %} checked {% endif %} class="form-check-input">#}
|
{# {% if current_user.ignore_loop_email %} checked {% endif %} class="form-check-input">#}
|
||||||
{# <label for="ignore-loop-email">Ignore Loop Emails</label>#}
|
{# <label for="ignore-loop-email">Ignore Loop Emails</label>#}
|
||||||
{# </div>#}
|
{# </div>#}
|
||||||
{# <button type="submit" class="btn btn-outline-primary">Update</button>#}
|
{# <button type="submit" class="btn btn-outline-primary">Update</button>#}
|
||||||
{# </form>#}
|
{# </form>#}
|
||||||
{# </div>#}
|
{# </div>#}
|
||||||
{# </div>#}
|
{# </div>#}
|
||||||
<!-- END Ignore Loop Email -->
|
<!-- END Ignore Loop Email -->
|
||||||
|
|
||||||
<!-- One-click subscribe -->
|
<!-- One-click subscribe -->
|
||||||
|
|
Loading…
Reference in a new issue