| 1 | <?php |
||
| 8 | trait FindRecordTrait |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * Returns the data model based on the primary key given in the param. |
||
| 12 | * If the data model is not found, an HTTP exception will be raised. |
||
| 13 | * |
||
| 14 | * @param int $id the ID of the model to be loaded |
||
| 15 | * @param string $class |
||
| 16 | * |
||
| 17 | * @return ActiveRecordInterface the loaded model |
||
| 18 | * |
||
| 19 | * @throws HttpException |
||
| 20 | */ |
||
| 21 | public function findModel($id, $class) |
||
| 28 | } |
||
| 29 |