mirror of
https://github.com/frappe/lms.git
synced 2026-04-28 03:29:26 +03:00
fix: render styles properly in text editor for batchform and courseform
(cherry picked from commit 80b802a76b)
This commit is contained in:
@@ -323,7 +323,6 @@ import {
|
||||
createLMSCategory,
|
||||
getMetaInfo,
|
||||
openSettings,
|
||||
sanitizeHTML,
|
||||
updateMetaInfo,
|
||||
} from '@/utils'
|
||||
import { useRouter } from 'vue-router'
|
||||
@@ -458,16 +457,7 @@ const formatTime = (timeStr) => {
|
||||
return `${hours}:${minutes}`
|
||||
}
|
||||
|
||||
const validateFields = () => {
|
||||
Object.keys(batchDetail.doc).forEach((key) => {
|
||||
if (typeof batchDetail.doc[key] === 'string') {
|
||||
batchDetail.doc[key] = sanitizeHTML(batchDetail.doc[key])
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
const submitBatch = () => {
|
||||
validateFields()
|
||||
updateBatch()
|
||||
}
|
||||
|
||||
|
||||
@@ -354,12 +354,7 @@ import {
|
||||
watch,
|
||||
getCurrentInstance,
|
||||
} from 'vue'
|
||||
import {
|
||||
getMetaInfo,
|
||||
sanitizeHTML,
|
||||
updateMetaInfo,
|
||||
createLMSCategory,
|
||||
} from '@/utils'
|
||||
import { getMetaInfo, updateMetaInfo, createLMSCategory } from '@/utils'
|
||||
import { X } from 'lucide-vue-next'
|
||||
import { useRouter } from 'vue-router'
|
||||
import Link from '@/components/Controls/Link.vue'
|
||||
@@ -457,7 +452,6 @@ const updateCourseData = () => {
|
||||
}
|
||||
|
||||
const submitCourse = () => {
|
||||
validateFields()
|
||||
updateCourse()
|
||||
}
|
||||
|
||||
@@ -471,14 +465,6 @@ const onMemberCreated = (user) => {
|
||||
}
|
||||
}
|
||||
|
||||
const validateFields = () => {
|
||||
Object.keys(courseResource.doc).forEach((key) => {
|
||||
if (typeof courseResource.doc[key] === 'string') {
|
||||
courseResource.doc[key] = sanitizeHTML(courseResource.doc[key])
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
const updateCourse = () => {
|
||||
courseResource.setValue.submit(
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user