Merge branch 'ticket-13010-ModifFraud' into develop

This commit is contained in:
Marion 2017-05-03 15:47:42 +02:00
commit 3235913d20
4 changed files with 15 additions and 14 deletions

View File

@ -236,7 +236,7 @@ class FraudCore {
FROM `'._DB_PREFIX_.'order_history` h FROM `'._DB_PREFIX_.'order_history` h
LEFT JOIN `'._DB_PREFIX_.'orders` o on h.`id_order` = o.`id_order` LEFT JOIN `'._DB_PREFIX_.'orders` o on h.`id_order` = o.`id_order`
WHERE o.`id_customer` = '.(int) $this->customer->id.' WHERE o.`id_customer` = '.(int) $this->customer->id.'
AND h.`id_order_state` IN (15,16,18) AND h.`id_order_state` IN (15,16)
'); ');
$already_suspect = Db::getInstance()->getValue(' $already_suspect = Db::getInstance()->getValue('

View File

@ -2,24 +2,24 @@
<div id="landingpage-connect"> <div id="landingpage-connect">
<form action="{$link->getPageLink('authentication.php', true)}" method="post" id="account-creation_form" class="std"> <form action="{$link->getPageLink('authentication.php', true)}" method="post" id="account-creation_form" class="std">
<fieldset> <fieldset>
<h3>{l s='Registered' mod='landingpage'}</h3> <h3>{l s='Registered' mod='landingpages'}</h3>
<p class="required text"> <p class="required text">
<label for="customer_firstname">{l s='First name' mod='landingpage'}</label> <label for="customer_firstname">{l s='First name' mod='landingpages'}</label>
<input onkeyup="$('#firstname').val(this.value);" type="text" class="text" id="customer_firstname" name="customer_firstname" value="{if isset($smarty.request.customer_firstname)}{$smarty.request.customer_firstname}{/if}" /> <input onkeyup="$('#firstname').val(this.value);" type="text" class="text" id="customer_firstname" name="customer_firstname" value="{if isset($smarty.request.customer_firstname)}{$smarty.request.customer_firstname}{/if}" />
<sup>*</sup> <sup>*</sup>
</p> </p>
<p class="required text"> <p class="required text">
<label for="customer_lastname">{l s='Last name' mod='landingpage'}</label> <label for="customer_lastname">{l s='Last name' mod='landingpages'}</label>
<input onkeyup="$('#lastname').val(this.value);" type="text" class="text" id="customer_lastname" name="customer_lastname" value="{if isset($smarty.request.customer_lastname)}{$smarty.request.customer_lastname}{/if}" /> <input onkeyup="$('#lastname').val(this.value);" type="text" class="text" id="customer_lastname" name="customer_lastname" value="{if isset($smarty.request.customer_lastname)}{$smarty.request.customer_lastname}{/if}" />
<sup>*</sup> <sup>*</sup>
</p> </p>
<p class="required text"> <p class="required text">
<label for="email">{l s='E-mail' mod='landingpage'}</label> <label for="email">{l s='E-mail' mod='landingpages'}</label>
<input type="text" class="text" id="email" name="email" value="{if isset($smarty.request.email)}{$smarty.request.email}{/if}" /> <input type="text" class="text" id="email" name="email" value="{if isset($smarty.request.email)}{$smarty.request.email}{/if}" />
<sup>*</sup> <sup>*</sup>
</p> </p>
<p class="required password"> <p class="required password">
<label for="passwd">{l s='Password' mod='landingpage'}</label> <label for="passwd">{l s='Password' mod='landingpages'}</label>
<input type="password" class="text" name="passwd" id="passwd" /> <input type="password" class="text" name="passwd" id="passwd" />
<sup>*</sup> <sup>*</sup>
{*<span class="form_info">{l s='(5 characters min.)'}</span>*} {*<span class="form_info">{l s='(5 characters min.)'}</span>*}
@ -41,7 +41,7 @@
{if isset($newsletter) && $newsletter} {if isset($newsletter) && $newsletter}
<p class="checkbox" > <p class="checkbox" >
<input type="checkbox" name="newsletter" id="newsletter" value="1" {if isset($smarty.post.newsletter) AND $smarty.post.newsletter == 1} checked="checked"{/if} /> <input type="checkbox" name="newsletter" id="newsletter" value="1" {if isset($smarty.post.newsletter) AND $smarty.post.newsletter == 1} checked="checked"{/if} />
<label for="newsletter">{l s='Sign up for our newsletter' mod='landingpage'}</label> <label for="newsletter">{l s='Sign up for our newsletter' mod='landingpages'}</label>
</p> </p>
{/if} {/if}
</fieldset> </fieldset>
@ -49,8 +49,8 @@
<input type="hidden" name="email_create" value="1" /> <input type="hidden" name="email_create" value="1" />
<input type="hidden" name="is_new_customer" value="1" /> <input type="hidden" name="is_new_customer" value="1" />
<input type="hidden" name="lp" value="{$lp}" /> <input type="hidden" name="lp" value="{$lp}" />
<input type="submit" name="submitAccount" id="submitAccount" value="{l s='Register' mod='landingpage'}" class="exclusive" onclick="if($('#newsletter:checked').length == 0) { alert('{l s='Please accept our terms of use to continue' js=1}'); return false; }" /> <input type="submit" name="submitAccount" id="submitAccount" value="{l s='Register' mod='landingpages'}" class="exclusive" onclick="if($('#newsletter:checked').length == 0) { alert('{l s='Please accept our terms of use to continue' js=1}'); return false; }" />
<span><sup>*</sup>{l s='Required field' mod='landingpage'}</span> <span><sup>*</sup>{l s='Required field' mod='landingpages'}</span>
</p> </p>
</fieldset> </fieldset>
</form> </form>

View File

@ -253,7 +253,7 @@ class LandingPages extends Module {
$on_home = 0; $on_home = 0;
$lp = Tools::getValue('lpes'); $lp = Tools::getValue('lpes');
if(_PS_MOBILE_ || _THEME_NAME_ == 'site_mobile') { if($lp && _PS_MOBILE_ && _THEME_NAME_ == 'site_mobile') {
$link = new Link(); $link = new Link();
Tools::redirectLink($link->getPageLink('authentication.php').'?create_account=1'.(isset($lp)? '&lp='.$lp: '')); Tools::redirectLink($link->getPageLink('authentication.php').'?create_account=1'.(isset($lp)? '&lp='.$lp: ''));
} }
@ -270,7 +270,7 @@ class LandingPages extends Module {
} }
} }
if(!$on_home){ if(!$on_home){
return true; return;
} }
$smarty->assign(array( $smarty->assign(array(

View File

@ -1,7 +1,8 @@
<?php <?php
class CategoryController extends CategoryControllerCore { class CategoryController extends CategoryControllerCore {
public function preProcess() { public function preProcess() {
global $site_version_front; $cookie; global $site_version_front;
global $cookie;
parent::preProcess(); parent::preProcess();
@ -14,12 +15,12 @@ class CategoryController extends CategoryControllerCore {
if(!empty($sale)){ if(!empty($sale)){
$other_sales = $sale->getOthersSales(true, null, null, 'current', false, Configuration::get('PRIVATES_SHOW_PUBLIC'), '`date_start` desc', $site_version_front); $other_sales = $sale->getOthersSales(true, null, null, 'current', false, Configuration::get('PRIVATES_SHOW_PUBLIC'), '`date_start` desc', $site_version_front);
foreach ($other_sales as $key => &$s) { foreach ($other_sales as $key => &$s) {
$s['is_thumb_img_lang'] = false;
$s['is_thumb_img'] = false;
if(file_exists(_PS_ROOT_DIR_.'/img/c/'.(int)$s['id_category'].'_thumb_vp_'.$cookie->id_lang.'.jpg')) { if(file_exists(_PS_ROOT_DIR_.'/img/c/'.(int)$s['id_category'].'_thumb_vp_'.$cookie->id_lang.'.jpg')) {
$s['is_thumb_img_lang'] = true; $s['is_thumb_img_lang'] = true;
} elseif (file_exists(_PS_ROOT_DIR_.'/img/c/'.(int)$s['id_category'].'_thumb_vp.jpg')) { } elseif (file_exists(_PS_ROOT_DIR_.'/img/c/'.(int)$s['id_category'].'_thumb_vp.jpg')) {
$s['is_thumb_img'] = true; $s['is_thumb_img'] = true;
} else {
$s['is_thumb_img'] = false;
} }
} }
} }