Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Route::get('/', 'IndexController@home');
- // To add a product
- Route::get('/product', 'ProductController@index');
- Route::get('/product/create', 'ProductController@create');
- Route::post('/product', 'ProductController@store');
- // To add a voucher bind to a certain product
- Route::get('/product/{id}', 'ProductController@show');
- Route::get('/product/{id}/add_voucher', 'ProductController@add_voucher');
- Route::post('/product/{id}/add_voucher', 'ProductController@associate_voucher');
- // To remove voucher bind from a certain product
- Route::get('/product/{id}/remove_voucher', 'ProductController@remove_voucher');
- Route::post('/product/{id}/remove_voucher', 'ProductController@remove_associated_voucher');
- // To buy a product
- Route::delete('/product/{id}', 'ProductController@delete');
- // To create a voucher and associate it with a discount tier
- Route::get('/voucher', 'VoucherController@voucher');
- Route::post('/voucher', 'VoucherController@voucher_create');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement