first commit
This commit is contained in:
No files matched your search
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
use Illuminate\Support\Facades\DB;
|
||||
/** @var \Laravel\Lumen\Routing\Router $router */
|
||||
|
||||
/*
|
||||
|--------------------------------------------------------------------------
|
||||
| Application Routes
|
||||
|--------------------------------------------------------------------------
|
||||
|
|
||||
| Here is where you can register all of the routes for an application.
|
||||
| It is a breeze. Simply tell Lumen the URIs it should respond to
|
||||
| and give it the Closure to call when that URI is requested.
|
||||
|
|
||||
*/
|
||||
|
||||
$router->get('/', function () use ($router) {
|
||||
return redirect('api/login/');
|
||||
});
|
||||
$router->get('/key', function() { return \Illuminate\Support\Str::random(32); });
|
||||
$router->get('/db',function() {
|
||||
// Test database connection
|
||||
try {
|
||||
DB::connection()->getPdo();
|
||||
echo "Connection success";
|
||||
} catch (\Exception $e) {
|
||||
die("Could not connect to the database. Please check your configuration. error:" . $e );
|
||||
}
|
||||
});
|
||||
$router->group(['prefix' => 'api'], function () use ($router) {
|
||||
$router->get('login/','UserController@authenticate');
|
||||
|
||||
$router->get('rajal/diag/{tgl_awal}/{tgl_akhir}','IcdController@rajalDiagFiltered');
|
||||
$router->get('rajal/tind/{tgl_awal}/{tgl_akhir}','IcdController@rajalTindakanFiltered');
|
||||
$router->get('igd/diag/{tgl_awal}/{tgl_akhir}','IcdController@igdDiagFiltered');
|
||||
$router->get('igd/tind/{tgl_awal}/{tgl_akhir}','IcdController@igdTindakanFiltered');
|
||||
$router->get('ranap/diag/{tgl_awal}/{tgl_akhir}','IcdController@ranapDiagFiltered');
|
||||
$router->get('ranap/tind/{tgl_awal}/{tgl_akhir}','IcdController@ranapTindakanFiltered');
|
||||
|
||||
$router->get('pasien','PasienController@pasienFilter');
|
||||
$router->get('pasien/{nomr}','PasienController@pasienFilter');
|
||||
$router->get('pasien/{nomr}/labsentral','PasienController@labsentralFilter');
|
||||
$router->get('pasien/{nomr}/labmikro','PasienController@labmikroFilter');
|
||||
$router->get('pasien/{nomr}/labpatologi','PasienController@labpatologiFilter');
|
||||
$router->get('pasien/{nomr}/resume','PasienController@resumeFilter');
|
||||
});
|
||||
Reference in New Issue
Block a user