Changeset 9935 for extensions/autoupdate/trunk/template/autoupdate.js
- Timestamp:
- Mar 30, 2011, 12:14:02 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/autoupdate/trunk/template/autoupdate.js
r9735 r9935 12 12 13 13 function 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') { 19 21 jQuery(".pluginBox, fieldset").show(); 20 22 jQuery("#update_all").show(); … … 25 27 } 26 28 } 27 );29 }); 28 30 }; 29 31 … … 57 59 jQuery('.autoupdate_bar').toggle(); 58 60 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' }, 62 64 success: function(data) { 63 if (data[' result']) {65 if (data['stat'] == 'ok') { 64 66 jQuery("#"+type+"_"+id).remove(); 65 67 checkFieldsets(); 66 68 jQuery.jGrowl( 67 data[' msg'],69 data['result'], 68 70 { 69 71 theme: 'success', … … 77 79 } else { 78 80 jQuery.jGrowl( 79 data[' msg'],81 data['result'], 80 82 { 81 83 theme: 'error', … … 105 107 106 108 function 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') { 112 116 jQuery("#"+type+"_"+id).hide(); 113 117 jQuery("#reset_ignore").show(); … … 115 119 } 116 120 } 117 );121 }); 118 122 };
Note: See TracChangeset
for help on using the changeset viewer.