<?php

namespace App\Filament\Resources\TaskResource\Pages;

use App\Filament\Resources\TaskResource;
use Filament\Actions;
use Filament\Resources\Pages\ManageRecords;

class ManageTasks extends ManageRecords
{
    protected static string $resource = TaskResource::class;

    protected function getHeaderActions(): array
    {
        return [
            Actions\CreateAction::make(),
            Actions\Action::make('import')
                ->label(__('admin.common.import_csv'))
                ->icon('heroicon-o-arrow-up-tray')
                ->url(TaskResource::getUrl('import')),
            Actions\Action::make('template')
                ->label(__('admin.common.download_csv_template'))
                ->icon('heroicon-o-document-arrow-down')
                ->url(url('/super-admin/templates/tasks.csv')),
        ];
    }
}
