File tree 1 file changed +8
-4
lines changed
templates/checkout/_partials
1 file changed +8
-4
lines changed Original file line number Diff line number Diff line change 12
12
<ul class =" cart-voucher__list" >
13
13
{ foreach from= $cart .vouchers.added item= voucher}
14
14
<li class =" cart-voucher__item row" >
15
- <span class =" cart-voucher__name col" >{ $voucher .name} </span >
16
15
<div class =" d-flex align-items-center justify-content-end col" >
16
+ <span class =" cart-voucher__name col" >{ $voucher .name} </span >
17
17
<span class =" fw-bold" >{ $voucher .reduction_formatted} </span >
18
18
{ if isset($voucher .code) && $voucher .code !== ' ' }
19
- <a href =" { $voucher .delete_url} " class =" ms-2" data-link-action =" remove-voucher" ><i class =" material-icons" title =" { l s= ' Remove Voucher' d= ' Shop.Theme.Checkout' } " > ; </i ></a >
19
+ <form action =" { $urls .pages.cart} ?action=show" data-link-action =" remove-voucher" class =" d-flex" method =" post" >
20
+ <input type =" hidden" name =" token" value =" { $static_token } " >
21
+ <input type =" hidden" name =" deleteDiscount" value =" { $voucher .id_cart_rule} " >
22
+ <button type =" submit" class =" btn btn-link ms-2" ><span ><i class =" material-icons" title =" { l s= ' Remove Voucher' d= ' Shop.Theme.Checkout' } " > ; </i ></span ></button >
23
+ </form >
20
24
{ /if }
21
25
</div >
22
26
</li >
23
27
{ /foreach }
24
28
</ul >
25
29
{ /block }
26
30
{ /if }
27
-
31
+
28
32
<hr />
29
33
30
34
<div class =" accordion" >
36
40
<div id =" promo-code" class =" accordion-collapse collapse" >
37
41
<div class =" accordion-body px-0" >
38
42
{ block name= ' cart_voucher_form' }
39
- <form action =" { $urls .pages.cart} " data-link-action =" add-voucher" class =" d-flex" method =" post" >
43
+ <form action =" { $urls .pages.cart} ?action=show " data-link-action =" add-voucher" class =" d-flex" method =" post" >
40
44
<input type =" hidden" name =" token" value =" { $static_token } " >
41
45
<input type =" hidden" name =" addDiscount" value =" 1" >
42
46
<input class =" form-control" type =" text" name =" discount_name" placeholder =" { l s= ' Paste your voucher here' d= ' Shop.Theme.Checkout' } " >
You can’t perform that action at this time.
0 commit comments