芝麻web文件管理V1.00
编辑当前文件:/home2/sdektunc/hocabayucatan.gob.mx/media/com_mails/js/admin-email-template-edit-es5.min.js
!function(){"use strict";!function(t,e){var i=function(){function i(t,e){this.form=t,this.inputSubject=this.form.querySelector("#jform_subject"),this.inputBody=this.form.querySelector("#jform_body"),this.inputHtmlBody=this.form.querySelector("#jform_htmlbody"),this.templateData=e&&e.templateData?e.templateData:{},this.form.EmailTemplateEdit=this}var n=i.prototype;return n.setBodyValue=function(t){e.editors.instances[this.inputBody.id]?e.editors.instances[this.inputBody.id].setValue(t):this.inputBody.value=t},n.setHtmlBodyValue=function(t){e.editors.instances[this.inputHtmlBody.id]?e.editors.instances[this.inputHtmlBody.id].setValue(t):this.inputHtmlBody.value=t},n.insertTag=function(t,i){if(!t)return!1;var n;switch(i){case"body":n=this.inputBody;break;case"htmlbody":n=this.inputHtmlBody;break;default:return!1}return e.editors.instances[n.id]?e.editors.instances[n.id].replaceSelection(t):n.value+=" "+t,!0},n.bindListeners=function(){var e=this;t.querySelector("#btnResetSubject").addEventListener("click",(function(t){t.preventDefault(),e.inputSubject.value=e.templateData.subject?e.templateData.subject:""}));var i=t.querySelector("#btnResetBody");i&&i.addEventListener("click",(function(t){t.preventDefault(),e.setBodyValue(e.templateData.body?e.templateData.body:"")}));var n=t.querySelector("#btnResetHtmlBody");n&&n.addEventListener("click",(function(t){t.preventDefault(),e.setHtmlBodyValue(e.templateData.htmlbody?e.templateData.htmlbody:"")})),this.form.querySelectorAll(".edit-action-add-tag").forEach((function(t){t.addEventListener("click",(function(t){t.preventDefault();var i=t.target;e.insertTag(i.dataset.tag,i.dataset.target)}))}))},i}();t.addEventListener("DOMContentLoaded",(function(){new i(t.getElementById("item-form"),e.getOptions("com_mails")).bindListeners()}))}(document,Joomla)}();