Shipping plugin - hide price in options

Hello,

we are fine-tuning our shipping plugin based on pickup plugin.

1/ Usually, all prices are the same and we are storing price also in one variable. Is it possible to hide price from select options?

The most important part of calculate() function is:

$deliveries[$i++] = array(
                'id'         => $rate['id'],
		'name'         => $rate['location'],
                'currency'     => $currency,
                'rate'         => $delivery_price,
                'est_delivery' => ''
);

Each option in select box contains price, which is also written next to the plugin name. I would like to hide price from each option:

2/ We have added custom option for filtering location by regions. We are using solution from topic (https://support.webasyst.com/18875/modify-user-interface-in-shipping-selection-for-customers/#comment58075). Custom controls are rendered after selection of this plugin by customer. Select with all location is visible all the time, but these controls not. Is it possible to preorder custom control before classical select? To put our select fog regions before list of locations.

Thank for advices,

Tomas

1 answer

  • 1
    Mike Webasyst June 13, 2017 16:00 #

    Sorry for a late comment...

    1. I think that you can only use JavaScript in a custom control to hide prices from your shipping options. Or customize your design theme to achieve the same. Unfortinately, this will only affect your personal online store and will work if you publish your plugin in Webasyst Store. Because ultimately displaying of shipping methods and their options is controlled by design themes.
    2. This behavior is also controlled by the app and the design theme your plugin is used with. In case of Shop-Script, you can try to change it using JavaScript, too. Should some day appear another app with shipping plugins support, it may have its own way of displaying

Add answer

To add a comment please sign up or login