From bbb90428fcbbfef2f1547b77912ad22c96ca9994 Mon Sep 17 00:00:00 2001 From: Dennis Eichhorn Date: Sun, 31 Mar 2019 20:32:17 +0200 Subject: [PATCH] table test and bug style fixes --- Models/HelperStatus.php | 2 +- Models/Report.php | 17 +++++++++++------ Views/HelperView.php | 2 +- 3 files changed, 13 insertions(+), 8 deletions(-) diff --git a/Models/HelperStatus.php b/Models/HelperStatus.php index 76b31b6..a7e91f8 100644 --- a/Models/HelperStatus.php +++ b/Models/HelperStatus.php @@ -27,5 +27,5 @@ use phpOMS\Stdlib\Base\Enum; abstract class HelperStatus extends Enum { public const INACTIVE = 0; - public const ACTIVE = 1; + public const ACTIVE = 1; } diff --git a/Models/Report.php b/Models/Report.php index 5212bc0..36c780f 100644 --- a/Models/Report.php +++ b/Models/Report.php @@ -92,7 +92,7 @@ class Report implements \JsonSerializable /** * Report source. * - * @var int + * @var int|\Modules\Media\Models\Collection * @since 1.0.0 */ private $source = 0; @@ -281,15 +281,20 @@ class Report implements \JsonSerializable return $this->source; } + /** + * @return array + * + * @since 1.0.0 + */ public function toArray() : array { return [ - 'id' => $this->id, - 'createdBy' => $this->createdBy, - 'createdAt' => $this->createdAt->format('Y-m-d H:i:s'), - 'name' => $this->title, + 'id' => $this->id, + 'createdBy' => $this->createdBy, + 'createdAt' => $this->createdAt->format('Y-m-d H:i:s'), + 'name' => $this->title, 'description' => $this->description, - 'status' => $this->status, + 'status' => $this->status, ]; } diff --git a/Views/HelperView.php b/Views/HelperView.php index 41d22ac..9f7dd1d 100644 --- a/Views/HelperView.php +++ b/Views/HelperView.php @@ -27,5 +27,5 @@ use phpOMS\Views\View; class HelperView extends View { protected $dataSets = []; - protected $dataSet = null; + protected $dataSet = null; }