Skip to content

Commit

Permalink
refactor #769 Move some namespaces on Grid (loic425)
Browse files Browse the repository at this point in the history
This PR was merged into the 1.11 branch.

Discussion
----------

| Q               | A
| --------------- | -----
| Bug fix?        | no
| New feature?    | no
| BC breaks?      | no
| Deprecations?   | no
| Related tickets | 
| License         | MIT


Commits
-------

93bb4bf Move some namespaces on Grid
f6caa4b Fix Phpspec tests
  • Loading branch information
lchrusciel authored Nov 7, 2023
2 parents 37ad1b4 + f6caa4b commit 08b7ee1
Show file tree
Hide file tree
Showing 11 changed files with 15 additions and 15 deletions.
2 changes: 1 addition & 1 deletion src/Bundle/Grid/View/LegacyGridViewFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
use Sylius\Component\Grid\Definition\Grid;
use Sylius\Component\Grid\Parameters;
use Sylius\Component\Grid\View\GridView;
use Sylius\Component\Resource\Grid\View\Factory\GridViewFactoryInterface;
use Sylius\Resource\Context\Context;
use Sylius\Resource\Context\Option\MetadataOption;
use Sylius\Resource\Grid\View\Factory\GridViewFactoryInterface;

final class LegacyGridViewFactory implements GridViewFactoryInterface
{
Expand Down
4 changes: 2 additions & 2 deletions src/Bundle/Resources/config/services/integrations/grid.xml
Original file line number Diff line number Diff line change
Expand Up @@ -61,9 +61,9 @@
<argument type="service" id=".inner" />
</service>

<service id="sylius.grid.view_factory.resource" class="Sylius\Component\Resource\Grid\View\Factory\GridViewFactory">
<service id="sylius.grid.view_factory.resource" class="Sylius\Resource\Grid\View\Factory\GridViewFactory">
<argument type="service" id="sylius.grid.data_provider" />
</service>
<service id="Sylius\Component\Resource\Grid\View\Factory\GridViewFactoryInterface" alias="sylius.grid.view_factory.resource" />
<service id="Sylius\Resource\Grid\View\Factory\GridViewFactoryInterface" alias="sylius.grid.view_factory.resource" />
</services>
</container>
2 changes: 1 addition & 1 deletion src/Bundle/Resources/config/services/state.xml
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@
<tag name="sylius.state_responder" />
</service>

<service id="Sylius\Component\Resource\Grid\State\RequestGridProvider">
<service id="Sylius\Resource\Grid\State\RequestGridProvider">
<argument type="service" id="sylius.grid.view_factory.resource" on-invalid="null" />
<argument type="service" id="sylius.grid.service_grid_provider" on-invalid="null" />
<tag name="sylius.state_provider" />
Expand Down
2 changes: 1 addition & 1 deletion src/Bundle/spec/Grid/View/LegacyGridViewFactorySpec.php
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,10 @@
use Sylius\Component\Grid\Definition\Grid;
use Sylius\Component\Grid\Parameters;
use Sylius\Component\Grid\View\GridView;
use Sylius\Component\Resource\Grid\View\Factory\GridViewFactoryInterface;
use Sylius\Component\Resource\Metadata\MetadataInterface;
use Sylius\Resource\Context\Context;
use Sylius\Resource\Context\Option\MetadataOption;
use Sylius\Resource\Grid\View\Factory\GridViewFactoryInterface;

final class LegacyGridViewFactorySpec extends ObjectBehavior
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@

namespace Sylius\Component\Resource\Metadata\Resource\Factory;

use Sylius\Component\Resource\Grid\State\RequestGridProvider;
use Sylius\Component\Resource\Metadata\GridAwareOperationInterface;
use Sylius\Component\Resource\Metadata\Operation;
use Sylius\Component\Resource\Metadata\Operations;
use Sylius\Component\Resource\Metadata\Resource\ResourceMetadataCollection;
use Sylius\Component\Resource\Metadata\ResourceMetadata;
use Sylius\Component\Resource\Symfony\Request\State\Provider;
use Sylius\Resource\Grid\State\RequestGridProvider;

final class ProviderResourceMetadataCollectionFactory implements ResourceMetadataCollectionFactoryInterface
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@
namespace spec\Sylius\Component\Resource\Metadata\Resource\Factory;

use PhpSpec\ObjectBehavior;
use Sylius\Component\Resource\Grid\State\RequestGridProvider;
use Sylius\Component\Resource\Metadata\Index;
use Sylius\Component\Resource\Metadata\Operations;
use Sylius\Component\Resource\Metadata\Resource\Factory\ProviderResourceMetadataCollectionFactory;
use Sylius\Component\Resource\Metadata\Resource\Factory\ResourceMetadataCollectionFactoryInterface;
use Sylius\Component\Resource\Metadata\Resource\ResourceMetadataCollection;
use Sylius\Component\Resource\Metadata\ResourceMetadata;
use Sylius\Component\Resource\Symfony\Request\State\Provider;
use Sylius\Resource\Grid\State\RequestGridProvider;

final class ProviderResourceMetadataCollectionFactorySpec extends ObjectBehavior
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,16 +11,16 @@

declare(strict_types=1);

namespace Sylius\Component\Resource\Grid\State;
namespace Sylius\Resource\Grid\State;

use Pagerfanta\Pagerfanta;
use Sylius\Component\Grid\Parameters;
use Sylius\Component\Grid\Provider\GridProviderInterface;
use Sylius\Component\Resource\Grid\View\Factory\GridViewFactoryInterface;
use Sylius\Component\Resource\Metadata\GridAwareOperationInterface;
use Sylius\Component\Resource\Metadata\Operation;
use Sylius\Resource\Context\Context;
use Sylius\Resource\Context\Option\RequestOption;
use Sylius\Resource\Grid\View\Factory\GridViewFactoryInterface;
use Sylius\Resource\State\ProviderInterface;

final class RequestGridProvider implements ProviderInterface
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

declare(strict_types=1);

namespace Sylius\Component\Resource\Grid\View\Factory;
namespace Sylius\Resource\Grid\View\Factory;

use Sylius\Component\Grid\Data\DataProviderInterface;
use Sylius\Component\Grid\Definition\Grid;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

declare(strict_types=1);

namespace Sylius\Component\Resource\Grid\View\Factory;
namespace Sylius\Resource\Grid\View\Factory;

use Sylius\Component\Grid\Definition\Grid;
use Sylius\Component\Grid\Parameters;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,20 +11,20 @@

declare(strict_types=1);

namespace spec\Sylius\Component\Resource\Grid\State;
namespace spec\Sylius\Resource\Grid\State;

use Pagerfanta\Pagerfanta;
use PhpSpec\ObjectBehavior;
use Sylius\Component\Grid\Definition\Grid;
use Sylius\Component\Grid\Parameters;
use Sylius\Component\Grid\Provider\GridProviderInterface;
use Sylius\Component\Grid\View\GridView;
use Sylius\Component\Resource\Grid\State\RequestGridProvider;
use Sylius\Component\Resource\Grid\View\Factory\GridViewFactoryInterface;
use Sylius\Component\Resource\Metadata\Create;
use Sylius\Component\Resource\Metadata\Index;
use Sylius\Resource\Context\Context;
use Sylius\Resource\Context\Option\RequestOption;
use Sylius\Resource\Grid\State\RequestGridProvider;
use Sylius\Resource\Grid\View\Factory\GridViewFactoryInterface;
use Symfony\Component\HttpFoundation\InputBag;
use Symfony\Component\HttpFoundation\Request;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,9 @@

namespace App\BoardGameBlog\Infrastructure\Sylius\State\Http\Provider;

use Sylius\Component\Resource\Grid\State\RequestGridProvider;
use Sylius\Component\Resource\Metadata\Operation;
use Sylius\Resource\Context\Context;
use Sylius\Resource\Grid\State\RequestGridProvider;
use Sylius\Resource\State\ProviderInterface;

final class BoardGameCollectionProvider implements ProviderInterface
Expand Down

0 comments on commit 08b7ee1

Please sign in to comment.