<?php

use Illuminate\Support\Facades\Route;

/*
|--------------------------------------------------------------------------
| Web Routes
|--------------------------------------------------------------------------
|
| Here is where you can register web routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| contains the "web" middleware group. Now create something great!
|
*/

//Route::get('/', function () {
//    return view('welcome');
//});

Auth::routes();

Route::get('/', [App\Http\Controllers\HomeController::class, 'dashboard'])->name('dashboard');
Route::get('/addNew', [App\Http\Controllers\HomeController::class, 'index'])->name('home');
Route::post('/storeData', [App\Http\Controllers\HomeController::class, 'store'])->name('store.data');
Route::post('/import', [App\Http\Controllers\HomeController::class, 'import'])->name('upload.data');
Route::get('/list', [App\Http\Controllers\HomeController::class, 'view'])->name('list.data');
Route::get('/list/cancelled', [App\Http\Controllers\HomeController::class, 'cancelled'])->name('cancelled.data');
Route::post('/cancel/{id}', [App\Http\Controllers\HomeController::class, 'cancel'])->name('cancel.data');
Route::get('/download', [App\Http\Controllers\HomeController::class, 'download'])->name('download.data');

Route::post('/search', [App\Http\Controllers\HomeController::class, 'search'])->name('search.data');


