update basic data surveyor

This commit is contained in:
majid
2024-11-25 16:40:14 +07:00
parent 102f0e07ae
commit 107b1ca590
29 changed files with 1225 additions and 246 deletions

View File

@@ -4,6 +4,7 @@ namespace Modules\Lpj\Http\Controllers;
use Illuminate\Http\Request;
use Modules\Lpj\Models\Permohonan;
use Modules\Lpj\Models\Inspeksi;
use App\Http\Controllers\Controller;
class PenilaiController extends Controller
@@ -21,6 +22,22 @@ class PenilaiController extends Controller
/**
* Show the form for creating a new resource.
*/
public function lampiran($id){
$permohonan = Permohonan::with('debiture.documents')->find($id);
$jaminanId = $permohonan->debiture->documents->first()->jenis_jaminan_id;
$inpeksi = Inspeksi::where('permohonan_id', $id)->where('jenis_jaminan_id', $jaminanId)->first();
$formFoto = null;
if ($inpeksi) {
$formFoto = json_decode($inpeksi->foto_form, true);
}
return view('lpj::penilai.lampiran', compact('permohonan', 'formFoto'));
}
public function create()
{
return view('lpj::create');