course tags corrected

This commit is contained in:
HolgerHatGarKeineNode
2023-02-27 18:42:28 +01:00
parent 384740daeb
commit 01623de424

View File

@@ -55,6 +55,12 @@ class CourseForm extends Component
->can('update', $this->course) ->can('update', $this->course)
) { ) {
abort(403); abort(403);
} else {
$this->selectedTags = $this->course->tags()
->where('type', 'course')
->get()
->map(fn($tag) => $tag->name)
->toArray();
} }
if (!$this->fromUrl) { if (!$this->fromUrl) {
$this->fromUrl = url()->previous(); $this->fromUrl = url()->previous();