PATH:
home
/
cuisinesj
/
www
/
new
/
wp-content
/
plugins
/
woocommerce
/
assets
/
js
/
admin
/* global woocommerce_settings_params */ ( function( $ ) { // Sell Countries $( 'select#woocommerce_allowed_countries' ).change( function() { if ( 'specific' === $( this ).val() ) { $( this ).closest('tr').next( 'tr' ).hide(); $( this ).closest('tr').next().next( 'tr' ).show(); } else if ( 'all_except' === $( this ).val() ) { $( this ).closest('tr').next( 'tr' ).show(); $( this ).closest('tr').next().next( 'tr' ).hide(); } else { $( this ).closest('tr').next( 'tr' ).hide(); $( this ).closest('tr').next().next( 'tr' ).hide(); } }).change(); // Ship Countries $( 'select#woocommerce_ship_to_countries' ).change( function() { if ( 'specific' === $( this ).val() ) { $( this ).closest('tr').next( 'tr' ).show(); } else { $( this ).closest('tr').next( 'tr' ).hide(); } }).change(); // Stock management $( 'input#woocommerce_manage_stock' ).change( function() { if ( $( this ).is(':checked') ) { $( this ).closest('tbody').find( '.manage_stock_field' ).closest( 'tr' ).show(); } else { $( this ).closest('tbody').find( '.manage_stock_field' ).closest( 'tr' ).hide(); } }).change(); // Color picker $( '.colorpick' ) .iris({ change: function( event, ui ) { $( this ).parent().find( '.colorpickpreview' ).css({ backgroundColor: ui.color.toString() }); }, hide: true, border: true }) .on( 'click focus', function( event ) { event.stopPropagation(); $( '.iris-picker' ).hide(); $( this ).closest( 'td' ).find( '.iris-picker' ).show(); $( this ).data( 'original-value', $( this ).val() ); }) .on( 'change', function() { if ( $( this ).is( '.iris-error' ) ) { var original_value = $( this ).data( 'original-value' ); if ( original_value.match( /^\#([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/ ) ) { $( this ).val( $( this ).data( 'original-value' ) ).change(); } else { $( this ).val( '' ).change(); } } }); $( 'body' ).on( 'click', function() { $( '.iris-picker' ).hide(); }); // Edit prompt $( function() { var changed = false; $( 'input, textarea, select, checkbox' ).change( function() { changed = true; }); $( '.woo-nav-tab-wrapper a' ).click( function() { if ( changed ) { window.onbeforeunload = function() { return woocommerce_settings_params.i18n_nav_warning; }; } else { window.onbeforeunload = ''; } }); $( '.submit input' ).click( function() { window.onbeforeunload = ''; }); }); // Sorting $( 'table.wc_gateways tbody, table.wc_shipping tbody' ).sortable({ items: 'tr', cursor: 'move', axis: 'y', handle: 'td.sort', scrollSensitivity: 40, helper: function( event, ui ) { ui.children().each( function() { $( this ).width( $( this ).width() ); }); ui.css( 'left', '0' ); return ui; }, start: function( event, ui ) { ui.item.css( 'background-color', '#f6f6f6' ); }, stop: function( event, ui ) { ui.item.removeAttr( 'style' ); } }); // Select all/none $( '.woocommerce' ).on( 'click', '.select_all', function() { $( this ).closest( 'td' ).find( 'select option' ).attr( 'selected', 'selected' ); $( this ).closest( 'td' ).find( 'select' ).trigger( 'change' ); return false; }); $( '.woocommerce' ).on( 'click', '.select_none', function() { $( this ).closest( 'td' ).find( 'select option' ).removeAttr( 'selected' ); $( this ).closest( 'td' ).find( 'select' ).trigger( 'change' ); return false; }); })( jQuery );
[+]
..
[-] api-keys.min.js
[edit]
[-] meta-boxes.min.js
[edit]
[-] meta-boxes-product-variation.js
[edit]
[-] wc-product-import.min.js
[edit]
[-] wc-orders.js
[edit]
[-] meta-boxes.js
[edit]
[-] quick-edit.js
[edit]
[-] meta-boxes-product-variation.min.js
[edit]
[-] product-ordering.min.js
[edit]
[-] wc-shipping-classes.js
[edit]
[-] meta-boxes-coupon.min.js
[edit]
[-] wc-product-import.js
[edit]
[-] wc-product-export.min.js
[edit]
[-] wc-shipping-zones.js
[edit]
[-] reports.js
[edit]
[-] meta-boxes-order.min.js
[edit]
[-] wc-setup.min.js
[edit]
[-] system-status.js
[edit]
[-] meta-boxes-order.js
[edit]
[-] users.min.js
[edit]
[-] product-ordering.js
[edit]
[-] settings.js
[edit]
[-] reports.min.js
[edit]
[-] wc-setup.js
[edit]
[-] woocommerce_admin.js
[edit]
[-] wc-shipping-zones.min.js
[edit]
[-] wc-product-export.js
[edit]
[-] term-ordering.js
[edit]
[-] wc-clipboard.min.js
[edit]
[-] system-status.min.js
[edit]
[-] woocommerce_admin.min.js
[edit]
[-] wc-shipping-classes.min.js
[edit]
[-] meta-boxes-product.min.js
[edit]
[-] quick-edit.min.js
[edit]
[-] meta-boxes-product.js
[edit]
[-] wc-shipping-zone-methods.min.js
[edit]
[-] wc-enhanced-select.js
[edit]
[-] settings.min.js
[edit]
[-] backbone-modal.min.js
[edit]
[-] wc-shipping-zone-methods.js
[edit]
[-] settings-views-html-settings-tax.min.js
[edit]
[-] users.js
[edit]
[-] backbone-modal.js
[edit]
[-] meta-boxes-coupon.js
[edit]
[-] api-keys.js
[edit]
[-] term-ordering.min.js
[edit]
[-] wc-enhanced-select.min.js
[edit]
[-] wc-clipboard.js
[edit]
[-] wc-orders.min.js
[edit]
[-] settings-views-html-settings-tax.js
[edit]