Skip to content

Commit

Permalink
fix 404 help center (#1835)
Browse files Browse the repository at this point in the history
  • Loading branch information
ClaraLpresta authored Oct 22, 2024
1 parent fd16a2e commit 031a27b
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
7 changes: 6 additions & 1 deletion _dev/apps/ui/src/assets/json/prestashopUrl.json
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
{
"contactForm": "https://help-center.prestashop.com/contact"
"contactForm": {
"en": "https://prestashop-academy.com/gb/contact-us",
"fr": "https://prestashop-academy.com/fr/nous-contacter",
"it": "https://prestashop-academy.com/it/contattaci",
"es": "https://prestashop-academy.com/es/contactenos"
}
}
3 changes: 2 additions & 1 deletion _dev/apps/ui/src/store/modules/app/getters.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,8 +43,9 @@ export default {
state: LocalState, getters, rootState, rootGetters,
): string {
const {domain} = rootGetters['accounts/GET_PS_ACCOUNTS_CONTEXT'].currentShop;
const languageCode = rootGetters[`app/${GettersTypes.GET_CURRENT_LANGUAGE}`];

return `${prestashopUrls.contactForm}?utm_source=back-office&utm_medium=psx&psx=psxmarketingwithgoogle&shop_domain=${domain}`;
return `${prestashopUrls.contactForm[languageCode] ?? prestashopUrls.contactForm.en}?utm_source=back-office&utm_medium=psx&psx=psxmarketingwithgoogle&shop_domain=${domain}`;
},
[GettersTypes.GET_DEBUG_DATA](state: LocalState): DebugData {
return state.debugData;
Expand Down

0 comments on commit 031a27b

Please sign in to comment.