first commit

This commit is contained in:
2024-12-17 13:43:22 +01:00
commit 8e6cd8b410
21292 changed files with 3514826 additions and 0 deletions

View File

@@ -0,0 +1,28 @@
<?php
/**
* Copyright since 2007 PrestaShop SA and Contributors
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License version 3.0
* that is bundled with this package in the file LICENSE.md.
* It is also available through the world-wide-web at this URL:
* https://opensource.org/licenses/AFL-3.0
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* @author PrestaShop SA and Contributors <contact@prestashop.com>
* @copyright Since 2007 PrestaShop SA and Contributors
* @license https://opensource.org/licenses/AFL-3.0 Academic Free License version 3.0
*/
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
header('Cache-Control: no-store, no-cache, must-revalidate');
header('Cache-Control: post-check=0, pre-check=0', false);
header('Pragma: no-cache');
header('Location: ../');
exit;

View File

@@ -0,0 +1,2 @@
imports:
- { resource: ../config.yml }

View File

@@ -0,0 +1,147 @@
services:
_defaults:
public: true
ps_accounts.module:
class: Ps_accounts
factory: ['Module', 'getInstanceByName']
arguments:
- 'ps_accounts'
ps_accounts.context:
class: Context
factory: [ 'Context', 'getContext' ]
PrestaShop\Module\PsAccounts\Context\ShopContext:
class: PrestaShop\Module\PsAccounts\Context\ShopContext
arguments:
- '@PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository'
- '@ps_accounts.context'
PrestaShop\Module\PsAccounts\Adapter\Configuration:
class: PrestaShop\Module\PsAccounts\Adapter\Configuration
arguments:
- '@ps_accounts.context'
PrestaShop\Module\PsAccounts\Adapter\Link:
class: PrestaShop\Module\PsAccounts\Adapter\Link
arguments:
- '@PrestaShop\Module\PsAccounts\Context\ShopContext'
#####################
# installer
PrestaShop\Module\PsAccounts\Installer\Installer:
class: PrestaShop\Module\PsAccounts\Installer\Installer
arguments:
- '@PrestaShop\Module\PsAccounts\Context\ShopContext'
- '@PrestaShop\Module\PsAccounts\Adapter\Link'
#####################
# services
PrestaShop\Module\PsAccounts\Service\ShopKeysService:
class: PrestaShop\Module\PsAccounts\Service\ShopKeysService
arguments:
- '@PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository'
PrestaShop\Module\PsAccounts\Service\ShopTokenService:
class: PrestaShop\Module\PsAccounts\Service\ShopTokenService
arguments:
- '@PrestaShop\Module\PsAccounts\Api\Client\FirebaseClient'
- '@PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository'
PrestaShop\Module\PsAccounts\Service\PsAccountsService:
class: PrestaShop\Module\PsAccounts\Service\PsAccountsService
arguments:
- '@ps_accounts.module'
- '@PrestaShop\Module\PsAccounts\Service\ShopTokenService'
- '@PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository'
- '@PrestaShop\Module\PsAccounts\Adapter\Link'
PrestaShop\Module\PsAccounts\Service\SsoService:
class: PrestaShop\Module\PsAccounts\Service\SsoService
arguments:
- { sso_resend_verification_email_url: '%ps_accounts.sso_resend_verification_email_url%',
sso_account_url: '%ps_accounts.sso_account_url%' }
PrestaShop\Module\PsAccounts\Service\ShopLinkAccountService:
class: PrestaShop\Module\PsAccounts\Service\ShopLinkAccountService
arguments:
- { accounts_ui_url: '%ps_accounts.svc_accounts_ui_url%' }
- '@PrestaShop\Module\PsAccounts\Provider\ShopProvider'
- '@PrestaShop\Module\PsAccounts\Service\ShopKeysService'
- '@PrestaShop\Module\PsAccounts\Service\ShopTokenService'
- '@PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository'
- '@PrestaShop\Module\PsAccounts\Adapter\Link'
PrestaShop\Module\PsAccounts\Service\PsBillingService:
class: PrestaShop\Module\PsAccounts\Service\PsBillingService
arguments:
- '@PrestaShop\Module\PsAccounts\Api\Client\ServicesBillingClient'
- '@PrestaShop\Module\PsAccounts\Service\ShopTokenService'
- '@PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository'
#####################
# providers
PrestaShop\Module\PsAccounts\Provider\ShopProvider:
class: PrestaShop\Module\PsAccounts\Provider\ShopProvider
arguments:
- '@PrestaShop\Module\PsAccounts\Context\ShopContext'
- '@PrestaShop\Module\PsAccounts\Adapter\Link'
#####################
# handlers
PrestaShop\Module\PsAccounts\Handler\Error\Sentry:
class: PrestaShop\Module\PsAccounts\Handler\Error\Sentry
arguments:
- '%ps_accounts.sentry_credentials%'
- '@=service("ps_accounts.module").getModuleEnv()'
- '@PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository'
###############
# api clients
PrestaShop\Module\PsAccounts\Api\Client\FirebaseClient:
class: PrestaShop\Module\PsAccounts\Api\Client\FirebaseClient
arguments:
- { api_key: '%ps_accounts.firebase_api_key%' }
PrestaShop\Module\PsAccounts\Api\Client\ServicesBillingClient:
class: PrestaShop\Module\PsAccounts\Api\Client\ServicesBillingClient
arguments:
- { api_url: '%ps_accounts.svc_billing_api_url%' }
- '@PrestaShop\Module\PsAccounts\Service\PsAccountsService'
- '@PrestaShop\Module\PsAccounts\Provider\ShopProvider'
- '@PrestaShop\Module\PsAccounts\Adapter\Link'
PrestaShop\Module\PsAccounts\Api\Client\ServicesAccountsClient:
class: PrestaShop\Module\PsAccounts\Api\Client\ServicesAccountsClient
arguments:
- { api_url: '%ps_accounts.svc_accounts_api_url%' }
- '@PrestaShop\Module\PsAccounts\Provider\ShopProvider'
- '@PrestaShop\Module\PsAccounts\Service\ShopTokenService'
- '@PrestaShop\Module\PsAccounts\Adapter\Link'
#####################
# repositories
PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository:
class: PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository
arguments:
- '@PrestaShop\Module\PsAccounts\Adapter\Configuration'
#####################
# presenters
PrestaShop\Module\PsAccounts\Presenter\PsAccountsPresenter:
class: PrestaShop\Module\PsAccounts\Presenter\PsAccountsPresenter
arguments:
- '@PrestaShop\Module\PsAccounts\Service\PsAccountsService'
- '@PrestaShop\Module\PsAccounts\Provider\ShopProvider'
- '@PrestaShop\Module\PsAccounts\Service\ShopLinkAccountService'
- '@PrestaShop\Module\PsAccounts\Service\SsoService'
- '@PrestaShop\Module\PsAccounts\Installer\Installer'
- '@PrestaShop\Module\PsAccounts\Repository\ConfigurationRepository'

