Only show drafts to dispatchers #28
This commit is contained in:
@@ -70,7 +70,7 @@ export const SituationBoard = () => {
|
|||||||
{/* head */}
|
{/* head */}
|
||||||
<thead>
|
<thead>
|
||||||
<tr>
|
<tr>
|
||||||
<th>ID</th>
|
<th>E-Nr.</th>
|
||||||
<th>Stichwort</th>
|
<th>Stichwort</th>
|
||||||
<th>Stadt</th>
|
<th>Stadt</th>
|
||||||
<th>Stationen</th>
|
<th>Stationen</th>
|
||||||
@@ -78,39 +78,42 @@ export const SituationBoard = () => {
|
|||||||
</thead>
|
</thead>
|
||||||
<tbody>
|
<tbody>
|
||||||
{/* row 1 */}
|
{/* row 1 */}
|
||||||
{missions?.map((mission) => (
|
{missions?.map(
|
||||||
<tr
|
(mission) =>
|
||||||
onDoubleClick={() => {
|
(dispatcherConnected || mission.state !== "draft") && (
|
||||||
setOpenMissionMarker({
|
<tr
|
||||||
open: [
|
onDoubleClick={() => {
|
||||||
{
|
setOpenMissionMarker({
|
||||||
id: mission.id,
|
open: [
|
||||||
tab: "home",
|
{
|
||||||
},
|
id: mission.id,
|
||||||
],
|
tab: "home",
|
||||||
close: [],
|
},
|
||||||
});
|
],
|
||||||
setMap({
|
close: [],
|
||||||
center: {
|
});
|
||||||
lat: mission.addressLat,
|
setMap({
|
||||||
lng: mission.addressLng,
|
center: {
|
||||||
},
|
lat: mission.addressLat,
|
||||||
zoom: 14,
|
lng: mission.addressLng,
|
||||||
});
|
},
|
||||||
}}
|
zoom: 14,
|
||||||
key={mission.id}
|
});
|
||||||
className={cn(mission.state === "draft" && "bg-base-300")}
|
}}
|
||||||
>
|
key={mission.id}
|
||||||
<td>{mission.publicId}</td>
|
className={cn(mission.state === "draft" && "missionListItem")}
|
||||||
<td>{mission.missionKeywordAbbreviation}</td>
|
>
|
||||||
<td>{mission.addressCity}</td>
|
<td>{mission.publicId}</td>
|
||||||
<td>
|
<td>{mission.missionKeywordAbbreviation}</td>
|
||||||
{(mission as any).MissionsOnStations?.map(
|
<td>{mission.addressCity}</td>
|
||||||
(mos: { Station: Station }) => mos.Station?.bosCallsignShort,
|
<td>
|
||||||
).join(", ")}
|
{(mission as any).MissionsOnStations?.map(
|
||||||
</td>
|
(mos: { Station: Station }) => mos.Station?.bosCallsignShort,
|
||||||
</tr>
|
).join(", ")}
|
||||||
))}
|
</td>
|
||||||
|
</tr>
|
||||||
|
),
|
||||||
|
)}
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
@@ -56,3 +56,8 @@
|
|||||||
.leaflet-popup-close-button {
|
.leaflet-popup-close-button {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.missionListItem {
|
||||||
|
background-color: color-mix(in oklab, var(--color-info) 8%, var(--color-base-100));
|
||||||
|
color: var(--color-info, var(--color-base-content));
|
||||||
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user