diff --git a/modules/ant_configurations/AdminAntConfigurations.php b/modules/ant_configurations/AdminAntConfigurations.php index 812cc5be..bd911c75 100644 --- a/modules/ant_configurations/AdminAntConfigurations.php +++ b/modules/ant_configurations/AdminAntConfigurations.php @@ -67,7 +67,7 @@ class AdminAntConfigurations extends AdminTab '); HelperFormBootstrap::displaySuccess($this->l('Produits associés aux ventes depuis le produit #').$min_id_product); } else { - HelperFormBootstrap::displayErrors($this->l('Pas de produit ajouté depuis 10 jours')); + HelperFormBootstrap::displayWarning($this->l('Pas de produit ajouté depuis 10 jours')); } } } elseif(Tools::isSubmit('submitCategorySaleCache')) { @@ -171,6 +171,8 @@ class AdminAntConfigurations extends AdminTab } else { HelperFormBootstrap::displayWarning($this->l('Aucun résultat trouvé')); } + } elseif (Tools::isSubmit('submitExportLoyalty')){ + HelperFormBootstrap::displayWarning($this->l('Outils non disponible pour le moment !')); } } @@ -221,6 +223,14 @@ class AdminAntConfigurations extends AdminTab .control-label { padding: 0; } + .heading-title{ + margin: 5px 0 20px; + display: block; + text-overflow: ellipsis; + overflow: hidden; + white-space: nowrap; + color: #504d8b; + } '; $id_sale_options = array(); @@ -247,204 +257,238 @@ class AdminAntConfigurations extends AdminTab $helperForm = new HelperFormBootstrap(); $helperForm->_select2 = true; $helperForm->_inputMask = true; + $form .= $helperForm->renderStyle(); - $helperForm->_forms = array( - array( - 'action' => $base_link, - 'title' => $this->l('Outils - Suivi bons réduction'), - 'icon' => ' ', - 'class' => 'form-horizontal', - 'class_div' => 'col-md-4', - // 'information' => 'Petit outils d\'exports utiles pour les suivis', - 'sections' => array( - array( - 'inputs' => array( - array( - 'type' => 'simpleDate', - 'period' => true, - 'class-from' => 'col-md-6', - 'class-to' => 'col-md-6', - // 'label' => 'De :', - // 'label-to' => 'A :', - 'id' => 'date_from', - 'id-to' => 'date_to', - 'name' => 'date_from', - 'name-to' => 'date_to', - 'before' => '', - 'before-to' => '', + $form .= ' +
+
+
+

'.$this->l('Outils utiles').'

+ + +
+
+
+

'.$this->l('Association Catégories/Ventes').'

+
+
+
'; + $input = $input = array( + 'type' => 'select2', + 'label' => $this->l('Vente à associer :'), + 'label-class' => 'col-md-12', + 'input-class' => 'col-md-12', + 'select-class' => 'col-md-12', + 'name' => 'id_sale', + 'options' => $id_sale_options, + ); + $form .= $helperForm->generateInput($input). + '
+
+
+
+ +
+
+
+
+ +
+
+

'.$this->l('Association Produit/Ventes').'

+
+
+
+

'.$this->l('Permet d\'associer les produits aux ventes lorsque le cron n\'est pas encore passé.').'

+

'.$this->l('Passage du cron toutes les 3h : 6h12, 9H12, 12h12 ...').'

+
+
+
+
+ +
+
+
+
+ +
+
+

'.$this->l('Suivi Code Promo').'

+
+
+
+

'.$this->l('Export des codes promos générés et de leur utilisations.').'

+

'.$this->l('Préférer de courtes périodes (se base sur la date de génération du bon).').'

'; + $input = array( + 'type' => 'simpleDate', + 'period' => true, + 'class-from' => 'col-md-6', + 'class-to' => 'col-md-6', + 'label' => 'De :', + 'label-to' => 'A :', + 'id' => 'date_from', + 'id-to' => 'date_to', + 'name' => 'date_from', + 'name-to' => 'date_to', + 'before' => '', + 'before-to' => '', + ); + $form .= $helperForm->generateInput($input). + '
+
+
+
+ +
+
+
+
+ +
+
+

