Rev 30877 | Rev 33047 | Go to most recent revision | View as "text/plain" | Blame | Compare with Previous | Last modification | View Log | RSS feed
$(function () {$(document).on('click', ".partner-credit-detail", function () {loadCreditDetail("main-content");});$(document).on('click', '.activate-partner-kred', function () {var row = $(this).closest("tr");var id = $(this).data('id');let gateway = $(row).find('select').val();console.log(id)if (confirm(`Are you sure you want to activate ${gateway}?`)) {doPostAjaxRequestHandler(`${context}/activateKred?id=${id}&gateway=${gateway}`,function (response) {row.html(response);alert(`${gateway} successfully activated`);});}});$(document).on('click', '.deactivate-partner-kred', function () {var row = $(this).closest("tr");var id = $(this).data('id');console.log(id)if (confirm('Are you sure you want to deactivate?')) {doPostAjaxRequestHandler(context + "/deactivateKred?id=" + id,function (response) {row.html(response);alert(`${gateway} successfully deactivated`);});}});});function loadCreditDetail(domId) {doGetAjaxRequestHandler(context + "/getCreditDetail",function (response) {$('#' + domId).html(response);});}