mirror of
https://github.com/lennart-k/rustical.git
synced 2025-12-13 22:52:22 +00:00
frontend: Show group calendars
This commit is contained in:
@@ -60,7 +60,7 @@ li.collection-list-item {
|
||||
{% for calendar in calendars %}
|
||||
{% let color = calendar.color.to_owned().unwrap_or("red".to_owned()) %}
|
||||
<li class="collection-list-item" style="--color: {{ color }}">
|
||||
<a href="/frontend/user/{{ user_id }}/calendar/{{ calendar.id}}">
|
||||
<a href="/frontend/user/{{ calendar.principal }}/calendar/{{ calendar.id}}">
|
||||
<span class="title">{{ calendar.displayname.to_owned().unwrap_or(calendar.id.to_owned()) }}</span>
|
||||
<span class="description">
|
||||
{% if let Some(description) = calendar.description %}{{ description }}{% endif %}
|
||||
@@ -71,6 +71,8 @@ li.collection-list-item {
|
||||
<div class="color-chip"></div>
|
||||
</a>
|
||||
</li>
|
||||
{% else %}
|
||||
You do not have any calendars yet
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{%if !deleted_calendars.is_empty() %}
|
||||
@@ -79,7 +81,7 @@ li.collection-list-item {
|
||||
{% for calendar in deleted_calendars %}
|
||||
{% let color = calendar.color.to_owned().unwrap_or("red".to_owned()) %}
|
||||
<li class="collection-list-item" style="--color: {{ color }}">
|
||||
<a href="/frontend/user/{{ user_id }}/calendar/{{ calendar.id}}">
|
||||
<a href="/frontend/user/{{ calendar.principal }}/calendar/{{ calendar.id}}">
|
||||
<span class="title">{{ calendar.displayname.to_owned().unwrap_or(calendar.id.to_owned()) }}</span>
|
||||
<span class="description">
|
||||
{% if let Some(description) = calendar.description %}{{ description }}{% endif %}
|
||||
@@ -98,13 +100,15 @@ li.collection-list-item {
|
||||
<ul>
|
||||
{% for addressbook in addressbooks %}
|
||||
<li class="collection-list-item">
|
||||
<a href="/frontend/user/{{ user_id }}/addressbook/{{ addressbook.id}}">
|
||||
<a href="/frontend/user/{{ addressbook.principal }}/addressbook/{{ addressbook.id}}">
|
||||
<span class="title">{{ addressbook.displayname.to_owned().unwrap_or(addressbook.id.to_owned()) }}</span>
|
||||
<span class="description">
|
||||
{% if let Some(description) = addressbook.description %}{{ description }}{% endif %}
|
||||
</span>
|
||||
</a>
|
||||
</li>
|
||||
{% else %}
|
||||
You do not have any addressbooks yet
|
||||
{% endfor %}
|
||||
</ul>
|
||||
{%if !deleted_addressbooks.is_empty() %}
|
||||
@@ -112,7 +116,7 @@ li.collection-list-item {
|
||||
<ul>
|
||||
{% for addressbook in deleted_addressbooks %}
|
||||
<li class="collection-list-item">
|
||||
<a href="/frontend/user/{{ user_id }}/addressbook/{{ addressbook.id}}">
|
||||
<a href="/frontend/user/{{ addressbook.principal }}/addressbook/{{ addressbook.id}}">
|
||||
<span class="title">{{ addressbook.displayname.to_owned().unwrap_or(addressbook.id.to_owned()) }}</span>
|
||||
<span class="description">
|
||||
{% if let Some(description) = addressbook.description %}{{ description }}{% endif %}
|
||||
|
||||
Reference in New Issue
Block a user