<?php

namespace App\Datatables\Admin\Core\Mail;

use App\Datatables\ParentDataTable as DataTable;
use App\Models\Core\Mail\MailTemplate;
use App\Repositories\Core\Auth\Users;
use Yajra\DataTables\Html\Column;

class MailTemplatesDataTable extends DataTable
{
    public $model_name = 'mail_templates';

    public $sortedColumn = 0;

    public $sortedOrder = 'desc';

    public $stateSave = true;

    public function query(MailTemplate $model)
    {
        return $this->buildQuery($model);
    }

    protected function getColumns()
    {
        return [
            Column::make('subject')->title(__('Core.subject')),
            Column::make('mailable')->title(__('Mailable')),
            $this->makeColumnButtons()->width('60'),
        ];
    }
}
