Siopas Inventory PETI for ISTW Website
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

81 lines
3.0 KiB

1 year ago
<?php
1 year ago
use App\Http\Controllers\ProfileController;
use App\Http\Controllers\TransaksiController;
use App\Http\Controllers\PeminjamanController;
use App\Http\Controllers\PengembalianController;
use App\Http\Controllers\PengadaanController;
use App\Http\Controllers\ProductController;
1 year ago
use App\Http\Controllers\M_assetController;
use App\Http\Controllers\M_userController;
1 year ago
use App\Http\Controllers\SettingPlatformController;
1 year ago
use App\Models\m_asset;
1 year ago
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 and all of them will
| be assigned to the "web" middleware group. Make something great!
|
*/
1 year ago
Route::get('/coba', function () {
return view('landing_page.layouts.main');
});
Route::get('/logincoba', function () {
// return view('landing_page.login');
return view('login');
});
1 year ago
Route::get('/', function () {
1 year ago
return view('welcome');
1 year ago
});
1 year ago
Route::middleware('auth')->group(function () {
Route::get('/profile', [ProfileController::class, 'edit'])->name('profile.edit');
Route::patch('/profile', [ProfileController::class, 'update'])->name('profile.update');
Route::delete('/profile', [ProfileController::class, 'destroy'])->name('profile.destroy');
1 year ago
Route::put('/profile/{id}', [ProfileController::class, 'updateprofile'])->name('profile.updateprofile');
1 year ago
Route::post('/profile-update', [ProfileController::class, 'updatePhoto'])->name('profile-update');
Route::get('/setting', [ProfileController::class, 'setting'])->name('profile.setting');
1 year ago
});
1 year ago
Route::group(['prefix' => 'dashboard'], function () {
//Halaman dashboard
Route::middleware('auth')->get('', function () {
return view('dashboard.index');
});
1 year ago
1 year ago
//Halaman Transaksi
Route::middleware('auth')->resource('/transaksi', TransaksiController::class);
1 year ago
1 year ago
//Halaman Peminjaman
Route::middleware('auth')->resource('/peminjaman', PeminjamanController::class);
1 year ago
Route::get('/hapusPeminjaman/{id}', [PeminjamanController::class, 'destroy'])->name('hapusPeminjaman.destroy');
1 year ago
1 year ago
//Halaman Pengembalian
Route::middleware('auth')->resource('/pengembalian', PengembalianController::class);
1 year ago
1 year ago
//Halaman Pengadaan
Route::middleware('auth')->resource('/pengadaan', PengadaanController::class);
1 year ago
1 year ago
//Halaman Manajemen Asset
Route::middleware('auth')->resource('/asset', M_assetController::class);
Route::get('/hapusAsset/{id}', [M_assetController::class, 'destroy'])->name('hapusAsset.destroy');
//Halaman Manajemen User
Route::middleware('auth')->resource('/user', M_userController::class);
Route::get('/hapusUser/{id}', [M_userController::class, 'destroy'])->name('hapusUser.destroy');
// Route::get('/hapusAsset/{id}', [M_assetController::class, 'destroy'])->name('hapusAsset.destroy');
1 year ago
});
1 year ago
require __DIR__ . '/auth.php';