From ff867b7d25b9e6b001e38092d1397fae6f9becad Mon Sep 17 00:00:00 2001 From: mDeflotte Date: Tue, 6 Mar 2012 14:49:13 +0000 Subject: [PATCH] // blocklayered: fix bug with a bad information sentence --- modules/blocklayered/blocklayered.php | 15 +++++++++++---- modules/blocklayered/fr.php | 2 ++ 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/modules/blocklayered/blocklayered.php b/modules/blocklayered/blocklayered.php index 44625b809..56c59f2bd 100644 --- a/modules/blocklayered/blocklayered.php +++ b/modules/blocklayered/blocklayered.php @@ -1503,12 +1503,12 @@ class BlockLayered extends Module href="'.$domain.__PS_BASE_URI__.'modules/blocklayered/blocklayered-price-indexer.php'.'?token='.substr(Tools::encrypt('blocklayered/index'), 0, 10).'&full=1">'. $this->l('Re-build entire price index').'
- '. $this->l('Build attribute index').'
- '. $this->l('Build url index').' @@ -1546,6 +1546,7 @@ class BlockLayered extends Module } this.restartAllowed = false; + var type = $(this).attr(\'rel\'); $.ajax({ url: this.href+\'&ajax=1\', @@ -1558,7 +1559,10 @@ class BlockLayered extends Module this.restartAllowed = true; $(\'#indexing-warning\').hide(); $(this).html(this.legend); - $(\'#ajax-message-ok span\').html(\''.addslashes($this->l('Url indexation finished')).'\'); + if (type == \'price\') + $(\'#ajax-message-ok span\').html(\''.addslashes($this->l('Url indexation finished')).'\'); + else + $(\'#ajax-message-ok span\').html(\''.addslashes($this->l('Attribute indexation finished')).'\'); $(\'#ajax-message-ok\').show(); return; }, @@ -1566,7 +1570,10 @@ class BlockLayered extends Module { this.restartAllowed = true; $(\'#indexing-warning\').hide(); - $(\'#ajax-message-ko span\').html(\''.addslashes($this->l('Url indexation failed')).'\'); + if (type == \'price\') + $(\'#ajax-message-ko span\').html(\''.addslashes($this->l('Url indexation failed')).'\'); + else + $(\'#ajax-message-ko span\').html(\''.addslashes($this->l('Attribute indexation failed')).'\'); $(\'#ajax-message-ko\').show(); $(this).html(this.legend); diff --git a/modules/blocklayered/fr.php b/modules/blocklayered/fr.php index 1e99b6595..488c72213 100644 --- a/modules/blocklayered/fr.php +++ b/modules/blocklayered/fr.php @@ -34,7 +34,9 @@ $_MODULE['<{blocklayered}prestashop>blocklayered_5a12793d564ff29c49e4ab3f542dd72 $_MODULE['<{blocklayered}prestashop>blocklayered_16349835364cf839e6670b0de7da6362'] = 'Il est recommandé de procéder à la réindexation de nuit.'; $_MODULE['<{blocklayered}prestashop>blocklayered_56fc8142961f1f3e9f9ec0c178881b69'] = '(en cours)'; $_MODULE['<{blocklayered}prestashop>blocklayered_e1e43ed7e0922095a801341dca2f1822'] = 'Indexation des URL terminée'; +$_MODULE['<{blocklayered}prestashop>blocklayered_8bf466a25752f2552df8dc8b04fc10ba'] = 'Indexation des attributs terminée'; $_MODULE['<{blocklayered}prestashop>blocklayered_1c1783101d972ba096fff9756378b0e1'] = 'L\'indexation des URL a échoué'; +$_MODULE['<{blocklayered}prestashop>blocklayered_399e951fec4faaeab09333f40bf6d80c'] = 'L\'Indexation des attributs a échoué'; $_MODULE['<{blocklayered}prestashop>blocklayered_e2dd8f544131eaf47a4f722ace7f876b'] = 'Indexation des prix terminée'; $_MODULE['<{blocklayered}prestashop>blocklayered_7cf7d150dd287df0a8e17eeb4cf2161d'] = '(en cours, %s des prix de produits à indexer)'; $_MODULE['<{blocklayered}prestashop>blocklayered_ceda32b8540dee4f1222cd482a513db8'] = 'L\'indexation des prix a échoué';