<?php

namespace App\Traits;

trait WithCategorySelector
{
    public function selectAllCategories()
    {
        $this->form->category_ids = array_keys($this->categories);
    }

    public function deselectAllCategories()
    {
        $this->form->category_ids = [];
    }
}
