File: D:/HostingSpaces/SBogers10/shop.komma.nl/app/Categories/Kms/CategoryController.php
<?php
namespace App\Categories\Kms;
use Komma\KMS\Core\SectionController;
use App\Categories\Models\Category;
use App\Categories\Models\CategoryTranslation;
class CategoryController extends SectionController
{
protected $sortable = true;
protected string $slug = "categories";
protected string $classModelName = Category::class;
protected ?string $forTranslationModelName = CategoryTranslation::class;
/**
* Constructor
*/
public function __construct()
{
$section = new CategorySection($this->slug);
parent::__construct($section);
$this->modelService = new CategoryModelService();
}
public function namesById() {
return $this->modelService->namesById();
}
}