routes.php 1.02 KB
<?php

/*
|--------------------------------------------------------------------------
| Application Routes
|--------------------------------------------------------------------------
|
| Here is where you can register all of the routes for an application.
| It's a breeze. Simply tell Laravel the URIs it should respond to
| and give it the controller to call when that URI is requested.
|
*/

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


Route::get('pdf/{id}', 'PdfController@pdf');


Route::group(array('prefix' => 'api/v1'), function($json)
{

    Route::resource('add', 'ApiController@insert');
    Route::resource('get-list', 'ApiController@getList');
    Route::resource('get-pdf', 'ApiController@getpdf');
    Route::resource('api', 'ApiController@getApi');

});

Route::get('fileentry', 'FileEntryController@index');
Route::get('fileentry/get/{filename}', [
    'as' => 'getentry', 'uses' => 'FileEntryController@get']);
Route::post('fileentry/add',[
    'as' => 'addentry', 'uses' => 'FileEntryController@add']);