gutenberg
3 years ago
gutenbergComponents
3 years ago
autoupdate_banner.js
3 years ago
banner_main.js
3 years ago
circle-progress.js
3 years ago
datatables.min.js
4 years ago
jquery.multi-select.js
4 years ago
jquery.tagsinput.min.js
4 years ago
referral_program.js
3 years ago
sidebar-plugin.js
3 years ago
speed.js
3 years ago
two_admin.js
1 year ago
two_admin_bar.js
4 years ago
two_bf_countdown.js
3 years ago
two_deactivate_plugin.js
4 years ago
two_elementor_editor.js
2 years ago
two_preview.js
3 years ago
two_update_white_label.js
1 year ago
two_white_label.js
2 years ago
autoupdate_banner.js
25 lines
| 1 | jQuery(document).ready( function(){ |
| 2 | jQuery('.two-set-autoupdate').on('click', function(){ |
| 3 | two_set_autoupdate_data(jQuery(this)); |
| 4 | }); |
| 5 | }); |
| 6 | |
| 7 | function two_set_autoupdate_data(that) { |
| 8 | two_close_banner(); |
| 9 | let auto_update = ''; |
| 10 | if ( jQuery(that).hasClass('two-enable-autoupdate') ) { |
| 11 | auto_update = 'enable'; |
| 12 | } |
| 13 | jQuery.ajax({ |
| 14 | type: 'POST', |
| 15 | url: two_speed.ajax_url, |
| 16 | dataType: 'json', |
| 17 | data: { |
| 18 | action: 'two_set_autoupdate_from_banner', |
| 19 | auto_update: auto_update, |
| 20 | nonce: two_speed.nonce, |
| 21 | } |
| 22 | }).success(function ($result) { |
| 23 | console.log($result); |
| 24 | }); |
| 25 | } |