mirror of
https://github.com/lennart-k/rustical.git
synced 2025-12-13 13:32:16 +00:00
57 lines
1.7 KiB
HTML
57 lines
1.7 KiB
HTML
<h2>{{ user.id }}'s Profile</h2>
|
|
|
|
{% let groups = user.memberships_without_self() %}
|
|
{% if groups.len() > 0 %}
|
|
<h3>Groups</h3>
|
|
<ul>
|
|
{% for group in groups %}
|
|
<li>{{ group }}</li>
|
|
{% endfor %}
|
|
</ul>
|
|
{% endif %}
|
|
|
|
<h3>App tokens</h3>
|
|
<table id="app-tokens">
|
|
<tr>
|
|
<th>Name</th>
|
|
<th>Created at</th>
|
|
<th></th>
|
|
</tr>
|
|
{% for app_token in app_tokens %}
|
|
<tr>
|
|
<td>{{ app_token.name }}</td>
|
|
<td>
|
|
{% if let Some(created_at) = app_token.created_at %}
|
|
{{ chrono_humanize::HumanTime::from(created_at.to_owned()) }}
|
|
{% endif %}
|
|
</td>
|
|
<td>
|
|
<form action="/frontend/user/{{ user.id }}/app_token/{{ app_token.id }}/delete" method="POST">
|
|
<button type="submit" class="delete">Delete</button>
|
|
</form>
|
|
</td>
|
|
</tr>
|
|
{% endfor %}
|
|
<tr class="generate">
|
|
<td>
|
|
<form action="/frontend/user/{{ user.id }}/app_token" method="POST" id="form_generate_app_token">
|
|
<label class="font_bold" for="generate_app_token_name">App name</label>
|
|
<input type="text" name="name" id="generate_app_token_name" />
|
|
</form>
|
|
</td>
|
|
<td></td>
|
|
<td>
|
|
<button type="submit" form="form_generate_app_token">Generate</button>
|
|
{% if is_apple %}
|
|
<button type="submit" form="form_generate_app_token" name="apple" value="true">Apple Configuration Profile
|
|
(contains token)</button>
|
|
{% endif %}
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
{% if let Some(hostname) = davx5_hostname %}
|
|
<a
|
|
href="intent://{{ hostname | urlencode }}#Intent;action=android.intent.action.VIEW;component=at.bitfire.davdroid.ui.setup.LoginActivity;scheme=davx5;package=at.bitfire.davdroid;S.loginFlow=1;end">Configure
|
|
in DAVx5</a>
|
|
{% endif %}
|