@@ -222,9 +222,9 @@ discard block |
||
| 222 | 222 | return $this; |
| 223 | 223 | } |
| 224 | 224 | |
| 225 | - /** |
|
| 226 | - * {@inheritedoc} |
|
| 227 | - */ |
|
| 225 | + /** |
|
| 226 | + * {@inheritedoc} |
|
| 227 | + */ |
|
| 228 | 228 | public function sequence(string $sequence): self |
| 229 | 229 | { |
| 230 | 230 | $this->sequence = $sequence; |
@@ -252,9 +252,9 @@ discard block |
||
| 252 | 252 | return $this; |
| 253 | 253 | } |
| 254 | 254 | |
| 255 | - /** |
|
| 256 | - * {@inheritedoc} |
|
| 257 | - */ |
|
| 255 | + /** |
|
| 256 | + * {@inheritedoc} |
|
| 257 | + */ |
|
| 258 | 258 | public function guarded(array $columns): self |
| 259 | 259 | { |
| 260 | 260 | $this->guarded = $columns; |
@@ -314,9 +314,9 @@ discard block |
||
| 314 | 314 | unset($this->columns[$name]); |
| 315 | 315 | } |
| 316 | 316 | |
| 317 | - /** |
|
| 318 | - * {@inheritedoc} |
|
| 319 | - */ |
|
| 317 | + /** |
|
| 318 | + * {@inheritedoc} |
|
| 319 | + */ |
|
| 320 | 320 | public function hasColumn(string $column): bool |
| 321 | 321 | { |
| 322 | 322 | return array_key_exists($column, $this->columns) |
@@ -349,9 +349,9 @@ discard block |
||
| 349 | 349 | $this->rawColumns[$name] = $value; |
| 350 | 350 | } |
| 351 | 351 | |
| 352 | - /** |
|
| 353 | - * {@inheritedoc} |
|
| 354 | - */ |
|
| 352 | + /** |
|
| 353 | + * {@inheritedoc} |
|
| 354 | + */ |
|
| 355 | 355 | public function getRelated(string $name, callable $callback = null) |
| 356 | 356 | { |
| 357 | 357 | if (array_key_exists($name, $this->relations)) { |
@@ -97,12 +97,12 @@ discard block |
||
| 97 | 97 | } |
| 98 | 98 | |
| 99 | 99 | /** |
| 100 | - * |
|
| 101 | - * @param DataMapper $mapper |
|
| 102 | - * @param Entity $entity |
|
| 103 | - * |
|
| 104 | - * @return bool |
|
| 105 | - */ |
|
| 100 | + * |
|
| 101 | + * @param DataMapper $mapper |
|
| 102 | + * @param Entity $entity |
|
| 103 | + * |
|
| 104 | + * @return bool |
|
| 105 | + */ |
|
| 106 | 106 | public function link(DataMapper $mapper, Entity $entity): bool |
| 107 | 107 | { |
| 108 | 108 | $manager = $mapper->getEntityManager(); |
@@ -375,7 +375,7 @@ discard block |
||
| 375 | 375 | } |
| 376 | 376 | }); |
| 377 | 377 | |
| 378 | - $foreignKeys = $this->foreignKey->getValue($mapper->getRawColumns(), true); |
|
| 378 | + $foreignKeys = $this->foreignKey->getValue($mapper->getRawColumns(), true); |
|
| 379 | 379 | if (is_array($foreignKeys)) { |
| 380 | 380 | foreach ($foreignKeys as $fkColumn => $value) { |
| 381 | 381 | $select->where($junctionTable . '.' . $fkColumn)->is($value); |
@@ -189,9 +189,9 @@ |
||
| 189 | 189 | } |
| 190 | 190 | |
| 191 | 191 | /** |
| 192 | - * Map the entity information |
|
| 193 | - * @param EntityMapperInterface $mapper |
|
| 194 | - */ |
|
| 192 | + * Map the entity information |
|
| 193 | + * @param EntityMapperInterface $mapper |
|
| 194 | + */ |
|
| 195 | 195 | abstract public static function mapEntity(EntityMapperInterface $mapper): void; |
| 196 | 196 | |
| 197 | 197 | /** |
@@ -139,8 +139,8 @@ discard block |
||
| 139 | 139 | public function get(array $columns = [], bool $primaryColumn = true): ?Entity |
| 140 | 140 | { |
| 141 | 141 | $result = $this->query($columns, $primaryColumn) |
| 142 | - ->fetchAssoc() |
|
| 143 | - ->get(); |
|
| 142 | + ->fetchAssoc() |
|
| 143 | + ->get(); |
|
| 144 | 144 | |
| 145 | 145 | if ($result === false) { |
| 146 | 146 | return null; |
@@ -289,11 +289,11 @@ discard block |
||
| 289 | 289 | } |
| 290 | 290 | |
| 291 | 291 | /** |
| 292 | - * Find entities record using primary key values |
|
| 293 | - * @param mixed ...$ids |
|
| 294 | - * |
|
| 295 | - * @return array<int, Entity> |
|
| 296 | - */ |
|
| 292 | + * Find entities record using primary key values |
|
| 293 | + * @param mixed ...$ids |
|
| 294 | + * |
|
| 295 | + * @return array<int, Entity> |
|
| 296 | + */ |
|
| 297 | 297 | public function findAll(...$ids): array |
| 298 | 298 | { |
| 299 | 299 | if (is_array($ids[0])) { |
@@ -526,6 +526,6 @@ discard block |
||
| 526 | 526 | protected function transaction(Closure $callback) |
| 527 | 527 | { |
| 528 | 528 | return $this->manager->getConnection() |
| 529 | - ->transaction($callback); |
|
| 529 | + ->transaction($callback); |
|
| 530 | 530 | } |
| 531 | 531 | } |
@@ -155,7 +155,7 @@ |
||
| 155 | 155 | |
| 156 | 156 | if ($this->offset >= 0 && $this->limit >= 0) { |
| 157 | 157 | $query->offset($this->offset) |
| 158 | - ->limit($this->limit); |
|
| 158 | + ->limit($this->limit); |
|
| 159 | 159 | |
| 160 | 160 | $this->offset = -1; |
| 161 | 161 | $this->limit = 0; |