Penambahan Sementara Pengajuan Presensi WhatsApp

This commit is contained in:
Ariyutta
2026-09-15 14:42:01 +07:00
parent 88d27ef207
commit ffcfdd3579
23 changed files with 1257 additions and 384 deletions
+33
View File
@@ -0,0 +1,33 @@
<?php
namespace App\Services;
use Illuminate\Support\Facades\Log;
use Throwable;
class GoogleDriveService
{
// TODO: isi path credentials service account (JSON) & folder ID tujuan setelah tersedia.
private string $credentialsPath = '';
private string $folderId = '';
public function uploadPdf(string $content, string $fileName): string|false
{
if (! $this->credentialsPath || ! $this->folderId) {
Log::error("GoogleDriveService: belum dikonfigurasi, upload '$fileName' dilewati.");
return false;
}
try {
// TODO: implementasi upload pakai google/apiclient setelah credentials tersedia.
} catch (Throwable $th) {
Log::error('GoogleDriveService uploadPdf : '.$th->getMessage());
return false;
}
return false;
}
}