@extends('layouts.app')

@section('page_title', 'Station Management')

@section('content')
    @php
        $stations = [
            [
                'id' => 1,
                'station_code' => 'ST001',
                'station_name' => 'North Station',
                'branch_name' => 'Quezon City Branch',
                'date_created' => '2023-05-01',
                'created_by' => 'Maryse Howe',
                'modified_by' => 'Joseph Sazon',
                'date_modified' => '2023-06-15'
            ],
            [
                'id' => 2,
                'station_code' => 'ST002',
                'station_name' => 'East Hub',
                'branch_name' => 'Pasig Branch',
                'date_created' => '2023-05-10',
                'created_by' => 'Graxia Montino',
                'modified_by' => 'Cine Rosimo',
                'date_modified' => '2023-07-01'
            ],
            [
                'id' => 3,
                'station_code' => 'ST003',
                'station_name' => 'West Terminal',
                'branch_name' => 'Makati Branch',
                'date_created' => '2023-06-20',
                'created_by' => 'Cine Rosimo',
                'modified_by' => 'Graxia Montino',
                'date_modified' => '2023-08-05'
            ],
            [
                'id' => 4,
                'station_code' => 'ST004',
                'station_name' => 'Central Depot',
                'branch_name' => 'Manila Branch',
                'date_created' => '2023-07-05',
                'created_by' => 'Maryse Howe',
                'modified_by' => 'Maryse Howe',
                'date_modified' => '2023-09-10'
            ],
            [
                'id' => 5,
                'station_code' => 'ST005',
                'station_name' => 'South Station',
                'branch_name' => 'Parañaque Branch',
                'date_created' => '2023-08-15',
                'created_by' => 'Joseph Sazon',
                'modified_by' => 'Graxia Montino',
                'date_modified' => '2023-10-01'
],
[
                'id' => 1,
                'station_code' => 'ST001',
                'station_name' => 'North Station',
                'branch_name' => 'Quezon City Branch',
                'date_created' => '2023-05-01',
                'created_by' => 'Maryse Howe',
                'modified_by' => 'Joseph Sazon',
                'date_modified' => '2023-06-15'
            ],
            [
                'id' => 2,
                'station_code' => 'ST002',
                'station_name' => 'East Hub',
                'branch_name' => 'Pasig Branch',
                'date_created' => '2023-05-10',
                'created_by' => 'Graxia Montino',
                'modified_by' => 'Cine Rosimo',
                'date_modified' => '2023-07-01'
            ],
            [
                'id' => 3,
                'station_code' => 'ST003',
                'station_name' => 'West Terminal',
                'branch_name' => 'Makati Branch',
                'date_created' => '2023-06-20',
                'created_by' => 'Cine Rosimo',
                'modified_by' => 'Graxia Montino',
                'date_modified' => '2023-08-05'
            ],
            [
                'id' => 4,
                'station_code' => 'ST004',
                'station_name' => 'Central Depot',
                'branch_name' => 'Manila Branch',
                'date_created' => '2023-07-05',
                'created_by' => 'Maryse Howe',
                'modified_by' => 'Maryse Howe',
                'date_modified' => '2023-09-10'
            ],
            [
                'id' => 5,
                'station_code' => 'ST005',
                'station_name' => 'South Station',
                'branch_name' => 'Parañaque Branch',
                'date_created' => '2023-08-15',
                'created_by' => 'Joseph Sazon',
                'modified_by' => 'Graxia Montino',
                'date_modified' => '2023-10-01'
],
            [
                'id' => 1,
                'station_code' => 'ST001',
                'station_name' => 'North Station',
                'branch_name' => 'Quezon City Branch',
                'date_created' => '2023-05-01',
                'created_by' => 'Maryse Howe',
                'modified_by' => 'Joseph Sazon',
                'date_modified' => '2023-06-15'
            ],
            [
                'id' => 2,
                'station_code' => 'ST002',
                'station_name' => 'East Hub',
                'branch_name' => 'Pasig Branch',
                'date_created' => '2023-05-10',
                'created_by' => 'Graxia Montino',
                'modified_by' => 'Cine Rosimo',
                'date_modified' => '2023-07-01'
            ],
            [
                'id' => 3,
                'station_code' => 'ST003',
                'station_name' => 'West Terminal',
                'branch_name' => 'Makati Branch',
                'date_created' => '2023-06-20',
                'created_by' => 'Cine Rosimo',
                'modified_by' => 'Graxia Montino',
                'date_modified' => '2023-08-05'
            ],
            [
                'id' => 4,
                'station_code' => 'ST004',
                'station_name' => 'Central Depot',
                'branch_name' => 'Manila Branch',
                'date_created' => '2023-07-05',
                'created_by' => 'Maryse Howe',
                'modified_by' => 'Maryse Howe',
                'date_modified' => '2023-09-10'
            ],
            [
                'id' => 5,
                'station_code' => 'ST005',
                'station_name' => 'South Station',
                'branch_name' => 'Parañaque Branch',
                'date_created' => '2023-08-15',
                'created_by' => 'Joseph Sazon',
                'modified_by' => 'Graxia Montino',
                'date_modified' => '2023-10-01'
],
        ];
    @endphp

    @include('components.table-component', [
        'pageTitle' => 'Station Management',
        'data' => $stations,
        'columns' => [
            ['name' => 'Station Code', 'key' => 'station_code', 'sortable' => true],
            ['name' => 'Station Name', 'key' => 'station_name', 'sortable' => true],
            ['name' => 'Branch Name', 'key' => 'branch_name', 'sortable' => true],
            ['name' => 'Date Created', 'key' => 'date_created', 'sortable' => true],
            ['name' => 'Created By', 'key' => 'created_by', 'sortable' => true],
            ['name' => 'Modified By', 'key' => 'modified_by', 'sortable' => true],
            ['name' => 'Date Modified', 'key' => 'date_modified', 'sortable' => true]
        ],
        'actions' => ['edit', 'view', 'delete'],
        'showAddButton' => true,
        'addButtonUrl' => '/add-station',
        'showCheckboxes' => false,
        'showBatchDelete' => false,
        'showEditModal' => true,
        'showViewModal' => true
    ])
@endsection
