56 lines
1.1 KiB
Vue
56 lines
1.1 KiB
Vue
<script setup lang="ts">
|
|
|
|
import teamRoutes from "@/routes/teams";
|
|
import {Head} from "@inertiajs/vue3";
|
|
import type {Team} from "@/types/models";
|
|
import TextLink from "@/components/TextLink.vue";
|
|
|
|
defineOptions({
|
|
layout: {
|
|
breadcrumbs: [
|
|
{
|
|
title: 'Meine Teams',
|
|
href: teamRoutes.index(),
|
|
},
|
|
],
|
|
},
|
|
});
|
|
|
|
defineProps<{
|
|
teams: Team[]
|
|
}>()
|
|
</script>
|
|
|
|
<template>
|
|
<Head title="Teams"/>
|
|
|
|
<div>
|
|
|
|
</div>
|
|
<table>
|
|
<thead>
|
|
<tr>
|
|
<th>Name</th>
|
|
<th>Slug</th>
|
|
<th>Mitglieder</th>
|
|
<th>2FA</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
<tr
|
|
v-if="teams.length > 0"
|
|
v-for="team in teams"
|
|
>
|
|
<th>{{ team.name }}</th>
|
|
<th>{{ team.slug }}</th>
|
|
<th>{{ team.members.length }}</th>
|
|
<th>{{ team.multi_factor_required }}</th>
|
|
</tr>
|
|
<tr v-else class="text-center font-bold">
|
|
Du bist noch von keinem Team mitglied.
|
|
Tritt einem Team bei oder <TextLink href="{{ route('teams.create') }}">erstelle eins.</TextLink>
|
|
</tr>
|
|
</tbody>
|
|
</table>
|
|
</template>
|