Ignore:
Timestamp:
Mar 30, 2011, 12:14:02 PM (13 years ago)
Author:
patdenice
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • extensions/autoupdate/trunk/template/autoupdate.js

    r9735 r9935  
    1212
    1313function resetIgnored() {
    14   jQuery.post(
    15     "plugins/autoupdate/ajax/ignore_list.php",
    16     { reset: true, pwg_token: pwg_token },
    17     function(data) {
    18       if (data == "ok") {
     14  jQuery.ajax({
     15    type: 'GET',
     16    url: 'ws.php',
     17    dataType: 'json',
     18    data: { method: 'pwg.extensions.ignoreUpdates', reset: true, pwg_token: pwg_token, format: 'json' },
     19    success: function(data) {
     20      if (data['stat'] == 'ok') {
    1921        jQuery(".pluginBox, fieldset").show();
    2022        jQuery("#update_all").show();
     
    2527      }
    2628    }
    27   );
     29  });
    2830};
    2931
     
    5759  jQuery('.autoupdate_bar').toggle();
    5860  jQuery.ajax({
    59     type: 'POST',
    60     url: 'plugins/autoupdate/ajax/update_'+type+'.php',
    61     data: { id: id, revision: revision, pwg_token: pwg_token },
     61    type: 'GET',
     62    url: 'ws.php',
     63    data: { method: 'pwg.'+type+'s.update', id: id, revision: revision, pwg_token: pwg_token, format: 'json' },
    6264    success: function(data) {
    63       if (data['result']) {
     65      if (data['stat'] == 'ok') {
    6466        jQuery("#"+type+"_"+id).remove();
    6567        checkFieldsets();
    6668        jQuery.jGrowl(
    67           data['msg'],
     69          data['result'],
    6870          {
    6971            theme:  'success',
     
    7779      } else {
    7880        jQuery.jGrowl(
    79           data['msg'],
     81          data['result'],
    8082          {
    8183            theme:  'error',
     
    105107
    106108function ignoreExtension(type, id) {
    107   jQuery.post(
    108     "plugins/autoupdate/ajax/ignore_list.php",
    109     { type: type+'s', id: id, pwg_token: pwg_token },
    110     function(data) {
    111       if (data == "ok") {
     109  jQuery.ajax({
     110    type: 'GET',
     111    url: 'ws.php',
     112    dataType: 'json',
     113    data: { method: 'pwg.extensions.ignoreUpdates', type: type+'s', id: id, pwg_token: pwg_token, format: 'json' },
     114    success: function(data) {
     115      if (data['stat'] == 'ok') {
    112116        jQuery("#"+type+"_"+id).hide();
    113117        jQuery("#reset_ignore").show();
     
    115119      }
    116120    }
    117   );
     121  });
    118122};
Note: See TracChangeset for help on using the changeset viewer.