Skip to content
This repository was archived by the owner on Sep 16, 2021. It is now read-only.

Commit 004ad59

Browse files
committed
Merge pull request #286 from symfony-cmf/ref_partials
Refactored common ref blocks to partials
2 parents 141fd9a + 37d5fbf commit 004ad59

File tree

9 files changed

+66
-319
lines changed

9 files changed

+66
-319
lines changed

reference/configuration/block.rst

Lines changed: 2 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -109,53 +109,7 @@ is the following configuration:
109109
enabled
110110
"""""""
111111

112-
**type**: ``boolean`` **default**: ``false``
113-
114-
If ``true``, PHPCR is enabled in the service container.
115-
116-
If the :doc:`CoreBundle <../../bundles/core/index>` is registered, this will default to
117-
the value of ``cmf_core.persistence.phpcr.enabled``.
118-
119-
PHPCR can be enabled by multiple ways such as:
120-
121-
.. configuration-block::
122-
123-
.. code-block:: yaml
124-
125-
phpcr: ~ # use default configuration
126-
# or
127-
phpcr: true # straight way
128-
# or
129-
phpcr:
130-
manager_name: ... # or any other option under 'phpcr'
131-
132-
.. code-block:: xml
133-
134-
<persistence>
135-
<!-- use default configuration -->
136-
<phpcr />
137-
138-
<!-- or setting it the straight way -->
139-
<phpcr>true</phpcr>
140-
141-
<!-- or setting an option under 'phpcr' -->
142-
<phpcr manager-name="..." />
143-
</persistence>
144-
145-
.. code-block:: php
146-
147-
$container->loadFromExtension('cmf_block', array(
148-
// ...
149-
'persistence' => array(
150-
'phpcr' => null, // use default configuration
151-
// or
152-
'phpcr' => true, // straight way
153-
// or
154-
'phpcr' => array(
155-
'manager_name' => '...', // or any other option under 'phpcr'
156-
),
157-
),
158-
));
112+
.. include:: partials/persistence_phpcr_enabled.rst.inc
159113

160114
block_basepath
161115
""""""""""""""
@@ -170,13 +124,7 @@ the value of ``%cmf_core.persistence.phpcr.basepath%/content``.
170124
manager_name
171125
""""""""""""
172126

173-
**type**: ``string`` **default**: ``null``
174-
175-
The name of the Doctrine Manager to use. ``null`` tells the manager registry to
176-
retrieve the default manager.<persistence>
177-
178-
If the :doc:`CoreBundle <../../bundles/core/index>` is registered, this will default to
179-
the value of ``cmf_core.persistence.phpcr.manager_name``.
127+
.. include:: partials/persistence_phpcr_manager_name.rst.inc
180128

