Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
daVitekPL committed Jul 22, 2024
1 parent e0ce630 commit c33e9ad
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 5 deletions.
2 changes: 1 addition & 1 deletion src/Http/Resources/TopicType/Admin/ScormScoResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public function toArray($request)
return [
'id' => $this->resource->id,
'value' => $this->resource->value,
'uuid' => $scormSco ? $scormSco->resource->uuid : null,
'uuid' => $scormSco ? $scormSco->uuid : null,

Check failure on line 18 in src/Http/Resources/TopicType/Admin/ScormScoResource.php

View workflow job for this annotation

GitHub Actions / php82-laravel-latest-phpstan-postgres

Access to an undefined property Illuminate\Database\Eloquent\Collection<int, Peopleaps\Scorm\Model\ScormScoModel>|Peopleaps\Scorm\Model\ScormScoModel::$uuid.
'created_at' => $this->resource->created_at,
'updated_at' => $this->resource->updated_at,
];
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Resources/TopicType/Client/ScormScoResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ public function toArray($request)
return [
'id' => $this->resource->id,
'value' => $this->resource->value,
'uuid' => $scormSco ? $scormSco->resource->uuid : null,
'uuid' => $scormSco ? $scormSco->uuid : null,

Check failure on line 18 in src/Http/Resources/TopicType/Client/ScormScoResource.php

View workflow job for this annotation

GitHub Actions / php82-laravel-latest-phpstan-postgres

Access to an undefined property Illuminate\Database\Eloquent\Collection<int, Peopleaps\Scorm\Model\ScormScoModel>|Peopleaps\Scorm\Model\ScormScoModel::$uuid.
];
}
}
2 changes: 1 addition & 1 deletion src/Http/Resources/TopicType/Export/Cmi5AuResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,8 @@

namespace EscolaLms\TopicTypes\Http\Resources\TopicType\Export;

use EscolaLms\Cmi5\Models\Cmi5Au;
use EscolaLms\TopicTypes\Http\Resources\TopicType\Contacts\TopicTypeResourceContract;
use EscolaLms\TopicTypes\Models\TopicContent\Cmi5Au;
use Illuminate\Http\Resources\Json\JsonResource;

class Cmi5AuResource extends JsonResource implements TopicTypeResourceContract
Expand Down
4 changes: 2 additions & 2 deletions src/Http/Resources/TopicType/Export/ScormScoResource.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ public function toArray($request)
return [
'id' => $this->resource->id,
'value' => $this->resource->value,
'uuid' => $scormSco ? $scormSco->resource->uuid : null,
'identifier' => $scormSco ? $scormSco->resource->identifier : null,
'uuid' => $scormSco ? $scormSco->uuid : null,

Check failure on line 20 in src/Http/Resources/TopicType/Export/ScormScoResource.php

View workflow job for this annotation

GitHub Actions / php82-laravel-latest-phpstan-postgres

Access to an undefined property Illuminate\Database\Eloquent\Collection<int, Peopleaps\Scorm\Model\ScormScoModel>|Peopleaps\Scorm\Model\ScormScoModel::$uuid.
'identifier' => $scormSco ? $scormSco->identifier : null,

Check failure on line 21 in src/Http/Resources/TopicType/Export/ScormScoResource.php

View workflow job for this annotation

GitHub Actions / php82-laravel-latest-phpstan-postgres

Access to an undefined property Illuminate\Database\Eloquent\Collection<int, Peopleaps\Scorm\Model\ScormScoModel>|Peopleaps\Scorm\Model\ScormScoModel::$identifier.
'scorm_file' => $destination,
'created_at' => $this->resource->created_at,
'updated_at' => $this->resource->updated_at,
Expand Down
3 changes: 3 additions & 0 deletions src/Models/TopicContent/AbstractTopicContent.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
use Illuminate\Support\Facades\Storage;
use EscolaLms\Courses\Models\TopicContent\AbstractTopicContent as AbstractTopicContentExtend;

/**
* @property mixed $value
*/
abstract class AbstractTopicContent extends AbstractTopicContentExtend implements TopicContentContract
{
protected static function booted()
Expand Down
3 changes: 3 additions & 0 deletions src/Models/TopicContent/AbstractTopicFileContent.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,9 @@
use Illuminate\Support\Collection;
use Illuminate\Support\Facades\Storage;

/**
* @property mixed $value
*/
abstract class AbstractTopicFileContent extends AbstractTopicContent implements TopicFileContentContract
{
protected $appends = ['url'];
Expand Down

0 comments on commit c33e9ad

Please sign in to comment.