fetch writeable calendars of user and display a dropdown in confirm dialog with list of calendars to choose for the event
This commit is contained in:
1 parent
f51bb830ab
commit
fa398f5b36
3 files changed
+112
-17
No files matched your search
@@ -100,6 +100,24 @@ $h = static function (string $value): string {
|
||||
method="post"
|
||||
action="<?= $h($_['createUrl']) ?>"
|
||||
>
|
||||
<?php if ($_['calendars'] !== []): ?>
|
||||
<div class="atocal-row">
|
||||
<label for="atocal-calendar">
|
||||
<strong>Calendar</strong>
|
||||
</label>
|
||||
<select id="atocal-calendar" name="calendarId">
|
||||
<?php foreach ($_['calendars'] as $calendar): ?>
|
||||
<option
|
||||
value="<?= $h($calendar['id']) ?>"
|
||||
<?= $calendar['id'] === $_['calendarId'] ? 'selected' : '' ?>
|
||||
>
|
||||
<?= $h($calendar['displayName']) ?>
|
||||
</option>
|
||||
<?php endforeach; ?>
|
||||
</select>
|
||||
</div>
|
||||
<?php endif; ?>
|
||||
|
||||
<input
|
||||
type="hidden"
|
||||
name="requesttoken"
|
||||
|
||||
@@ -52,6 +52,17 @@
|
||||
overflow-wrap: anywhere;
|
||||
}
|
||||
|
||||
.atocal-row select {
|
||||
align-self: center;
|
||||
width: 100%;
|
||||
max-width: 280px;
|
||||
padding: 6px 8px;
|
||||
border: 1px solid var(--color-border);
|
||||
border-radius: 6px;
|
||||
background: var(--color-main-background);
|
||||
color: var(--color-main-text);
|
||||
}
|
||||
|
||||
.atocal-row .description {
|
||||
white-space: normal;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user