This repository has been archived by the owner on Nov 30, 2017. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 99
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Grid] Docs improvements accoring to upcoming changes
- ``sortable`` column option fix - sort column by multiple keys - general improvements
- Loading branch information
Showing
3 changed files
with
33 additions
and
1 deletion.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
Column configuration | ||
==================== | ||
|
||
Each column can be configured with several configuration fields, to make it more suitable to your grid requirements. | ||
|
||
+------------+------------+------------------------------------------------------------------------------------------------------------------------+ | ||
| Name | Type | Description | | ||
+============+============+========================================================================================================================+ | ||
| type | string | Type of column. Default column types are described `here </en/latest/bundles/SyliusGridBundle/column_types.html>`_. | | ||
+------------+------------+------------------------------------------------------------------------------------------------------------------------+ | ||
| label | string | Label displayed in column header. By default, it is column name. | | ||
+------------+------------+------------------------------------------------------------------------------------------------------------------------+ | ||
| sortable | bool | Whether column should be sortable or not. True by default. | | ||
+------------+------------+------------------------------------------------------------------------------------------------------------------------+ | ||
| options | array | Array of column options (see below). | | ||
+------------+------------+------------------------------------------------------------------------------------------------------------------------+ | ||
|
||
``options`` field can contains following fields: | ||
|
||
+------------+--------------+---------------------------------------------------------------------------------------------------------------------------+-------------+ | ||
| Name | Type | Description | Default | | ||
+============+==============+===========================================================================================================================+=============+ | ||
| template | string | Available (and required) for *twig* column type. Path to template that is used to render column value. | | | ||
+------------+--------------+---------------------------------------------------------------------------------------------------------------------------+-------------+ | ||
| path | string | Path to property displayed in column (can be property of resource or one of its referenced object). | column name | | ||
+------------+--------------+---------------------------------------------------------------------------------------------------------------------------+-------------+ | ||
| sort | string|array | One or more properties that will be used to column sorting (can be property of resource or one of its referenced object). | column name | | ||
+------------+--------------+---------------------------------------------------------------------------------------------------------------------------+-------------+ |
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