Initial commit

This commit is contained in:
2019-11-20 07:44:43 +01:00
commit 5bf49c4a81
41188 changed files with 5459177 additions and 0 deletions

View File

@@ -0,0 +1,35 @@
<?php
/**
* 2007-2019 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2019 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*/
header("Expires: Mon, 26 Jul 1997 05:00:00 GMT");
header("Last-Modified: ".gmdate("D, d M Y H:i:s")." GMT");
header("Cache-Control: no-store, no-cache, must-revalidate");
header("Cache-Control: post-check=0, pre-check=0", false);
header("Pragma: no-cache");
header("Location: ../");
exit;

View File

@@ -0,0 +1,118 @@
{*
* 2007-2019 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2019 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
{*Displaying a button or the iframe*}
<div class="row">
<div class="col-xs-12 col-md-10">
<div class="braintree-row-payment">
<div class="payment_module braintree-card">
<form action="{$braintreeSubmitUrl}" id="braintree-form" method="post">
{if isset($init_error)}
<div class="alert alert-danger">{$init_error|escape:'htmlall':'UTF-8'}</div>
<div id="logo_braintree_by_paypal"><img src="https://s3-us-west-1.amazonaws.com/bt-partner-assets/paypal-braintree.png" height="20px"></div>
{else}
{if isset($active_vaulting) && isset($payment_methods) && !empty($payment_methods)}
<div id="bt-vault-form">
<p><b>{l s='Choose your card' mod='paypal'}:</b></p>
<select name="bt_vaulting_token" class="form-control">
<option value="">{l s='Choose your card' mod='paypal'}</option>
{foreach from=$payment_methods key=method_key item=method}
<option value="{$method.token|escape:'htmlall':'UTF-8'}" {if $check3Dsecure} data-nonce="{$method.nonce}"{/if}>
{if $method.name}{$method.name|escape:'htmlall':'UTF-8'} - {/if}
{$method.info|escape:'htmlall':'UTF-8'}
</option>
{/foreach}
</select>
</div>
{/if}
<div id="block-card-number" class="block_field">
<div id="card-number" class="hosted_field"><div id="card-image"></div></div>
</div>
<div id="block-expiration-date" class="block_field half_block_field">
<div id="expiration-date" class="hosted_field"></div>
</div>
<div id="block-cvv" class="block_field half_block_field">
<div id="cvv" class="hosted_field"></div>
</div>
<input type="hidden" name="deviceData" id="deviceData"/>
<input type="hidden" name="client_token" value="{$braintreeToken|escape:'htmlall':'UTF-8'}">
<input type="hidden" name="liabilityShifted" id="liabilityShifted"/>
<input type="hidden" name="liabilityShiftPossible" id="liabilityShiftPossible"/>
<input type="hidden" name="payment_method_nonce" id="payment_method_nonce"/>
<input type="hidden" name="card_type" id="braintree_card_type"/>
<input type="hidden" name="payment_method_bt" value="{$method_bt|escape:'htmlall':'UTF-8'}"/>
<div class="paypal_clear"></div>
<div id="bt-card-error-msg" class="alert alert-danger"></div>
{if isset($active_vaulting) && $active_vaulting}
<div class="save-in-vault">
<input type="checkbox" name="save_card_in_vault" id="save_card_in_vault"/> <label for="save_card_in_vault"> {l s='Memorize my card' mod='paypal'}</label>
</div>
{/if}
<div id="logo_braintree_by_paypal"><img src="https://s3-us-west-1.amazonaws.com/bt-partner-assets/paypal-braintree.png" height="20px"></div>
{/if}
</form>
</div>
</div>
</div>
</div>
<script>
var authorization = '{$braintreeToken|escape:'htmlall':'UTF-8'}';
var bt_amount = {$braintreeAmount|escape:'htmlall':'UTF-8'};
var check3DS = {$check3Dsecure|escape:'htmlall':'UTF-8'};
var bt_translations = {
client:"{l s='Error create Client' mod='paypal'}",
card_nmb:"{l s='Card number' mod='paypal'}",
cvc:"{l s='CVC' mod='paypal'}",
date:"{l s='MM/YY' mod='paypal'}",
hosted:"{l s='Error create Hosted fields' mod='paypal'}",
empty:"{l s='All fields are empty! Please fill out the form.' mod='paypal'}",
invalid:"{l s='Some fields are invalid :' mod='paypal'}",
token:"{l s='Tokenization failed server side. Is the card valid?' mod='paypal'}",
network:"{l s='Network error occurred when tokenizing.' mod='paypal'}",
tkn_failed:"{l s='Tokenize failed' mod='paypal'}",
https:"{l s='3D Secure requires HTTPS.' mod='paypal'}",
load_3d:"{l s='Load 3D Secure Failed' mod='paypal'}",
request_problem:"{l s='There was a problem with your request.' mod='paypal'}",
failed_3d:"{l s='3D Secure Failed' mod='paypal'}",
empty_field:"{l s='is empty.' mod='paypal'}",
expirationDate:"{l s='Expiration Date' mod='paypal'}",
number:"{l s='card number' mod='paypal'}",
cvv:"{l s='CVV' mod='paypal'}",
};
</script>

View File

@@ -0,0 +1,94 @@
{*
* 2007-2019 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2019 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
<!-- Header part menu -->
<head>
{block name='head'}
{include file='_partials/head.tpl'}
{/block}
</head>
<body>
{hook h='displayAfterBodyOpeningTag'}
<main>
<!-- Menu part-->
<header id="header">
{block name='header'}
{include file='_partials/header.tpl'}
{/block}
</header>
<!-- Header part ends -->
<section id="wrapper">
<div class="container">
<section id="main">
<section id="content" class="page-content card card-block">
{include file='_partials/breadcrumb.tpl'}
{if $method == 'BT'}
<h2>{l s='Error in Braintree' mod='paypal'}</h2>
{else}
<h2>{l s='Error in Paypal' mod='paypal'}</h2>
{/if}
<div class="table-responsive-row clearfix">
<p class="paypal_error_msg">
{if $error_msg == '' && $msg_long == ''}
{if $error_code}<span class="code">[{$error_code|escape:'htmlall':'UTF-8'}]</span>{/if}
{l s='Unexpected error occurred.' mod='paypal'}
{else}
{if $error_code}<span class="code">[{$error_code|escape:'htmlall':'UTF-8'}]</span>{/if}
{if $error_msg}<span class="short">{$error_msg|escape:'htmlall':'UTF-8'}</span>{/if}
<br>
{if $msg_long && $msg_long != $error_msg}
<span class="long">{l s='Additional error message : ' mod='paypal'}{$msg_long|escape:'htmlall':'UTF-8'}</span>
{/if}
{/if}
</p>
{if $show_retry}
<a class="btn btn-secondary" href="{$link->getPageLink('order', true)}">{l s='Try to pay again' mod='paypal'}</a>
{/if}
</div>
</section>
</section>
</div>
</section>
<!-- Footer starts -->
<footer id="footer">
{block name="footer"}
{include file="_partials/footer.tpl"}
{/block}
</footer>
<!-- Footer Ends -->
{block name='javascript_bottom'}
{include file="_partials/javascript.tpl" javascript=$javascript.bottom}
{/block}
{hook h='displayBeforeBodyClosingTag'}
</main>
</body>

View File

@@ -0,0 +1,29 @@
{*
* 2007-2019 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2019 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
<p>{l s='Benefit from many PayPal advantages such as :' mod='paypal'}</p>
<p><img src="{$path|escape:'html':'UTF-8'}views/img/protected.png" style="height: 43px; padding-right: 10px;">{l s='Your orders are protected' mod='paypal'}*</p>
<p><img src="{$path|escape:'html':'UTF-8'}views/img/refund.png" style=" height: 43px; padding-right: 10px;">{l s='Return shipping refunded' mod='paypal'}*</p>
<p><i>{l s='* See conditions on PayPal website' mod='paypal'}</i></p>

View File

@@ -0,0 +1,28 @@
{*
* 2007-2019 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2019 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
<p>{l s='You will be redirected to the PayPal website to process your card payment.' mod='paypal'}</p>
<p>{l s='PayPal secures your payment and protect your financial information with strong encryption tools.' mod='paypal'}</p>

View File

@@ -0,0 +1,65 @@
{*
* 2007-2019 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2019 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
{extends file='customer/page.tpl'}
{block name='page_title'}
{l s='My payment methods' mod='paypal'}
{/block}
{block name='page_content'}
<!-- Page content -->
{if $payment_methods}
<form action="{$link->getModuleLink('paypal', 'account', ['process' => 'save'])}" method="post">
{foreach from=$payment_methods key=method_key item=payment_method}
{if $method_key == 'card-braintree'}<h3>{l s='Your cards' mod='paypal'}</h3>{/if}
{if $method_key == 'paypal-braintree'}<h3>{l s='Your paypal accounts' mod='paypal'}</h3>{/if}
{foreach from=$payment_method key=key item=method}
<p class="method">
{if $method.name}<b>{$method.name|escape:'htmlall':'UTF-8'} : </b>{/if}
{$method.info|escape:'htmlall':'UTF-8'}
<a href="{$link->getModuleLink('paypal', 'account', ['process' => 'delete', 'method' => {$method.method|escape:'htmlall':'UTF-8'}, 'id_method' => {$method.id_paypal_vaulting|escape:'htmlall':'UTF-8'}])}"><i class="material-icons">delete</i></a>
<br />
{if !$method.name}{l s='Add name' mod='paypal'}{else}{l s='Edit name' mod='paypal'}{/if}
<span class="edit_name" data-method_id="{$method.id_paypal_vaulting|escape:'htmlall':'UTF-8'}"><i class="material-icons">mode_edit</i></span>
<input type="text" value="{$method.name|escape:'htmlall':'UTF-8'}" name="name_{$method.id_paypal_vaulting|escape:'htmlall':'UTF-8'}" class="form-control" style="display: none"/>
</p>
{/foreach}
{/foreach}
<p><button class="btn btn-default" type="submit">{l s='Save' mod='paypal'} <i class="material-icons">save</i></button></p>
</form>
{else}
{l s='You don\'t have saved payment methods from Paypal' mod='paypal'}
{/if}
<script type="text/javascript">
document.addEventListener("DOMContentLoaded", function(){
$(document).on('click', '.edit_name', function(){
var methodId = $(this).data('method_id');
$('input[name=name_'+methodId+']').show();
});
});
</script>
{/block}

View File

@@ -0,0 +1,78 @@
{*
* 2007-2019 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2019 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
<div class="row">
<div class="col-xs-12 col-md-10">
<div class="paypal-braintree-row-payment">
<div class="payment_module paypal-braintree">
<form action="{$braintreeSubmitUrl}" id="paypal-braintree-form" method="post">
{include file="module:paypal/views/templates/front/payment_infos.tpl"}
{if isset($init_error)}
<div class="alert alert-danger">{$init_error}</div>
{else}
<input type="hidden" name="payment_method_nonce" id="paypal_payment_method_nonce"/>
<input type="hidden" name="payment_method_bt" value="{$bt_method|escape:'htmlall':'UTF-8'}"/>
<div id="paypal-button"></div>
<div id="paypal-vault-info"><p>{l s='You have to finish your payment done with your account PayPal:' mod='paypal'}</p></div>
{if isset($active_vaulting) && $active_vaulting}
<div class="save-in-vault">
<input type="checkbox" name="save_account_in_vault" id="save_account_in_vault"/> <label for="save_account_in_vault"> {l s='Memorize my PayPal account' mod='paypal'}</label>
</div>
{/if}
{if isset($active_vaulting) && isset($payment_methods) && !empty($payment_methods)}
<div id="bt-vault-form">
<p><b>{l s='Choose your PayPal account' mod='paypal'}:</b></p>
<select name="pbt_vaulting_token" class="form-control">
<option value="">{l s='Choose your paypal account' mod='paypal'}</option>
{foreach from=$payment_methods key=method_key item=method}
<option value="{$method.token|escape:'htmlall':'UTF-8'}">
{if $method.name}{$method.name|escape:'htmlall':'UTF-8'} - {/if}
{$method.info|escape:'htmlall':'UTF-8'}
</option>
{/foreach}
</select>
</div>
{/if}
{/if}
</form>
<div id="bt-paypal-error-msg" class="alert alert-danger"></div>
</div>
</div>
</div>
</div>
<script>
var paypal_braintree = {
authorization : '{$braintreeToken|escape:'htmlall':'UTF-8'}',
amount : {$braintreeAmount|escape:'htmlall':'UTF-8'},
mode : '{$mode|escape:'htmlall':'UTF-8'}',
currency : '{$currency|escape:'htmlall':'UTF-8'}'
};
paypal_braintree.translations = {
empty_nonce:"{l s='Click paypal button first' mod='paypal'}"
};
</script>

View File

@@ -0,0 +1,57 @@
{*
* 2007-2019 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2019 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
<style>
#popup-ppp-waiting p{
font-size: 16px;
margin: 10px;
line-height: 1.5em;
color: #373a3c;
}
</style>
<div class="row">
<div class="col-xs-12 col-md-10">
<div class="paypal-plus-row-payment">
<div class="payment_module paypal-plus">
{include file="module:paypal/views/templates/front/payment_infos.tpl"}
<div id="ppplus" style="width: 100%;"> </div>
</div>
</div>
</div>
</div>
<script type="text/javascript">
// no escape on url
var ppp_approval_url = '{$approval_url_ppp nofilter}';
var ppp_mode = '{$mode|escape:'htmlall':'UTF-8'}';
var ppp_language_iso_code = '{$ppp_language_iso_code|escape:'htmlall':'UTF-8'}';
var ppp_country_iso_code = '{$ppp_country_iso_code|escape:'htmlall':'UTF-8'}';
// no escape on url
var ajax_patch_url = '{$ajax_patch_url nofilter}';
var waiting_redirection = "{l s='In few seconds you will be redirected to PayPal. Please wait.' mod='paypal'}";
</script>

View File

@@ -0,0 +1,30 @@
{*
* 2007-2019 PrestaShop
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License (AFL 3.0)
* that is bundled with this package in the file LICENSE.txt.
* It is also available through the world-wide-web at this URL:
* http://opensource.org/licenses/afl-3.0.php
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* DISCLAIMER
*
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
* versions in the future. If you wish to customize PrestaShop for your
* needs please refer to http://www.prestashop.com for more information.
*
* @author PrestaShop SA <contact@prestashop.com>
* @copyright 2007-2019 PrestaShop SA
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
* International Registered Trademark & Property of PrestaShop SA
*}
<p id="paypal-es-checked" style="display: none">
{l s='You are about to pay with your PayPal account' mod='paypal'} {$paypal_account_email|escape:'htmlall':'UTF-8'}
</p>
<p id="paypal-ppp-checked" style="display: none">
{l s='You are about to pay with your PayPal account' mod='paypal'} {$paypal_account_email|escape:'htmlall':'UTF-8'}
</p>