Skip to content

Commit

Permalink
Merge pull request #300 from PrestaShopCorp/ACCOUNT-1655/feat/error-r…
Browse files Browse the repository at this point in the history
…emove-link-to-hc-article

[ACCOUNT-1655] Removed link to help center article for employee not found error
  • Loading branch information
hschoenenberger authored Feb 28, 2023
2 parents 8a0ce62 + 42b5930 commit 5e1b379
Show file tree
Hide file tree
Showing 13 changed files with 11 additions and 29 deletions.
2 changes: 0 additions & 2 deletions config/config.yml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -32,5 +32,3 @@ parameters:
ps_accounts.oauth2_url_resource_owner_details: 'http://hydra:4444/userinfo'
ps_accounts.oauth2_url_session_logout: 'http://hydra:4444/oauth2/sessions/logout'

ps_accounts.uri_help_center_en: "https://help-center.prestashop.com/en/articles/8087001455634-i-cannot-log-in-to-the-back-office-of-my-edition-shop-with-my-prestashop-account"
ps_accounts.uri_help_center_fr: "https://help-center.prestashop.com/fr/articles/8087001455634-je-ne-peux-pas-me-connecter-au-back-office-de-ma-boutique-edition-avec-mon-compte-prestashop"
15 changes: 0 additions & 15 deletions controllers/admin/AdminLoginController.php
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,6 @@ public function createPsAccountsLoginTemplate()

$isoCode = $this->context->currentLocale->getCode();

$this->context->smarty->assign('uriHelpCenter', $this->getUriHelpCenter($isoCode));
$this->context->smarty->assign('loginError', $session->remove('loginError'));
$this->context->smarty->assign('meta_title', '');
$this->context->smarty->assign('ssoResendVerificationEmail',
Expand Down Expand Up @@ -174,18 +173,4 @@ public function getPsAccountsTemplateDir()
DIRECTORY_SEPARATOR . 'login' .
DIRECTORY_SEPARATOR;
}

