174 lines
6.8 KiB
Smarty
174 lines
6.8 KiB
Smarty
{**
|
|
* 2010-2020 Webkul.
|
|
*
|
|
* NOTICE OF LICENSE
|
|
*
|
|
* All right is reserved,
|
|
* Please go through this link for complete license : https://store.webkul.com/license.html
|
|
*
|
|
* DISCLAIMER
|
|
*
|
|
* Do not edit or add to this file if you wish to upgrade this module to newer
|
|
* versions in the future. If you wish to customize this module for your
|
|
* needs please refer to https://store.webkul.com/customisation-guidelines/ for more information.
|
|
*
|
|
* @author Webkul IN <support@webkul.com>
|
|
* @copyright 2010-2020 Webkul IN
|
|
* @license https://store.webkul.com/license.html
|
|
*}
|
|
|
|
<div class="wk-payment-method">
|
|
<div class="wk-heading-img">
|
|
<div class="wk-payment-icon wk-sprit wk-left"></div>
|
|
<h4 class="wk-left">{l s='Payment Method' mod='wkonepagecheckout'}</h4>
|
|
<div class="wkerrorcolor wkhide wk-left" id="wkpayment-error" style="margin-left:25px;"></div>
|
|
</div>
|
|
<div class="payment-options">
|
|
{if $wk_is_logged == 1}
|
|
{if isset($is_free) && $is_free}
|
|
<input type="hidden" value="{$is_free}" id="wk_free_order" />
|
|
<p>{l s='No payment needed for this order' mod='wkonepagecheckout'}</p>
|
|
{/if}
|
|
{if isset($payment_options) && $payment_options}
|
|
<div {if $is_free}class="hidden-xs-up"{/if}>
|
|
{foreach from=$payment_options item="module_options"}
|
|
<div class="row wk-payment-select">
|
|
{foreach from=$module_options item="option"}
|
|
<div class="wk-payment-list col-md-12 col-sm-12 col-xs-12">
|
|
<div id="{$option.id}-container" class="wk-payment col-xs-1 col-sm-1 col-md-1 payment-option wkpadding">
|
|
{* This is the way an option should be selected when Javascript is enabled *}
|
|
<span class="custom-radio pull-xs-left">
|
|
<input
|
|
{if Configuration::get('WK_CHECKOUT_DEFAULT_PAYMENT') == $option.module_name || $is_free}checked="checked"{/if}
|
|
class="ps-shown-by-js {if $option.binary} binary {/if}"
|
|
id="{$option.id}"
|
|
data-module-name="{$option.module_name}"
|
|
name="payment-option"
|
|
type="radio"
|
|
required>
|
|
<span></span>
|
|
</span>
|
|
{* This is the way an option should be selected when Javascript is disabled *}
|
|
<form method="GET" class="ps-hidden-by-js">
|
|
<button class="ps-hidden-by-js" type="submit" name="select_payment_option" value="{$option.id}">
|
|
{l s='Choose' mod='wkonepagecheckout'}
|
|
</button>
|
|
</form>
|
|
</div>
|
|
<div class="wk-payment-info col-md-11 col-sm-9 col-xs-9 wk-selected-payment-{$option.id} {if Configuration::get('WK_CHECKOUT_DEFAULT_PAYMENT') && (Configuration::get('WK_CHECKOUT_DEFAULT_PAYMENT') == $option.module_name)}wkSelectedBorder{/if}">
|
|
<div class="row">
|
|
{if Configuration::get('WK_CHECKOUT_PAYMENT_LOGO')}
|
|
<div class="col-md-3 col-xs-12 col-sm-3">
|
|
{if $option.logo}
|
|
<img src="{$option.logo}" width="50">
|
|
{else}
|
|
<img class="wk-custom-payment-icon" width="50" src="{$wk_opc_modules_dir}img/wk-icon-money.jpg">
|
|
{/if}
|
|
</div>
|
|
{/if}
|
|
<div class="col-md-9 col-xs-12 col-sm-9">
|
|
{php}
|
|
$user_group = Customer::getDefaultGroupId( Context::getContext() -> customer -> id );
|
|
if ( $user_group >= 4 )
|
|
{
|
|
{/php}
|
|
{if $option.call_to_action_text == 'Zapłać przelewem'}
|
|
<p>Przedpłata / Przelew</p>
|
|
{else}
|
|
<p>{$option.call_to_action_text}</p>
|
|
{/if}
|
|
{php}
|
|
}
|
|
else
|
|
{
|
|
{/php}
|
|
{if $option.module_name == 'imoje'}
|
|
{if $language.id == 2 }
|
|
<p>Fast online transfers, BLIK, Google Pay and cards</p>
|
|
{else}
|
|
<p>{$option.call_to_action_text}</p>
|
|
{/if}
|
|
{else}
|
|
<p>{$option.call_to_action_text}</p>
|
|
{/if}
|
|
{php}
|
|
}
|
|
{/php}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{if $option.module_name == 'imoje'}
|
|
<img src="/img/imoje-big4.png"
|
|
style="
|
|
width: 100%;
|
|
max-width: fit-content;
|
|
margin-top: 10px;
|
|
margin-left: auto;
|
|
margin-right: auto;
|
|
display: block;
|
|
padding: 0 15px;
|
|
"
|
|
>
|
|
{/if}
|
|
{if $option.additionalInformation}
|
|
<div
|
|
id="{$option.id}-additional-information"
|
|
class="js-additional-information definition-list col-sm-11 offset-sm-1 wk-payment-info">
|
|
{$option.additionalInformation nofilter}
|
|
{if $option.module_name == 'ps_wirepayment'}
|
|
{php}
|
|
global $cookie;
|
|
|
|
$iso_code = Language::getIsoById( (int)$cookie->id_lang );
|
|
$user_group = Customer::getDefaultGroupId( Context::getContext() -> customer -> id );
|
|
|
|
if ( $user_group >= 4 )
|
|
{
|
|
if ( $iso_code == 'pl' )
|
|
echo 'Przedpłata po otrzymaniu faktury<br/>Przelew w uzgodnionym terminie';
|
|
else
|
|
echo 'Prepayment after receiving the invoice <br/> Transfer within the agreed period';
|
|
}
|
|
{/php}
|
|
{/if}
|
|
</div>
|
|
{/if}
|
|
<div id="pay-with-{$option.id}-form" class="js-payment-option-form wk-left">
|
|
{if $option.form}
|
|
{$option.form nofilter}
|
|
{else}
|
|
<form id="payment-form" method="POST" action="{$option.action nofilter}">
|
|
{foreach from=$option.inputs item=input}
|
|
<input type="{$input.type}" name="{$input.name}" value="{$input.value}">
|
|
{/foreach}
|
|
<button style="display:none" id="pay-with-{$option.id}" type="submit"></button>
|
|
</form>
|
|
{/if}
|
|
</div>
|
|
{/foreach}
|
|
</div>
|
|
{/foreach}
|
|
</div>
|
|
{else}
|
|
<div class="row">
|
|
<div class="col-md-12 col-sm-12 col-xs-12">
|
|
<div class="alert alert-danger">
|
|
{l s='Unfortunately, there are no payment method available.' mod='wkonepagecheckout'}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
{else}
|
|
<div class="row">
|
|
<div class="col-md-12 col-sm-12 col-xs-12">
|
|
<div class="alert alert-danger">
|
|
{l s='First you need to fill the shipping address.' mod='wkonepagecheckout'}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{/if}
|
|
</div>
|
|
<div id="wkpayment-method"></div>
|
|
</div>
|