Compare commits

..

No commits in common. "a32a49b281e7d08f76154e7ec29d46acd2e518f3" and "80cec7130853c2d5d2eeae3b44f4de4f0e8a01ea" have entirely different histories.

9 changed files with 8 additions and 71 deletions

View file

@ -3,10 +3,7 @@
SPDX-License-Identifier: AGPL-3.0-or-later
-->
<template>
<section
class="event"
:class="{ cancelled: event.cancelled }"
>
<section class="event">
<h3>{{ event.name }}</h3>
<p v-if=event.host>
Host: {{ event.host }}
@ -39,12 +36,7 @@
<h4>Timeslots</h4>
<ul>
<li
v-for="slot in event.slots.values()"
:key="slot.id"
class="slot"
:class="{ cancelled: slot.cancelled }"
>
<li v-for="slot in event.slots.values()" :key="slot.id">
{{ formatTime(slot.start) }} - {{ formatTime(slot.end) }}
<button
v-if="accountStore.valid && event.slots.size > 1"
@ -99,10 +91,6 @@ async function toggle(type: "event" | "slot", id: number, slotIds?: number[]) {
padding: 0.5rem;
border-radius: 0.5rem;
}
.event.cancelled>*, .slot.cancelled {
text-decoration: line-through;
color: grey;
}
.event h3 {
margin: 0;
}
@ -110,9 +98,7 @@ async function toggle(type: "event" | "slot", id: number, slotIds?: number[]) {
margin-block-start: 0.5rem;
}
.event .notice {
text-decoration: none;
color: CanvasText;
.notice {
display: flex;
width: fit-content;
gap: 0.5rem;

View file

@ -3,10 +3,7 @@
SPDX-License-Identifier: AGPL-3.0-or-later
-->
<template>
<section
class="eventSlot"
:class="{ cancelled: slot.cancelled || event?.cancelled }"
>
<section class="eventSlot">
<hgroup>
<h3>{{ event?.name }}</h3>
<p>
@ -78,10 +75,6 @@ function formatTime(time: DateTime) {
padding: 0.5rem;
border-radius: 0.5rem;
}
.eventSlot.cancelled>* {
text-decoration: line-through;
color: grey;
}
.eventSlot h3 {
margin: 0;
}
@ -89,9 +82,7 @@ function formatTime(time: DateTime) {
margin-block-start: 0.5rem;
}
.eventSlot .notice {
text-decoration: none;
color: CanvasText;
.notice {
display: flex;
width: fit-content;
gap: 0.5rem;

View file

@ -29,12 +29,6 @@
:after='event.crew ? "No" : "Yes"'
:state
/>
<DiffFieldString
title="Cancelled"
:before='event.serverCancelled ? "Yes" : "No"'
:after='event.cancelled ? "Yes" : "No"'
:state
/>
<DiffFieldString
title="Notice"
:before="event.serverNotice"

View file

@ -24,12 +24,6 @@
:entities="schedule.locations"
:state
/>
<DiffFieldString
title="Cancelled"
:before='slot.serverCancelled ? "Yes" : "No"'
:after='slot.cancelled ? "Yes" : "No"'
:state
/>
<DiffFieldSetEntityId
title="Assigned"
:before="slot.serverAssigned"

View file

@ -12,7 +12,6 @@
<th>duration</th>
<th>event</th>
<th>location</th>
<th title="cancelled">c</th>
<th>assigned</th>
<th v-if="edit"></th>
</tr>
@ -51,7 +50,6 @@
/>
</td>
<td></td>
<td></td>
<td>
Add at
<button
@ -99,11 +97,6 @@
v-model="es.slot.locationIds"
/>
</td>
<td>
<input
type="checkbox"
v-model="es.slot.cancelled">
</td>
<td>
<SelectMultiEntity
:entities="usersStore.users"
@ -156,7 +149,6 @@
/>
</td>
<td></td>
<td></td>
<td colspan="2">
<button
type="button"
@ -185,7 +177,6 @@
<td>{{ es.end.diff(es.start).toFormat('hh:mm') }}</td>
<td>{{ es.event?.name }}</td>
<td></td>
<td>{{ es.slot.cancelled ? "x" : undefined }}</td>
<td><AssignedCrew :modelValue="es.slot.assigned" :edit="false" /></td>
</template>
</tr>

View file

@ -14,7 +14,6 @@
<th>notice</th>
<th>description</th>
<th>p</th>
<th title="cancelled">c</th>
<th>s</th>
<th v-if="edit"></th>
</tr>
@ -70,13 +69,6 @@
@change="event.crew = !event.crew"
>
</td>
<td>
<input
type="checkbox"
:disabled="!canEdit(event)"
v-model="event.cancelled"
>
</td>
<td>{{ event.slots.size ? event.slots.size : "" }}</td>
<td>
<button
@ -131,7 +123,6 @@
>
</td>
<td></td>
<td></td>
<td>
<button
v-if="eventExists(newEventName)"

View file

@ -55,6 +55,7 @@ nav {
}
.tab {
display: flex;
flex-wrap: wrap;
}
.tab.active {
padding-block-start: 1px;
@ -64,7 +65,6 @@ nav {
}
.tab .spacer {
flex: 1 0 0.75rem;
width: 0.75rem;
}
.tab .flap,
.tab .spacer {

View file

@ -102,11 +102,7 @@
v-for="cell, index in row"
:key="index"
:colSpan="cell.span"
:class="{
event: cell.slot,
crew: cell.event?.crew,
cancelled: cell.event?.cancelled || cell.slot?.cancelled,
}"
:class='{"event": cell.slot, "crew": cell.event?.crew }'
:title="cell.event?.name"
>
{{ cell.event?.notice ? "⚠️" : undefined }}
@ -795,9 +791,4 @@ tr.hours>th + th.dayShift div {
.event.crew {
background-color: color-mix(in oklab, var(--background), rgb(127, 127, 127) 60%);
}
.event.cancelled {
color: color-mix(in oklab, CanvasText, rgb(127, 127, 127) 80%);
text-decoration: line-through;
}
</style>

View file

@ -192,9 +192,8 @@ function sendEventToStream(stream: EventStream, event: ApiEvent) {
if (event.type === "session-expired") {
if (stream.sessionId === event.sessionId) {
stream.close("session expired");
return false;
}
return true;
return false;
}
// Account events are specially handled and only sent to the user they belong to.