Skip to content

Commit 82f3b6e

Browse files
committed
browsing_content.md: Fix include_file indexes after merge
1 parent ee23889 commit 82f3b6e

File tree

1 file changed

+11
-12
lines changed

1 file changed

+11
-12
lines changed

docs/content_management/content_api/browsing_content.md

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,9 @@ You can also use it to request other Content-related value objects from various
2828
``` php hl_lines="10"
2929
// ...
3030
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 4, 5) =]]
31-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 18, 19) =]]
31+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 22, 24) =]]
3232
// ...
33-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 52, 54) =]][[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 60, 61) =]]
34-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 62, 68) =]]
33+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 57, 59) =]][[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 65, 73) =]]
3534
```
3635

3736

@@ -47,7 +46,7 @@ It provides you with basic content metadata such as modification and publication
4746
To get the locations of a content item you need to make use of the [`LocationService`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-LocationService.html):
4847

4948
``` php
50-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 70, 74) =]]
49+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 75, 79) =]] }
5150
```
5251

5352
[`LocationService::loadLocations`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-LocationService.html#method_loadLocations) uses `ContentInfo` to get all the locations of a content item.
@@ -61,29 +60,29 @@ The [`URLAliasService`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-C
6160
[`URLAliasService::reverseLookup`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-URLAliasService.html#method_reverseLookup) gets the location's main [URL alias](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-Values-Content-URLAlias.html):
6261

6362
``` php
64-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 70, 73) =]][[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 74, 77) =]]
63+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 75, 78) =]][[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 79, 82) =]]
6564
```
6665

6766
### Content type
6867

6968
You can retrieve the content type of a content item through the [`getContentType`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-Values-Content-ContentInfo.html#method_getContentType) method of the ContentInfo object:
7069

7170
``` php
72-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 79, 81) =]]
71+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 84, 86) =]]
7372
```
7473

7574
### Versions
7675

7776
To iterate over the versions of a content item, use the [`ContentService::loadVersions`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-ContentService.html#method_loadVersions) method, which returns an array of `VersionInfo` value objects.
7877

7978
``` php
80-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 83, 90) =]]
79+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 88, 94) =]]
8180
```
8281

8382
You can additionally provide the `loadVersions` method with the version status to get only versions of a specific status, for example:
8483

8584
``` php
86-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 90, 91) =]]
85+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 95, 96) =]]
8786
```
8887

8988
!!! note
@@ -100,7 +99,7 @@ This method loads only the specified subset of relations to improve performance
10099
You can get the current version's `VersionInfo` using [`ContentService::loadVersionInfo`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-ContentService.html#method_loadVersionInfo).
101100

102101
``` php
103-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 102, 113) =]]
102+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 107, 118) =]]
104103
```
105104

106105
You can also specify the version number as the second argument to get Relations for a specific version:
@@ -119,7 +118,7 @@ It also holds the [relation type](content_relations.md), and the optional field
119118
You can use the `getOwner` method of the `ContentInfo` object to load the content item's owner as a `User` value object.
120119

121120
``` php
122-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 115, 116) =]]
121+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 120, 121) =]]
123122
```
124123

125124
To get the creator of the current version and not the content item's owner, you need to use the `creatorId` property from the current version's `VersionInfo` object.
@@ -129,7 +128,7 @@ To get the creator of the current version and not the content item's owner, you
129128
You can find the section to which a content item belongs through the [`getSection`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-Values-Content-ContentInfo.html#method_getSection) method of the ContentInfo object:
130129

131130
``` php
132-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 118, 119) =]]
131+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 123, 124) =]]
133132
```
134133

135134
!!! note
@@ -144,7 +143,7 @@ You need to provide it with the object state group.
144143
All object state groups can be retrieved through [`loadObjectStateGroups`](/api/php_api/php_api_reference/classes/Ibexa-Contracts-Core-Repository-ObjectStateService.html#method_loadObjectStateGroups).
145144

146145
``` php
147-
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 121, 126) =]]
146+
[[= include_file('code_samples/api/public_php_api/src/Command/ViewContentMetaDataCommand.php', 126, 131) =]]
148147
```
149148

150149
## Viewing content with fields

0 commit comments

Comments
 (0)