2016-01-19 17:57:03 +00:00
< ? php
if ( ! defined ( 'ABSPATH' ) ) {
exit ;
}
?>
2016-05-13 15:08:19 +00:00
< h2 >
< a href = " <?php echo admin_url( 'admin.php?page=wc-settings&tab=shipping' ); ?> " >< ? php _e ( 'Shipping Zones' , 'woocommerce' ); ?> </a> >
< ? php echo esc_html ( $zone -> get_zone_name () ); ?>
< ? php echo wc_help_tip ( __ ( 'The following shipping methods apply to customers with shipping addresses within this zone.' , 'woocommerce' ) ); ?>
</ h2 >
2016-05-23 16:01:45 +00:00
< ? php do_action ( 'woocommerce_shipping_zone_before_methods_table' ); ?>
2016-05-20 12:27:25 +00:00
2016-01-05 11:23:15 +00:00
< table class = " wc-shipping-zone-methods widefat " >
2016-05-12 10:07:18 +00:00
< thead >
< tr >
< th class = " wc-shipping-zone-method-sort " >< ? php echo wc_help_tip ( __ ( 'Drag and drop to re-order your shipping methods. This is the order in which they will display during checkout.' , 'woocommerce' ) ); ?> </th>
< th class = " wc-shipping-zone-method-title " >< ? php esc_html_e ( 'Title' , 'woocommerce' ); ?> </th>
2016-01-05 11:23:15 +00:00
< th class = " wc-shipping-zone-method-enabled " >< ? php esc_html_e ( 'Enabled' , 'woocommerce' ); ?> </th>
2016-05-12 10:07:18 +00:00
< th class = " wc-shipping-zone-method-type " >< ? php esc_html_e ( 'Type' , 'woocommerce' ); ?> </th>
< th class = " wc-shipping-zone-method-description " >< ? php esc_html_e ( 'Description' , 'woocommerce' ); ?> </th>
</ tr >
</ thead >
< tfoot >
< tr >
< td colspan = " 5 " >
< input type = " submit " name = " save " class = " button button-primary wc-shipping-zone-method-save " value = " <?php esc_attr_e( 'Save changes', 'woocommerce' ); ?> " disabled />
2016-05-12 10:29:33 +00:00
< input type = " submit " class = " button button-secondary wc-shipping-zone-add-method " value = " <?php esc_attr_e( 'Add shipping method', 'woocommerce' ); ?> " />
2016-05-12 10:07:18 +00:00
</ td >
</ tr >
</ tfoot >
< tbody class = " wc-shipping-zone-method-rows " ></ tbody >
2016-01-05 11:23:15 +00:00
</ table >
< script type = " text/html " id = " tmpl-wc-shipping-zone-method-row-blank " >
< tr >
2016-05-12 10:07:18 +00:00
< td class = " wc-shipping-zone-method-blank-state " colspan = " 5 " >
2016-03-29 18:51:09 +00:00
< p class = " main " >< ? php _e ( 'Add shipping methods to this zone' , 'woocommerce' ); ?> </p>
< p >< ? php _e ( 'You can add multiple shipping methods within this zone. Only customers within the zone will see them.' , 'woocommerce' ); ?> </p>
< p >< ? php _e ( 'Choose a method from the dropdown below and click "Add shipping method" to get started.' , 'woocommerce' ); ?> </p>
2016-01-05 11:23:15 +00:00
</ td >
</ tr >
</ script >
< script type = " text/html " id = " tmpl-wc-shipping-zone-method-row " >
2016-05-12 10:07:18 +00:00
< tr data - id = " { { data.instance_id }} " data - enabled = " { { data.enabled }} " >
< td width = " 1% " class = " wc-shipping-zone-method-sort " ></ td >
< td class = " wc-shipping-zone-method-title " >
2016-05-12 10:37:48 +00:00
< a class = " wc-shipping-zone-method-settings " href = " admin.php?page=wc-settings&tab=shipping&instance_id= { { data.instance_id }} " > {{ data . title }} </ a >
2016-05-12 10:07:18 +00:00
< div class = " row-actions " >
< a class = " wc-shipping-zone-method-settings " href = " admin.php?page=wc-settings&tab=shipping&instance_id= { { data.instance_id }} " >< ? php _e ( 'Settings' , 'woocommerce' ); ?> </a> | <a href="#" class="wc-shipping-zone-method-delete"><?php _e( 'Remove', 'woocommerce' ); ?></a>
</ div >
2016-01-05 11:23:15 +00:00
</ td >
2016-05-12 10:07:18 +00:00
< td width = " 1% " class = " wc-shipping-zone-method-enabled " >< a href = " # " > {{{ data . enabled_icon }}} </ a ></ td >
< td class = " wc-shipping-zone-method-type " > {{ data . method_title }} </ td >
< td class = " wc-shipping-zone-method-description " > {{ data . method_description }} </ td >
</ tr >
2016-01-05 11:23:15 +00:00
</ script >
2016-03-24 17:26:40 +00:00
< script type = " text/template " id = " tmpl-wc-modal-shipping-method-settings " >
2016-03-24 18:31:39 +00:00
< div class = " wc-backbone-modal wc-backbone-modal-shipping-method-settings " >
2016-03-24 17:26:40 +00:00
< div class = " wc-backbone-modal-content " >
< section class = " wc-backbone-modal-main " role = " main " >
< header class = " wc-backbone-modal-header " >
2016-04-22 17:08:44 +00:00
< h1 >< ? php echo esc_html ( sprintf ( _x ( '%s Settings' , 'Shipping Method Settings' , 'woocommerce' ), '{{{ data.method.method_title }}}' ) ); ?> </h1>
2016-03-24 17:26:40 +00:00
< button class = " modal-close modal-close-link dashicons dashicons-no-alt " >
< span class = " screen-reader-text " >< ? php _e ( 'Close modal panel' , 'woocommerce' ); ?> </span>
</ button >
</ header >
< article class = " wc-modal-shipping-method-settings " >
< form action = " " method = " post " >
{{{ data . method . settings_html }}}
< input type = " hidden " name = " instance_id " value = " { { { data.instance_id }}} " />
</ form >
</ article >
< footer >
< div class = " inner " >
< button id = " btn-ok " class = " button button-primary button-large " >< ? php _e ( 'Save changes' , 'woocommerce' ); ?> </button>
</ div >
</ footer >
</ section >
</ div >
</ div >
< div class = " wc-backbone-modal-backdrop modal-close " ></ div >
</ script >
2016-05-12 10:29:33 +00:00
< script type = " text/template " id = " tmpl-wc-modal-add-shipping-method " >
< div class = " wc-backbone-modal " >
< div class = " wc-backbone-modal-content " >
< section class = " wc-backbone-modal-main " role = " main " >
< header class = " wc-backbone-modal-header " >
< h1 >< ? php _e ( 'Add shipping method' , 'woocommerce' ); ?> </h1>
< button class = " modal-close modal-close-link dashicons dashicons-no-alt " >
< span class = " screen-reader-text " >< ? php _e ( 'Close modal panel' , 'woocommerce' ); ?> </span>
</ button >
</ header >
< article >
< form action = " " method = " post " >
< div class = " wc-shipping-zone-method-selector " >
2016-06-20 11:50:52 +00:00
< p >< ? php esc_html_e ( 'Choose the shipping method you wish to add. Only shipping methods which support zones are listed.' , 'woocommerce' ); ?> </p>
2016-05-12 10:29:33 +00:00
< select name = " add_method_id " >
< ? php
foreach ( WC () -> shipping -> load_shipping_methods () as $method ) {
if ( ! $method -> supports ( 'shipping-zones' ) ) {
continue ;
}
echo '<option data-description="' . esc_attr ( $method -> method_description ) . '" value="' . esc_attr ( $method -> id ) . '">' . esc_attr ( $method -> title ) . '</li>' ;
}
?>
</ select >
</ div >
</ form >
</ article >
< footer >
< div class = " inner " >
< button id = " btn-ok " class = " button button-primary button-large " >< ? php _e ( 'Add shipping method' , 'woocommerce' ); ?> </button>
</ div >
</ footer >
</ section >
</ div >
</ div >
< div class = " wc-backbone-modal-backdrop modal-close " ></ div >
</ script >