Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| a1462095a7 | |||
| dcf57bcfdc | |||
| 05ab6fee35 | |||
| 16571fdffc | |||
| f2aeb9c695 | |||
| 261fa7ff8f |
@@ -85,7 +85,7 @@ PERIODE_VERIFIKATOR=395
|
||||
VERIFIKATOR_WEBHOOK_URL=http://172.16.50.94:8087/webhook/verifikator
|
||||
VERIFIKATOR_WEBHOOK_KEY=
|
||||
|
||||
VERIFIKASI_ABSEN_WA_URL=http://verifikasi-presensi-whatsapp.test
|
||||
VERIFIKASI_ABSEN_WA_URL=http://verifikator-untan.test/verifikasi-absen
|
||||
|
||||
GOOGLE_DRIVE_FOLDER_ID=0AJQK-NMrB4b_Uk9PVA
|
||||
|
||||
|
||||
+1
-1
@@ -85,7 +85,7 @@ PERIODE_VERIFIKATOR=395
|
||||
VERIFIKATOR_WEBHOOK_URL=http://172.16.50.94:8087/webhook/verifikator
|
||||
VERIFIKATOR_WEBHOOK_KEY=
|
||||
|
||||
VERIFIKASI_ABSEN_WA_URL=http://verifikasi-presensi-whatsapp.test
|
||||
VERIFIKASI_ABSEN_WA_URL=http://verifikator-untan.test/verifikasi-absen
|
||||
|
||||
GOOGLE_DRIVE_FOLDER_ID=
|
||||
|
||||
|
||||
@@ -34,9 +34,9 @@ class VerifikasiAbsenController extends Controller
|
||||
{
|
||||
$pengajuan = PengajuanPresensi::with(['pegawai', 'notes'])->findOrFail($id);
|
||||
|
||||
$otorisasi = $this->otorisasiAtasan($request, $pengajuan);
|
||||
$otorisasi = $this->otorisasiAtasan($request, $pengajuan, renewSesi: true);
|
||||
|
||||
if (is_array($otorisasi)) {
|
||||
if (! $otorisasi['ok']) {
|
||||
return $this->responseTidakBerwenang($otorisasi['reason']);
|
||||
}
|
||||
|
||||
@@ -44,6 +44,7 @@ class VerifikasiAbsenController extends Controller
|
||||
'success' => true,
|
||||
'state' => $this->resolveState($pengajuan),
|
||||
'data' => $this->formatPengajuan($pengajuan),
|
||||
'new_token' => $otorisasi['new_token'],
|
||||
]);
|
||||
}
|
||||
|
||||
@@ -58,11 +59,11 @@ class VerifikasiAbsenController extends Controller
|
||||
|
||||
$otorisasi = $this->otorisasiAtasan($request, $pengajuan);
|
||||
|
||||
if (is_array($otorisasi)) {
|
||||
if (! $otorisasi['ok']) {
|
||||
return $this->responseTidakBerwenang($otorisasi['reason']);
|
||||
}
|
||||
|
||||
$nipAtasan = $otorisasi;
|
||||
$nipAtasan = $otorisasi['nip'];
|
||||
|
||||
if ($gagal = $this->cekBisaDiproses($pengajuan)) {
|
||||
return $gagal;
|
||||
@@ -117,11 +118,11 @@ class VerifikasiAbsenController extends Controller
|
||||
|
||||
$otorisasi = $this->otorisasiAtasan($request, $pengajuan);
|
||||
|
||||
if (is_array($otorisasi)) {
|
||||
if (! $otorisasi['ok']) {
|
||||
return $this->responseTidakBerwenang($otorisasi['reason']);
|
||||
}
|
||||
|
||||
$nipAtasan = $otorisasi;
|
||||
$nipAtasan = $otorisasi['nip'];
|
||||
|
||||
if ($gagal = $this->cekBisaDiproses($pengajuan)) {
|
||||
return $gagal;
|
||||
@@ -201,23 +202,23 @@ class VerifikasiAbsenController extends Controller
|
||||
}
|
||||
|
||||
/**
|
||||
* @return string|array{reason: string} Nip atasan kalau berhasil, atau array alasan gagal.
|
||||
* @return array{ok: bool, nip: ?string, reason: ?string, new_token: ?string}
|
||||
*/
|
||||
private function otorisasiAtasan(Request $request, PengajuanPresensi $pengajuan): string|array
|
||||
private function otorisasiAtasan(Request $request, PengajuanPresensi $pengajuan, bool $renewSesi = false): array
|
||||
{
|
||||
$token = $request->input('token');
|
||||
|
||||
$hasil = $this->linkService->verify($pengajuan->id, $token);
|
||||
$hasil = $this->linkService->verify($pengajuan->id, $token, $renewSesi);
|
||||
|
||||
if (! $hasil['ok']) {
|
||||
return ['reason' => $hasil['reason']];
|
||||
return ['ok' => false, 'nip' => null, 'reason' => $hasil['reason'], 'new_token' => null];
|
||||
}
|
||||
|
||||
if (! $this->dawaiService->isAtasanDari($hasil['nip'], $pengajuan->nip)) {
|
||||
return ['reason' => 'invalid'];
|
||||
return ['ok' => false, 'nip' => null, 'reason' => 'invalid', 'new_token' => null];
|
||||
}
|
||||
|
||||
return $hasil['nip'];
|
||||
return ['ok' => true, 'nip' => $hasil['nip'], 'reason' => null, 'new_token' => $hasil['new_token']];
|
||||
}
|
||||
|
||||
private function responseTidakBerwenang(string $reason): JsonResponse
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
<?php
|
||||
|
||||
namespace App\Http\Controllers;
|
||||
|
||||
class VerifikasiAbsenHalamanController extends Controller
|
||||
{
|
||||
public function show(int $id)
|
||||
{
|
||||
return view('verifikasi-absen.halaman', ['id' => $id]);
|
||||
}
|
||||
}
|
||||
@@ -44,11 +44,15 @@ class VerifikasiAbsenLinkService
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array{ok: bool, nip: ?string, reason: ?string}
|
||||
* @param bool $renewSesi Saat true dan sesi sudah lewat 5 menit, token lama akan digantikan dengan
|
||||
* token baru (bukan langsung ditolak). Dipakai saat tautan dibuka ulang dari
|
||||
* WhatsApp (klik tombol "Tinjau Pengajuan"), supaya tidak perlu membuat
|
||||
* pengajuan baru hanya untuk mendapatkan token baru.
|
||||
* @return array{ok: bool, nip: ?string, reason: ?string, new_token: ?string}
|
||||
*/
|
||||
public function verify(int $pengajuanId, ?string $token): array
|
||||
public function verify(int $pengajuanId, ?string $token, bool $renewSesi = false): array
|
||||
{
|
||||
$gagal = fn (string $reason) => ['ok' => false, 'nip' => null, 'reason' => $reason];
|
||||
$gagal = fn (string $reason) => ['ok' => false, 'nip' => null, 'reason' => $reason, 'new_token' => null];
|
||||
|
||||
if (! $token) {
|
||||
return $gagal('invalid');
|
||||
@@ -67,13 +71,23 @@ class VerifikasiAbsenLinkService
|
||||
return $gagal('link_expired');
|
||||
}
|
||||
|
||||
$tokenBaru = null;
|
||||
|
||||
if ($row->first_accessed_at === null) {
|
||||
$row->update(['first_accessed_at' => now()]);
|
||||
} elseif (now()->greaterThan($row->first_accessed_at->copy()->addMinutes(self::SESI_MENIT))) {
|
||||
return $gagal('session_expired');
|
||||
if (! $renewSesi) {
|
||||
return $gagal('session_expired');
|
||||
}
|
||||
|
||||
$tokenBaru = Str::random(40);
|
||||
$row->update([
|
||||
'token' => $this->hash($tokenBaru),
|
||||
'first_accessed_at' => now(),
|
||||
]);
|
||||
}
|
||||
|
||||
return ['ok' => true, 'nip' => $row->nip, 'reason' => null];
|
||||
return ['ok' => true, 'nip' => $row->nip, 'reason' => null, 'new_token' => $tokenBaru];
|
||||
}
|
||||
|
||||
public function markUsed(int $pengajuanId, string $token): void
|
||||
|
||||
+1
-1
@@ -47,7 +47,7 @@ return [
|
||||
],
|
||||
|
||||
'verifikasi_absen_wa' => [
|
||||
'url' => env('VERIFIKASI_ABSEN_WA_URL', 'http://verifikasi-presensi-whatsapp.test'),
|
||||
'url' => env('VERIFIKASI_ABSEN_WA_URL', env('APP_URL', 'http://localhost').'/verifikasi-absen'),
|
||||
],
|
||||
|
||||
'google_drive' => [
|
||||
|
||||
@@ -0,0 +1,390 @@
|
||||
<!DOCTYPE html>
|
||||
<html lang="id">
|
||||
|
||||
<head>
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Verifikasi Presensi | {{ config('app.name') }}</title>
|
||||
<link href="https://cdnjs.cloudflare.com/ajax/libs/bootstrap/5.3.0/css/bootstrap.min.css" rel="stylesheet">
|
||||
<link href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.0.0/css/all.min.css" rel="stylesheet">
|
||||
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/simple-notify/dist/simple-notify.css" />
|
||||
|
||||
<link rel="preconnect" href="https://fonts.googleapis.com">
|
||||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Inter:ital,opsz,wght@0,14..32,100..900;1,14..32,100..900&display=swap"
|
||||
rel="stylesheet">
|
||||
|
||||
<style>
|
||||
body {
|
||||
background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 50%, #1d4ed8 100%);
|
||||
min-height: 100vh;
|
||||
font-family: "Inter", sans-serif;
|
||||
padding: 30px 15px;
|
||||
}
|
||||
|
||||
.wrapper {
|
||||
max-width: 640px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.card {
|
||||
border: none;
|
||||
border-radius: 16px;
|
||||
box-shadow: 0 20px 40px rgba(30, 58, 138, 0.3);
|
||||
}
|
||||
|
||||
.card-header {
|
||||
background: linear-gradient(135deg, #1e3a8a 0%, #3b82f6 50%, #1d4ed8 100%);
|
||||
color: #fff;
|
||||
border-radius: 16px 16px 0 0 !important;
|
||||
padding: 24px;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.card-header img {
|
||||
height: 48px;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
|
||||
.card-body {
|
||||
padding: 28px;
|
||||
}
|
||||
|
||||
dt {
|
||||
color: #6b7280;
|
||||
font-size: 13px;
|
||||
font-weight: 600;
|
||||
text-transform: uppercase;
|
||||
}
|
||||
|
||||
dd {
|
||||
margin-bottom: 14px;
|
||||
font-size: 15px;
|
||||
}
|
||||
|
||||
.status-badge {
|
||||
font-size: 13px;
|
||||
padding: 6px 14px;
|
||||
}
|
||||
|
||||
.btn-setujui {
|
||||
background: #16a34a;
|
||||
border-color: #16a34a;
|
||||
}
|
||||
|
||||
.btn-setujui:hover {
|
||||
background: #15803d;
|
||||
border-color: #15803d;
|
||||
}
|
||||
|
||||
.btn-tolak {
|
||||
background: #dc2626;
|
||||
border-color: #dc2626;
|
||||
}
|
||||
|
||||
.btn-tolak:hover {
|
||||
background: #b91c1c;
|
||||
border-color: #b91c1c;
|
||||
}
|
||||
|
||||
.aksi-form {
|
||||
display: none;
|
||||
border-top: 1px solid #e5e7eb;
|
||||
margin-top: 20px;
|
||||
padding-top: 20px;
|
||||
}
|
||||
|
||||
#loadingState {
|
||||
text-align: center;
|
||||
padding: 60px 20px;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
#loadingState .fa-spinner {
|
||||
font-size: 2.5rem;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<div class="wrapper">
|
||||
<div id="loadingState">
|
||||
<i class="fas fa-spinner fa-spin"></i>
|
||||
<p class="mt-3">Memuat data pengajuan...</p>
|
||||
</div>
|
||||
|
||||
<div class="card d-none" id="mainCard">
|
||||
<div class="card-header">
|
||||
<img src="{{ asset('assets/images/logo-untan.png') }}" alt="untan">
|
||||
<h5 class="mb-0">Verifikasi Presensi</h5>
|
||||
<small>Universitas Tanjungpura</small>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div id="pesanState" class="d-none">
|
||||
<div class="text-center py-4">
|
||||
<i id="pesanIcon" class="fas fa-info-circle fa-3x text-secondary mb-3"></i>
|
||||
<p id="pesanText" class="mb-0"></p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div id="detailState" class="d-none">
|
||||
<div class="d-flex justify-content-between align-items-start mb-3">
|
||||
<h6 class="mb-0">Detail Pengajuan</h6>
|
||||
<span id="statusBadge" class="badge status-badge"></span>
|
||||
</div>
|
||||
|
||||
<dl class="row mb-0">
|
||||
<div class="col-6">
|
||||
<dt>Nama Pemohon</dt>
|
||||
<dd id="dataNama">-</dd>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<dt>NIP</dt>
|
||||
<dd id="dataNip">-</dd>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<dt>Tanggal</dt>
|
||||
<dd id="dataTanggal">-</dd>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<dt>Kategori</dt>
|
||||
<dd id="dataKategori">-</dd>
|
||||
</div>
|
||||
<div class="col-12">
|
||||
<dt>Keterangan</dt>
|
||||
<dd id="dataKeterangan">-</dd>
|
||||
</div>
|
||||
<div class="col-12" id="dataAlasanWrap" style="display:none">
|
||||
<dt>Catatan</dt>
|
||||
<dd id="dataAlasan">-</dd>
|
||||
</div>
|
||||
<div class="col-12">
|
||||
<dt>Bukti</dt>
|
||||
<dd><a id="dataFile" href="#" target="_blank">Lihat file bukti <i class="fas fa-external-link-alt"></i></a></dd>
|
||||
</div>
|
||||
</dl>
|
||||
|
||||
<div id="aksiButtons" class="d-flex gap-2 mt-3">
|
||||
<button type="button" class="btn btn-setujui text-white flex-fill" id="btnBukaSetujui">
|
||||
<i class="fas fa-check"></i> Setujui
|
||||
</button>
|
||||
<button type="button" class="btn btn-tolak text-white flex-fill" id="btnBukaTolak">
|
||||
<i class="fas fa-times"></i> Tolak
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<form id="formSetujui" class="aksi-form">
|
||||
<h6>Setujui & Tanda Tangani Dokumen</h6>
|
||||
<div class="mb-3">
|
||||
<label class="form-label">NIK</label>
|
||||
<input type="text" class="form-control" name="nik" required>
|
||||
</div>
|
||||
<div class="mb-3">
|
||||
<label class="form-label">Passphrase</label>
|
||||
<input type="password" class="form-control" name="passphrase" required>
|
||||
</div>
|
||||
<div class="d-flex gap-2">
|
||||
<button type="submit" class="btn btn-setujui text-white flex-fill">Kirim Persetujuan</button>
|
||||
<button type="button" class="btn btn-outline-secondary batal-aksi">Batal</button>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
<form id="formTolak" class="aksi-form">
|
||||
<h6>Tolak Pengajuan</h6>
|
||||
<div class="mb-3">
|
||||
<label class="form-label">Catatan Penolakan</label>
|
||||
<textarea class="form-control" name="catatan" rows="3" maxlength="500" required></textarea>
|
||||
</div>
|
||||
<div class="d-flex gap-2">
|
||||
<button type="submit" class="btn btn-tolak text-white flex-fill">Kirim Penolakan</button>
|
||||
<button type="button" class="btn btn-outline-secondary batal-aksi">Batal</button>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.7.1/jquery.min.js"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/simple-notify/dist/simple-notify.min.js"></script>
|
||||
|
||||
<script>
|
||||
const pengajuanId = {{ (int) $id }};
|
||||
let token = new URLSearchParams(window.location.search).get('token');
|
||||
const apiBase = "{{ url('/api/v1/verifikasi-absen') }}/" + pengajuanId;
|
||||
|
||||
function showNotification(status, title, text) {
|
||||
new Notify({
|
||||
status,
|
||||
title,
|
||||
text,
|
||||
effect: 'fade',
|
||||
speed: 300,
|
||||
showIcon: true,
|
||||
showCloseButton: true,
|
||||
autoclose: true,
|
||||
autotimeout: status === 'error' ? 5000 : 3000,
|
||||
type: 'outline',
|
||||
position: 'right top',
|
||||
});
|
||||
}
|
||||
|
||||
function ambilPesanError(xhr) {
|
||||
try {
|
||||
const data = JSON.parse(xhr.responseText);
|
||||
return data.message || 'Terjadi kesalahan. Silakan coba lagi.';
|
||||
} catch (e) {
|
||||
return 'Terjadi kesalahan. Silakan coba lagi.';
|
||||
}
|
||||
}
|
||||
|
||||
const statusBadgeMap = {
|
||||
'Diajukan': ['bg-warning text-dark', 'Menunggu Verifikasi'],
|
||||
'Diterima': ['bg-success', 'Diterima'],
|
||||
'Ditolak': ['bg-danger', 'Ditolak'],
|
||||
};
|
||||
|
||||
function tampilkanPesan(icon, text, colorClass) {
|
||||
$('#pesanState').removeClass('d-none');
|
||||
$('#detailState').addClass('d-none');
|
||||
$('#pesanIcon').attr('class', `fas ${icon} fa-3x mb-3 ${colorClass}`);
|
||||
$('#pesanText').text(text);
|
||||
}
|
||||
|
||||
function tampilkanDetail(data, state) {
|
||||
$('#pesanState').addClass('d-none');
|
||||
$('#detailState').removeClass('d-none');
|
||||
|
||||
$('#dataNama').text(data.nama || '-');
|
||||
$('#dataNip').text(data.nip || '-');
|
||||
$('#dataTanggal').text(data.tanggal || '-');
|
||||
$('#dataKategori').text(data.kategori || '-');
|
||||
$('#dataKeterangan').text(data.keterangan || '-');
|
||||
$('#dataFile').attr('href', data.file || '#');
|
||||
|
||||
const badge = statusBadgeMap[data.status] || ['bg-secondary', data.status];
|
||||
$('#statusBadge').attr('class', `badge status-badge ${badge[0]}`).text(badge[1]);
|
||||
|
||||
if (data.alasan) {
|
||||
$('#dataAlasanWrap').show();
|
||||
$('#dataAlasan').text(data.alasan);
|
||||
}
|
||||
|
||||
if (state === 'pending') {
|
||||
$('#aksiButtons').removeClass('d-none');
|
||||
} else {
|
||||
$('#aksiButtons').addClass('d-none');
|
||||
}
|
||||
}
|
||||
|
||||
function muatData() {
|
||||
if (!token) {
|
||||
tampilkanPesan('fa-ban', 'Tautan tidak valid: token tidak ditemukan.', 'text-danger');
|
||||
selesaiLoading();
|
||||
return;
|
||||
}
|
||||
|
||||
$.ajax({
|
||||
url: `${apiBase}?token=${encodeURIComponent(token)}`,
|
||||
method: 'GET',
|
||||
success: function (res) {
|
||||
if (res.new_token) {
|
||||
token = res.new_token;
|
||||
const url = new URL(window.location.href);
|
||||
url.searchParams.set('token', token);
|
||||
window.history.replaceState({}, '', url);
|
||||
}
|
||||
|
||||
tampilkanDetail(res.data, res.state);
|
||||
selesaiLoading();
|
||||
},
|
||||
error: function (xhr) {
|
||||
const pesan = ambilPesanError(xhr);
|
||||
tampilkanPesan('fa-exclamation-triangle', pesan, 'text-danger');
|
||||
selesaiLoading();
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
function selesaiLoading() {
|
||||
$('#loadingState').addClass('d-none');
|
||||
$('#mainCard').removeClass('d-none');
|
||||
}
|
||||
|
||||
function tutupForm() {
|
||||
$('.aksi-form').slideUp(150, function () {
|
||||
$(this).hide();
|
||||
});
|
||||
$('#aksiButtons').removeClass('d-none');
|
||||
}
|
||||
|
||||
$('#btnBukaSetujui').on('click', function () {
|
||||
$('#aksiButtons').addClass('d-none');
|
||||
$('#formTolak').hide();
|
||||
$('#formSetujui').show();
|
||||
});
|
||||
|
||||
$('#btnBukaTolak').on('click', function () {
|
||||
$('#aksiButtons').addClass('d-none');
|
||||
$('#formSetujui').hide();
|
||||
$('#formTolak').show();
|
||||
});
|
||||
|
||||
$('.batal-aksi').on('click', tutupForm);
|
||||
|
||||
$('#formSetujui').on('submit', function (e) {
|
||||
e.preventDefault();
|
||||
const $btn = $(this).find('button[type=submit]');
|
||||
const originalText = $btn.text();
|
||||
$btn.prop('disabled', true).text('Memproses...');
|
||||
|
||||
$.ajax({
|
||||
url: `${apiBase}/setujui?token=${encodeURIComponent(token)}`,
|
||||
method: 'POST',
|
||||
data: {
|
||||
nik: $(this).find('[name=nik]').val(),
|
||||
passphrase: $(this).find('[name=passphrase]').val(),
|
||||
},
|
||||
success: function (res) {
|
||||
showNotification('success', 'Berhasil', res.message);
|
||||
tampilkanDetail(res.data, res.state);
|
||||
},
|
||||
error: function (xhr) {
|
||||
showNotification('error', 'Gagal', ambilPesanError(xhr));
|
||||
},
|
||||
complete: function () {
|
||||
$btn.prop('disabled', false).text(originalText);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
$('#formTolak').on('submit', function (e) {
|
||||
e.preventDefault();
|
||||
const $btn = $(this).find('button[type=submit]');
|
||||
const originalText = $btn.text();
|
||||
$btn.prop('disabled', true).text('Memproses...');
|
||||
|
||||
$.ajax({
|
||||
url: `${apiBase}/tolak?token=${encodeURIComponent(token)}`,
|
||||
method: 'POST',
|
||||
data: {
|
||||
catatan: $(this).find('[name=catatan]').val(),
|
||||
},
|
||||
success: function (res) {
|
||||
showNotification('success', 'Berhasil', res.message);
|
||||
tampilkanDetail(res.data, res.state);
|
||||
},
|
||||
error: function (xhr) {
|
||||
showNotification('error', 'Gagal', ambilPesanError(xhr));
|
||||
},
|
||||
complete: function () {
|
||||
$btn.prop('disabled', false).text(originalText);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
||||
muatData();
|
||||
</script>
|
||||
</body>
|
||||
|
||||
</html>
|
||||
@@ -4,6 +4,7 @@ use App\Http\Controllers\Auth\LoginController;
|
||||
use App\Http\Controllers\Auth\OauthController;
|
||||
use App\Http\Controllers\CaptchaController;
|
||||
use App\Http\Controllers\JurnalController;
|
||||
use App\Http\Controllers\VerifikasiAbsenHalamanController;
|
||||
use Illuminate\Support\Facades\Route;
|
||||
|
||||
Route::get('/', function () {
|
||||
@@ -26,6 +27,11 @@ Route::get('/auth/google/callback', [OauthController::class, 'callback'])->name(
|
||||
// Jurnal Routes
|
||||
Route::get('/jurnal', [JurnalController::class, 'index']);
|
||||
|
||||
// Halaman Verifikasi Presensi via WhatsApp (publik, otorisasi lewat token di query string)
|
||||
Route::get('/verifikasi-absen/{id}', [VerifikasiAbsenHalamanController::class, 'show'])
|
||||
->where('id', '[0-9]+')
|
||||
->name('verifikasi-absen.halaman');
|
||||
|
||||
Route::middleware('auth')->group(function () {
|
||||
include __DIR__.'/prefix/profil.php';
|
||||
include __DIR__.'/prefix/dashboard.php';
|
||||
|
||||
Reference in New Issue
Block a user