<?php

use App\Http\Controllers\DownloadFileController;
use App\Http\Controllers\Setting\DataLembagaController;
use App\Http\Controllers\Setting\UploadSiswaKelasController;
use Illuminate\Http\Request;
use Illuminate\Support\Facades\Route;
// use Modules\Panel\Http\Controllers\ComboMasterController;
// use Modules\Panel\Http\Controllers\Management\User\PegawaiController;

/*
    |--------------------------------------------------------------------------
    | 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!
    |
*/

Route::group(['prefix' => 'dalem', 'middleware' => []], function () {
    Route::post('read', [DataLembagaController::class, 'read'])->name('read');
    Route::post('update', [DataLembagaController::class, 'update'])->name('update');
    Route::post('combobox/{tipe}', [DataLembagaController::class, 'combobox'])->name('combobox');
});

Route::group(['prefix' => 'sups', 'middleware' => []], function () {
    Route::post('main-table', [UploadSiswaKelasController::class, 'mainTable'])->name('main-table');
    Route::post('upload', [UploadSiswaKelasController::class, 'upload'])->name('upload');
    // Route::post('update/{id}', [UploadSiswaKelasController::class, 'update'])->name('update');
    Route::post('delete', [UploadSiswaKelasController::class, 'delete'])->name('delete');
    Route::post('combox/{tipe}', [UploadSiswaKelasController::class, 'combox'])->name('combox');
    Route::get('download/{id}', [DownloadFileController::class, 'filesiswakelas'])->name('file.upload.siswa.download');
});