File Editor
Directories:
.. (Back)
Files:
logger.js
logger.min.js
Create New File
Create
Edit File: logger.min.js
const WPFormsLogger=window.WPFormsLogger||function(t,n){const s={init(){n(s.ready)},ready(){s.bindEvents()},bindPopup(){n(".wpforms-list-table--logs .wp-list-table").on("click",".js-single-log-target",function(o){o.preventDefault(),s.showPopup(n(this).attr("data-log-id"))})},bindEvents(){s.bindPopup(),n("#wpforms-setting-logs-enable").change(function(){s.toggleLogs(n(this).is(":checked"))})},toggleLogs(o){n(".wpforms-logs-settings").toggleClass("wpforms-hidden",!o)},showPopup(o){if(o){const e=wp.template("wpforms-log-record");n.dialog({title:!1,boxWidth:Math.min(1200,.8*n(t).width()),content(){const t=this;return n.get(wpforms_admin.ajax_url,{action:"wpforms_get_log_record",nonce:wpforms_admin.nonce,recordId:o}).done(function(o){o.success&&o.data?t.setContent(e(o.data)):(s.error(o.data),t.close())}).fail(function(o,e){s.error(e+" "+o.responseText),t.close()})},animation:"scale",columnClass:"medium",closeIcon:!0,closeAnimation:"scale",backgroundDismiss:!0})}},error(o){wpforms_admin.debug&&(o=_.isEmpty(o)?"":": "+o,console.log("WPForms Debug: Error receiving log record data"+o))}};return s}((document,window),jQuery);WPFormsLogger.init();
Save Changes
Rename File
Rename