View File

@@ -0,0 +1,10 @@
imports:
- { resource: common.yml }
parameters:
ps_accounts.firebase_api_key: 'AIzaSyBEm26bA2KR893rY68enLdVGpqnkoW2Juo'
ps_accounts.svc_accounts_api_url: 'https://accounts-api.psessentials.net'
ps_accounts.svc_accounts_ui_url: 'https://accounts.psessentials.net'
ps_accounts.svc_billing_api_url: 'https://billing-api.distribution.prestashop.net'
ps_accounts.sso_account_url: 'https://auth.prestashop.com/login'
ps_accounts.sso_resend_verification_email_url: 'https://auth.prestashop.com/account/send-verification-email'
ps_accounts.sentry_credentials: 'https://4c7f6c8dd5aa405b8401a35f5cf26ada@o298402.ingest.sentry.io/5354585'

View File

@@ -0,0 +1,19 @@
imports:
- { resource: common.yml }
parameters:
# In case you need to override with environment variables, you can follow this example :
# env(PS_ACCOUNTS_SENTRY_CREDENTIALS): 'https://4c7f6c8dd5aa405b8401a35f5cf26ada@o298402.ingest.sentry.io/5354585'
# sentry.credentials: '%env(string:PS_ACCOUNTS_SENTRY_CREDENTIALS)%'
#
# In order to manage multiple config files you can use PS_ACCOUNTS_ENV=[myenv] environment variable
# to load a specific services_[myenv].yml
# prestashop-ready-integration.firebaseapp.com
ps_accounts.firebase_api_key: 'AIzaSyASHFE2F08ncoOH9NhoCF8_6z7qnoLVKSA'
ps_accounts.svc_accounts_api_url: 'http://accounts-api:3000'
ps_accounts.svc_accounts_ui_url: 'http://localhost:8080'
ps_accounts.svc_billing_api_url: 'https://billing-api.psessentials-integration.net'
ps_accounts.sso_account_url: 'https://prestashop-newsso-staging.appspot.com/login'
ps_accounts.sso_resend_verification_email_url: 'https://prestashop-newsso-staging.appspot.com/account/send-verification-email'
ps_accounts.sentry_credentials: 'https://4c7f6c8dd5aa405b8401a35f5cf26ada@o298402.ingest.sentry.io/5354585'

View File

@@ -0,0 +1,28 @@
<?php
/**
* Copyright since 2007 PrestaShop SA and Contributors
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License version 3.0
* that is bundled with this package in the file LICENSE.md.
* It is also available through the world-wide-web at this URL:
* https://opensource.org/licenses/AFL-3.0
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* @author PrestaShop SA and Contributors <contact@prestashop.com>
* @copyright Since 2007 PrestaShop SA and Contributors
* @license https://opensource.org/licenses/AFL-3.0 Academic Free License version 3.0
*/
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
header('Cache-Control: no-store, no-cache, must-revalidate');
header('Cache-Control: post-check=0, pre-check=0', false);
header('Pragma: no-cache');
header('Location: ../');
exit;

View File

@@ -0,0 +1,2 @@
imports:
- { resource: ../config.yml }

View File

@@ -0,0 +1,28 @@
<?php
/**
* Copyright since 2007 PrestaShop SA and Contributors
* PrestaShop is an International Registered Trademark & Property of PrestaShop SA
*
* NOTICE OF LICENSE
*
* This source file is subject to the Academic Free License version 3.0
* that is bundled with this package in the file LICENSE.md.
* It is also available through the world-wide-web at this URL:
* https://opensource.org/licenses/AFL-3.0
* If you did not receive a copy of the license and are unable to
* obtain it through the world-wide-web, please send an email
* to license@prestashop.com so we can send you a copy immediately.
*
* @author PrestaShop SA and Contributors <contact@prestashop.com>
* @copyright Since 2007 PrestaShop SA and Contributors
* @license https://opensource.org/licenses/AFL-3.0 Academic Free License version 3.0
*/
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT');
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT');
header('Cache-Control: no-store, no-cache, must-revalidate');
header('Cache-Control: post-check=0, pre-check=0', false);
header('Pragma: no-cache');
header('Location: ../');
exit;