diff --git a/app/Auth/CrmUserProvider.php b/app/Auth/CrmUserProvider.php index cd0e3ab..af103ab 100644 --- a/app/Auth/CrmUserProvider.php +++ b/app/Auth/CrmUserProvider.php @@ -113,7 +113,7 @@ class CrmUserProvider extends EloquentUserProvider implements UserProviderContra } // ! Assert Authenticable model must be valided (MustValidate trait). if ($e->getApiError()->equals(ApiError::customerNotActivated)) { - Session::flash('warning', \trans('Vous devez activer votre compte')); + Session::flash('warning', \trans('front.messages.account_not_activated')); return true; } } catch (CrmException | \Exception $e) { diff --git a/app/Http/Controllers/Fo/Auth/ForgotPasswordController.php b/app/Http/Controllers/Fo/Auth/ForgotPasswordController.php index e16b5c1..711eb57 100644 --- a/app/Http/Controllers/Fo/Auth/ForgotPasswordController.php +++ b/app/Http/Controllers/Fo/Auth/ForgotPasswordController.php @@ -19,7 +19,7 @@ class ForgotPasswordController extends Controller * @var string * @phpcs:disable Generic.Files.LineLength.TooLong */ - private $message = 'Si votre compte existe vous devriez recevoir un message avec un lien pour réinitialiser votre mot de passe'; + private $message = 'front.messages.password_reset_email_sent'; //phpcs:enable /** diff --git a/app/Http/Controllers/Fo/Auth/LoginController.php b/app/Http/Controllers/Fo/Auth/LoginController.php index 7de2e19..c6b3b83 100644 --- a/app/Http/Controllers/Fo/Auth/LoginController.php +++ b/app/Http/Controllers/Fo/Auth/LoginController.php @@ -75,11 +75,11 @@ class LoginController extends Controller if (count($countries) && !in_array($crmCustomer->country->value, $countries)) { $this->logout($request); - Session::flash('info', trans('Ce jeu n\'est pas disponible dans votre pays')); + Session::flash('info', trans('front.messages.game_not_available_in_country')); } else { $user->last_connection = \now(); $user->saveOrFail(); - Session::flash('info', trans('Vous êtes à présent connecté')); + Session::flash('info', trans('front.messages.login_success')); } } @@ -92,7 +92,7 @@ class LoginController extends Controller */ protected function loggedOut(Request $request): void { - Session::flash('info', trans('Vous êtes à présent déconnecté')); + Session::flash('info', trans('front.messages.logout_success')); } /** diff --git a/app/Http/Controllers/Fo/Auth/RegisterController.php b/app/Http/Controllers/Fo/Auth/RegisterController.php index 5598672..26f3063 100644 --- a/app/Http/Controllers/Fo/Auth/RegisterController.php +++ b/app/Http/Controllers/Fo/Auth/RegisterController.php @@ -115,7 +115,7 @@ class RegisterController extends Controller // ! Pour accéder au partie du Klub. if ($customer->saveOrFail()) { // phpcs:ignore Generic.Files.LineLength.TooLong - Session::flash('success', trans('Votre compte à bien été crée, vous devez valider votre adresse email, un email de confirmation vous à été envoyé.')); + Session::flash('success', trans('front.messages.account_created_email_confirmation_sent')); } return $customer; @@ -123,7 +123,7 @@ class RegisterController extends Controller } catch (ApiErrorException $e) { if ($e->getApiError()->equals(ApiError::customerExists)) { throw IlluminateValidationException::withMessages([ - 'error' => trans('Un compte est déjà associé à cette adresse email.') + 'error' => trans('front.messages.email_already_in_use') ]); } if ($e->getApiError()->equals(ApiError::validationFailed)) { diff --git a/app/Http/Controllers/Fo/Auth/ResetPasswordController.php b/app/Http/Controllers/Fo/Auth/ResetPasswordController.php index 08d603b..5d6475e 100644 --- a/app/Http/Controllers/Fo/Auth/ResetPasswordController.php +++ b/app/Http/Controllers/Fo/Auth/ResetPasswordController.php @@ -83,7 +83,7 @@ class ResetPasswordController extends Controller } catch (\TypeError | CrmException | ApiErrorException $e) { report($e); throw ValidationException::withMessages([ - 'error' => trans('Une erreur est survenue, merci de réessayer ultérieurement.') + 'error' => trans('front.messages.unexpected_error_try_later') ]); } catch (ExceptionsValidationException $e) { throw ValidationException::withMessages([ diff --git a/app/Http/Controllers/Fo/Auth/VerificationController.php b/app/Http/Controllers/Fo/Auth/VerificationController.php index 020bab5..38d10b5 100644 --- a/app/Http/Controllers/Fo/Auth/VerificationController.php +++ b/app/Http/Controllers/Fo/Auth/VerificationController.php @@ -101,7 +101,7 @@ class VerificationController extends Controller { // phpcs:enable return redirect($this->redirectPath())->with('success', trans( - 'Votre compte est bien activé, vous pouvez à présent participer au jeu' + 'front.messages.account_activated_can_play' )); } @@ -131,7 +131,7 @@ class VerificationController extends Controller $customer->clearApiDataCache(); } catch (ValidationException) { redirect($this->redirectPath())->with('error', trans( - 'Une erreur est survenue' + 'front.messages.unexpected_error_try_later' ))->throwResponse(); } catch (CrmException | ApiErrorException $e) { if ($e->getApiError()->equals(ApiError::customerAlreadyActive)) { @@ -140,7 +140,7 @@ class VerificationController extends Controller } else { report($e); redirect($this->redirectPath())->with('error', trans( - 'Une erreur est survenue' + 'front.messages.unexpected_error_try_later' ))->throwResponse(); } } diff --git a/app/Http/Controllers/Fo/CustomerController.php b/app/Http/Controllers/Fo/CustomerController.php index 897f03e..8a12bc5 100644 --- a/app/Http/Controllers/Fo/CustomerController.php +++ b/app/Http/Controllers/Fo/CustomerController.php @@ -82,7 +82,7 @@ class CustomerController extends Controller 'opt_in', ] ), ['postcode' => $request->input('postal_code')])); - Session::flash('success', trans('Vos informations ont bien été mis à jour')); + Session::flash('success', trans('front.messages.profile_updated_success')); return response()->redirectToRoute('fo.participate'); }); @@ -106,7 +106,7 @@ class CustomerController extends Controller 'error' => trans('Une erreur est survenue, veuillez réssayer plus tard') ]); } //end try - return back()->withInput()->withErrors(trans('Une erreur est survenue, merci de réessayer ultérieurement.')); + return back()->withInput()->withErrors(trans('front.messages.unexpected_error_try_later')); } /** @@ -155,21 +155,21 @@ class CustomerController extends Controller { try { SingleOptin::setStatus($request->email, true); - return \response(trans("Votre inscription à la newsletter a été prise en compte"), 200); + return \response(trans("front.messages.newsletter_subscription_success"), 200); } catch (ApiErrorException $e) { // Il y a deja un customerInfo avec optin a true pour ce customer. if ($e->getApiError()->equals(ApiError::singleOptinCustomerExists)) { - return trans('Vous êtes déjà inscrit avec cette adresse email'); + return trans('front.messages.newsletter_email_already_subscribed'); } if (app()->bound('sentry')) { app('sentry')->captureException($e); } - return \response(trans('Une erreur est survenue, merci de réessayer ultérieurement'), 404); + return \response(trans('front.messages.unexpected_error_try_later'), 404); } catch (CrmException $e) { if (app()->bound('sentry')) { app('sentry')->captureException($e); } - return \response(trans('Une erreur est survenue, merci de réessayer ultérieurement'), 404); + return \response(trans('front.messages.unexpected_error_try_later'), 404); } } } diff --git a/app/Http/Controllers/Fo/DiscountController.php b/app/Http/Controllers/Fo/DiscountController.php index ba78aa6..b5630ec 100644 --- a/app/Http/Controllers/Fo/DiscountController.php +++ b/app/Http/Controllers/Fo/DiscountController.php @@ -22,7 +22,7 @@ class DiscountController extends Controller if ($pdf === null) { \back()->withErrors([ - 'coupon' => trans('Impossible de récupérer le fichier pdf') + 'coupon' => trans('front.messages.pdf_download_error') ])->throwResponse(); } diff --git a/app/Http/Controllers/Fo/HomeController.php b/app/Http/Controllers/Fo/HomeController.php index 6f3037f..748e16f 100644 --- a/app/Http/Controllers/Fo/HomeController.php +++ b/app/Http/Controllers/Fo/HomeController.php @@ -19,7 +19,7 @@ class HomeController extends Controller public function home(): \Illuminate\Contracts\View\View { if (!Gate::check('fo.gameEnabled')) { - \session()->flash('warning', trans('Il manque des éléments pour que le jeu soit jouable')); + \session()->flash('warning', trans('front.messages.game_missing_required_elements')); } return view('theme::pages.home'); } diff --git a/app/Http/Controllers/Fo/ParticipateController.php b/app/Http/Controllers/Fo/ParticipateController.php index 2bb667a..9f18b3f 100644 --- a/app/Http/Controllers/Fo/ParticipateController.php +++ b/app/Http/Controllers/Fo/ParticipateController.php @@ -10,7 +10,6 @@ use App\Mail\Won\PrizeWonAdminMail; use App\Models\Customer; use App\Models\InstantWin; use App\Models\Participation; -use App\Models\Discount; use App\Models\Settings; use App\Notifications\Customer\HasWonDiscount; use App\Notifications\Customer\HasWonInstantWin; @@ -248,7 +247,7 @@ class ParticipateController extends Controller } catch (\RuntimeException $e) { report($e); // * Retenter ? - back()->with('error', trans('Une erreur est survenue, veuillez réssayer.'))->throwResponse(); + back()->with('error', trans('front.messages.unexpected_error_try_later'))->throwResponse(); } //end try throw new \Error('Should not reach this point'); @@ -294,13 +293,13 @@ class ParticipateController extends Controller } catch (ValidationException) { response()->redirectToRoute('fo.profil.verify') ->with('warning', trans( - 'Vous devez compléter des informations sur votre profil pour pouvoir participer.' + 'front.messages.profile_incomplete_cannot_play' ))->throwResponse(); } catch (\Exception $e) { report($e); // * Retenter ? response()->redirectToRoute('fo.homepage') - ->with('error', trans('Une erreur est survenue, veuillez réssayer.')) + ->with('error', trans('front.messages.unexpected_error_try_later')) ->throwResponse(); } //end try } diff --git a/app/Http/Controllers/Fo/WinningProofController.php b/app/Http/Controllers/Fo/WinningProofController.php index aef02cf..a299b8e 100644 --- a/app/Http/Controllers/Fo/WinningProofController.php +++ b/app/Http/Controllers/Fo/WinningProofController.php @@ -139,7 +139,7 @@ class WinningProofController extends Controller return response()->redirectToRoute('fo.homepage') ->with('success', trans( - 'Nous avons bien pris en compte vos preuve de gains, vous serez contactés prochainement' + 'front.messages.winning_proof_submitted_will_be_contacted' )); }); } catch (ApiErrorException $e) { diff --git a/app/Http/Requests/Fo/ParticipateRequest.php b/app/Http/Requests/Fo/ParticipateRequest.php index 515474a..fdd3ec9 100644 --- a/app/Http/Requests/Fo/ParticipateRequest.php +++ b/app/Http/Requests/Fo/ParticipateRequest.php @@ -108,7 +108,7 @@ class ParticipateRequest extends FormRequest function (string $attribute, $value, callable $fail) { // ? Le Code unique est resolved ? if ($value === false or !\is_object($value) or \get_class($value) !== Code::class) { - $fail(trans('Code unique incorrect, veuillez réessayer.')); + $fail(trans('front.messages.unique_code_invalid')); return; } @@ -122,7 +122,7 @@ class ParticipateRequest extends FormRequest ->whereHas('customer', fn (Builder $q) => $q->where('id', $customer->id)); // ! Une seule participation avec un code donné par joueur if ($query->exists()) { - $fail(trans('Vous avez déjà utilisé ce code unique.')); + $fail(trans('front.messages.unique_code_already_used')); return; } @@ -130,7 +130,7 @@ class ParticipateRequest extends FormRequest // ? Le code unique à été trop utilisé ? if ($value->has_been_used_too_many_times) { // * Ne pas laisser d'indices, message générique - $fail(trans('Code unique incorrect, veuillez réessayer.')); + $fail(trans('front.messages.unique_code_invalid')); return; } } @@ -150,7 +150,7 @@ class ParticipateRequest extends FormRequest empty($product) or !is_object($product) or !($product instanceof Model) or !$product->exists ) { - $fail(trans('Le code barre entré est incorrect, veuillez réessayer.')); + $fail(trans('front.messages.barcode_invalid')); } } ]]); diff --git a/app/Mail/Won/DiscountWonMail.php b/app/Mail/Won/DiscountWonMail.php index 6814da6..fb67134 100644 --- a/app/Mail/Won/DiscountWonMail.php +++ b/app/Mail/Won/DiscountWonMail.php @@ -46,7 +46,7 @@ class DiscountWonMail extends Mailable implements ShouldQueue { return new Envelope( to: [$this->recipient], - subject: trans('Votre gain du jeu :game_name', [ + subject: trans('front.mails.subjects.game_winning', [ 'game_name' => $this->game_name ]), ); diff --git a/app/Mail/Won/PrizeIsSentMail.php b/app/Mail/Won/PrizeIsSentMail.php index 843bc08..ec5718f 100644 --- a/app/Mail/Won/PrizeIsSentMail.php +++ b/app/Mail/Won/PrizeIsSentMail.php @@ -39,7 +39,7 @@ class PrizeIsSentMail extends Mailable implements ShouldQueue { return new Envelope( to: [$this->recipient], - subject: trans('Votre lot à été envoyé'), + subject: trans('front.mails.subjects.prize_shipped'), ); } diff --git a/app/Mail/Won/PrizeWonMail.php b/app/Mail/Won/PrizeWonMail.php index d09cc56..cbc2f4e 100644 --- a/app/Mail/Won/PrizeWonMail.php +++ b/app/Mail/Won/PrizeWonMail.php @@ -45,7 +45,7 @@ class PrizeWonMail extends Mailable implements ShouldQueue { return new Envelope( to: [$this->recipient], - subject: trans('Votre gain du jeu :game_name', [ + subject: trans('front.mails.subjects.game_winning', [ 'game_name' => $this->game_name ]), ); diff --git a/app/Mail/Won/WinningProofSubmitedMail.php b/app/Mail/Won/WinningProofSubmitedMail.php index fa324eb..996b0f9 100644 --- a/app/Mail/Won/WinningProofSubmitedMail.php +++ b/app/Mail/Won/WinningProofSubmitedMail.php @@ -39,7 +39,7 @@ class WinningProofSubmitedMail extends Mailable implements ShouldQueue { return new Envelope( to: [$this->recipient], - subject: trans('Nous avons recu vos preuves de gains'), + subject: trans('front.mails.subjects.winning_proof_received'), ); } diff --git a/app/Notifications/Customer/DestroyCustomer.php b/app/Notifications/Customer/DestroyCustomer.php index 52b373c..892420a 100644 --- a/app/Notifications/Customer/DestroyCustomer.php +++ b/app/Notifications/Customer/DestroyCustomer.php @@ -37,18 +37,13 @@ class DestroyCustomer extends Notification $first_name = $notifiable->api_data->firstname; return (new MailMessage()) - ->subject(trans('Supression du compte - :site_name', [ + ->subject(trans('front.mails.subjects.destroy_customer', [ 'site_name' => $settings->name ])) - ->greeting(trans('Bonjour :first_name', ['first_name' => $first_name])) + ->greeting(trans('front.mails.greetings.with_name', ['first_name' => $first_name])) ->line(trans( - "Votre compte :site_name a été marqué pour suppression, - il sera définitivement effacé au bout de 1 semaine. - Vous pourrez le réactiver durant ce délai si vous le - souhaitez en vous reconnectant.", - [ - 'site_name' => $settings->name - ] + 'front.mails.contents.destroy_customer', + ['site_name' => $settings->name] )); } } diff --git a/app/Notifications/Customer/DestroyedCustomer.php b/app/Notifications/Customer/DestroyedCustomer.php index 994fd76..114ee3f 100644 --- a/app/Notifications/Customer/DestroyedCustomer.php +++ b/app/Notifications/Customer/DestroyedCustomer.php @@ -37,17 +37,13 @@ class DestroyedCustomer extends Notification /** @var \App\Models\Customer $notifiable */ return (new MailMessage()) - ->subject(trans('Votre compte est suprimé - :site_name', [ + ->subject(trans('front.mails.subjects.destroyed_customer', [ 'site_name' => $settings->name ])) - ->greeting('Bonjour') + ->greeting('front.mails.greetings.without_name') ->line(trans( - "Votre compte :site_name a été définitivement supprimé ainsi ques les données associés, - si vous aviez effectué une commande elle sera bien sûr toujours honorée. Les commandes associés - a votre compte continueront d'exister mais les données de votre compte ont bien été supprimées.", - [ - 'site_name' => $settings->name - ] + 'front.mails.contents.destroyed_customer', + ['site_name' => $settings->name] )); } } diff --git a/app/Notifications/Customer/ResetPassword.php b/app/Notifications/Customer/ResetPassword.php index 65f1ea0..483bae9 100644 --- a/app/Notifications/Customer/ResetPassword.php +++ b/app/Notifications/Customer/ResetPassword.php @@ -57,13 +57,13 @@ class ResetPassword extends NotificationsResetPassword $first_name = $notifiable->api_data->firstname; return (new MailMessage()) - ->subject(trans('Mot de passe oublié - :site_name', ['site_name' => $settings->name])) - ->greeting(trans('Bonjour :first_name', ['first_name' => $first_name])) + ->subject(trans('front.mails.subjects.reset_password', ['site_name' => $settings->name])) + ->greeting(trans('front.mails.greetings.with_name', ['first_name' => $first_name])) ->line(trans( - 'Afin réinitialiser votre mot de passe pour vous connecter à :site_name, cliquez sur le lien suivant :', + 'front.mails.contents.reset_password', ['site_name' => $settings->name] )) /** @var string $verificationUrl */ - ->action(trans('Réinitialisez votre mot de passe'), $resetUrl); + ->action(trans('front.mails.actions.reset_password'), $resetUrl); } } diff --git a/app/Notifications/Customer/UpdateEmail.php b/app/Notifications/Customer/UpdateEmail.php index b321fd2..a1a164c 100644 --- a/app/Notifications/Customer/UpdateEmail.php +++ b/app/Notifications/Customer/UpdateEmail.php @@ -37,11 +37,11 @@ class UpdateEmail extends Notification $first_name = $notifiable->api_data->firstname; return (new MailMessage()) - ->subject(trans('Mise à jour de l\'email - :site_name', [ + ->subject(trans('front.mails.subjects.update_email', [ 'site_name' => $settings->name ])) - ->greeting(trans('Bonjour :first_name', ['first_name' => $first_name])) - ->line(trans('L\'email associé à votre compte :site_name vient d\'être modifié.', [ + ->greeting(trans('front.mails.greetings.with_name', ['first_name' => $first_name])) + ->line(trans('front.mails.contents.update_email', [ 'site_name' => $settings->name ])); } diff --git a/app/Notifications/Customer/UpdatePassword.php b/app/Notifications/Customer/UpdatePassword.php index 804af58..766315d 100644 --- a/app/Notifications/Customer/UpdatePassword.php +++ b/app/Notifications/Customer/UpdatePassword.php @@ -37,11 +37,11 @@ class UpdatePassword extends Notification $first_name = $notifiable->api_data->firstname; return (new MailMessage()) - ->subject(trans('Mise à jour du mot de passe - :site_name', [ + ->subject(trans('front.mails.subjects.update_password', [ 'site_name' => $settings->name ])) - ->greeting(trans('Bonjour :first_name', ['first_name' => $first_name])) - ->line(trans("Le mot de passe associé à votre compte :site_name vient d'être modifié.", [ + ->greeting(trans('front.mails.greetings.with_name', ['first_name' => $first_name])) + ->line(trans('front.mails.contents.update_password', [ 'site_name' => $settings->name ])); } diff --git a/app/Notifications/Customer/VerifyEmail.php b/app/Notifications/Customer/VerifyEmail.php index 1acceda..d70758c 100644 --- a/app/Notifications/Customer/VerifyEmail.php +++ b/app/Notifications/Customer/VerifyEmail.php @@ -59,13 +59,11 @@ class VerifyEmail extends NotificationsVerifyEmail return (new MailMessage()) ->success() - ->subject(trans("Inscription - :site_name", ['site_name' => $settings->name])) - ->greeting(trans('Bonjour :first_name', ['first_name' => $first_name])) - ->line(trans('Vous n\'êtes plus qu\'à un clic de votre inscription... ')) - ->line(trans('Pour finaliser votre inscription, merci de cliquer sur le lien ci-dessous :')) - ->action(trans('Confirmer mon adresse email'), $verificationUrl) - ->line(trans( - 'Si vous avez des questions, n\'hésitez pas à nous contacter via notre formulaire de contact' - )); + ->subject(trans("front.mails.subjects.verify_email", ['site_name' => $settings->name])) + ->greeting(trans('front.mails.greetings.with_name', ['first_name' => $first_name])) + ->line(trans('front.mails.contents.verify_email_1')) + ->line(trans('front.mails.contents.verify_email_2')) + ->action(trans('front.mails.actions.verify_email'), $verificationUrl) + ->line(trans('front.mails.contents.verify_email_3')); } } diff --git a/config/app.php b/config/app.php index d216dfd..d772f0a 100644 --- a/config/app.php +++ b/config/app.php @@ -82,7 +82,7 @@ return [ | */ - 'locale' => 'fr', + 'locale' => env('APP_LOCALE', 'fr'), /* |-------------------------------------------------------------------------- @@ -95,7 +95,7 @@ return [ | */ - 'fallback_locale' => 'fr', + 'fallback_locale' => env('APP_FALLBACK_LOCALE', 'fr'), /* |-------------------------------------------------------------------------- @@ -108,7 +108,7 @@ return [ | */ - 'faker_locale' => 'fr_FR', + 'faker_locale' => env('APP_FAKER_LOCALE', 'fr_FR'), /* |-------------------------------------------------------------------------- diff --git a/deployment/manifest.yaml b/deployment/manifest.yaml index b288bb7..c87b1c8 100644 --- a/deployment/manifest.yaml +++ b/deployment/manifest.yaml @@ -10,6 +10,9 @@ data: APP_DEBUG: "${APP_APP_DEBUG}" APP_URL: "https://${APP_DOMAIN}" ASSET_URL: "https://${APP_DOMAIN}" + APP_LOCALE: "${APP_APP_LOCALE}" + APP_FALLBACK_LOCALE: "${APP_APP_FALLBACK_LOCALE}" + APP_FAKER_LOCALE: "${APP_APP_FAKER_LOCALE}" LOG_CHANNEL: "k8s" DB_HOST: "mariadb-service.common-services" DB_DATABASE: "${APP_DB_DATABASE}" @@ -84,7 +87,6 @@ spec: persistentVolumeClaim: claimName: ggw-${CI_PROJECT_NAME}-pvc-storage - --- apiVersion: v1 kind: Service @@ -142,35 +144,35 @@ spec: affinity: podAffinity: requiredDuringSchedulingIgnoredDuringExecution: - - labelSelector: - matchExpressions: - - key: app - operator: In - values: - - ggw-${CI_PROJECT_NAME}-app - topologyKey: "kubernetes.io/hostname" - namespaces: [$KUBE_NAMESPACE] + - labelSelector: + matchExpressions: + - key: app + operator: In + values: + - ggw-${CI_PROJECT_NAME}-app + topologyKey: "kubernetes.io/hostname" + namespaces: [$KUBE_NAMESPACE] containers: - - name: ggw-${CI_PROJECT_NAME}-scheduled - image: $IMAGE_TAG - imagePullPolicy: IfNotPresent - command: - - "php" - args: - - "artisan" - - "schedule:run" - envFrom: - - configMapRef: - name: ggw-${CI_PROJECT_NAME}-config-map - volumeMounts: - - name: storage - mountPath: /app/srcs/storage + - name: ggw-${CI_PROJECT_NAME}-scheduled + image: $IMAGE_TAG + imagePullPolicy: IfNotPresent + command: + - "php" + args: + - "artisan" + - "schedule:run" + envFrom: + - configMapRef: + name: ggw-${CI_PROJECT_NAME}-config-map + volumeMounts: + - name: storage + mountPath: /app/srcs/storage imagePullSecrets: - - name: docker-registry-credentials + - name: docker-registry-credentials volumes: - - name: storage - persistentVolumeClaim: - claimName: ggw-${CI_PROJECT_NAME}-pvc-storage + - name: storage + persistentVolumeClaim: + claimName: ggw-${CI_PROJECT_NAME}-pvc-storage securityContext: runAsUser: 33 runAsGroup: 33 @@ -194,42 +196,42 @@ spec: app: ggw-${CI_PROJECT_NAME}-app-queue spec: affinity: - podAffinity: - requiredDuringSchedulingIgnoredDuringExecution: - - labelSelector: - matchExpressions: + podAffinity: + requiredDuringSchedulingIgnoredDuringExecution: + - labelSelector: + matchExpressions: - key: app operator: In values: - - ggw-${CI_PROJECT_NAME}-app - topologyKey: "kubernetes.io/hostname" - namespaces: [$KUBE_NAMESPACE] + - ggw-${CI_PROJECT_NAME}-app + topologyKey: "kubernetes.io/hostname" + namespaces: [$KUBE_NAMESPACE] containers: - - name: ggw-${CI_PROJECT_NAME}-container-queue - image: "registry.s-web.fr/ldc-web/projets/op-insta:latest" - command: - - php - args: - - artisan - - queue:work - - --max-jobs=200 - - --sleep=3 - - --tries=3 - imagePullPolicy: IfNotPresent - envFrom: - - configMapRef: - name: ggw-${CI_PROJECT_NAME}-config-map - volumeMounts: - - name: storage - mountPath: /app/srcs/storage + - name: ggw-${CI_PROJECT_NAME}-container-queue + image: "registry.s-web.fr/ldc-web/projets/op-insta:latest" + command: + - php + args: + - artisan + - queue:work + - --max-jobs=200 + - --sleep=3 + - --tries=3 + imagePullPolicy: IfNotPresent + envFrom: + - configMapRef: + name: ggw-${CI_PROJECT_NAME}-config-map + volumeMounts: + - name: storage + mountPath: /app/srcs/storage imagePullSecrets: - - name: docker-registry-credentials + - name: docker-registry-credentials volumes: - - name: storage - persistentVolumeClaim: - claimName: ggw-${CI_PROJECT_NAME}-pvc-storage + - name: storage + persistentVolumeClaim: + claimName: ggw-${CI_PROJECT_NAME}-pvc-storage securityContext: runAsUser: 33 runAsGroup: 33 fsGroup: 33 - fsGroupChangePolicy: "OnRootMismatch" \ No newline at end of file + fsGroupChangePolicy: "OnRootMismatch" diff --git a/resources/lang/de/enums.php b/resources/lang/de/enums.php deleted file mode 100644 index 0b67a5f..0000000 --- a/resources/lang/de/enums.php +++ /dev/null @@ -1,3 +0,0 @@ - [ + 'password_reset_email_sent' => 'Falls Ihr Konto existiert, sollten Sie eine Nachricht mit einem Link zum Zurücksetzen Ihres Passworts erhalten.', + 'game_not_available_in_country' => 'Dieses Spiel ist in Ihrem Land nicht verfügbar.', + 'login_success' => 'Sie sind jetzt angemeldet.', + 'logout_success' => 'Sie sind jetzt abgemeldet.', + 'account_created_email_confirmation_sent' => 'Ihr Konto wurde erfolgreich erstellt. Sie müssen Ihre E-Mail-Adresse bestätigen. Eine Bestätigungs-E-Mail wurde an Sie gesendet.', + 'email_already_in_use' => 'Mit dieser E-Mail-Adresse ist bereits ein Konto verknüpft.', + 'unexpected_error_try_later' => 'Ein Fehler ist aufgetreten. Bitte versuchen Sie es später erneut.', + 'account_activated_can_play' => 'Ihr Konto wurde erfolgreich aktiviert. Sie können jetzt am Spiel teilnehmen.', + 'profile_updated_success' => 'Ihre Informationen wurden erfolgreich aktualisiert.', + 'newsletter_subscription_success' => 'Ihre Newsletter-Anmeldung wurde erfolgreich registriert.', + 'newsletter_email_already_subscribed' => 'Sie sind bereits mit dieser E-Mail-Adresse angemeldet.', + 'pdf_download_error' => 'Die PDF-Datei konnte nicht abgerufen werden.', + 'game_missing_required_elements' => 'Es fehlen Elemente, damit das Spiel spielbar ist.', + 'profile_incomplete_cannot_play' => 'Sie müssen Ihre Profilinformationen vervollständigen, um teilnehmen zu können.', + 'winning_proof_submitted_will_be_contacted' => 'Wir haben Ihre Gewinnbelege erhalten und werden Sie in Kürze kontaktieren.', + 'account_not_activated' => 'Sie müssen Ihr Konto aktivieren.', + 'unique_code_invalid' => 'Ungültiger Einmalcode, bitte versuchen Sie es erneut.', + 'unique_code_already_used' => 'Sie haben diesen Einmalcode bereits verwendet.', + 'barcode_invalid' => 'Der eingegebene Barcode ist falsch, bitte versuchen Sie es erneut.', + ], + 'mails' => [ + 'subjects' => [ + 'game_winning' => 'Ihr Spielgewinn :game_name', + 'prize_shipped' => 'Ihr Gewinn wurde versandt', + 'winning_proof_received' => 'Wir haben Ihre Gewinnbelege erhalten', + 'destroy_customer' => 'Konto löschen - :site_name', + 'destroyed_customer' => 'Ihr Konto wurde gelöscht - :site_name', + 'reset_password' => 'Passwort vergessen - :site_name', + 'update_email' => 'E-Mail-Adresse aktualisieren - :site_name', + 'update_password' => 'Passwort aktualisieren - :site_name', + 'verify_email' => 'Anmeldung - :site_name', + ], + 'greetings' => [ + 'with_name' => 'Guten Tag :first_name', + 'without_name' => 'Guten Tag', + ], + 'contents' => [ + 'destroy_customer' => 'Ihr Konto :site_name wurde zur Löschung vorgemerkt und wird nach einer Woche endgültig gelöscht. + Sie können es innerhalb dieser Frist wieder aktivieren, + indem Sie sich erneut anmelden.', + 'destroyed_customer' => 'Ihr Konto bei :site_name wurde zusammen mit den zugehörigen Daten endgültig gelöscht. + Sollten Sie eine Bestellung aufgegeben haben, wird diese selbstverständlich weiterhin bearbeitet. + Die mit Ihrem Konto verbundenen Bestellungen bleiben bestehen, + Ihre Kontodaten wurden jedoch gelöscht.', + 'reset_password' => 'Um Ihr Passwort für die Anmeldung bei :site_name zurückzusetzen, + klicken Sie bitte auf den folgenden Link:', + 'update_email' => 'Die mit Ihrem Konto bei :site_name verknüpfte E-Mail-Adresse wurde soeben geändert.', + 'update_password' => 'Das Passwort für Ihr Konto bei :site_name wurde soeben geändert.', + 'verify_email_1' => 'Sie sind nur noch einen Klick von Ihrer Anmeldung entfernt...', + 'verify_email_2' => 'Um Ihre Anmeldung abzuschließen, klicken Sie bitte auf den folgenden Link:', + 'verify_email_3' => 'Wenn Sie Fragen haben, zögern Sie bitte nicht, uns über unser Kontaktformular zu kontaktieren', + ], + 'actions' => [ + 'reset_password' => 'Passwort zurücksetzen', + 'verify_email' => 'Meine E-Mail-Adresse bestätigen', + ], + ], +]; diff --git a/resources/lang/de/validation.php b/resources/lang/de/validation.php index acf87f4..994b1dc 100644 --- a/resources/lang/de/validation.php +++ b/resources/lang/de/validation.php @@ -162,7 +162,7 @@ return [ 'description' => 'Beschreibung', 'district' => 'Bezirk', 'duration' => 'Dauer', - 'email' => 'E-Mail-Adresse', + 'email' => 'E-Mail Adresse', 'excerpt' => 'Auszug', 'filter' => 'Filter', 'first_name' => 'Vorname', @@ -172,8 +172,8 @@ return [ 'image' => 'Bild', 'last_name' => 'Nachname', 'lesson' => 'Lektion', - 'line_address_1' => 'Adresszeile 1', - 'line_address_2' => 'Adresszeile 2', + 'line_address_1' => 'Adresse', + 'line_address_2' => 'Adresszusatz', 'message' => 'Nachricht', 'middle_name' => 'Zweitname', 'minute' => 'Minute', @@ -183,7 +183,7 @@ return [ 'national_code' => 'Länderkennung', 'number' => 'Nummer', 'password' => 'Passwort', - 'password_confirmation' => 'Passwortbestätigung', + 'password_confirmation' => 'Passwort bestätigen', 'phone' => 'Telefonnummer', 'photo' => 'Foto', 'postal_code' => 'Postleitzahl', @@ -276,5 +276,6 @@ return [ 'barcode' => 'Produktbarcode', 'ticket' => 'Kassenbon mit Datum', 'sticker' => 'Produktaufkleber', + 'error_list' => 'Fehlerliste:' ], ]; diff --git a/resources/lang/en/front.php b/resources/lang/en/front.php new file mode 100644 index 0000000..c05b2a1 --- /dev/null +++ b/resources/lang/en/front.php @@ -0,0 +1,61 @@ + [ + 'password_reset_email_sent' => 'If your account exists, you should receive a message with a link to reset your password.', + 'game_not_available_in_country' => 'This game is not available in your country.', + 'login_success' => 'You are now logged in.', + 'logout_success' => 'You are now logged out.', + 'account_created_email_confirmation_sent' => 'Your account has been successfully created. You need to verify your email address, a confirmation email has been sent to you.', + 'email_already_in_use' => 'An account is already associated with this email address.', + 'unexpected_error_try_later' => 'An error has occurred, please try again later.', + 'account_activated_can_play' => 'Your account has been activated, you can now participate in the game.', + 'profile_updated_success' => 'Your information has been successfully updated.', + 'newsletter_subscription_success' => 'Your newsletter subscription has been registered.', + 'newsletter_email_already_subscribed' => 'You are already registered with this email address.', + 'pdf_download_error' => 'Unable to retrieve the PDF file.', + 'game_missing_required_elements' => 'Some elements are missing for the game to be playable.', + 'profile_incomplete_cannot_play' => 'You must complete your profile information in order to participate.', + 'winning_proof_submitted_will_be_contacted' => 'Your proof of winnings has been received, you will be contacted shortly.', + 'account_not_activated' => 'You must activate your account.', + 'unique_code_invalid' => 'Invalid unique code, please try again.', + 'unique_code_already_used' => 'You have already used this unique code.', + 'barcode_invalid' => 'The barcode entered is incorrect, please try again.', + ], + 'mails' => [ + 'subjects' => [ + 'game_winning' => 'Your game reward :game_name', + 'prize_shipped' => 'Your prize has been shipped', + 'winning_proof_received' => 'We have received your proof of winnings', + 'destroy_customer' => 'Account deletion - :site_name', + 'destroyed_customer' => 'Your account has been deleted - :site_name', + 'reset_password' => 'Forgot password - :site_name', + 'update_email' => 'Email address updated - :site_name', + 'update_password' => 'Password updated - :site_name', + 'verify_email' => 'Registration - :site_name', + ], + 'greetings' => [ + 'with_name' => 'Hello :first_name,', + 'without_name' => 'Hello,', + ], + 'contents' => [ + 'destroy_customer' => 'Your :site_name account has been marked for deletion, + it will be permanently deleted after 1 week. + You can reactivate it during this period if you wish + by logging back in.', + 'destroyed_customer' => 'Your :site_name account has been permanently deleted along with all associated data. + If you had placed an order, it will of course still be fulfilled. Orders associated + with your account will continue to exist, but your account data has been permanently deleted.', + 'reset_password' => 'To reset your password and log in to :site_name, click the following link:', + 'update_email' => 'The email address associated with your :site_name account has just been updated.', + 'update_password' => 'The password associated with your :site_name account has just been updated.', + 'verify_email_1' => 'You are just one click away from completing your registration...', + 'verify_email_2' => 'To finalise your registration, please click the link below:', + 'verify_email_3' => 'If you have any questions, feel free to contact us via our contact form.', + ], + 'actions' => [ + 'reset_password' => 'Reset your password', + 'verify_email' => 'Confirm my email address', + ], + ] +]; diff --git a/resources/lang/en/validation.php b/resources/lang/en/validation.php index 56ab93d..3b06268 100644 --- a/resources/lang/en/validation.php +++ b/resources/lang/en/validation.php @@ -108,7 +108,8 @@ return [ 'mixed' => 'The :attribute field must contain at least one uppercase and one lowercase letter.', 'numbers' => 'The :attribute field must contain at least one number.', 'symbols' => 'The :attribute field must contain at least one symbol.', - 'uncompromised' => 'The given :attribute has appeared in a data leak. Please choose a different :attribute.', + 'uncompromised' => 'The given :attribute has appeared in a data leak. + Please choose a different :attribute.', ], 'present' => 'The :attribute field must be present.', 'prohibited' => 'The :attribute field is prohibited.', @@ -214,24 +215,68 @@ return [ 'username' => 'username', 'year' => 'year', ], + 'ean' => 'The :attribute field must be a valid EAN code (7, 8 or 13 digits).', + 'postal_code' => 'The :attribute field accepts postal codes from the following countries: + :countries, for example :examples.', + 'phone' => 'The :attribute field is not a valid phone number, it accepts numbers + from the following countries: :countries.', 'custom' => [ 'of_the' => [ 'male' => 'of the ', 'female' => 'of the ', 'vowel' => 'of the ' ], - 'event' => 'event', - 'model' => 'target element', - 'order' => 'order', - 'publication' => 'publication', - 'activated' => 'activated', - 'target' => 'target', - 'static_page_type' => 'static page type', - 'seo_title' => 'SEO title', - 'seo_description' => 'SEO description', - 'authorized_countries' => 'eligible countries at game', - - 'postal_code' => 'the :attribute field accepts postal codes from the following - :countries such as :examples', + 'attribute_alt' => 'alt attribute', + 'attribute_title' => 'title attribute', + 'event' => 'event', + 'model' => 'target element', + 'order' => 'order', + 'publication' => 'publication', + 'activated' => 'activated', + 'target' => 'target', + 'static_page_type' => 'static page type', + 'seo_title' => 'SEO title', + 'seo_description' => 'SEO description', + 'ip' => 'IP', + 'code' => 'code', + 'unique_code' => 'unique code', + 'product' => 'product', + 'value' => 'value', + 'question' => 'question', + 'answer' => 'answer', + 'theme' => 'theme', + 'file_name' => 'file name', + 'label' => 'label', + 'arg' => 'argument', + 'subtitle' => 'subtitle', + 'quantity' => 'quantity', + 'pdf_winning_proof' => 'proof of winnings PDF', + 'picture' => 'illustration', + 'ean_code' => 'EAN code', + 'start_date' => 'start date', + 'end_date' => 'end date', + 'nb_participation_player' => 'number of participations per player', + 'nb_participation_ip' => 'number of participations per IP address', + 'nb_unique_code_use' => 'number of unique code uses', + 'code_length' => 'unique code length', + 'code_type' => 'code type', + 'activated_teaser' => 'teaser activation', + 'activated_close_page' => 'closing page activation', + 'close_page_active_date' => 'page active until', + 'redirect_close' => 'redirect URL after game end date', + 'winning_proof' => 'enable proof of winnings', + 'company' => 'company', + 'discounts_activated' => 'enable discount vouchers', + 'discounts_site' => 'site reference', + 'discounts_campaign' => 'campaign reference', + 'analytics' => 'analytics', + 'game_rules' => 'game rules', + 'notify_prize_sent' => 'prize sent notification to participant', + 'comment' => 'comment', + 'authorized_countries' => 'eligible countries at game', + 'barcode' => 'product barcode', + 'ticket' => 'receipt with date', + 'sticker' => 'product sticker', + 'error_list' => 'Error list:', ], ]; diff --git a/resources/lang/fr/front.php b/resources/lang/fr/front.php new file mode 100644 index 0000000..2a50d7d --- /dev/null +++ b/resources/lang/fr/front.php @@ -0,0 +1,61 @@ + [ + 'password_reset_email_sent' => 'Si votre compte existe vous devriez recevoir un message avec un lien pour réinitialiser votre mot de passe', + 'game_not_available_in_country' => 'Ce jeu n\'est pas disponible dans votre pays.', + 'login_success' => 'Vous êtes à présent connecté.', + 'logout_success' => 'Vous êtes à présent déconnecté.', + 'account_created_email_confirmation_sent' => 'Votre compte à bien été crée, vous devez valider votre adresse email, un email de confirmation vous à été envoyé.', + 'email_already_in_use' => 'Un compte est déjà associé à cette adresse email.', + 'unexpected_error_try_later' => 'Une erreur est survenue, merci de réessayer ultérieurement.', + 'account_activated_can_play' => 'Votre compte est bien activé, vous pouvez à présent participer au jeu.', + 'profile_updated_success' => 'Vos informations ont bien été mis à jour.', + 'newsletter_subscription_success' => 'Votre inscription à la newsletter a été prise en compte.', + 'newsletter_email_already_subscribed' => 'Vous êtes déjà inscrit avec cette adresse email.', + 'pdf_download_error' => 'Impossible de récupérer le fichier pdf.', + 'game_missing_required_elements' => 'Il manque des éléments pour que le jeu soit jouable.', + 'profile_incomplete_cannot_play' => 'Vous devez compléter des informations sur votre profil pour pouvoir participer.', + 'winning_proof_submitted_will_be_contacted' => 'Nous avons bien pris en compte vos preuve de gains, vous serez contactés prochainement.', + 'account_not_activated' => 'Vous devez activer votre compte.', + 'unique_code_invalid' => 'Code unique incorrect, veuillez réessayer.', + 'unique_code_already_used' => 'Vous avez déjà utilisé ce code unique.', + 'barcode_invalid' => 'Le code barre entré est incorrect, veuillez réessayer.', + ], + 'mails' => [ + 'subjects' => [ + 'game_winning' => 'Votre gain du jeu :game_name', + 'prize_shipped' => 'Votre lot à été envoyé', + 'winning_proof_received' => 'Nous avons recu vos preuves de gains', + 'destroy_customer' => 'Supression du compte - :site_name', + 'destroyed_customer' => 'Votre compte est supprimé - :site_name', + 'reset_password' => 'Mot de passe oublié - :site_name', + 'update_email' => 'Mise à jour de l\'email - :site_name', + 'update_password' => 'Mise à jour du mot de passe - :site_name', + 'verify_email' => 'Inscription - :site_name', + ], + 'greetings' => [ + 'with_name' => 'Bonjour :first_name', + 'without_name' => 'Bonjour', + ], + 'contents' => [ + 'destroy_customer' => 'Votre compte :site_name a été marqué pour suppression, + il sera définitivement effacé au bout de 1 semaine. + Vous pourrez le réactiver durant ce délai si vous le + souhaitez en vous reconnectant.', + 'destroyed_customer' => 'Votre compte :site_name a été définitivement supprimé ainsi ques les données associés, + si vous aviez effectué une commande elle sera bien sûr toujours honorée. Les commandes associés + a votre compte continueront d\'exister mais les données de votre compte ont bien été supprimées.', + 'reset_password' => 'Afin réinitialiser votre mot de passe pour vous connecter à :site_name, cliquez sur le lien suivant :', + 'update_email' => 'L\'email associé à votre compte :site_name vient d\'être modifié.', + 'update_password' => 'Le mot de passe associé à votre compte :site_name vient d\'être modifié.', + 'verify_email_1' => 'Vous n\'êtes plus qu\'à un clic de votre inscription...', + 'verify_email_2' => 'Pour finaliser votre inscription, merci de cliquer sur le lien ci-dessous :', + 'verify_email_3' => 'Si vous avez des questions, n\'hésitez pas à nous contacter via notre formulaire de contact', + ], + 'actions' => [ + 'reset_password' => 'Réinitialisez votre mot de passe', + 'verify_email' => 'Confirmer mon adresse email', + ], + ] +]; diff --git a/resources/lang/fr/validation.php b/resources/lang/fr/validation.php index 37d9f7c..43bb0e2 100644 --- a/resources/lang/fr/validation.php +++ b/resources/lang/fr/validation.php @@ -226,17 +226,17 @@ return [ 'female' => 'de la ', 'vowel' => 'de l\'' ], - 'attribute_alt' => 'attribut alt', - 'attribute_title' => 'attribut title', - 'event' => 'évènement', - 'model' => 'élément ciblé', - 'order' => 'ordre', - 'publication' => 'publication', - 'activated' => 'activé', - 'target' => 'cible', - 'static_page_type' => 'type de page', - 'seo_title' => 'titre SEO', - 'seo_description' => 'description SEO', + 'attribute_alt' => 'attribut alt', + 'attribute_title' => 'attribut title', + 'event' => 'évènement', + 'model' => 'élément ciblé', + 'order' => 'ordre', + 'publication' => 'publication', + 'activated' => 'activé', + 'target' => 'cible', + 'static_page_type' => 'type de page', + 'seo_title' => 'titre SEO', + 'seo_description' => 'description SEO', 'ip' => 'IP', 'code' => 'code', 'unique_code' => 'code unique', @@ -277,5 +277,6 @@ return [ 'barcode' => 'code-barres du produit', 'ticket' => 'ticket de caisse avec la date', 'sticker' => 'sticker du produit', + 'error_list' => 'Liste des erreurs :', ], ];