new user: disable kobo token on new user page

kobo token generator function is related to a user id, which is not
present on new user page.
Disable the Kobo token part when creating a new user.
pull/1162/head
Simon Latapie 5 years ago
parent cd9bb56db5
commit 69fa7d0091

@ -55,7 +55,7 @@
{% endfor %} {% endfor %}
</div> </div>
{% endif %} {% endif %}
{% if feature_support['kobo'] %} {% if feature_support['kobo'] and not new_user %}
<label>{{ _('Kobo Sync Token')}}</label> <label>{{ _('Kobo Sync Token')}}</label>
<div class="form-group col"> <div class="form-group col">
<a class="btn btn-default" id="config_create_kobo_token" data-toggle="modal" data-target="#modal_kobo_token" data-remote="false" href="{{ url_for('kobo_auth.generate_auth_token', user_id=content.id) }}">{{_('Create/View')}}</a> <a class="btn btn-default" id="config_create_kobo_token" data-toggle="modal" data-target="#modal_kobo_token" data-remote="false" href="{{ url_for('kobo_auth.generate_auth_token', user_id=content.id) }}">{{_('Create/View')}}</a>

Loading…
Cancel
Save