Skip to content

Commit 13e40bc

Browse files
stlgaitsgitbook-bot
authored andcommitted
GITBOOK-28: Estelle's Oct 16 changes - replace PHP legacy with "config file" for clarity in tabs
1 parent 884b5df commit 13e40bc

File tree

1 file changed

+16
-16
lines changed

1 file changed

+16
-16
lines changed

docs/grid/your_first_grid.md

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ This command will generate a grid with a field entry for each of your PHP class
4242
Now we can configure our first grid:
4343

4444
{% tabs %}
45-
{% tab title="PHP service" %}
45+
{% tab title="PHP (recommended)" %}
4646
{% code title="/src/Grid/AdminSupplierGrid.php" lineNumbers="true" %}
4747
```php
4848
<?php
@@ -82,7 +82,7 @@ final class AdminSupplierGrid extends AbstractGrid
8282
{% endcode %}
8383
{% endtab %}
8484

85-
{% tab title="PHP config file (legacy)" %}
85+
{% tab title="PHP config file" %}
8686
{% code lineNumbers="true" %}
8787
```php
8888
<?php
@@ -236,7 +236,7 @@ Now, your new grid should look like this when accessing the index on _/admin/sup
236236
To allow users to search for specific items in the grid, you can use filters.
237237

238238
{% tabs %}
239-
{% tab title="PHP service" %}
239+
{% tab title="PHP (recommended)" %}
240240
{% code title="src/Grid/AdminSupplierGrid.php" lineNumbers="true" %}
241241
```php
242242
<?php
@@ -275,7 +275,7 @@ final class AdminSupplierGrid extends AbstractGrid
275275
{% endcode %}
276276
{% endtab %}
277277

278-
{% tab title="PHP (legacy)" %}
278+
{% tab title="PHP config file" %}
279279
{% code lineNumbers="true" %}
280280
```php
281281
<?php
@@ -337,7 +337,7 @@ There are 2 ways you can do this :&#x20;
337337
#### Custom repository method (Doctrine-only)
338338

339339
{% tabs %}
340-
{% tab title="PHP service" %}
340+
{% tab title="PHP (recommended)" %}
341341
{% code title="src/Grid/AdminSupplierGrid.php" lineNumbers="true" %}
342342
```php
343343
<?php
@@ -367,7 +367,7 @@ final class AdminSupplierGrid extends AbstractGrid
367367
{% endcode %}
368368
{% endtab %}
369369

370-
{% tab title="PHP (legacy)" %}
370+
{% tab title="PHP config file" %}
371371
{% code title="config/packages/sylius_grid.php" lineNumbers="true" %}
372372
```php
373373
<?php
@@ -520,7 +520,7 @@ final class SupplierRepository extends DoctrineRepository
520520
Then you can simply insert your filter inside the grid.
521521

522522
{% tabs %}
523-
{% tab title="PHP " %}
523+
{% tab title="PHP (recommended)" %}
524524
{% code title="src/Grid/AdminSupplierGrid.php" lineNumbers="true" %}
525525
```php
526526
<?php
@@ -559,7 +559,7 @@ final class AdminSupplierGrid extends AbstractGrid
559559
{% endcode %}
560560
{% endtab %}
561561

562-
{% tab title="PHP (legacy)" %}
562+
{% tab title="PHP config file" %}
563563
{% code title="config/packages/sylius_grid.php" lineNumbers="true" %}
564564
```php
565565
<?php
@@ -607,7 +607,7 @@ sylius_grid:
607607
You can define by which field you want the grid to be sorted and how using `orderBy()` .
608608

609609
{% tabs %}
610-
{% tab title="PHP service" %}
610+
{% tab title="PHP (recommended)" %}
611611
{% code title="src/Grid/AdminSupplierGrid.php" lineNumbers="true" %}
612612
```php
613613
<?php
@@ -639,7 +639,7 @@ final class AdminSupplierGrid extends AbstractGrid
639639

640640
{% endtab %}
641641

642-
{% tab title="PHP (legacy)" %}
642+
{% tab title="PHP config file" %}
643643
{% code title="config/packages/sylius_grid.php" lineNumbers="true" %}
644644
```php
645645
<?php
@@ -675,7 +675,7 @@ sylius_grid:
675675
Then in the fields section, indicate that the field can be used for sorting with `setSortable()`:
676676

677677
{% tabs %}
678-
{% tab title="PHP" %}
678+
{% tab title="PHP (recommended)" %}
679679
{% code title="src/Grid/AdminSupplierGrid.php" lineNumbers="true" %}
680680
```php
681681
<?php
@@ -712,7 +712,7 @@ final class AdminSupplierGrid extends AbstractGrid
712712
{% endcode %}
713713
{% endtab %}
714714

715-
{% tab title="PHP (legacy)" %}
715+
{% tab title="PHP config file" %}
716716
{% code title="config/packages/sylius_grid.php" lineNumbers="true" %}
717717
```php
718718
<?php
@@ -758,7 +758,7 @@ sylius_grid:
758758
If your field is not of a "simple" type, e.g. a Twig template with a specific path, you can enable sorting with the following definition:
759759

760760
{% tabs %}
761-
{% tab title="PHP" %}
761+
{% tab title="PHP (recommended)" %}
762762
{% code title="src/Grid/AdminSupplierGrid.php" lineNumbers="true" %}
763763
```php
764764
<?php
@@ -795,7 +795,7 @@ final class AdminSupplierGrid extends AbstractGrid
795795
{% endcode %}
796796
{% endtab %}
797797

798-
{% tab title="PHP (legacy)" %}
798+
{% tab title="PHP config file" %}
799799
{% code title="config/packages/sylius_grid.php" lineNumbers="true" %}
800800
```php
801801
<?php
@@ -937,7 +937,7 @@ There are two types of actions that can be added to a grid:&#x20;
937937
{% endhint %}
938938

939939
{% tabs %}
940-
{% tab title="PHP" %}
940+
{% tab title="PHP (recommended)" %}
941941
{% code title="src/Grid/AdminSupplierGrid.php" lineNumbers="true" %}
942942
```php
943943
<?php
@@ -983,7 +983,7 @@ final class AdminSupplierGrid extends AbstractGrid
983983
{% endcode %}
984984
{% endtab %}
985985

986-
{% tab title="PHP (legacy)" %}
986+
{% tab title="PHP config file" %}
987987
{% code title="config/packages/sylius_grid.php" lineNumbers="true" %}
988988
```php
989989
<?php

0 commit comments

Comments
 (0)