Thread Starter
angel9
(@lovesgigi)
I fixed the issues.
run_custom_browser: function (t) {
["browser-" + t + "-chart", "browser-" + t + "-table"].forEach(function (t) {
jQuery("#" + t + " .inside").css("height", "430px")
}), jQuery("#browser-" + t + "-table .inside").html(d.placeholder()), jQuery("#browser-" + t + "-chart .inside").html(d.circle_placeholder()), jQuery(".wps-ph-picture").attr("style", "height: 310px;");
var e = {
name: "browsers",
wps_nonce: "" + d.global.rest_api_nonce,//**this code fix the issues
browser: t
};
Thread Starter
angel9
(@lovesgigi)
Fix for 14.5.2
/wp-statistics/assets/js/admin.min.js
run_custom_browser: function (agent) {
// Show Placeholder
['browser-' + agent + '-chart', 'browser-' + agent + '-table'].forEach((key) => {
jQuery("#" + key + " .inside").css('height', '430px');
});
jQuery("#browser-" + agent + "-table .inside").html(wps_js.placeholder());
jQuery("#browser-" + agent + "-chart .inside").html(wps_js.circle_placeholder());
jQuery(".wps-ph-picture").attr("style", "height: 310px;");
//Prepare Params
let params = {'name': 'browsers', 'browser': agent, 'wps_nonce': wps_js.global.rest_api_nonce};//**fix the issues
['from', 'to'].forEach((key) => {
if (wps_js.isset(wps_js.global, 'request_params', key)) {
params[key] = wps_js.global.request_params[key];
}
});
// Send Request
wps_js.ajaxQ(wps_js.global.meta_box_api, params, 'show_custom_agent', 'error_custom_agent', 'GET', false);
}
-
This reply was modified 2 years ago by
angel9.