From 0141bc28c7c2b8715de1cff7647df260f8d8fb6c Mon Sep 17 00:00:00 2001 From: vChabot Date: Wed, 11 Jan 2012 13:45:03 +0000 Subject: [PATCH] [-] FO : BugFix : #PSTEST-190 : adding a link to create an address in the "my-account" page, if a customer hasn't filled any addresses --- controllers/front/MyAccountController.php | 2 ++ themes/default/lang/fr.php | 40 +++++++++-------------- themes/default/my-account.tpl | 3 ++ 3 files changed, 21 insertions(+), 24 deletions(-) diff --git a/controllers/front/MyAccountController.php b/controllers/front/MyAccountController.php index cfb21cbd4..d16e5c0d7 100644 --- a/controllers/front/MyAccountController.php +++ b/controllers/front/MyAccountController.php @@ -44,7 +44,9 @@ class MyAccountControllerCore extends FrontController */ public function initContent() { + $has_address = $this->context->customer->getAddresses($this->context->language->id); $this->context->smarty->assign(array( + 'has_customer_an_address' => empty($has_address), 'voucherAllowed' => (int)(Configuration::get('PS_VOUCHERS')), 'returnAllowed' => (int)(Configuration::get('PS_ORDER_RETURN')) )); diff --git a/themes/default/lang/fr.php b/themes/default/lang/fr.php index bf0042191..115f3dfae 100644 --- a/themes/default/lang/fr.php +++ b/themes/default/lang/fr.php @@ -56,10 +56,12 @@ $_LANG['authentication_8b5dd64ab8d0b8158906796b53a200e2'] = 'Adresse e-mail'; $_LANG['authentication_5f0258bf719ab828e20edf91e4fb24a7'] = 'Déjà enregistré ?'; $_LANG['authentication_dc647eb65e6711e155375218212b3964'] = 'Mot de passe'; $_LANG['authentication_01a569ddc6cf67ddec2a683f0a5f5956'] = 'Mot de passe oublié ?'; -$_LANG['authentication_766d4aaf3e045538be23f9a9e17a1593'] = 'Commande express'; +$_LANG['authentication_6335a00a08fde0fbb8f6d6630cdadd92'] = 'Vos informations personnelles'; $_LANG['authentication_b78a3223503896721cca1303f776159b'] = 'Civilité'; $_LANG['authentication_20db0bfeecd8fe60533206a2b5e9891a'] = 'Prénom'; $_LANG['authentication_8d3f5eff9c40ee315d452392bed5309b'] = 'Nom'; +$_LANG['authentication_1e884e3078d9978e216a027ecd57fb34'] = 'E-mail'; +$_LANG['authentication_bf2957630c4209f61a388a08c2154915'] = '(5 caractères min.)'; $_LANG['authentication_10803b83a68db8f7e7a33e3b41e184d0'] = 'Date de naissance'; $_LANG['authentication_86f5978d9b80124f509bdb71786e929e'] = 'Janvier'; $_LANG['authentication_659e59f062c75f81259d22786d6c44aa'] = 'Février'; @@ -75,38 +77,32 @@ $_LANG['authentication_7e823b37564da492ca1629b4732289a8'] = 'Novembre'; $_LANG['authentication_82331503174acbae012b2004f6431fa5'] = 'Décembre'; $_LANG['authentication_6f6162d3a052bb330e9c60285c74c6c9'] = 'S\'inscrire à la newsletter'; $_LANG['authentication_ac135c86084a47630c9eadb4edd5ef75'] = 'Recevez les offres spéciales de nos partenaires'; -$_LANG['authentication_af0f5bdc5be121b9307687aeeae38c17'] = 'Adresse de livraison'; -$_LANG['authentication_1c76cbfe21c6f44c1d1e59d54f3e4420'] = 'Société'; -$_LANG['authentication_7cb32e708d6b961d476baced73d362bb'] = 'Numéro TVA'; -$_LANG['authentication_dd7bf230fde8d4836917806aff6a6b27'] = 'Adresse'; -$_LANG['authentication_d30f507473129e70c4b962ceccf175cf'] = 'Code postal'; -$_LANG['authentication_57d056ed0984166336b7879c2af3657f'] = 'Ville'; -$_LANG['authentication_59716c97497eb9694541f7c3d37b1a4d'] = 'Pays'; -$_LANG['authentication_46a2a41cc6e552044816a2d04634545d'] = 'Etat'; -$_LANG['authentication_bcc254b55c4a1babdf1dcb82c207506b'] = 'Téléphone'; -$_LANG['authentication_ae7bdef7fe2bbbbf02c11e92c5fceb40'] = 'Mon adresse'; -$_LANG['authentication_c773457e85b990c10f8823eacb21346c'] = 'Identification fiscale'; -$_LANG['authentication_b60bb13a87fe3ae5463aeb0980a5a8a1'] = 'Numéro d\'identification'; -$_LANG['authentication_ea318a4ad37f0c2d2c368e6c958ed551'] = 'DNI / NIF / NIE'; -$_LANG['authentication_19f823c6453c2b1ffd09cb715214813d'] = 'Champs requis'; -$_LANG['authentication_a0bfb8e59e6c13fc8d990781f77694fe'] = 'Continuer'; -$_LANG['authentication_6335a00a08fde0fbb8f6d6630cdadd92'] = 'Vos informations personnelles'; -$_LANG['authentication_1e884e3078d9978e216a027ecd57fb34'] = 'E-mail'; -$_LANG['authentication_bf2957630c4209f61a388a08c2154915'] = '(5 caractères min.)'; $_LANG['authentication_7c4afd8114c2cd8dd000bf3601057b0f'] = 'Vos informations société'; +$_LANG['authentication_1c76cbfe21c6f44c1d1e59d54f3e4420'] = 'Société'; $_LANG['authentication_4f68183551e5dbd7c341347ffe308682'] = 'SIRET'; $_LANG['authentication_85fb93a8ee9440499692da24a1621769'] = 'APE'; $_LANG['authentication_15bbb9d0bbf25e8d2978de1168c749dc'] = 'Site web'; $_LANG['authentication_455175f3f5be6306247babb349c0515a'] = 'Votre adresse'; +$_LANG['authentication_7cb32e708d6b961d476baced73d362bb'] = 'Numéro TVA'; +$_LANG['authentication_dd7bf230fde8d4836917806aff6a6b27'] = 'Adresse'; $_LANG['authentication_6a1fdb6502fefe71937a62c4d03a810e'] = 'Numéro dans la rue, boîte postale, nom de la société'; $_LANG['authentication_846a54955f32846032981f8fe48c35ff'] = 'Adresse (2)'; $_LANG['authentication_092daa39d2b825e4a7fe9b31c2080ecb'] = 'Appartement, suite, l\'unité, bâtiment, étage, etc'; +$_LANG['authentication_d30f507473129e70c4b962ceccf175cf'] = 'Code postal'; +$_LANG['authentication_57d056ed0984166336b7879c2af3657f'] = 'Ville'; +$_LANG['authentication_59716c97497eb9694541f7c3d37b1a4d'] = 'Pays'; +$_LANG['authentication_46a2a41cc6e552044816a2d04634545d'] = 'Etat'; $_LANG['authentication_0f68b904e33d9ac04605aecc958bcf52'] = 'Informations complémentaires'; $_LANG['authentication_39916f579f264041641c122e68e545d5'] = 'Vous devez enregistrer au moins un numéro de téléphone'; $_LANG['authentication_fe66abce284ec8589e7d791185b5c442'] = 'Téléphone domicile'; $_LANG['authentication_41c2fff4867cc204120f001e7af20f7a'] = 'Téléphone portable'; $_LANG['authentication_6c1c4d5a22e3d6ed8385e7287233396f'] = 'Donnez un titre à cette adresse pour la retrouver plus facilement'; +$_LANG['authentication_ae7bdef7fe2bbbbf02c11e92c5fceb40'] = 'Mon adresse'; +$_LANG['authentication_c773457e85b990c10f8823eacb21346c'] = 'Identification fiscale'; +$_LANG['authentication_b60bb13a87fe3ae5463aeb0980a5a8a1'] = 'Numéro d\'identification'; +$_LANG['authentication_ea318a4ad37f0c2d2c368e6c958ed551'] = 'DNI / NIF / NIE'; $_LANG['authentication_0ba7583639a274c434bbe6ef797115a4'] = 'S\'inscrire'; +$_LANG['authentication_19f823c6453c2b1ffd09cb715214813d'] = 'Champs requis'; $_LANG['best-sales_3cb29f0ccc5fd220a97df89dafe46290'] = 'Meilleures ventes'; $_LANG['best-sales_32af07c9205de16855c50c3d20a51698'] = 'Pas de meilleure vente pour le moment.'; $_LANG['breadcrumb_157f518779095e8206908ff1268f10a7'] = 'retour à'; @@ -116,11 +112,6 @@ $_LANG['category-count_4ce81305b7edb043d0a7a5c75cab17d0'] = 'Il y a'; $_LANG['category-count_6357d3551190ec7e79371a8570121d3a'] = 'Il y a'; $_LANG['category-count_b30e141e947fd1b73ad9a02c2c37e7a2'] = 'produit.'; $_LANG['category-count_aac098b07937926af675e5b248734d50'] = 'produits.'; -$_LANG['category_5c9838becf9bbce28ba90a7426daf171'] = 'Il n\'y a pas de produit.'; -$_LANG['category_4ce81305b7edb043d0a7a5c75cab17d0'] = 'Il y a'; -$_LANG['category_6357d3551190ec7e79371a8570121d3a'] = 'Il y a'; -$_LANG['category_b30e141e947fd1b73ad9a02c2c37e7a2'] = 'produit.'; -$_LANG['category_aac098b07937926af675e5b248734d50'] = 'produits.'; $_LANG['category_d3da97e2d9aee5c8fbe03156ad051c99'] = 'Plus'; $_LANG['category_f73cc399b5ce12735a57f03414f09ef9'] = 'Sous-catégories'; $_LANG['category_ff32f7dba36bcd6d0a4214cd80253c3a'] = 'Il n\'y a aucun produit dans cette catégorie.'; @@ -255,6 +246,7 @@ $_LANG['manufacturer_a65ed5e8df4b1c2bb34844f81cc9b451'] = 'Pas de produit pour c $_LANG['my-account_d95cf4ab2cbf1dfb63f066b50558b07d'] = 'Mon compte'; $_LANG['my-account_a341bed9cce718f17657a7aeb3d96af1'] = 'Votre compte est maintenant créé.'; $_LANG['my-account_c75db6799ed40b04a5f0fe865cb75020'] = 'Bienvenue sur votre page d\'accueil. Vous pouvez gérer vos informations personnelles, vos commandes ainsi que vos adresses.'; +$_LANG['my-account_f4c5b2b545efb89fefa11fd6c9da1cb3'] = 'Ajouter ma première adresse'; $_LANG['my-account_7442e29d7d53e549b78d93c46b8cdcfc'] = 'Commandes'; $_LANG['my-account_d1c55b03aa566f1dbe40569fe957c496'] = 'Historique et détails de mes commandes'; $_LANG['my-account_e06d7593c1cd6dabef450be6c3da7091'] = 'Retours produit'; diff --git a/themes/default/my-account.tpl b/themes/default/my-account.tpl index 4f438c98c..baf3b305b 100644 --- a/themes/default/my-account.tpl +++ b/themes/default/my-account.tpl @@ -35,6 +35,9 @@ {/if}

{l s='Welcome to your account. Here you can manage your addresses and orders.'}