/**
* @param string $isoCode
*
* @return mixed
*
* @throws Exception
*/
private function getUriHelpCenter(string $isoCode)
{
return 0 !== strpos($isoCode, 'fr')
? $this->psAccountsModule->getParameter('ps_accounts.uri_help_center_en')
: $this->psAccountsModule->getParameter('ps_accounts.uri_help_center_fr');
}
}
2 changes: 1 addition & 1 deletion translations/de.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Zu anderer Maschine verbinden';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'Sie müssen Ihr Konto erst aktivieren, indem Sie auf den Link in der E-Mail klicken. Wenn Sie einen neuen Aktivierungslink erhalten möchten,[1]klicken Sie bitte hier[/1]';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'Beim Login ist ein Fehler aufgetreten, bitte kontaktieren Sie den PrestaShop-Support';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'Mit diesem Konto können Sie nicht auf das Backoffice zugreifen. Verwenden Sie ein anderes Konto oder kontaktieren Sie Ihren Administrator. [1]Zum Hilfe-Center[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'Mit diesem Konto können Sie nicht auf das Backoffice zugreifen. Verwenden Sie ein anderes Konto oder kontaktieren Sie Ihren Administrator.';
2 changes: 1 addition & 1 deletion translations/en.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Connect with another method';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'You need to activate your account first by clicking the link in the email. If you need to receive a new activation link,[1]please click here[/1]';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'An error occured during login, please contact PrestaShop support';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'You cannot access the back office with this account. Try another account or contact your administrator. [1]Go to Help Center[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'You cannot access the back office with this account. Try another account or contact your administrator.';
2 changes: 1 addition & 1 deletion translations/es.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Conectar con otro método ';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'Primero tienes que activar tu cuenta haciendo clic en el enlace del correo electrónico. Si necesitas recibir un nuevo enlace de activación, [1]haz clic aquí[/1]';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'Se ha producido un error durante el inicio de sesión, ponte en contacto con el soporte de PrestaShop';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'No puedes acceder al back office con esta cuenta. Intenta otra cuenta o contacta con tu administrador. [1]Ir a Centro de ayuda[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'No puedes acceder al back office con esta cuenta. Intenta otra cuenta o contacta con tu administrador.';
2 changes: 1 addition & 1 deletion translations/fr.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Se connecter avec une autre méthode';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'Vous devez d\'abord activer votre compte en cliquant sur le lien contenu dans l\'e-mail. Si vous souhaitez recevoir un nouveau lien d\'activation, [1]veuillez cliquer ici[/1].';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'Une erreur s\'est produite lors de la connexion, veuillez contacter le support PrestaShop.';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'Vous ne pouvez pas accéder au back-office avec ce compte. Essayez un autre compte ou contactez votre administrateur. [1]Allez sur le Centre d\'aide[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'Vous ne pouvez pas accéder au back-office avec ce compte. Essayez un autre compte ou contactez votre administrateur.';
2 changes: 1 addition & 1 deletion translations/it.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Connettiti con un altro metodo';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'È necessario attivare il proprio account facendo clic sul link contenuto nell\'e-mail. Se ha bisogno di ricevere un nuovo link di attivazione,[1]faccia clic qui[/1].';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'Si è verificato un errore durante il login, si prega di contattare l\'assistenza PrestaShop';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'Non puoi accedere al back office con questo account. Prova con un altro account o contatta l\'amministratore. [1]Vai al Centro assistenza[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'Non puoi accedere al back office con questo account. Prova con un altro account o contatta l\'amministratore.';
2 changes: 1 addition & 1 deletion translations/nl.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Verbinden met een andere methode';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'U moet uw account eerst activeren door op de link in de e-mail te klikken. Als u een nieuwe activeringslink wilt ontvangen,[1]klik dan hier[/1]';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'Er is een fout opgetreden tijdens het inloggen, neem contact op met PrestaShop support.';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'U hebt geen toegang tot de back-office met dit account. Probeer een ander account of neem contact op met uw beheerder. [1]Ga naar het Helpcentrum[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'U hebt geen toegang tot de back-office met dit account. Probeer een ander account of neem contact op met uw beheerder.';
2 changes: 1 addition & 1 deletion translations/pl.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Połącz się z innym urządzeniem';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'Musisz najpierw aktywować swoje konto klikając na link w mailu. Jeśli chcesz otrzymać nowy link aktywacyjny,[1]kliknij tutaj[/1]';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'Wystąpił błąd podczas logowania, prosimy o kontakt z supportem PrestaShop';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'You cannot access the back office with this account. Try another account or contact your administrator. [1]Go to Help Center[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'You cannot access the back office with this account. Try another account or contact your administrator.';
2 changes: 1 addition & 1 deletion translations/pt.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Ligar com outro método';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'Tem de activar a sua conta primeiro clicando na ligação no e-mail. Se precisar de receber uma nova ligação de activação,[1]por favor clique aqui[/1]';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'Ocorreu um erro durante o login, por favor contacte o suporte da PrestaShop';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'Você não pode acessar o back-office com esta conta. Tente com uma outra conta ou entre em contato com o administrador. [1]Ir para a Central de Suporte[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'Você não pode acessar o back-office com esta conta. Tente com uma outra conta ou entre em contato com o administrador.';
2 changes: 1 addition & 1 deletion translations/ro.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Conectează-te cu o altă metodă';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'Trebuie să îți activezi contul mai întâi făcând clic pe link-ul din e-mail. Dacă ai nevoie să primești un nou link de activare,[1]te rugăm să apeși aici[/1]';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'A apărut o eroare în timpul autentificării, te rugăm să contactezi suportul PrestaShop';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'Nu poți accesa back office-ul cu acest cont. Încearcă un alt cont sau contactează administratorul. [1]Mergi la Centrul de asistență[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'Nu poți accesa back office-ul cu acest cont. Încearcă un alt cont sau contactează administratorul.';
2 changes: 1 addition & 1 deletion translations/ru.php
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,4 @@
$_MODULE['<{ps_accounts}prestashop>content_8905a5daaa6744846452108776efa036'] = 'Connect with another method';
$_MODULE['<{ps_accounts}prestashop>content_729f27762821b8ec88f1a656be7dff72'] = 'You need to activate your account first by clicking the link in the email. If you need to receive a new activation link,[1]please click here[/1]';
$_MODULE['<{ps_accounts}prestashop>content_476ff05d1175f9a35d268828caf300f2'] = 'An error occured during login, please contact PrestaShop support';
$_MODULE['<{ps_accounts}prestashop>content_c8fc2e859e06da33e96d200b0106cfa3'] = 'You cannot access the back office with this account. Try another account or contact your administrator. [1]Go to Help Center[/1]';
$_MODULE['<{ps_accounts}prestashop>content_fd359ea79740b865e45c2bf6fe5d3ab1'] = 'You cannot access the back office with this account. Try another account or contact your administrator.';
3 changes: 1 addition & 2 deletions views/templates/override/controllers/login/content.tpl
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,7 @@
<span class="puik-alert__description">
{if $loginError eq 'employee_not_found'}
{l
s='You cannot access the back office with this account. Try another account or contact your administrator. [1]Go to Help Center[/1]'
tags=["<a class=\"puik-link\" href=\"{$uriHelpCenter}\" target=\"_blank\">"]
s='You cannot access the back office with this account. Try another account or contact your administrator.'
mod='ps_accounts'
}
{elseif $loginError eq 'email_not_verified'}
Expand Down

0 comments on commit 5e1b379

Please sign in to comment.