Merge branch 'staging' into feature/senior-officer
This commit is contained in:
44
app/Http/Controllers/LampiranDokumenController.php
Normal file
44
app/Http/Controllers/LampiranDokumenController.php
Normal file
@@ -0,0 +1,44 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Modules\Lpj\Http\Controllers;
|
||||||
|
|
||||||
|
use App\Http\Controllers\Controller;
|
||||||
|
use Illuminate\Http\Request;
|
||||||
|
use Illuminate\Support\Facades\Storage;
|
||||||
|
use Modules\Lpj\Models\LampiranDokumen;
|
||||||
|
|
||||||
|
class LampiranDokumenController extends Controller
|
||||||
|
{
|
||||||
|
public function download($id)
|
||||||
|
{
|
||||||
|
$lampiran = LampiranDokumen::findOrFail($id);
|
||||||
|
return Storage::download($lampiran->path_file, $lampiran->nama_file);
|
||||||
|
}
|
||||||
|
|
||||||
|
public function upload(Request $request)
|
||||||
|
{
|
||||||
|
$request->validate([
|
||||||
|
'permohonan_id' => 'required|exists:permohonan,id',
|
||||||
|
'nama_file' => 'nullable|string|max:255',
|
||||||
|
'file' => 'required|file|max:10240',
|
||||||
|
'keterangan' => 'nullable|string|max:255',
|
||||||
|
]);
|
||||||
|
|
||||||
|
$lampiran = LampiranDokumen::uploadLampiran($request->all());
|
||||||
|
|
||||||
|
if ($lampiran) {
|
||||||
|
return redirect()->back()->with('success', 'Lampiran uploaded successfully');
|
||||||
|
} else {
|
||||||
|
return redirect()->back()->with('error', 'Unauthorized or upload failed');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public function delete(LampiranDokumen $lampiran)
|
||||||
|
{
|
||||||
|
if ($lampiran->deleteLampiran()) {
|
||||||
|
return redirect()->back()->with('success', 'Lampiran deleted successfully');
|
||||||
|
} else {
|
||||||
|
return redirect()->back()->with('error', 'Unauthorized or delete failed');
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -10,7 +10,6 @@ use Illuminate\Support\Facades\Auth;
|
|||||||
use Illuminate\Support\Facades\Validator;
|
use Illuminate\Support\Facades\Validator;
|
||||||
use Maatwebsite\Excel\Facades\Excel;
|
use Maatwebsite\Excel\Facades\Excel;
|
||||||
use Modules\Lpj\Http\Requests\PersetujuanPenawaranRequest;
|
use Modules\Lpj\Http\Requests\PersetujuanPenawaranRequest;
|
||||||
use Modules\Lpj\Models\LaporanExternal;
|
|
||||||
use Modules\Lpj\Models\PenawaranTender;
|
use Modules\Lpj\Models\PenawaranTender;
|
||||||
use Modules\Lpj\Models\Permohonan;
|
use Modules\Lpj\Models\Permohonan;
|
||||||
use Modules\Lpj\Models\PersetujuanPenawaran;
|
use Modules\Lpj\Models\PersetujuanPenawaran;
|
||||||
@@ -236,13 +235,6 @@ class PembayaranController extends Controller
|
|||||||
'updated_by' => Auth::id(),
|
'updated_by' => Auth::id(),
|
||||||
'updated_at' => now(),
|
'updated_at' => now(),
|
||||||
]);
|
]);
|
||||||
|
|
||||||
LaporanExternal::create([
|
|
||||||
'permohonan_id' => $permohonan->id,
|
|
||||||
'nomor_laporan' => $permohonan->nomor_registrasi,
|
|
||||||
'tanggal_laporan' => now(),
|
|
||||||
'created_by' => Auth::id(),
|
|
||||||
]);
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -18,6 +18,7 @@ use Illuminate\Support\Carbon;
|
|||||||
use Illuminate\Support\Facades\Mail;
|
use Illuminate\Support\Facades\Mail;
|
||||||
use Illuminate\Http\Response;
|
use Illuminate\Http\Response;
|
||||||
use Modules\Lpj\Models\Debiture;
|
use Modules\Lpj\Models\Debiture;
|
||||||
|
use Modules\Lpj\Models\LaporanExternal;
|
||||||
use Modules\Lpj\Models\Permohonan;
|
use Modules\Lpj\Models\Permohonan;
|
||||||
use Modules\Lpj\Models\Branch;
|
use Modules\Lpj\Models\Branch;
|
||||||
use Modules\Lpj\Models\Surveyor;
|
use Modules\Lpj\Models\Surveyor;
|
||||||
@@ -768,6 +769,15 @@ class SurveyorController extends Controller
|
|||||||
'submitted_at' => now()
|
'submitted_at' => now()
|
||||||
]);
|
]);
|
||||||
|
|
||||||
|
LaporanExternal::updateOrCreate(
|
||||||
|
['permohonan_id' => $permohonan->id],
|
||||||
|
[
|
||||||
|
'nomor_laporan' => $permohonan->nomor_registrasi,
|
||||||
|
'tanggal_laporan' => now(),
|
||||||
|
'created_by' => Auth::id(),
|
||||||
|
]
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
return response()->json([
|
return response()->json([
|
||||||
'success' => true,
|
'success' => true,
|
||||||
|
|||||||
67
app/Models/LampiranDokumen.php
Normal file
67
app/Models/LampiranDokumen.php
Normal file
@@ -0,0 +1,67 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Modules\Lpj\Models;
|
||||||
|
|
||||||
|
use Illuminate\Support\Facades\Auth;
|
||||||
|
use Illuminate\Support\Facades\Storage;
|
||||||
|
|
||||||
|
class LampiranDokumen extends Base
|
||||||
|
{
|
||||||
|
protected $table = 'lampiran_dokumen';
|
||||||
|
|
||||||
|
protected $fillable = ['permohonan_id', 'nama_file', 'path_file', 'keterangan'];
|
||||||
|
|
||||||
|
public function permohonan()
|
||||||
|
{
|
||||||
|
return $this->belongsTo(Permohonan::class);
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Upload lampiran dokumen for penilai or administrator
|
||||||
|
*
|
||||||
|
* @param int $permohonanId
|
||||||
|
* @param array $fileData
|
||||||
|
* @return LampiranDokumen|null
|
||||||
|
*/
|
||||||
|
public static function uploadLampiran($fileData)
|
||||||
|
{
|
||||||
|
$user = Auth::user();
|
||||||
|
|
||||||
|
if ($user && ($user->hasRole('penilai') || $user->hasRole('administrator'))) {
|
||||||
|
$file = $fileData['file'];
|
||||||
|
$keterangan = $fileData['keterangan'] ?? null;
|
||||||
|
|
||||||
|
$fileName = $fileData['nama_file'] ?? time() . '_' . $file->getClientOriginalName();
|
||||||
|
$filePath = $file->storeAs('lampiran_dokumen', $fileName, 'public');
|
||||||
|
|
||||||
|
return self::create([
|
||||||
|
'permohonan_id' => $fileData['permohonan_id'] ?? null,
|
||||||
|
'nama_file' => $fileName,
|
||||||
|
'path_file' => $filePath,
|
||||||
|
'keterangan' => $keterangan,
|
||||||
|
]);
|
||||||
|
}
|
||||||
|
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Delete lampiran dokumen
|
||||||
|
*
|
||||||
|
* @return bool
|
||||||
|
*/
|
||||||
|
public function deleteLampiran()
|
||||||
|
{
|
||||||
|
$user = Auth::user();
|
||||||
|
|
||||||
|
if ($user && ($user->hasRole('penilai') || $user->hasRole('administrator'))) {
|
||||||
|
// Delete the file from storage
|
||||||
|
Storage::disk('public')->delete($this->path_file);
|
||||||
|
|
||||||
|
// Delete the database record
|
||||||
|
return $this->delete();
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -161,7 +161,8 @@
|
|||||||
return $this->belongsTo(JenisFasilitasKredit::class);
|
return $this->belongsTo(JenisFasilitasKredit::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function jenisPenilaian(){
|
public function jenisPenilaian()
|
||||||
|
{
|
||||||
return $this->belongsTo(JenisPenilaian::class);
|
return $this->belongsTo(JenisPenilaian::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -170,7 +171,8 @@
|
|||||||
return $this->belongsTo(Penilaian::class, 'nomor_registrasi', 'nomor_registrasi');
|
return $this->belongsTo(Penilaian::class, 'nomor_registrasi', 'nomor_registrasi');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function penilai(){
|
public function penilai()
|
||||||
|
{
|
||||||
return $this->belongsTo(Penilai::class, 'id', 'permohonan_id');
|
return $this->belongsTo(Penilai::class, 'id', 'permohonan_id');
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -199,27 +201,38 @@
|
|||||||
return $this->hasMany(DokumenJaminan::class);
|
return $this->hasMany(DokumenJaminan::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function pembatalan(){
|
public function pembatalan()
|
||||||
|
{
|
||||||
return $this->hasMany(PermohonanPembatalan::class);
|
return $this->hasMany(PermohonanPembatalan::class);
|
||||||
}
|
}
|
||||||
|
|
||||||
public function approveBayar(){
|
public function approveBayar()
|
||||||
|
{
|
||||||
return $this->belongsTo(User::class, 'approve_bayar_by', 'id');
|
return $this->belongsTo(User::class, 'approve_bayar_by', 'id');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function approveEo(){
|
public function approveEo()
|
||||||
|
{
|
||||||
return $this->belongsTo(User::class, 'approval_eo', 'id');
|
return $this->belongsTo(User::class, 'approval_eo', 'id');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function approveDd(){
|
public function approveDd()
|
||||||
|
{
|
||||||
return $this->belongsTo(User::class, 'approval_dd', 'id');
|
return $this->belongsTo(User::class, 'approval_dd', 'id');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function approveSo(){
|
public function approveSo()
|
||||||
|
{
|
||||||
return $this->belongsTo(User::class, 'approval_so', 'id');
|
return $this->belongsTo(User::class, 'approval_so', 'id');
|
||||||
}
|
}
|
||||||
|
|
||||||
public function authorization(){
|
public function authorization()
|
||||||
|
{
|
||||||
return $this->belongsTo(Authorization::class, 'id', 'permohonan_id');
|
return $this->belongsTo(Authorization::class, 'id', 'permohonan_id');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function lampiranDokumen()
|
||||||
|
{
|
||||||
|
return $this->hasMany(LampiranDokumen::class);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,32 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
use Illuminate\Database\Migrations\Migration;
|
||||||
|
use Illuminate\Database\Schema\Blueprint;
|
||||||
|
use Illuminate\Support\Facades\Schema;
|
||||||
|
|
||||||
|
class CreateLampiranDokumenTable extends Migration
|
||||||
|
{
|
||||||
|
public function up()
|
||||||
|
{
|
||||||
|
Schema::create('lampiran_dokumen', function (Blueprint $table) {
|
||||||
|
$table->id();
|
||||||
|
$table->unsignedBigInteger('permohonan_id');
|
||||||
|
$table->string('nama_file');
|
||||||
|
$table->string('path_file');
|
||||||
|
$table->text('keterangan')->nullable();
|
||||||
|
$table->timestamps();
|
||||||
|
$table->softDeletes();
|
||||||
|
|
||||||
|
$table->unsignedBigInteger('created_by')->nullable();
|
||||||
|
$table->unsignedBigInteger('updated_by')->nullable();
|
||||||
|
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||||
|
|
||||||
|
$table->foreign('permohonan_id')->references('id')->on('permohonan')->onDelete('cascade');
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
public function down()
|
||||||
|
{
|
||||||
|
Schema::dropIfExists('lampiran_dokumen');
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -199,6 +199,8 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div class="card border border-agi-100 min-w-full">
|
<div class="card border border-agi-100 min-w-full">
|
||||||
<div class="card-header light:bg-agi-50">
|
<div class="card-header light:bg-agi-50">
|
||||||
<h3 class="card-title">
|
<h3 class="card-title">
|
||||||
@@ -348,6 +350,72 @@
|
|||||||
@if (!isset($status))
|
@if (!isset($status))
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<!-- New section for Lampiran Dokumen -->
|
||||||
|
<div class="card border border-agi-100 min-w-full mt-5">
|
||||||
|
<div class="card-header light:bg-agi-50">
|
||||||
|
<h3 class="card-title">
|
||||||
|
Lampiran Dokumen
|
||||||
|
</h3>
|
||||||
|
</div>
|
||||||
|
<div class="card-body">
|
||||||
|
<div class="grid grid-cols-1 md:grid-cols-2 lg:grid-cols-3 gap-4">
|
||||||
|
@forelse($permohonan->lampiranDokumen as $lampiran)
|
||||||
|
<div class="border p-4 rounded-lg">
|
||||||
|
<h4 class="font-semibold mb-2">{{ $lampiran->nama_file }}</h4>
|
||||||
|
<p class="text-sm text-gray-600 mb-2">Keterangan : {{ $lampiran->keterangan }}</p>
|
||||||
|
<div class="flex justify-between items-center">
|
||||||
|
<div>
|
||||||
|
<a href="{{ Storage::url($lampiran->path_file) }}" target="_blank" class="text-blue-600 hover:underline">
|
||||||
|
<i class="ki-filled ki-eye mr-2"></i>View
|
||||||
|
</a>
|
||||||
|
<a href="{{ Storage::url($lampiran->path_file) }}" download="{{ Storage::url($lampiran->path_file) }}" class="text-green-600 hover:underline ml-4">
|
||||||
|
<i class="ki-filled ki-cloud-download mr-2"></i>Download
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
@if(Auth::user()->hasRole('administrator'))
|
||||||
|
<form action="{{ route('lampiran.delete', $lampiran->id) }}" method="POST" onsubmit="return confirm('Are you sure you want to delete this lampiran?');">
|
||||||
|
@csrf
|
||||||
|
@method('DELETE')
|
||||||
|
<button type="submit" class="text-red-600 hover:underline">
|
||||||
|
<i class="ki-filled ki-trash mr-2"></i>Delete
|
||||||
|
</button>
|
||||||
|
</form>
|
||||||
|
@endif
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
@empty
|
||||||
|
<p class="col-span-3 text-center text-gray-500">Tidak ada lampiran dokumen.</p>
|
||||||
|
@endforelse
|
||||||
|
</div>
|
||||||
|
|
||||||
|
@if(Auth::user()->hasRole(['penilai', 'administrator']))
|
||||||
|
<form action="{{ route('lampiran.upload',) }}" method="POST" enctype="multipart/form-data" class="mt-6">
|
||||||
|
@csrf
|
||||||
|
<input type="hidden" name="permohonan_id" value="{{ $permohonan->id }}">
|
||||||
|
<div class="grid grid-cols-1 md:grid-cols-2 gap-4">
|
||||||
|
<div>
|
||||||
|
<label for="nama_file" class="block text-sm font-medium text-gray-700">Nama File</label>
|
||||||
|
<input type="text" name="nama_file" id="nama_file" required class="input mt-1 focus:ring-indigo-500 focus:border-indigo-500 block w-full shadow-sm sm:text-sm border-gray-300 rounded-md">
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<label for="file" class=" block text-sm font-medium text-gray-700">File</label>
|
||||||
|
<input type="file" name="file" id="file" required class="file-input mt-1 focus:ring-indigo-500 focus:border-indigo-500 block w-full shadow-sm sm:text-sm border-gray-300 rounded-md">
|
||||||
|
</div>
|
||||||
|
<div class="md:col-span-2">
|
||||||
|
<label for="keterangan" class="block text-sm font-medium text-gray-700">Keterangan</label>
|
||||||
|
<textarea name="keterangan" id="keterangan" rows="3" class="textarea mt-1 focus:ring-indigo-500 focus:border-indigo-500 block w-full shadow-sm sm:text-sm border-gray-300 rounded-md"></textarea>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="mt-4">
|
||||||
|
<button type="submit" class="inline-flex justify-center py-2 px-4 border border-transparent shadow-sm text-sm font-medium rounded-md text-white bg-indigo-600 hover:bg-indigo-700 focus:outline-none focus:ring-2 focus:ring-offset-2 focus:ring-indigo-500">
|
||||||
|
Upload Lampiran
|
||||||
|
</button>
|
||||||
|
</div>
|
||||||
|
</form>
|
||||||
|
@endif
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
@include('lpj::component.history-permohonan')
|
@include('lpj::component.history-permohonan')
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -150,7 +150,7 @@
|
|||||||
tujuan_penilaian: {
|
tujuan_penilaian: {
|
||||||
title: 'Tujuan Penilaian',
|
title: 'Tujuan Penilaian',
|
||||||
render: (item, data) => {
|
render: (item, data) => {
|
||||||
return `${data.permohonan.penawaran?.tujuanPenilaianKjpp.name}` ?? '';
|
return `${data.permohonan.penawaran?.tujuan_penilaian_kjpp?.name}` ?? '';
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
jenis_jaminan: {
|
jenis_jaminan: {
|
||||||
|
|||||||
@@ -1,212 +1,155 @@
|
|||||||
@extends('layouts.auth')
|
@extends('layouts.auth')
|
||||||
|
|
||||||
|
@push('styles')
|
||||||
|
<style>
|
||||||
|
@media print {
|
||||||
|
body {
|
||||||
|
font-size: 10pt;
|
||||||
|
color: #000;
|
||||||
|
background-color: #fff;
|
||||||
|
line-height: 1.4;
|
||||||
|
}
|
||||||
|
.container {
|
||||||
|
width: 100%;
|
||||||
|
max-width: 100%;
|
||||||
|
padding: 0;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
.crd {
|
||||||
|
border: none !important;
|
||||||
|
box-shadow: none !important;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
.crd-header {
|
||||||
|
background-color: #f1f1f1 !important;
|
||||||
|
-webkit-print-color-adjust: exact;
|
||||||
|
padding: 3px 8px !important; /* Mengubah padding menjadi lebih tipis */
|
||||||
|
font-weight: bold;
|
||||||
|
font-size: 11pt; /* Sedikit memperkecil ukuran font */
|
||||||
|
}
|
||||||
|
|
||||||
|
.crd-body {
|
||||||
|
padding: 8px !important; /* Menyesuaikan padding body agar seimbang */
|
||||||
|
}
|
||||||
|
.no-print {
|
||||||
|
display: none !important;
|
||||||
|
}
|
||||||
|
.page-break {
|
||||||
|
page-break-before: always;
|
||||||
|
}
|
||||||
|
h1 {
|
||||||
|
font-size: 16pt;
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
h3 {
|
||||||
|
font-size: 12pt;
|
||||||
|
margin: 0;
|
||||||
|
}
|
||||||
|
h4 {
|
||||||
|
font-size: 11pt;
|
||||||
|
margin: 10px 0 5px;
|
||||||
|
}
|
||||||
|
p {
|
||||||
|
margin: 0 0 5px;
|
||||||
|
}
|
||||||
|
.grid {
|
||||||
|
display: flex;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
}
|
||||||
|
.col-1 {
|
||||||
|
flex: 0 0 33.333%;
|
||||||
|
max-width: 33.333%;
|
||||||
|
}
|
||||||
|
.col-2 {
|
||||||
|
flex: 0 0 66.666%;
|
||||||
|
max-width: 66.666%;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
@endpush
|
||||||
|
|
||||||
@section('content')
|
@section('content')
|
||||||
<div class="w-full gap-5 mx-auto" id="printtable">
|
<div class="container" id="printtable">
|
||||||
<div class="gap-5 w-full">
|
|
||||||
<div class="card">
|
|
||||||
<div class="card-body lg:py-7.5 grid grid-cols-2">
|
|
||||||
<div>
|
|
||||||
<div class="mb-5 grid grid-cols-2">
|
|
||||||
<h3 class="text-md text-gray-900 w-1/2">
|
|
||||||
Nomor Register Permohonan
|
|
||||||
</h3>
|
|
||||||
<span class="text-md font-medium text-gray-900 w-1/2">
|
|
||||||
: {{ $permohonan->nomor_registrasi }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="mb-5 grid grid-cols-2">
|
<div class="crd">
|
||||||
<h3 class="text-md text-gray-900 w-1/2">
|
<div class="crd-body">
|
||||||
Pemohon
|
<table style="width: 100%; border-collapse: collapse;">
|
||||||
</h3>
|
<tr>
|
||||||
<span class="text-md font-medium text-gray-900 w-1/2">
|
<td style="width: 40%; vertical-align: top; padding-right: 10px;">
|
||||||
: {{ $permohonan->user->nik }} | {{ $permohonan->user->name }}
|
@include('lpj::component.logo-bag')
|
||||||
</span>
|
</td>
|
||||||
</div>
|
<td style="width: 60%; vertical-align: top; text-align: right;">
|
||||||
|
<h1 style="font-size: 12pt; margin: 0; font-weight: bold;">PT BANK ARTHA GRAHA INTERNASIONAL</h1>
|
||||||
|
<p style="font-size: 10pt; margin:0;">Sub Direktorat Appraisal</p>
|
||||||
|
<p style="font-size: 10pt; margin: 0;">Jl. Kwitang Raya No. 24-26,<br>Jakarta – 10420, Indonesia</p>
|
||||||
|
<p style="font-size: 10pt; margin: 0;">Telp. (021) 3903040</p>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</table>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="mb-5 grid grid-cols-2">
|
<div class="crd">
|
||||||
<h3 class="text-md text-gray-900 w-1/2">
|
<div class="crd-body">
|
||||||
Tujan Permohonan
|
<div class="grid">
|
||||||
</h3>
|
<div class="col-1">
|
||||||
<span class="text-md font-medium text-gray-900 w-1/2">
|
<p><strong>Nomor Register:</strong> {{ $permohonan->nomor_registrasi }}</p>
|
||||||
: {{ $permohonan->tujuanPenilaian->name }}
|
<p><strong>Pemohon:</strong> {{ $permohonan->user->nik }} | {{ $permohonan->user->name }}</p>
|
||||||
</span>
|
<p><strong>Tujuan Permohonan:</strong> {{ $permohonan->tujuanPenilaian->name }}</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
<div class="col-1">
|
||||||
<div>
|
<p><strong>Status Permohonan:</strong> {{ ucwords($permohonan->status) }}</p>
|
||||||
<div class="mb-5 grid grid-cols-2">
|
<p><strong>Cabang Pemohon:</strong> {{ $permohonan->user->branch->name }}</p>
|
||||||
<h3 class="text-md text-gray-900 w-1/2">
|
<p><strong>Tanggal Permohonan:</strong> {{ formatTanggalIndonesia($permohonan->created_at) }}</p>
|
||||||
Status Permohonan
|
|
||||||
</h3>
|
|
||||||
<span class="text-md font-medium text-gray-900 w-1/2">
|
|
||||||
: {{ ucwords($permohonan->status) }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="mb-5 grid grid-cols-2">
|
|
||||||
<h3 class="text-md text-gray-900 w-1/2">
|
|
||||||
Cabang Pemohon
|
|
||||||
</h3>
|
|
||||||
<span class="text-md font-medium text-gray-900 w-1/2">
|
|
||||||
: {{ $permohonan->user->branch->name }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="mb-5 grid grid-cols-2">
|
|
||||||
<h3 class="text-md text-gray-900 w-1/2">
|
|
||||||
Tanggal Permohonan
|
|
||||||
</h3>
|
|
||||||
<span class="text-md font-medium text-gray-900 w-1/2">
|
|
||||||
: {{ formatTanggalIndonesia($permohonan->created_at) }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="gap-5 w-full grid grid-cols-3 mt-5">
|
</div>
|
||||||
<div>
|
|
||||||
<div class="card border border-agi-100 min-w-full">
|
|
||||||
<div class="card-header bg-agi-50" id="advanced_settings_appearance">
|
|
||||||
<h3 class="card-title">
|
|
||||||
1. Fasilitas Kredit
|
|
||||||
</h3>
|
|
||||||
</div>
|
|
||||||
<div class="card-body lg:py-7.5">
|
|
||||||
<div class="mb-5 grid grid-cols-2">
|
|
||||||
<h3 class="text-md text-gray-900">
|
|
||||||
Jenis Fasilitas
|
|
||||||
</h3>
|
|
||||||
<span class="text-md font-medium text-gray-900">
|
|
||||||
: {{ $permohonan->jenisFasilitasKredit->name }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="mb-5 grid grid-cols-2">
|
<div class="grid">
|
||||||
<h3 class="text-md text-gray-900">
|
<div class="col-1">
|
||||||
Nilai Plafond
|
<div class="crd">
|
||||||
</h3>
|
<div class="crd-header">1. Fasilitas Kredit</div>
|
||||||
<span class="text-md font-medium text-gray-900">
|
<div class="crd-body">
|
||||||
: {{ $permohonan->nilaiPlafond->name }}
|
<p><strong>Jenis Fasilitas:</strong> {{ $permohonan->jenisFasilitasKredit->name }}</p>
|
||||||
</span>
|
<p><strong>Nilai Plafond:</strong> {{ $permohonan->nilaiPlafond->name }}</p>
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="card border border-agi-100 mt-5 min-w-full">
|
|
||||||
<div class="card-header bg-agi-50">
|
|
||||||
<h3 class="card-title">
|
|
||||||
2. Identitas Debutur
|
|
||||||
</h3>
|
|
||||||
</div>
|
|
||||||
<div class="card-table scrollable-x-auto pb-3">
|
|
||||||
<div class="grid grid-cols-1 xl:grid-cols-2 gap-5 lg:gap-7.5">
|
|
||||||
<div class="col-span-1">
|
|
||||||
<table class="table align-middle text-sm text-gray-500">
|
|
||||||
<tr>
|
|
||||||
<td class="py-2 text-gray-600 font-normal">
|
|
||||||
Name
|
|
||||||
</td>
|
|
||||||
<td class="py-2 text-gray-800 font-normaltext-sm">
|
|
||||||
{{ $permohonan->debiture->name ?? "" }}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td class="py-3 text-gray-600 font-normal">
|
|
||||||
Cabang
|
|
||||||
</td>
|
|
||||||
<td class="py-2 text-gray-800 font-normaltext-sm">
|
|
||||||
{{ $permohonan->debiture->branch->name ?? "" }}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td class="py-3 text-gray-600 font-normal">
|
|
||||||
CIF
|
|
||||||
</td>
|
|
||||||
<td class="py-2 text-gray-800 font-normaltext-sm">
|
|
||||||
{{ $permohonan->debiture->cif ?? "" }}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td class="py-3 text-gray-600 font-normal">
|
|
||||||
Alamat
|
|
||||||
</td>
|
|
||||||
<td class="py-3 text-gray-700 text-sm font-normal">
|
|
||||||
{{ $permohonan->debiture->address ?? "" }}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td class="py-3 text-gray-600 font-normal">
|
|
||||||
|
|
||||||
</td>
|
|
||||||
<td class="py-3 text-gray-700 text-sm font-normal">
|
|
||||||
{{ $permohonan->debiture->village->name ?? "" }}, {{ $permohonan->debiture->district->name ?? "" }}, {{ $permohonan->debiture->city->name ?? "" }}, {{ $permohonan->debiture->province->name ?? "" }} - {{ $permohonan->debiture->village->postal_code ?? "" }}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-span-2">
|
|
||||||
<div class="card border border-agi-100 min-w-full">
|
|
||||||
<div class="card-header bg-agi-50">
|
|
||||||
<h3 class="card-title">
|
|
||||||
Data Jaminan
|
|
||||||
</h3>
|
|
||||||
</div>
|
|
||||||
<div class="card-table scrollable-x-auto pb-3">
|
|
||||||
@foreach($permohonan->documents as $dokumen)
|
|
||||||
<div class="card-body lg:py-7.5">
|
|
||||||
<span class="text-base text-gray-900 font-bold mb-5">
|
|
||||||
Jaminan {{ $loop->index + 1 }}
|
|
||||||
</span>
|
|
||||||
|
|
||||||
<div class="mb-5 grid grid-cols-2 mt-5">
|
<div class="crd">
|
||||||
<h3 class="text-md text-gray-900">
|
<div class="crd-header">2. Identitas Debitur</div>
|
||||||
Pemilik Jaminan
|
<div class="crd-body">
|
||||||
</h3>
|
<p><strong>Nama:</strong> {{ $permohonan->debiture->name ?? "" }}</p>
|
||||||
<span class="text-md font-medium text-gray-900">
|
<p><strong>Cabang:</strong> {{ $permohonan->debiture->branch->name ?? "" }}</p>
|
||||||
: {{ $dokumen->pemilik->name?? "" }}
|
<p><strong>CIF:</strong> {{ $permohonan->debiture->cif ?? "" }}</p>
|
||||||
</span>
|
<p><strong>Alamat:</strong> {{ $permohonan->debiture->address ?? "" }}</p>
|
||||||
</div>
|
<p>{{ $permohonan->debiture->village->name ?? "" }}, {{ $permohonan->debiture->district->name ?? "" }}, {{ $permohonan->debiture->city->name ?? "" }}, {{ $permohonan->debiture->province->name ?? "" }} - {{ $permohonan->debiture->village->postal_code ?? "" }}</p>
|
||||||
<div class="mb-5 grid grid-cols-2">
|
|
||||||
<h3 class="text-md text-gray-900">
|
|
||||||
Jenis Jaminan:
|
|
||||||
</h3>
|
|
||||||
<span class="text-md font-medium text-gray-900">
|
|
||||||
: {{ $dokumen->jenisJaminan->name?? "" }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
<div class="mb-5 grid grid-cols-2">
|
|
||||||
<h3 class="text-md text-gray-900">
|
|
||||||
Hubungan Pemilik Jaminan:
|
|
||||||
</h3>
|
|
||||||
<span class="text-md font-medium text-gray-900">
|
|
||||||
: {{ $dokumen->pemilik->hubungan_pemilik->name?? "" }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
<div class="mb-5 grid grid-cols-2">
|
|
||||||
<h3 class="text-md text-gray-900">
|
|
||||||
Alamat Pemilik Jaminan:
|
|
||||||
</h3>
|
|
||||||
<span class="text-md font-medium text-gray-900">
|
|
||||||
: {{ $dokumen->pemilik->address ?? ""}},
|
|
||||||
<br> {{ $dokumen->pemilik->village->name ?? "" }}, {{ $dokumen->pemilik->district->name ?? "" }}, {{ $dokumen->pemilik->city->name ?? "" }}, {{ $dokumen->pemilik->province->name ?? "" }} - {{ $dokumen->pemilik->village->postal_code ?? "" }}
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
@endforeach
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="col-2">
|
||||||
|
<div class="crd">
|
||||||
|
<div class="crd-header">3. Data Jaminan</div>
|
||||||
|
<div class="crd-body">
|
||||||
|
@foreach($permohonan->documents as $index => $dokumen)
|
||||||
|
<h4>Jaminan {{ $index + 1 }}</h4>
|
||||||
|
<p><strong>Pemilik Jaminan:</strong> {{ $dokumen->pemilik->name ?? "" }}</p>
|
||||||
|
<p><strong>Jenis Jaminan:</strong> {{ $dokumen->jenisJaminan->name ?? "" }}</p>
|
||||||
|
<p><strong>Hubungan Pemilik Jaminan:</strong> {{ $dokumen->pemilik->hubungan_pemilik->name ?? "" }}</p>
|
||||||
|
@if(!$loop->last)<hr style="margin: 10px 0;">@endif
|
||||||
|
@endforeach
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
@endsection
|
@endsection
|
||||||
|
|
||||||
@push('scripts')
|
@push('scripts')
|
||||||
<script type="module">
|
<script type="module">
|
||||||
var printtable = document.getElementById('printtable');
|
window.onload = function() {
|
||||||
window.print(printtable);
|
window.print();
|
||||||
</script>
|
}
|
||||||
|
</script>
|
||||||
@endpush
|
@endpush
|
||||||
|
|||||||
@@ -16,7 +16,8 @@ use Modules\Lpj\Http\Controllers\JenisLaporanController;
|
|||||||
use Modules\Lpj\Http\Controllers\JenisLegalitasJaminanController;
|
use Modules\Lpj\Http\Controllers\JenisLegalitasJaminanController;
|
||||||
use Modules\Lpj\Http\Controllers\JenisPenilaianController;
|
use Modules\Lpj\Http\Controllers\JenisPenilaianController;
|
||||||
use Modules\Lpj\Http\Controllers\KJPPController;
|
use Modules\Lpj\Http\Controllers\KJPPController;
|
||||||
use Modules\Lpj\Http\Controllers\LaporanController;
|
use Modules\Lpj\Http\Controllers\LampiranDokumenController;
|
||||||
|
use Modules\Lpj\Http\Controllers\LaporanController;
|
||||||
use Modules\Lpj\Http\Controllers\LaporanExternalController;
|
use Modules\Lpj\Http\Controllers\LaporanExternalController;
|
||||||
use Modules\Lpj\Http\Controllers\NilaiPlafondController;
|
use Modules\Lpj\Http\Controllers\NilaiPlafondController;
|
||||||
use Modules\Lpj\Http\Controllers\NocController;
|
use Modules\Lpj\Http\Controllers\NocController;
|
||||||
@@ -645,6 +646,9 @@ Route::middleware(['auth'])->group(function () {
|
|||||||
});
|
});
|
||||||
Route::resource('laporan-external', LaporanExternalController::class);
|
Route::resource('laporan-external', LaporanExternalController::class);
|
||||||
|
|
||||||
|
Route::get('/lampiran/download/{id}', [LampiranDokumenController::class, 'download'])->name('lampiran.download');
|
||||||
|
Route::post('lampiran/upload', [LampiranDokumenController::class, 'upload'])->name('lampiran.upload');
|
||||||
|
Route::delete('lampiran/{lampiran}', [LampiranDokumenController::class, 'delete'])->name('lampiran.delete');
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user