remove unnecessary controls from profile for ext. auth.

This commit is contained in:
thomasDOTde 2017-11-01 13:40:26 +01:00
parent baa960aad6
commit f92661c753

View File

@ -29,10 +29,10 @@
Info</a></li> Info</a></li>
<li><a href="#tabs-avatar" data-toggle="tab">Change <li><a href="#tabs-avatar" data-toggle="tab">Change
Avatar</a></li> Avatar</a></li>
<li><a href="#tabs-password" data-toggle="tab">Change {% if not external_account %}<li><a href="#tabs-password" data-toggle="tab">Change
Password</a></li> Password</a></li>
<li><a href="#tabs-authentication" data-toggle="tab">Authentication <li><a href="#tabs-authentication" data-toggle="tab">Authentication
</a></li> </a></li>{% endif %}>
</ul> </ul>
<div class="tab-content"> <div class="tab-content">
<div class="tab-pane active" id="tabs-personal"> <div class="tab-pane active" id="tabs-personal">
@ -51,10 +51,10 @@
<label for="email">E-mail</label> <input type="text" <label for="email">E-mail</label> <input type="text"
class="form-control" name="email" id="email" class="form-control" name="email" id="email"
placeholder="{{ current_user.email }}" {% if external_account %}disabled{% endif %}> placeholder="{{ current_user.email }}" {% if external_account %}disabled{% endif %}>
</div> </div>{% if not external_account %}
<div class="form-group"> <div class="form-group">
<button type="submit" class="btn btn-flat btn-primary">Submit</button> <button type="submit" class="btn btn-flat btn-primary">Submit</button>
</div> </div>{% endif %}
</form> </form>
</div> </div>
<div class="tab-pane" id="tabs-avatar"> <div class="tab-pane" id="tabs-avatar">
@ -69,25 +69,25 @@
else %} <img else %} <img
src="{{ current_user.email|email_to_gravatar_url(size=200) }}" src="{{ current_user.email|email_to_gravatar_url(size=200) }}"
alt="" /> {% endif %} alt="" /> {% endif %}
</div> </div>{% if not external_account %}
<div> <div>
<label for="file">Select image</label> <input type="file" <label for="file">Select image</label> <input type="file"
id="file" name="file" {% if external_account %}disabled{% endif %}> id="file" name="file">
</div> </div>{% endif %}
</div> </div>{% if not external_account %}
<div> <div>
<span class="label label-danger">NOTE! </span> <span>&nbsp;Only <span class="label label-danger">NOTE! </span> <span>&nbsp;Only
supports <strong>.PNG, .JPG, .JPEG</strong>. The best size supports <strong>.PNG, .JPG, .JPEG</strong>. The best size
to use is <strong>200x200</strong>. to use is <strong>200x200</strong>.
</span> </span>
</div> </div>{% endif %}
</div> </div>{% if not external_account %}
<div class="form-group"> <div class="form-group">
<button type="submit" class="btn btn-flat btn-primary">Submit</button> <button type="submit" class="btn btn-flat btn-primary">Submit</button>
</div> </div>{% endif %}
</form> </form>
</div> </div>
<div class="tab-pane" id="tabs-password"> {% if not external_account %}<div class="tab-pane" id="tabs-password">
{% if not current_user.password %} Your account password is {% if not current_user.password %} Your account password is
managed via LDAP which isn't supported to change here. {% else managed via LDAP which isn't supported to change here. {% else
%} %}
@ -124,7 +124,7 @@
{% endif %} {% endif %}
</div> </div>
</form> </form>
</div> </div>{% endif %}
</div> </div>
</div> </div>
</div> </div>