frontend: refactor model type management and catalog routes
This commit is contained in:
@@ -6,8 +6,8 @@
|
||||
<p class="text-sm text-gray-500">Gérez les modèles disponibles pour chaque famille de composant.</p>
|
||||
</div>
|
||||
<div class="tabs tabs-boxed">
|
||||
<NuxtLink to="/models/components" class="tab tab-active">Composants</NuxtLink>
|
||||
<NuxtLink to="/models/pieces" class="tab">Pièces</NuxtLink>
|
||||
<NuxtLink to="/component-catalog" class="tab tab-active">Composants</NuxtLink>
|
||||
<NuxtLink to="/pieces-catalog" class="tab">Pièces</NuxtLink>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
10
app/pages/component-category.vue
Normal file
10
app/pages/component-category.vue
Normal file
@@ -0,0 +1,10 @@
|
||||
<template>
|
||||
<ManagementView
|
||||
category="COMPONENT"
|
||||
heading="Catégories de composant"
|
||||
/>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import ManagementView from '~/components/model-types/ManagementView.vue'
|
||||
</script>
|
||||
@@ -7,10 +7,10 @@
|
||||
</p>
|
||||
</div>
|
||||
<div class="flex flex-wrap items-center justify-center gap-3">
|
||||
<NuxtLink to="/models/components" class="btn btn-primary">
|
||||
<NuxtLink to="/component-catalog" class="btn btn-primary">
|
||||
Catalogue de composant
|
||||
</NuxtLink>
|
||||
<NuxtLink to="/models/pieces" class="btn btn-outline">
|
||||
<NuxtLink to="/pieces-catalog" class="btn btn-outline">
|
||||
Catalogue de pièce
|
||||
</NuxtLink>
|
||||
</div>
|
||||
@@ -20,6 +20,6 @@
|
||||
<script setup>
|
||||
const route = useRoute()
|
||||
if (route.fullPath === '/models') {
|
||||
navigateTo('/models/components', { replace: true })
|
||||
navigateTo('/component-catalog', { replace: true })
|
||||
}
|
||||
</script>
|
||||
|
||||
10
app/pages/piece-category.vue
Normal file
10
app/pages/piece-category.vue
Normal file
@@ -0,0 +1,10 @@
|
||||
<template>
|
||||
<ManagementView
|
||||
category="PIECE"
|
||||
heading="Catégories de pièce"
|
||||
/>
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import ManagementView from '~/components/model-types/ManagementView.vue'
|
||||
</script>
|
||||
@@ -6,8 +6,8 @@
|
||||
<p class="text-sm text-gray-500">Gérez les modèles disponibles pour chaque groupe de pièces.</p>
|
||||
</div>
|
||||
<div class="tabs tabs-boxed">
|
||||
<NuxtLink to="/models/components" class="tab">Composants</NuxtLink>
|
||||
<NuxtLink to="/models/pieces" class="tab tab-active">Pièces</NuxtLink>
|
||||
<NuxtLink to="/component-catalog" class="tab">Composants</NuxtLink>
|
||||
<NuxtLink to="/pieces-catalog" class="tab tab-active">Pièces</NuxtLink>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
Reference in New Issue
Block a user