46 lines
1.4 KiB
HTML
46 lines
1.4 KiB
HTML
{#include base.html}
|
|
{#room_active}active{/}
|
|
{#contents}
|
|
|
|
<div class="mt-2">
|
|
{#if rooms.size == 0}
|
|
Kein Raum vorhanden
|
|
{#else}
|
|
<h2>Raum wählen</h2>
|
|
{/if}
|
|
|
|
<div class="btn-group" role="group">
|
|
{#for room in rooms}
|
|
<form action="/room/user" method="POST" name="chooseRoomForm" enctype="application/x-www-form-urlencoded">
|
|
<input type="radio" class="btn-check" name="room" value="{room.name}" id="radio{room.name}" autocomplete="off"
|
|
onchange="this.form.submit()" {#if room.name == current_room}checked{/if} >
|
|
<label class="btn btn-outline-primary" for="radio{room.name}">{room.name}</label>
|
|
</form>
|
|
{/for}
|
|
</div>
|
|
</div>
|
|
|
|
<div class="mt-2">
|
|
<img src="/room/plan" class="img-fluid" alt="kein Raumplan vorhanden">
|
|
</div>
|
|
|
|
{#if is_admin}
|
|
<div class="mt-2">
|
|
<form action="/room/plan" method="POST" enctype="multipart/form-data">
|
|
<label id="filelabel" class="btn btn-secondary" for="fileinput">
|
|
neuen Raumplan auswählen...
|
|
</label>
|
|
<input id="fileinput" type="file" name="file" accept="image/*" hidden
|
|
onchange="document.getElementById('filelabel').innerHTML = 'Datei: ' + this.files[0].name;" />
|
|
<input class="btn btn-primary" type="submit" value="Upload" />
|
|
</form>
|
|
</div>
|
|
|
|
<div class="mt-2">
|
|
<a class="btn btn-primary" data-bs-toggle="modal" data-bs-target="#roomModal" role="button">neuer Raum</a>
|
|
</div>
|
|
{#include room-modal.html}{/include}
|
|
{/if}
|
|
|
|
{/contents}
|
|
{/include} |