Files
izyim-api/routes/api.php
T
Zain Fauzan Rofie Azizi 041c643bb1 ongoing testing
2018-06-06 15:27:46 +08:00

71 lines
3.3 KiB
PHP

<?php
use Illuminate\Http\Request;
use App\Company;
/*
|--------------------------------------------------------------------------
| API Routes
|--------------------------------------------------------------------------
|
| Here is where you can register API routes for your application. These
| routes are loaded by the RouteServiceProvider within a group which
| is assigned the "api" middleware group. Enjoy building your API!
|
*/
/* Wshipping-order */
Route::get('/so', 'SoController@index');// get the list of the shipping order
Route::get('/so/{so_id}', 'SoController@showso');//get the shipping order
Route::post('/so', 'SoController@store');//store shipping order
Route::post('/so/{so_id}/cancelOrder', 'SoController@cancelOrder');//post the cancel order
Route::delete('/so/{so_id}', 'SoController@delete');// delete the shipping order
Route::put('/so/{so_id}', 'SoController@update');//update the shipping order
/* Warehouse-receive-note */
//Route::get('/so/{so_id}','warehousearrangementController@index');//view the list of wrn
Route::get('/warehousearr','WarehousearrangementController@index');//view the wrn
Route::post('/warehousearr','WarehousearrangementController@store');//store the new wrn
Route::post('/warehousearr/warehouse_picture/{wa_id}','WarehousearrangementController@warehousearrpic');//upload warehousepicture picture
Route::post('/warehousearr/warehouse_item_picture/{wa_id}','WarehousearrangementController@warehouseitempic');//upload warehousepicture picture
Route::put('/warehousearr/{wa_id}','WarehousearrangementController@update');//update the wrn
Route::post('/decision','WarehousearrangementController@storedecision');//decision reject and request the wrn
Route::post('/decision/decisionitem','WarehousearrangementController@storedecisionitem');//decision item for reject and request
/* Shipment-arrangement */
Route::get('/shipment','ShipmentarrangementController@index');//view the shipment
Route::post('/shipment','ShipmentarrangementController@store');//post the shipment
Route::put('/shipment/{sa_id}','ShipmentarrangementController@update');//update shipment //update shipment??
Route::post('/custom-exam','ShipmentarrangementController@customStore');;//post the custom-examintion
Route::put('/custom-exam/{id}','ShipmentarrangementController@customUpdate');//update the custom-examintion
/* Authentication */
Route::post('login', 'AuthController@login');
Route::post('password/recover', 'AuthController@recover');
Route::post('password/reset', 'AuthController@reset');
Route::post('send-verification', 'AuthController@sendVerification');
Route::post('verify-phone', 'AuthController@verifyPhone');
Route::group(['middleware' => ['jwt.auth']], function() {
Route::get('logout', 'AuthController@logout');
Route::patch('user', 'AuthController@updateUser');
Route::get('test', function(Request $request){
return response()->json(['user'=> $request->user()]);
});
/* Company */
Route::patch('/company', 'CompanyController@update'); //update company information
Route::post('/company/company_profile/', 'CompanyController@companyProfile');//upload company profile picture
Route::post('/company/reg_cert/', 'CompanyController@regCert'); //upload registration certificaate
});