-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
FRW-7936 Allow to provide store name as part of URL path. (#11121)
FRW-7936 Allow to provide store name as part of URL path.
- Loading branch information
1 parent
fbbc2f4
commit fac365d
Showing
14 changed files
with
260 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
34 changes: 34 additions & 0 deletions
34
src/Spryker/Yves/Router/Dependency/Client/RouterToStoreClientBridge.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright © 2016-present Spryker Systems GmbH. All rights reserved. | ||
* Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file. | ||
*/ | ||
|
||
namespace Spryker\Yves\Router\Dependency\Client; | ||
|
||
use Generated\Shared\Transfer\StoreTransfer; | ||
|
||
class RouterToStoreClientBridge implements RouterToStoreClientInterface | ||
{ | ||
/** | ||
* @var \Spryker\Client\Store\StoreClientInterface | ||
*/ | ||
protected $storeClient; | ||
|
||
/** | ||
* @param \Spryker\Client\Store\StoreClientInterface $storeClient | ||
*/ | ||
public function __construct($storeClient) | ||
{ | ||
$this->storeClient = $storeClient; | ||
} | ||
|
||
/** | ||
* @return \Generated\Shared\Transfer\StoreTransfer | ||
*/ | ||
public function getCurrentStore(): StoreTransfer | ||
{ | ||
return $this->storeClient->getCurrentStore(); | ||
} | ||
} |
18 changes: 18 additions & 0 deletions
18
src/Spryker/Yves/Router/Dependency/Client/RouterToStoreClientInterface.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
<?php | ||
|
||
/** | ||
* Copyright © 2016-present Spryker Systems GmbH. All rights reserved. | ||
* Use of this software requires acceptance of the Evaluation License Agreement. See LICENSE file. | ||
*/ | ||
|
||
namespace Spryker\Yves\Router\Dependency\Client; | ||
|
||
use Generated\Shared\Transfer\StoreTransfer; | ||
|
||
interface RouterToStoreClientInterface | ||
{ | ||
/** | ||
* @return \Generated\Shared\Transfer\StoreTransfer | ||
*/ | ||
public function getCurrentStore(): StoreTransfer; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.