diff --git a/app/dashboard/templates/dashboard/setting.html b/app/dashboard/templates/dashboard/setting.html index 2a9b654d..80ac9d2d 100644 --- a/app/dashboard/templates/dashboard/setting.html +++ b/app/dashboard/templates/dashboard/setting.html @@ -14,6 +14,13 @@

Profile

+ +
+ + {{ form.email(class="form-control", value=current_user.email, readonly=True) }} + {{ render_field_errors(form.email) }} +
+
{{ form.name(class="form-control", value=current_user.name) }} diff --git a/app/dashboard/views/setting.py b/app/dashboard/views/setting.py index a15844df..31bd7322 100644 --- a/app/dashboard/views/setting.py +++ b/app/dashboard/views/setting.py @@ -16,6 +16,7 @@ from app.utils import random_string class SettingForm(FlaskForm): + email = StringField("Email") name = StringField("Name", validators=[validators.DataRequired()]) profile_picture = FileField("Profile Picture") diff --git a/templates/header.html b/templates/header.html index bb17cebe..e6fac6b2 100644 --- a/templates/header.html +++ b/templates/header.html @@ -33,11 +33,11 @@ {{ current_user.name }} - {% if current_user.is_premium() %} - - Premium - {% endif %} - {{ current_user.email }} + + {% if current_user.is_premium() %} + Premium + {% endif %}