| @@ 73-85 (lines=13) @@ | ||
| 70 | /** |
|
| 71 | * {@inheritdoc} |
|
| 72 | */ |
|
| 73 | public function getBasicNodeData($nodeId, array $translations = null, bool $useAlwaysAvailable = true) |
|
| 74 | { |
|
| 75 | $q = $this->createNodeQueryBuilder($translations, $useAlwaysAvailable); |
|
| 76 | $q->andWhere( |
|
| 77 | $q->expr()->eq('t.node_id', $q->createNamedParameter($nodeId, PDO::PARAM_INT)) |
|
| 78 | ); |
|
| 79 | ||
| 80 | if ($row = $q->execute()->fetch(FetchMode::ASSOCIATIVE)) { |
|
| 81 | return $row; |
|
| 82 | } |
|
| 83 | ||
| 84 | throw new NotFound('location', $nodeId); |
|
| 85 | } |
|
| 86 | ||
| 87 | /** |
|
| 88 | * {@inheritdoc} |
|
| @@ 106-118 (lines=13) @@ | ||
| 103 | /** |
|
| 104 | * {@inheritdoc} |
|
| 105 | */ |
|
| 106 | public function getBasicNodeDataByRemoteId($remoteId, array $translations = null, bool $useAlwaysAvailable = true) |
|
| 107 | { |
|
| 108 | $q = $this->createNodeQueryBuilder($translations, $useAlwaysAvailable); |
|
| 109 | $q->andWhere( |
|
| 110 | $q->expr()->eq('t.remote_id', $q->createNamedParameter($remoteId, PDO::PARAM_STR)) |
|
| 111 | ); |
|
| 112 | ||
| 113 | if ($row = $q->execute()->fetch(FetchMode::ASSOCIATIVE)) { |
|
| 114 | return $row; |
|
| 115 | } |
|
| 116 | ||
| 117 | throw new NotFound('location', $remoteId); |
|
| 118 | } |
|
| 119 | ||
| 120 | /** |
|
| 121 | * Loads data for all Locations for $contentId, optionally only in the |
|