|
|
|
|
|
|
|
|
jQuery(document).ready(function () { |
|
|
jQuery(document).ready(function () { |
|
|
initLcCkEditor(); |
|
|
|
|
|
//generateNotice('error', 'Ceci est une notice'); |
|
|
//generateNotice('error', 'Ceci est une notice'); |
|
|
$('.action-delete').on('click', function(e) { |
|
|
$('.action-delete').on('click', function(e) { |
|
|
e.preventDefault(); |
|
|
e.preventDefault(); |
|
|
|
|
|
|
|
|
deleteForm.trigger('submit'); |
|
|
deleteForm.trigger('submit'); |
|
|
}); |
|
|
}); |
|
|
}); |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
window.addEventListener('load', (event) => { |
|
|
|
|
|
initLcCkEditor(); |
|
|
|
|
|
}); |
|
|
/* CKEditor */ |
|
|
/* CKEditor */ |
|
|
|
|
|
|
|
|
function initLcCkEditor(){ |
|
|
function initLcCkEditor(){ |
|
|
var elements = $( '.lc-ckeditor' ); |
|
|
var elements = $( '.lc-ckeditor' ); |
|
|
|
|
|
|
|
|
log(elements); |
|
|
|
|
|
if(elements.length) { |
|
|
if(elements.length) { |
|
|
for (var i = 0; i < elements.length; ++i) { |
|
|
for (var i = 0; i < elements.length; ++i) { |
|
|
if($(elements[i]).data('config')==='simple_config'){ |
|
|
if($(elements[i]).data('config')==='simple_config'){ |
|
|
var editor = CKEDITOR.replace(elements[i], { |
|
|
|
|
|
|
|
|
CKEDITOR.replace(elements[i], { |
|
|
"toolbar": [ |
|
|
"toolbar": [ |
|
|
{ |
|
|
{ |
|
|
items: ['Bold', 'Italic', 'Underline', 'Strike'] |
|
|
items: ['Bold', 'Italic', 'Underline', 'Strike'] |
|
|
|
|
|
|
|
|
'height': 100 |
|
|
'height': 100 |
|
|
}); |
|
|
}); |
|
|
}else{ |
|
|
}else{ |
|
|
var editor = CKEDITOR.replace(elements[i], { |
|
|
|
|
|
|
|
|
CKEDITOR.replace(elements[i], { |
|
|
"toolbar": [ |
|
|
"toolbar": [ |
|
|
{ |
|
|
{ |
|
|
name: "styles", |
|
|
name: "styles", |