fix: edit permission and other issues
This commit is contained in:
@@ -166,5 +166,13 @@ function enrollStudent() {
|
||||
}
|
||||
}
|
||||
|
||||
const is_instructor = () => {}
|
||||
const is_instructor = () => {
|
||||
let user_is_instructor = false
|
||||
props.course.data.instructors.forEach((instructor) => {
|
||||
if (!user_is_instructor && instructor.name == user.data?.name) {
|
||||
user_is_instructor = true
|
||||
}
|
||||
})
|
||||
return user_is_instructor
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -323,7 +323,6 @@ watch(activeQuestion, (value) => {
|
||||
watch(
|
||||
() => props.quizName,
|
||||
(newName) => {
|
||||
console.log(newName)
|
||||
if (newName) {
|
||||
quiz.reload()
|
||||
}
|
||||
@@ -392,7 +391,7 @@ const addToLocalStorage = () => {
|
||||
let quizData = JSON.parse(localStorage.getItem(quiz.data.title))
|
||||
let questionData = {
|
||||
question_index: activeQuestion.value,
|
||||
answers: getAnswers().join(),
|
||||
answer: getAnswers().join(),
|
||||
is_correct: showAnswers.filter((answer) => {
|
||||
return answer != undefined
|
||||
}),
|
||||
|
||||
@@ -26,7 +26,12 @@
|
||||
"
|
||||
>
|
||||
<div class="text-base font-medium text-gray-900 leading-none">
|
||||
<span v-if="branding.data?.brand_name">
|
||||
<span
|
||||
v-if="
|
||||
branding.data?.brand_name &&
|
||||
branding.data?.brand_name != 'Frappe'
|
||||
"
|
||||
>
|
||||
{{ branding.data?.brand_name }}
|
||||
</span>
|
||||
<span v-else> Learning </span>
|
||||
|
||||
Reference in New Issue
Block a user