181129
simple_document_class
182130
"""""""""""""""""""""

reference/configuration/content.rst

Lines changed: 1 addition & 47 deletions
Original file line numberDiff line numberDiff line change
@@ -74,53 +74,7 @@ is the following configuration:
7474
enabled
7575
*******
7676

77-
**type**: ``boolean`` **default**: ``false``
78-
79-
If ``true``, PHPCR is enabled in the service container.
80-
81-
If the :doc:`CoreBundle <../../bundles/core/index>` is registered, this will default to
82-
the value of ``cmf_core.persistence.phpcr.enabled``.
83-
84-
PHPCR can be enabled by multiple ways such as:
85-
86-
.. configuration-block::
87-
88-
.. code-block:: yaml
89-
90-
phpcr: ~ # use default configuration
91-
# or
92-
phpcr: true # straight way
93-
# or
94-
phpcr:
95-
manager: ... # or any other option under 'phpcr'
96-
97-
.. code-block:: xml
98-
99-
<persistence>
100-
<!-- use default configuration -->
101-
<phpcr />
102-
103-
<!-- or setting it the straight way -->
104-
<phpcr>true</phpcr>
105-
106-
<!-- or setting an option under 'phpcr' -->
107-
<phpcr manager="..." />
108-
</persistence>
109-
110-
.. code-block:: php
111-
112-
$container->loadFromExtension('cmf_simple_cms', array(
113-
// ...
114-
'persistence' => array(
115-
'phpcr' => null, // use default configuration
116-
// or
117-
'phpcr' => true, // straight way
118-
// or
119-
'phpcr' => array(
120-
'manager' => '...', // or any other option under 'phpcr'
121-
),
122-
),
123-
));
77+
.. include:: partials/persistence_phpcr_enabled.rst.inc
12478

12579
admin_class
12680
***********

reference/configuration/core.rst

Lines changed: 1 addition & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -71,9 +71,7 @@ is the following configuration:
7171
enabled
7272
"""""""
7373

74-
**type**: ``boolean`` **default**: ``false``
75-
76-
If ``true``, PHPCR is enabled in the service container.
74+
.. include:: partials/persistence_phpcr_enabled.rst.inc
7775

7876
Enabling this setting will also automatically enable the equivalent setting in the following Bundles:
7977

@@ -87,47 +85,6 @@ Enabling this setting will also automatically enable the equivalent setting in t
8785
* :doc:`SimpleCmsBundle <../../bundles/simple_cms/introduction>`
8886
* :doc:`TreeBrowserCmsBundle <../../bundles/tree_browser>`
8987

90-
PHPCR can be enabled by multiple ways such as:
91-
92-
.. configuration-block::
93-
94-
.. code-block:: yaml
95-
96-
phpcr: ~ # use default configuration
97-
# or
98-
phpcr: true # straight way
99-
# or
100-
phpcr:
101-
manager: ... # or any other option under 'phpcr'
102-
103-
.. code-block:: xml
104-
105-
<persistence>
106-
<!-- use default configuration -->
107-
<phpcr />
108-
109-
<!-- or setting it the straight way -->
110-
<phpcr>true</phpcr>
111-
112-
<!-- or setting an option under 'phpcr' -->
113-
<phpcr manager="..." />
114-
</persistence>
115-
116-
.. code-block:: php
117-
118-
$container->loadFromExtension('cmf_core', array(
119-
// ...
120-
'persistence' => array(
121-
'phpcr' => null, // use default configuration
122-
// or
123-
'phpcr' => true, // straight way
124-
// or
125-
'phpcr' => array(
126-
'manager' => '...', // or any other option under 'phpcr'
127-
),
128-
),
129-
));
130-
13188
basepath
13289
""""""""
13390

reference/configuration/media.rst

Lines changed: 2 additions & 54 deletions
Original file line numberDiff line numberDiff line change
@@ -77,53 +77,7 @@ is the following configuration:
7777
enabled
7878
"""""""
7979

80-
**type**: ``boolean`` **default**: ``false``
81-
82-
If ``true``, PHPCR is enabled in the service container.
83-
84-
If the :doc:`CoreBundle <../../bundles/core/index>` is registered, this will default to
85-
the value of ``cmf_core.persistence.phpcr.enabled``.
86-
87-
PHPCR can be enabled by multiple ways such as:
88-
89-
.. configuration-block::
90-
91-
.. code-block:: yaml
92-
93-
phpcr: ~ # use default configuration
94-
# or
95-
phpcr: true # straight way
96-
# or
97-
phpcr:
98-
manager_name: ... # or any other option under 'phpcr'
99-
100-
.. code-block:: xml
101-
102-
<persistence>
103-
<!-- use default configuration -->
104-
<phpcr />
105-
106-
<!-- or setting it the straight way -->
107-
<phpcr>true</phpcr>
108-
109-
<!-- or setting an option under 'phpcr' -->
110-
<phpcr manager-name="..." />
111-
</persistence>
112-
113-
.. code-block:: php
114-
115-
$container->loadFromExtension('cmf_block', array(
116-
// ...
117-
'persistence' => array(
118-
'phpcr' => null, // use default configuration
119-
// or
120-
'phpcr' => true, // straight way
121-
// or
122-
'phpcr' => array(
123-
'manager_name' => '...', // or any other option under 'phpcr'
124-
),
125-
),
126-
));
80+
.. include:: partials/persistence_phpcr_enabled.rst.inc
12781

12882
media_basepath
12983
""""""""""""""
@@ -138,13 +92,7 @@ the value of ``%cmf_core.persistence.phpcr.basepath%/media``.
13892
manager_name
13993
""""""""""""
14094

141-
**type**: ``string`` **default**: ``null``
142-
143-
The name of the Doctrine Manager to use. ``null`` tells the manager registry to
144-
retrieve the default manager.<persistence>
145-
146-
If the :doc:`CoreBundle <../../bundles/core/index>` is registered, this will default to
147-
the value of ``cmf_core.persistence.phpcr.manager_name``.
95+
.. include:: partials/persistence_phpcr_manager_name.rst.inc
14896

14997
media_class
15098
"""""""""""
Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,47 @@
1+
**type**: ``boolean`` **default**: ``false``
2+
3+
If ``true``, PHPCR is enabled in the service container.
4+
5+
If the :doc:`CoreBundle <../../bundles/core/index>` is registered, this will default to
6+
the value of ``cmf_core.persistence.phpcr.enabled``.
7+
8+
PHPCR can be enabled by multiple ways such as:
9+
10+
.. configuration-block::
11+
12+
.. code-block:: yaml
13+
14+
phpcr: ~ # use default configuration
15+
# or
16+
phpcr: true # straight way
17+
# or
18+
phpcr:
19+
manager: ... # or any other option under 'phpcr'
20+
21+
.. code-block:: xml
22+
23+
<persistence>
24+
<!-- use default configuration -->
25+
<phpcr />
26+
27+
<!-- or setting it the straight way -->
28+
<phpcr>true</phpcr>
29+
30+
<!-- or setting an option under 'phpcr' -->
31+
<phpcr manager="..." />
32+
</persistence>
33+
34+
.. code-block:: php
35+
36+
$container->loadFromExtension(..., array( // bundle configuration key, e.g. cmf_menu
37+
// ...
38+
'persistence' => array(
39+
'phpcr' => null, // use default configuration
40+
// or
41+
'phpcr' => true, // straight way
42+
// or
43+
'phpcr' => array(
44+
'manager' => '...', // or any other option under 'phpcr'
45+
),
46+
),
47+
));
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
**type**: ``string`` **default**: ``null``
2+
3+
The name of the Doctrine Manager to use. ``null`` tells the manager registry to
4+
retrieve the default manager.<persistence>
5+
6+
If the :doc:`CoreBundle <../../bundles/core/index>` is registered, this will default to
7+
the value of ``cmf_core.persistence.phpcr.manager_name``.

reference/configuration/routing.rst

Lines changed: 2 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -335,22 +335,12 @@ phpcr
335335
enabled
336336
*******
337337

338-
**type**: ``boolean`` **default**: ``false``
339-
340-
If ``true``, PHPCR is enabled in the service container.
341-
342-
If the :doc:`CoreBundle <../../bundles/core/index>` is registered, this will default to
343-
the value of ``cmf_core.persistence.phpcr.enabled``.
338+
.. include:: partials/persistence_phpcr_enabled.rst.inc
344339

345340
manager_name
346341
************
347342

348-
**type**: ``string`` **default**: ``null``
349-
350-
The name of the Doctrine Manager to use.
351-
352-
If the :doc:`CoreBundle <../../bundles/core/index>` is registered, this will default to
353-
the value of ``cmf_core.persistence.phpcr.manager_name``.
343+
.. include:: partials/persistence_phpcr_manager_name.rst.inc
354344

355345
route_basepath
356346
**************

0 commit comments

Comments
 (0)