mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-06 21:59:13 +00:00
Renamed Vue Files
This commit is contained in:
@@ -1,8 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<ContentTitle :title="contentData.title" :author="contentData.author" :publishDate="contentData.publish_date">
|
<Title :title="contentData.title" :author="contentData.author" :publishDate="contentData.publish_date">
|
||||||
<slot></slot>
|
<slot></slot>
|
||||||
</ContentTitle>
|
</Title>
|
||||||
<section class="article-content-section">
|
<section class="article-content-section">
|
||||||
<div class='container'>
|
<div class='container'>
|
||||||
<div class="content" v-html="contentData.content"></div>
|
<div class="content" v-html="contentData.content"></div>
|
||||||
@@ -17,10 +17,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import ContentTitle from './ContentTitle.vue'
|
import Title from './Title.vue'
|
||||||
export default {
|
export default {
|
||||||
props: ['content', 'type'],
|
props: ['content', 'type'],
|
||||||
name: 'ContentArticle',
|
name: 'Article',
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
contentData: ''
|
contentData: ''
|
||||||
@@ -38,7 +38,7 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
ContentTitle
|
Title
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
@@ -13,6 +13,6 @@
|
|||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
props:['title', 'description'],
|
props:['title', 'description'],
|
||||||
name: "AcademyList",
|
name: "CardList",
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
@@ -27,13 +27,13 @@
|
|||||||
|
|
||||||
<script>
|
<script>
|
||||||
import AButton from './Button.vue';
|
import AButton from './Button.vue';
|
||||||
import AcademyCourseCardButton from './AcademyCourseCardButton.vue'
|
import CourseCardButton from './CourseCardButton.vue'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
props: ['course', 'courseMeta', 'program_name'],
|
props: ['course', 'courseMeta', 'program_name'],
|
||||||
name: "AcademyCourseCard",
|
name: "CourseCard",
|
||||||
components: {
|
components: {
|
||||||
AcademyCourseCardButton,
|
CourseCardButton,
|
||||||
AButton
|
AButton
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@@ -4,7 +4,7 @@
|
|||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
props: ['course', 'nextContent', 'nextContentType'],
|
props: ['course', 'nextContent', 'nextContentType'],
|
||||||
name: "AcademyCourseCardButton",
|
name: "CourseCardButton",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
buttonName: 'Start',
|
buttonName: 'Start',
|
||||||
@@ -9,7 +9,7 @@
|
|||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
props: ['nextContent', 'nextContentType'],
|
props: ['nextContent', 'nextContentType'],
|
||||||
name: 'ContentNavigation',
|
name: 'Navigation',
|
||||||
methods: {
|
methods: {
|
||||||
goNext() {
|
goNext() {
|
||||||
if(this.$route.params.type != "Quiz"){
|
if(this.$route.params.type != "Quiz"){
|
||||||
@@ -28,7 +28,7 @@
|
|||||||
import AButton from './Button.vue';
|
import AButton from './Button.vue';
|
||||||
export default {
|
export default {
|
||||||
props: ['program', 'enrolled'],
|
props: ['program', 'enrolled'],
|
||||||
name: "AcademyProgramCard",
|
name: "ProgramCard",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
isLogin: lms.store.isLogin
|
isLogin: lms.store.isLogin
|
||||||
@@ -42,7 +42,7 @@
|
|||||||
import QuizSingleChoice from "./Quiz/QuizSingleChoice.vue"
|
import QuizSingleChoice from "./Quiz/QuizSingleChoice.vue"
|
||||||
export default {
|
export default {
|
||||||
props: ['content', 'type'],
|
props: ['content', 'type'],
|
||||||
name: 'ContentQuiz',
|
name: 'Quiz',
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
quizData: '',
|
quizData: '',
|
||||||
@@ -20,7 +20,7 @@
|
|||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
props: ['title', 'publishDate', 'author'],
|
props: ['title', 'publishDate', 'author'],
|
||||||
name: 'ContentTitle',
|
name: 'Title',
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|
||||||
@@ -19,6 +19,6 @@
|
|||||||
|
|
||||||
export default {
|
export default {
|
||||||
props: ['title', 'description'],
|
props: ['title', 'description'],
|
||||||
name: "AcademyTopSection",
|
name: "TopSection",
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
@@ -4,7 +4,7 @@
|
|||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
name: "AcademyTopSectionButton",
|
name: "TopSectionButton",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
buttonName: '',
|
buttonName: '',
|
||||||
@@ -39,7 +39,7 @@
|
|||||||
<script>
|
<script>
|
||||||
export default {
|
export default {
|
||||||
props: ['content', 'type'],
|
props: ['content', 'type'],
|
||||||
name: 'ContentVideo',
|
name: 'Video',
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
contentData: ''
|
contentData: ''
|
||||||
@@ -1,15 +1,15 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<component v-bind:is="currentComponent" :content="content" :type="type">
|
<component v-bind:is="currentComponent" :content="content" :type="type">
|
||||||
<ContentNavigation :nextContent="nextContent" :nextContentType="nextContentType"/>
|
<Navigation :nextContent="nextContent" :nextContentType="nextContentType"/>
|
||||||
</component>
|
</component>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import ContentArticle from "../components/ContentArticle.vue"
|
import Article from "../components/Article.vue"
|
||||||
import ContentQuiz from "../components/ContentQuiz.vue"
|
import Quiz from "../components/Quiz.vue"
|
||||||
import ContentVideo from "../components/ContentVideo.vue"
|
import Video from "../components/Video.vue"
|
||||||
import ContentNavigation from "../components/ContentNavigation.vue"
|
import Navigation from "../components/Navigation.vue"
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
props:['program_name', 'course', 'type', 'content'],
|
props:['program_name', 'course', 'type', 'content'],
|
||||||
@@ -23,13 +23,13 @@ export default {
|
|||||||
computed: {
|
computed: {
|
||||||
currentComponent: function() {
|
currentComponent: function() {
|
||||||
if(this.type === "Article") {
|
if(this.type === "Article") {
|
||||||
return 'ContentArticle'
|
return 'Article'
|
||||||
}
|
}
|
||||||
else if(this.type === "Quiz") {
|
else if(this.type === "Quiz") {
|
||||||
return 'ContentQuiz'
|
return 'Quiz'
|
||||||
}
|
}
|
||||||
else if(this.type === "Video") {
|
else if(this.type === "Video") {
|
||||||
return 'ContentVideo'
|
return 'Video'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
@@ -47,10 +47,10 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
ContentArticle,
|
Article,
|
||||||
ContentVideo,
|
Video,
|
||||||
ContentQuiz,
|
Quiz,
|
||||||
ContentNavigation
|
Navigation
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
@@ -1,18 +1,18 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<AcademyTopSection :title="portal.title" :description="portal.description">
|
<TopSection :title="portal.title" :description="portal.description">
|
||||||
<AcademyTopSectionButton/>
|
<TopSectionButton/>
|
||||||
</AcademyTopSection>
|
</TopSection>
|
||||||
<AcademyList :title="'Featured Programs'" :description="'Master ERPNext'">
|
<CardList :title="'Featured Programs'" :description="'Master ERPNext'">
|
||||||
<AcademyProgramCard v-for="item in featuredPrograms" :key="item.program.name" :program="item.program" :enrolled="item.is_enrolled"/>
|
<ProgramCard v-for="item in featuredPrograms" :key="item.program.name" :program="item.program" :enrolled="item.is_enrolled"/>
|
||||||
</AcademyList>
|
</CardList>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import AcademyTopSection from "../components/AcademyTopSection.vue"
|
import TopSection from "../components/TopSection.vue"
|
||||||
import AcademyList from "../components/AcademyList.vue"
|
import CardList from "../components/CardList.vue"
|
||||||
import AcademyProgramCard from "../components/AcademyProgramCard.vue"
|
import ProgramCard from "../components/ProgramCard.vue"
|
||||||
import AcademyTopSectionButton from "../components/AcademyTopSectionButton.vue"
|
import TopSectionButton from "../components/TopSectionButton.vue"
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "Home",
|
name: "Home",
|
||||||
@@ -24,10 +24,10 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
components: {
|
components: {
|
||||||
AcademyTopSection,
|
TopSection,
|
||||||
AcademyList,
|
CardList,
|
||||||
AcademyProgramCard,
|
ProgramCard,
|
||||||
AcademyTopSectionButton
|
TopSectionButton
|
||||||
},
|
},
|
||||||
beforeMount() {
|
beforeMount() {
|
||||||
// this.updateEnrolledPrograms().then(data => {
|
// this.updateEnrolledPrograms().then(data => {
|
||||||
|
|||||||
@@ -1,19 +1,19 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<AcademyTopSection v-bind:title="program.program_name" v-bind:description="program.description">
|
<TopSection v-bind:title="program.program_name" v-bind:description="program.description">
|
||||||
<!-- <a-button @click="startCourse">Start Course</a-button>
|
<!-- <a-button @click="startCourse">Start Course</a-button>
|
||||||
<a-button @click="continueCourse">Continue Course</a-button> -->
|
<a-button @click="continueCourse">Continue Course</a-button> -->
|
||||||
</AcademyTopSection>
|
</TopSection>
|
||||||
<AcademyList :title="'Courses'" :description="''">
|
<CardList :title="'Courses'" :description="''">
|
||||||
<AcademyCourseCard v-for="course in course_data" :course="course.course" :program_name="program_name" :courseMeta="course.meta" :key="course.meta.flag"/>
|
<CourseCard v-for="course in course_data" :course="course.course" :program_name="program_name" :courseMeta="course.meta" :key="course.meta.flag"/>
|
||||||
</AcademyList>
|
</CardList>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import Button from '../components/Button.vue';
|
import Button from '../components/Button.vue';
|
||||||
import AcademyTopSection from "../components/AcademyTopSection.vue"
|
import TopSection from "../components/TopSection.vue"
|
||||||
import AcademyList from "../components/AcademyList.vue"
|
import CardList from "../components/CardList.vue"
|
||||||
import AcademyCourseCard from "../components/AcademyCourseCard.vue"
|
import CourseCard from "../components/CourseCard.vue"
|
||||||
|
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
@@ -21,9 +21,9 @@ export default {
|
|||||||
name: "ProgramPage",
|
name: "ProgramPage",
|
||||||
components: {
|
components: {
|
||||||
AButton: Button,
|
AButton: Button,
|
||||||
AcademyTopSection,
|
TopSection,
|
||||||
AcademyList,
|
CardList,
|
||||||
AcademyCourseCard
|
CourseCard
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
|||||||
Reference in New Issue
Block a user