Jump to content

Payments Method won't update after change carrier free shipping.


drasl

Recommended Posts

Like the title says...

 

I wan't to except the COD payment method for a single carrier.

 

I just add this if in modules/codfee/views/templates/hook/payment.tpl :

{if (context::getContext()->cart->id_carrier != 133 )}
<div class="capa_codfee col-xs-12 col-md-6">
	<p class="payment_module">
		<a class="codfee" href="{$link->getModuleLink('codfee', 'validation', [], true)}" title="{l s='Cash on delivery (COD)' mod='codfee'}">
		{l s='Cash on delivery (COD) : you pay for the merchandise upon delivery' mod='codfee'} <span>{l s='Aditional cost: ' mod='codfee'}<strong>{convertPrice price=$fee}</strong></span>
		</a>
	</p>
</div>
{/if}

I thought it was working, but nop. It's works when I change between not free carriers, but when O change to a free shipping carrier, the {$HOOK_PAYMENT} won't update, it's only update via ajax when you change the radio option between not free carriers...

 

Do you guys have some idea about it?

Link to comment
Share on other sites

I won't work, the problem is when i switch between radio buttons free carriers, ajax won't update the codfee tpl. :(

 

 

 

it might be not that easy, but there should be a way for you to pass back the carrier selection info and free shipping or not via ajax call.

maybe you can try to contact the developer of the module for help.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...