src/services/ModelAccessorByHandle.php 1 location
|
@@ 41-52 (lines=12) @@
|
| 38 |
|
* @param string $toScenario |
| 39 |
|
* @return Model|ModelWithHandle|null |
| 40 |
|
*/ |
| 41 |
|
public function find($identifier, string $toScenario = null) |
| 42 |
|
{ |
| 43 |
|
|
| 44 |
|
if (is_string($identifier)) { |
| 45 |
|
|
| 46 |
|
return $this->findByHandle($identifier, $toScenario); |
| 47 |
|
|
| 48 |
|
} |
| 49 |
|
|
| 50 |
|
return parent::find($identifier, $toScenario); |
| 51 |
|
|
| 52 |
|
} |
| 53 |
|
|
| 54 |
|
|
| 55 |
|
/******************************************* |
src/services/ObjectAccessorByHandle.php 1 location
|
@@ 33-44 (lines=12) @@
|
| 30 |
|
* @param string $toScenario |
| 31 |
|
* @return Object|ObjectWithHandle|null |
| 32 |
|
*/ |
| 33 |
|
public function find($identifier, string $toScenario = null) |
| 34 |
|
{ |
| 35 |
|
|
| 36 |
|
if (is_string($identifier)) { |
| 37 |
|
|
| 38 |
|
return $this->findByHandle($identifier, $toScenario); |
| 39 |
|
|
| 40 |
|
} |
| 41 |
|
|
| 42 |
|
return parent::find($identifier, $toScenario); |
| 43 |
|
|
| 44 |
|
} |
| 45 |
|
|
| 46 |
|
/******************************************* |
| 47 |
|
* FIND/GET BY HANDLE |