Skip to content

Commit 7a97802

Browse files
AyakorKMaghwyn
authored andcommitted
Change redirections by vue-routers
1 parent dbd3d73 commit 7a97802

2 files changed

Lines changed: 7 additions & 3 deletions

File tree

front-end/src/components/RollCallComponents/MakeGroupsComponent.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
<template>
22
<div v-if="courseId" class="mx-auto">
3-
<a :href="groupUrl">
3+
<router-link :to="groupUrl">
44
<button class="bg-blue-500 text-white py-2 px-4 rounded mt-2 mb-4">Former les groupes</button>
5-
</a>
5+
</router-link>
66
</div>
77
</template>
88

front-end/src/components/RollCallComponents/ReturnButtonComponent.vue

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,11 @@
88
</template>
99

1010
<script setup>
11+
import { useRouter } from 'vue-router';
12+
13+
const router = useRouter();
14+
1115
const goBack = () => {
12-
window.history.back();
16+
router.go(-1);
1317
};
1418
</script>

0 commit comments

Comments
 (0)