generated from jric11/baseProject
ChatGPT's update to harden software and run db updates.
This commit is contained in:
+3
-43
@@ -5,53 +5,13 @@
|
||||
|
||||
$(document).ready(function () {
|
||||
|
||||
var $application = $("#APPLICATION_MNEMONIC").val(), $sessionStorage = JSON.parse(sessionStorage.getItem($application) || "{}"), $CKEditor;
|
||||
var $application = $("#APPLICATION_MNEMONIC").val(), $sessionStorage = JSON.parse(sessionStorage.getItem($application) || "{}");
|
||||
|
||||
// ----------------------
|
||||
// Initialize the Editor.
|
||||
// ----------------------
|
||||
|
||||
ClassicEditor
|
||||
.create(document.querySelector('#alert_message'), {
|
||||
toolbar: {
|
||||
items: [
|
||||
'heading',
|
||||
'|',
|
||||
'bold',
|
||||
'italic',
|
||||
'underline',
|
||||
'link',
|
||||
'bulletedList',
|
||||
'numberedList',
|
||||
'|',
|
||||
'fontColor',
|
||||
'fontSize',
|
||||
'fontFamily',
|
||||
'|',
|
||||
'indent',
|
||||
'outdent',
|
||||
'alignment',
|
||||
'|',
|
||||
'horizontalLine',
|
||||
'insertTable',
|
||||
'|',
|
||||
'undo',
|
||||
'redo',
|
||||
'|'
|
||||
]},
|
||||
link: {
|
||||
addTargetToExternalLinks: true,
|
||||
defaultProtocol: "http://"
|
||||
|
||||
}
|
||||
})
|
||||
.then(editor => {
|
||||
$CKEditor = editor;
|
||||
})
|
||||
.catch(error => {
|
||||
console.error('CK-Editor error...');
|
||||
console.error(error);
|
||||
});
|
||||
HcrRichText.create(document.querySelector('#alert_message'));
|
||||
|
||||
|
||||
// ------------
|
||||
@@ -210,7 +170,7 @@ $(document).ready(function () {
|
||||
|
||||
e.preventDefault();
|
||||
|
||||
$CKEditor.updateSourceElement();
|
||||
if (!HcrRichText.sync(document.querySelector('#alert_message'))) return;
|
||||
|
||||
$.post("./", $(this).serialize())
|
||||
|
||||
|
||||
Reference in New Issue
Block a user