Tax settings page clean.
This commit is contained in:
parent
48079a8fc6
commit
a2bfe99c18
|
@ -925,18 +925,16 @@ $woocommerce_settings['tax'] = apply_filters('woocommerce_tax_settings', array(
|
|||
'desc' => __( 'Enable taxes and tax calculations', 'woocommerce' ),
|
||||
'id' => 'woocommerce_calc_taxes',
|
||||
'std' => 'no',
|
||||
'type' => 'checkbox',
|
||||
'checkboxgroup' => 'start',
|
||||
'show_if_checked' => 'option',
|
||||
'type' => 'checkbox'
|
||||
),
|
||||
|
||||
array(
|
||||
'name' => __( 'Calculation settings', 'woocommerce' ),
|
||||
'desc' => __( 'Calculate tax based on the customer shipping address', 'woocommerce' ),
|
||||
'id' => 'woocommerce_tax_shipping_address',
|
||||
'std' => 'yes',
|
||||
'type' => 'checkbox',
|
||||
'show_if_checked' => 'yes',
|
||||
'checkboxgroup' => ''
|
||||
'checkboxgroup' => 'start'
|
||||
),
|
||||
|
||||
array(
|
||||
|
@ -944,7 +942,6 @@ $woocommerce_settings['tax'] = apply_filters('woocommerce_tax_settings', array(
|
|||
'id' => 'woocommerce_tax_round_at_subtotal',
|
||||
'std' => 'no',
|
||||
'type' => 'checkbox',
|
||||
'show_if_checked' => 'yes',
|
||||
'checkboxgroup' => ''
|
||||
),
|
||||
|
||||
|
@ -952,8 +949,6 @@ $woocommerce_settings['tax'] = apply_filters('woocommerce_tax_settings', array(
|
|||
'desc' => __( 'Display taxes on the cart page', 'woocommerce' ),
|
||||
'id' => 'woocommerce_display_cart_taxes',
|
||||
'std' => 'yes',
|
||||
'type' => 'checkbox',
|
||||
'show_if_checked' => 'yes',
|
||||
'checkboxgroup' => ''
|
||||
),
|
||||
|
||||
|
@ -962,7 +957,6 @@ $woocommerce_settings['tax'] = apply_filters('woocommerce_tax_settings', array(
|
|||
'id' => 'woocommerce_display_cart_taxes_if_zero',
|
||||
'std' => 'no',
|
||||
'type' => 'checkbox',
|
||||
'show_if_checked' => 'yes',
|
||||
'checkboxgroup' => 'end',
|
||||
),
|
||||
|
||||
|
|
|
@ -100,10 +100,14 @@ function woocommerce_tax_rates_setting() {
|
|||
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<?php if ( empty( $local_tax_rates ) ) : ?>
|
||||
<p style="margin: 1em 0 0;"><a href="#" data-tip="<?php _e( 'Add local tax rates to define rules for specific zip codes and cities.', 'woocommerce' ); ?>" class="tips toggle_local_tax_rates">+ <?php _e( 'Local tax rates', 'woocommerce' ); ?></a></p>
|
||||
<?php endif; ?>
|
||||
</td>
|
||||
</tr>
|
||||
<tr valign="top">
|
||||
<th scope="row" class="titledesc"><?php _e('Local Tax Rates', 'woocommerce') ?></th>
|
||||
<tr valign="top" <?php if ( empty( $local_tax_rates ) ) : ?>style="display:none;"<?php endif; ?> class="local_tax_rates">
|
||||
<th scope="row" class="titledesc"><?php _e( 'Local tax rates', 'woocommerce' ); ?></th>
|
||||
<td class="forminp">
|
||||
<a class="button export_rates" href="<?php echo add_query_arg( 'wc_export_tax_rates', 2 ); ?>"><?php _e('Export rates', 'woocommerce'); ?></a>
|
||||
<a class="button import_rates" href="<?php echo admin_url( 'admin.php?import=woocommerce_tax_rate_csv' ); ?>"><?php _e('Import rates', 'woocommerce'); ?></a>
|
||||
|
@ -369,6 +373,13 @@ function woocommerce_tax_rates_setting() {
|
|||
return false;
|
||||
});
|
||||
|
||||
// Show local rates
|
||||
jQuery( 'a.toggle_local_tax_rates' ).click(function(){
|
||||
jQuery(this).closest('p').hide();
|
||||
jQuery('tr.local_tax_rates').slideDown();
|
||||
return false;
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
<?php
|
||||
|
|
|
@ -190,6 +190,7 @@ Yes you can! Join in on our [GitHub repository](http://github.com/woothemes/wooc
|
|||
* Tweak - Removed upsell limit - show whats defined.
|
||||
* Tweak - Args for upsells to control per-page and cols.
|
||||
* Tweak - Recoded add_to_cart_action for better handling of variations and groups.
|
||||
* Tweak - Admin sales stats show totals.
|
||||
|
||||
* Fix - Added more error messages for coupons.
|
||||
* Fix - Variation sku updating after selection.
|
||||
|
|
Loading…
Reference in New Issue