23 lines
694 B
Vue
Raw Normal View History

2018-11-01 17:20:04 +05:30
<template>
<div class="nav-buttons">
2018-11-02 16:29:04 +05:30
<button class='btn btn-outline-secondary' @click="$router.go(-1)">Back</button>
<button v-if="nextContent" class='btn btn-primary' @click="$router.push({ name: 'content', params: { course: $route.params.course, type:nextContentType, content:nextContent }})">Next</button>
<button v-else class='btn btn-primary' @click="$router.push({ name: 'program', params: { code: $route.params.code}})">Finish Course</button>
2018-11-01 17:20:04 +05:30
</div>
</template>
<script>
export default {
props: ['nextContent', 'nextContentType'],
2018-11-02 16:29:04 +05:30
name: 'ContentNavigation'
2018-11-01 17:20:04 +05:30
};
</script>
<style lang="css" scoped>
.nav-buttons {
position: absolute;
bottom: 0;
right: 0;
}
</style>