'.$this->l('Suivi Crédit Fidélité').'

+
+
+
+

'.$this->l('Choisir de préférence un plage d\'1 mois').'

'; + $input = array( + 'type' => 'simpleDate', + 'period' => true, + 'class-from' => 'col-md-6', + 'class-to' => 'col-md-6', + 'label' => 'De :', + 'label-to' => 'A :', + 'id' => 'date_from_2', + 'id-to' => 'date_to_2', + 'name' => 'date_from', + 'name-to' => 'date_to', + 'before' => '', + 'before-to' => '', + ); + $form .= $helperForm->generateInput($input). + '
+
+
+
+ +
+
+
+
+
+
+
+
'; + + + if($cookie->id_employee == 1) { + $nb_credits = $this->getNbOrderToUpdate(); + $helperForm->_forms = array( + array( + 'action' => $base_link, + 'title' => $this->l('Section Antadis'), + 'class' => 'form-horizontal', + 'class_div' => 'col-md-12', + 'sections' => array( + array( + 'class' => 'col-md-6', + 'title' => $this->l('Actions diverses'), + 'inputs' => array( + array( + 'type' => 'submit', + 'class' => 'btn-default', + 'label-class' => 'col-md-6', + 'input-class' => 'col-md-4', + 'name' => 'submitUpdateLoyaltyOrders', + 'label' => $this->l('Credit fidélité ').($nb_credits>0?'('.$nb_credits.')':'').' : ', + 'value' => $this->l('Mettre à jour'), + ), + array( + 'type' => 'simpleText', + 'name' => 'carrier_dropshipping', + 'label-class' => 'col-md-6', + 'input-class' => 'col-md-4', + 'label' => $this->l('Transporteur Dropshipping :'), + 'default' => Configuration::get('ANT_CARRIER_DROP') + ), + array( + 'type' => 'simpleText', + 'name' => 'carrier_domicile', + 'label-class' => 'col-md-6', + 'input-class' => 'col-md-4', + 'label' => $this->l('Transporteur domicile :'), + 'default' => Configuration::get('ANT_CARRIER_DOM') + ), + array( + 'type' => 'simpleText', + 'name' => 'carriers_socol', + 'label-class' => 'col-md-6', + 'input-class' => 'col-md-4', + 'label' => $this->l('Transporteur socol :'), + 'default' => Configuration::get('ANT_CARRIERS_SOCOL') + ), + array( + 'type' => 'simpleText', + 'name' => 'carriers_ooh', + 'label-class' => 'col-md-6', + 'input-class' => 'col-md-4', + 'label' => $this->l('Transporteur OOH :'), + 'default' => Configuration::get('ANT_CARRIERS_OOH') + ), ), ), - 'actions' => array( - array( - 'type' => 'submit', - 'class' => 'btn-primary', - 'name' => 'submitExportDiscount', - 'value' => $this->l('Exporter Suivi Code promo'), + array( + 'class' => 'col-md-6', + 'title' => $this->l('Mettre à jour PS Cache'), + 'inputs' => array( + array( + 'label' => $this->l('PS Cache : '), + 'type' => 'select2', + 'class-select' => '', + 'name' => 'id_category', + 'options' => $id_category_options, + ), ), - ), - 'actions-class' => 'text-right', - ), - ), - ), - ); - $helperForm->_forms[] = array( - 'action' => $base_link, - 'title' => $this->l('Association Produits'), - 'icon' => ' ', - 'class' => 'form-horizontal', - 'class_div' => 'col-md-3', - 'information' => 'Permet d\'associer les produits aux ventes lorsque le cron n\'est pas encore passé', - 'sections' => array( - array( - 'inputs' => array( - array( - 'type' => 'submit', - 'class' => 'btn-primary', - 'name' => 'submitProductSaleCache', - 'value' => $this->l('Mettre à jour l\'association'), - ), - ), - ), - ), - ); - $helperForm->_forms[] = array( - 'action' => $base_link, - 'title' => $this->l('Association categories/ventes'), - 'icon' => ' ', - 'class' => 'form-horizontal', - 'class_div' => 'col-md-5', - 'sections' => array( - array( - 'inputs' => array( - array( - 'type' => 'select2', - 'class-select' => '', - 'name' => 'id_sale', - 'options' => $id_sale_options, + 'actions' => array( + array( + 'type' => 'submit', + 'class' => 'btn-default', + 'name' => 'submitShowProductCacheSale', + 'value' => $this->l('Voir'), + ), + array( + 'type' => 'submit', + 'class' => 'btn-primary', + 'name' => 'submitUpdateCacheSale', + 'value' => $this->l('Ré-Associer'), + ), + ), + 'actions-class' => 'text-right', ), ), 'actions' => array( array( 'type' => 'submit', 'class' => 'btn-primary', - 'name' => 'submitCategorySaleCache', - 'value' => $this->l('Associer') + 'name' => 'submitUpdateConfigurations', + 'value' => $this->l('Mettre à jour les configurations') ) ), - 'actions-class' => 'text-right', - ), - ), - ); - - if($cookie->id_employee == 1) { - $nb_credits = $this->getNbOrderToUpdate(); - $helperForm->_forms[] = array( - 'action' => $base_link, - 'title' => $this->l('Section Antadis'), - 'class' => 'form-horizontal', - 'class_div' => 'col-md-12', - 'sections' => array( - array( - 'class' => 'col-md-6', - 'title' => $this->l('Actions diverses'), - 'inputs' => array( - array( - 'type' => 'submit', - 'class' => 'btn-default', - 'label-class' => 'col-md-6', - 'input-class' => 'col-md-4', - 'name' => 'submitUpdateLoyaltyOrders', - 'label' => $this->l('Credit fidélité ').($nb_credits>0?'('.$nb_credits.')':'').' : ', - 'value' => $this->l('Mettre à jour'), - ), - array( - 'type' => 'simpleText', - 'name' => 'carrier_dropshipping', - 'label-class' => 'col-md-6', - 'input-class' => 'col-md-4', - 'label' => $this->l('Transporteur Dropshipping :'), - 'default' => Configuration::get('ANT_CARRIER_DROP') - ), - array( - 'type' => 'simpleText', - 'name' => 'carrier_domicile', - 'label-class' => 'col-md-6', - 'input-class' => 'col-md-4', - 'label' => $this->l('Transporteur domicile :'), - 'default' => Configuration::get('ANT_CARRIER_DOM') - ), - array( - 'type' => 'simpleText', - 'name' => 'carriers_socol', - 'label-class' => 'col-md-6', - 'input-class' => 'col-md-4', - 'label' => $this->l('Transporteur socol :'), - 'default' => Configuration::get('ANT_CARRIERS_SOCOL') - ), - array( - 'type' => 'simpleText', - 'name' => 'carriers_mr', - 'label-class' => 'col-md-6', - 'input-class' => 'col-md-4', - 'label' => $this->l('Transporteur MR :'), - 'default' => Configuration::get('ANT_CARRIERS_MR') - ), - array( - 'type' => 'simpleText', - 'name' => 'carriers_ooh', - 'label-class' => 'col-md-6', - 'input-class' => 'col-md-4', - 'label' => $this->l('Transporteur OOH :'), - 'default' => Configuration::get('ANT_CARRIERS_OOH') - ), - array( - 'type' => 'simpleText', - 'name' => 'carriers_special', - 'label-class' => 'col-md-6', - 'input-class' => 'col-md-4', - 'label' => $this->l('Transporteur speciaux :'), - 'default' => Configuration::get('ANT_CARRIERS_SPECIAL') - ), - ), - ), - array( - 'class' => 'col-md-6', - 'title' => $this->l('Mettre à jour PS Cache'), - 'inputs' => array( - array( - 'label' => $this->l('PS Cache : '), - 'type' => 'select2', - 'class-select' => '', - 'name' => 'id_category', - 'options' => $id_category_options, - ), - ), - 'actions' => array( - array( - 'type' => 'submit', - 'class' => 'btn-default', - 'name' => 'submitShowProductCacheSale', - 'value' => $this->l('Voir'), - ), - array( - 'type' => 'submit', - 'class' => 'btn-primary', - 'name' => 'submitUpdateCacheSale', - 'value' => $this->l('Ré-Associer'), - ), - ), - 'actions-class' => 'text-right', - ), - ), - 'actions' => array( - array( - 'type' => 'submit', - 'class' => 'btn-primary', - 'name' => 'submitUpdateConfigurations', - 'value' => $this->l('Mettre à jour les configurations') - ) - ), - 'actions-class' => 'text-center', + 'actions-class' => 'text-center', + ) ); } $helperForm->_js .= ' @@ -452,9 +496,12 @@ class AdminAntConfigurations extends AdminTab $(document).ready(function() { $("#date_from").inputmask("9999-99-99"); $("#date_to").inputmask("9999-99-99"); + $("#date_from_2").inputmask("9999-99-99"); + $("#date_to_2").inputmask("9999-99-99"); + + $("#id_sale").parent().children(".select2-container").css(\'width\',\'449px\'); }); '; - $form .= $helperForm->renderStyle(); $form .= '
'.$helperForm->renderForm(false, NULL, NULL, true).'
'; $form .= $helperForm->renderScript(); diff --git a/modules/ant_configurations/cron_discount.php b/modules/ant_configurations/cron_discount.php index de10b74e..a595bf58 100644 --- a/modules/ant_configurations/cron_discount.php +++ b/modules/ant_configurations/cron_discount.php @@ -70,7 +70,7 @@ function generateDiscount($id_customer) $discount->behavior_not_exhausted = 1; $discount->cumulable = 0; $discount->cumulable_reduction = 1; - $discount->minimal = 10; + $discount->minimal = 50; $discount->include_tax = 1; $discount->cart_display = 0; $discount->active = 1; @@ -99,7 +99,7 @@ function generateDiscount($id_customer) } $discount->id_currency = 1; - $discount->value = 50; + $discount->value = 10; if($discount->add(true, false, array(1)) ) { return $discount; diff --git a/modules/bulkupdate/AdminBulkUpdate.php b/modules/bulkupdate/AdminBulkUpdate.php index 1ff57395..058a73d7 100644 --- a/modules/bulkupdate/AdminBulkUpdate.php +++ b/modules/bulkupdate/AdminBulkUpdate.php @@ -40,7 +40,8 @@ class AdminBulkUpdate extends AdminTab { INSERT INTO `'._DB_PREFIX_.'product_customs` VALUES ( '.(int) $line[0].', "'.pSQL($line[1]).'", - "'.pSQL($line[2]).'" + "'.pSQL($line[2]).'", + 0 ) '); } diff --git a/themes/site/css/style.css b/themes/site/css/style.css index b55aaa34..6eb45021 100755 --- a/themes/site/css/style.css +++ b/themes/site/css/style.css @@ -3052,7 +3052,7 @@ div.addresses ul.address li.address_title { top: -37px; width: 257px; display: none; - z-index: 2; + z-index: 3; } #product .info_coeur p{ color: #666666; @@ -7231,6 +7231,30 @@ table#carrierTable tbody td { z-index: 2; border-top: 0; } +#category .info_random { + background: #fff; + height: auto!important; + padding: 10px!important; + left: 300px; + width: 150px; + position: absolute; + top: 115px; + display: none; + z-index: 3; + border-radius: 4px; + -webkit-filter:drop-shadow(rgba(0, 0, 0, 0.3) 0 2px 10px); + filter: drop-shadow(rgba(0, 0, 0, 0.3) 0 2px 10px); +} +#category .info_random:before{ + content: ''; + left: -10px; + top: 20px; + position: absolute; + border-top: 15px solid transparent; + border-bottom: 15px solid transparent; + border-right: 15px solid #fff; +} + #product .random{ left: 370px; position: absolute; @@ -7241,13 +7265,25 @@ table#carrierTable tbody td { height: 50px; } #product .info_random { - background: url(../img/bg_coup_coeur.png) no-repeat; - height: 143px; - left: 410px; - padding: 30px 45px; + background: #fff; + height: auto; + padding: 10px; + left: 412px; + width: 150px; position: absolute; - top: -10px; - width: 257px; + top: 45px; display: none; - z-index: 2; + z-index: 3; + border-radius: 4px; + -webkit-filter:drop-shadow(rgba(0, 0, 0, 0.3) 0 2px 10px); + filter: drop-shadow(rgba(0, 0, 0, 0.3) 0 2px 10px); +} +#product .info_random:before{ + content: ''; + left: -10px; + top: 20px; + position: absolute; + border-top: 15px solid transparent; + border-bottom: 15px solid transparent; + border-right: 15px solid #fff; } diff --git a/themes/site/modules/categoryscroll/header.tpl b/themes/site/modules/categoryscroll/header.tpl index 80a6b350..4a994f21 100755 --- a/themes/site/modules/categoryscroll/header.tpl +++ b/themes/site/modules/categoryscroll/header.tpl @@ -5,6 +5,14 @@ $(document).ready(function() { var endreached = false; var filter = new Array(); + $('.random').each(function(){ + $(this).hover(function() { + $(this).parent().children('.info_random').stop(true, true).fadeIn(); + }, function(){ + $(this).parent().children('.info_random').stop(true, true).fadeOut(); + }); + }); + $(window).scroll(function() { if(!endreached && !error) { if((($(window).scrollTop() + $(window).height()) + 550) >= $(document).height()) { @@ -26,7 +34,7 @@ $(document).ready(function() { animation: "slide", controlNav: false, slideshow: false, - itemWidth: 300, + itemWidth: 300, pauseOnHover : false, mousewheel: false, }); @@ -48,14 +56,14 @@ $(document).ready(function() { } } }); - + $(".block_filter :checkbox").change(function(){ if(loading == false) { filter.length = 0; $(".block_filter input:checkbox[name=size]:checked").each(function(){ filter.push($(this).val()); }); - $("#product_list").val(0); + $("#product_list").val(0); loading = true; $.get("{/literal}{$base_dir_ssl}{literal}modules/categoryscroll/ajax.php?c={/literal}{$id_category}{literal}&init=1&f="+ filter +"&p=1", function(loaded) { @@ -69,7 +77,7 @@ $(document).ready(function() { animation: "slide", controlNav: false, slideshow: false, - itemWidth: 300, + itemWidth: 300, pauseOnHover : false, mousewheel: false, }); @@ -87,7 +95,7 @@ $(document).ready(function() { loading = false; $("#product_list").trigger('updated'); }); - } + } // $.scrollTo('#product_list', 400); }); diff --git a/themes/site/modules/categoryscroll/product-list.tpl b/themes/site/modules/categoryscroll/product-list.tpl index 721c4307..a250fd39 100755 --- a/themes/site/modules/categoryscroll/product-list.tpl +++ b/themes/site/modules/categoryscroll/product-list.tpl @@ -10,6 +10,9 @@
{l s='Random'}
+
+

{l s='Bébé Boutik vous propose ce produit de façon aléatoire !'}

+
{/if}

{if isset($product.new) && $product.new == 1}{l s='New' mod='categoryscroll'}{/if}{$product.name|truncate:64:'...'|escape:'htmlall':'UTF-8'}

{if (!$PS_CATALOG_MODE AND ((isset($product.show_price) && $product.show_price) || (isset($product.available_for_order) && $product.available_for_order)))} diff --git a/themes/site/product-list.tpl b/themes/site/product-list.tpl index e7683594..931b178f 100755 --- a/themes/site/product-list.tpl +++ b/themes/site/product-list.tpl @@ -39,6 +39,9 @@
{l s='Random'}
+
+

{l s='Bébé Boutik vous propose ce produit de façon aléatoire !'}

+
{/if}

{if isset($product.new) && $product.new == 1}{l s='New'}{/if}{$product.name|truncate:64:'...'|escape:'htmlall':'UTF-8'}

{if (!$PS_CATALOG_MODE AND ((isset($product.show_price) && $product.show_price) || (isset($product.av3ailable_for_order) && $product.available_for_order)))}