From 90b503621b62ebff259ebbd00720583ddcee21a7 Mon Sep 17 00:00:00 2001 From: scmmishra Date: Tue, 26 Feb 2019 17:20:38 +0530 Subject: [PATCH] fix: Content Routing --- erpnext/public/js/education/lms/lms.js | 3 +-- erpnext/public/js/education/lms/routes.js | 3 ++- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/erpnext/public/js/education/lms/lms.js b/erpnext/public/js/education/lms/lms.js index 5fb7b7d558..15370d06ec 100644 --- a/erpnext/public/js/education/lms/lms.js +++ b/erpnext/public/js/education/lms/lms.js @@ -9,9 +9,8 @@ import './call'; Vue.use(VueRouter) var store = { - isLogin: false, enrolledPrograms: [], - enrolledCourses: {} + enrolledCourses: [] } frappe.ready(() => { diff --git a/erpnext/public/js/education/lms/routes.js b/erpnext/public/js/education/lms/routes.js index 7f06c78e51..d5aab29236 100644 --- a/erpnext/public/js/education/lms/routes.js +++ b/erpnext/public/js/education/lms/routes.js @@ -28,7 +28,8 @@ const routes = [{ component: ContentPage, props: true, beforeEnter: (to, from, next) => { - if (lms.store.checkProgramEnrollment(this.program_name)) { + console.log(from.params.program_name) + if (lms.store.checkProgramEnrollment(from.params.program_name)) { next() } else { next({