diff --git a/.idea/workspace.xml b/.idea/workspace.xml index da9a0c77..fc962f77 100644 --- a/.idea/workspace.xml +++ b/.idea/workspace.xml @@ -11,29 +11,20 @@ - - - - - - - - + - - - + - - + + @@ -44,6 +35,183 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + @@ -56,11 +224,11 @@ - + - + @@ -80,13 +248,13 @@ - + - + @@ -99,7 +267,14 @@ - + + + + + + + + + @@ -193,7 +369,7 @@ - + 1602059851601 @@ -244,7 +420,21 @@ - @@ -273,7 +463,9 @@ - @@ -288,70 +480,70 @@ - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + - + @@ -361,19 +553,19 @@ - + - + - + - + diff --git a/config/xml/default_country_modules_list.xml b/config/xml/default_country_modules_list.xml index 57dc807a..69642c79 100644 --- a/config/xml/default_country_modules_list.xml +++ b/config/xml/default_country_modules_list.xml @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/config/xml/must_have_modules_list.xml b/config/xml/must_have_modules_list.xml index 73137dcb..7a81ee6b 100644 --- a/config/xml/must_have_modules_list.xml +++ b/config/xml/must_have_modules_list.xml @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/modules/mesCategories/mesCategories.php b/modules/mesCategories/mesCategories.php index be2441e0..4540bf4a 100644 --- a/modules/mesCategories/mesCategories.php +++ b/modules/mesCategories/mesCategories.php @@ -139,10 +139,10 @@ class MesCategories extends Module 'input' => array( array( 'type' => 'switch', - 'label' => $this->l('Live mode'), - 'name' => 'MESCATEGORIES_LIVE_MODE', + 'label' => $this->l('Show images'), + 'name' => 'MESCATEGORIES_SHOW_IMAGES', 'is_bool' => true, - 'desc' => $this->l('Use this module in live mode'), + 'desc' => $this->l('Show your categories\' images'), 'values' => array( array( 'id' => 'active_on', @@ -156,19 +156,6 @@ class MesCategories extends Module ) ), ), - array( - 'col' => 3, - 'type' => 'text', - 'prefix' => '', - 'desc' => $this->l('Enter a valid email address'), - 'name' => 'MESCATEGORIES_ACCOUNT_EMAIL', - 'label' => $this->l('Email'), - ), - array( - 'type' => 'password', - 'name' => 'MESCATEGORIES_ACCOUNT_PASSWORD', - 'label' => $this->l('Password'), - ), ), 'submit' => array( 'title' => $this->l('Save'), @@ -183,9 +170,7 @@ class MesCategories extends Module protected function getConfigFormValues() { return array( - 'MESCATEGORIES_LIVE_MODE' => Configuration::get('MESCATEGORIES_LIVE_MODE', true), - 'MESCATEGORIES_ACCOUNT_EMAIL' => Configuration::get('MESCATEGORIES_ACCOUNT_EMAIL', 'contact@prestashop.com'), - 'MESCATEGORIES_ACCOUNT_PASSWORD' => Configuration::get('MESCATEGORIES_ACCOUNT_PASSWORD', null), + 'MESCATEGORIES_SHOW_IMAGES' => Configuration::get('MESCATEGORIES_SHOW_IMAGES', true), ); } @@ -251,9 +236,11 @@ class MesCategories extends Module } } $this->smarty->assign(array( - 'categories' => $my_array + 'categories' => $my_array, + 'SHOW_IMAGES' => Configuration::get('MESCATEGORIES_SHOW_IMAGES', true), )); + return $this->display(__FILE__, 'displayHome.tpl'); } diff --git a/modules/mesCategories/translations/fr.php b/modules/mesCategories/translations/fr.php new file mode 100644 index 00000000..d365b061 --- /dev/null +++ b/modules/mesCategories/translations/fr.php @@ -0,0 +1,15 @@ +mescategories_464e37a930f5702c14f862ab9497860d'] = 'mesCategories'; +$_MODULE['<{mescategories}prestashop>mescategories_9a73af1cac63425e4f4dc393db798d1a'] = 'Permet d\'afficher les catégories (et sous-catégories) sous forme de blocs, sur la page d\'accueil '; +$_MODULE['<{mescategories}prestashop>mescategories_f4f70727dc34561dfde1a3c529b6205c'] = 'Réglages'; +$_MODULE['<{mescategories}prestashop>mescategories_4861c3d5c88af6037e2bfb0d5c309ce1'] = 'Afficher les images'; +$_MODULE['<{mescategories}prestashop>mescategories_833a6f0f9fb2be7fe8082b41594a8043'] = 'Affiche les images de vos catégories sur la page au lieu de leur titre simplement'; +$_MODULE['<{mescategories}prestashop>mescategories_00d23a76e43b46dae9ec7aa9dcbebb32'] = 'Oui'; +$_MODULE['<{mescategories}prestashop>mescategories_b9f5c797ebbf55adccdd8539a65a0241'] = 'Non'; +$_MODULE['<{mescategories}prestashop>mescategories_c9cc8cce247e49bae79f15173ce97354'] = 'Enregistrer'; +$_MODULE['<{mescategories}prestashop>configure_464e37a930f5702c14f862ab9497860d'] = 'Module d\'affichage de vos catégories'; +$_MODULE['<{mescategories}prestashop>configure_0b79795d3efc95b9976c7c5b933afce2'] = 'Bienvenue sur le module d\'affichage de vos catégories !'; +$_MODULE['<{mescategories}prestashop>configure_261addf78c7b2c961032b3dd08ba0b1f'] = 'Ce module peut être inséré sur votre page d\'accueil (par exemple) et y faire apparaitre la liste de vos catégories (sous forme d\'images) ainsi que toutes les sous-catégories contenues dans chacune d\'elles.'; diff --git a/modules/mesCategories/views/css/front.css b/modules/mesCategories/views/css/front.css index 9e39d86f..acdd41b4 100644 --- a/modules/mesCategories/views/css/front.css +++ b/modules/mesCategories/views/css/front.css @@ -17,10 +17,6 @@ align-items: center; } -.category-image { - -} - /* Catégorie (image + titre) */ .figure img { width: 150px; @@ -34,20 +30,30 @@ color: black; } - -.subcategories-list { - margin-left: -145px; - line-height: 1.7rem; - z-index: 3; +#mesCategories > li > div > div > h2 { + width: 150px; + margin-bottom:150px; text-align: center; } -.subcategories-list a { - font-size: 0.95rem; - font-family: "Raleway", sans-serif; - color: black; - width: 100%; + + + +.subcategories-list { + margin-left: -150px; + line-height: 1.7rem; + z-index: 3; + text-align: left; + width: fit-content; + width:-moz-fit-content; } -.subcategories-list a:hover { - font-weight: bold; +.subcategories-list > a { + font-size: 0.95rem; + /*font-family: "Raleway", sans-serif;*/ + color: black; + font-weight: normal; +} +.subcategories-list > a:hover { + background-color: rgba(177,194,90,1); + color: white; } diff --git a/modules/mesCategories/views/templates/admin/configure.tpl b/modules/mesCategories/views/templates/admin/configure.tpl index 97a4ffd3..63a48b94 100644 --- a/modules/mesCategories/views/templates/admin/configure.tpl +++ b/modules/mesCategories/views/templates/admin/configure.tpl @@ -26,23 +26,7 @@

{l s='mesCategories' mod='mesCategories'}

- {l s='Here is my new generic module!' mod='mesCategories'}
- {l s='Thanks to PrestaShop, now I have a great module.' mod='mesCategories'}
- {l s='I can configure it using the following configuration form.' mod='mesCategories'} -

-
-

- {l s='This module will boost your sales!' mod='mesCategories'} -

-
- -
-

{l s='Documentation' mod='mesCategories'}

-

- » {l s='You can get a PDF documentation to configure this module' mod='mesCategories'} : -

+ {l s='Introduction' mod='mesCategories'}

+ {l s='Purpose' mod='mesCategories'}

diff --git a/modules/mesCategories/views/templates/hook/displayHome.tpl b/modules/mesCategories/views/templates/hook/displayHome.tpl index 2d0d770c..249ac771 100644 --- a/modules/mesCategories/views/templates/hook/displayHome.tpl +++ b/modules/mesCategories/views/templates/hook/displayHome.tpl @@ -5,10 +5,14 @@
  • + {if $SHOW_IMAGES}
    {$category.category_name}
    {$category.category_name|escape:'html':'UTF-8'}
    + {else} +

    {$category.category_name}

    + {/if}
    diff --git a/themes/classic-child/assets/css/custom.css b/themes/classic-child/assets/css/custom.css index 0fdf6f20..64878347 100644 --- a/themes/classic-child/assets/css/custom.css +++ b/themes/classic-child/assets/css/custom.css @@ -57,6 +57,10 @@ body { -webkit-font-smoothing: antialiased; } +a:hover { + color: rgba(177,194,90,1); +} + .breadcrumb { margin-top: 10px; text-align: center; @@ -109,6 +113,9 @@ body { .footer-container .block-contact, .footer-container li a, #footer > div.footer-container p { color: white; } +.footer-container li a:hover { + color: gold; +} .copyright { color: white; }