Merge pull request 'staging' (#24) from staging into dev
Reviewed-on: #24
This commit is contained in:
41
app/Helpers/Lpj.php
Normal file
41
app/Helpers/Lpj.php
Normal file
@@ -0,0 +1,41 @@
|
||||
<?php
|
||||
|
||||
use Carbon\Carbon;
|
||||
|
||||
function formatTanggalIndonesia($date)
|
||||
{
|
||||
$carbonDate = Carbon::parse($date);
|
||||
$indonesianMonths = [
|
||||
'Januari',
|
||||
'Februari',
|
||||
'Maret',
|
||||
'April',
|
||||
'Mei',
|
||||
'Juni',
|
||||
'Juli',
|
||||
'Agustus',
|
||||
'September',
|
||||
'Oktober',
|
||||
'November',
|
||||
'Desember',
|
||||
];
|
||||
$month = $indonesianMonths[$carbonDate->month - 1];
|
||||
return $carbonDate->format('d') . ' ' . $month . ' ' . $carbonDate->format('Y');
|
||||
}
|
||||
|
||||
|
||||
function formatRupiah($number)
|
||||
{
|
||||
$number = (float) $number;
|
||||
return 'Rp ' . number_format($number, 2, ',', '.');
|
||||
}
|
||||
|
||||
|
||||
function formatAlamat($alamat)
|
||||
{
|
||||
return ($alamat->address ? $alamat->address . ', ' : '') .
|
||||
(isset($alamat->village) ? $alamat->village->name . ', ' : '') .
|
||||
(isset($alamat->city) ? $alamat->city->name . ', ' : '') .
|
||||
(isset($alamat->province) ? $alamat->province->name . ', ' : '') .
|
||||
($alamat->postal_code ?? '');
|
||||
}
|
||||
@@ -38,15 +38,15 @@ class ProsesPenawaranController extends Controller
|
||||
}
|
||||
|
||||
// Retrieve data from the database
|
||||
$query =PenawaranTender::query()->where('status','=','tender')->withCount('penawarandetails');
|
||||
|
||||
$query = PenawaranTender::query()->where('status', '=', 'tender')->withCount('penawarandetails');
|
||||
|
||||
// Apply search filter if provided
|
||||
if ($request->has('search') && !empty($request->get('search'))) {
|
||||
$search = $request->get('search');
|
||||
$query->where(function ($q) use ($search) {
|
||||
$q->where('nomor_registrasi', 'LIKE', '%' . $search . '%');
|
||||
$q->orWhere('tanggal_permohonan', 'LIKE', '%' . $search . '%');
|
||||
|
||||
$q->orWhereRelation('tujuanPenilaianKJPP', 'name', 'LIKE', '%' . $search . '%');
|
||||
$q->orWhere('status', 'LIKE', '%' . $search . '%');
|
||||
});
|
||||
}
|
||||
@@ -75,7 +75,7 @@ class ProsesPenawaranController extends Controller
|
||||
|
||||
// Get the data for the current page
|
||||
//$data = $query->with(['user', 'debiture', 'branch', 'tujuanPenilaian'])->get();
|
||||
$data = $query->get();
|
||||
$data = $query->with(['tujuanPenilaianKJPP'])->get();
|
||||
|
||||
// Calculate the page count
|
||||
$pageCount = ceil($totalRecords / $request->get('size'));
|
||||
@@ -109,26 +109,24 @@ class ProsesPenawaranController extends Controller
|
||||
if (request()->ajax()) {
|
||||
$id = $request->id;
|
||||
$penawaran = PenawaranTender::findOrFail($id);
|
||||
$penawrandetails = PenawaranDetailTender::where('penawaran_id','=',$id)
|
||||
->leftJoin('kjpp', 'kjpp.id', '=', 'detail_penawaran.kjpp_rekanan_id')
|
||||
->select('detail_penawaran.*', 'kjpp.code AS kjpp_code', 'kjpp.name AS kjpp_name')
|
||||
->where('detail_penawaran.status','=',1)
|
||||
->get();
|
||||
$penawrandetails = PenawaranDetailTender::where('penawaran_id', '=', $id)
|
||||
->leftJoin('kjpp', 'kjpp.id', '=', 'detail_penawaran.kjpp_rekanan_id')
|
||||
->select('detail_penawaran.*', 'kjpp.code AS kjpp_code', 'kjpp.name AS kjpp_name')
|
||||
->where('detail_penawaran.status', '=', 1)
|
||||
->get();
|
||||
$data['status'] = 'success';
|
||||
if ($penawaran) {
|
||||
$i=0;
|
||||
foreach($penawrandetails as $obj)
|
||||
{
|
||||
$i = 0;
|
||||
foreach ($penawrandetails as $obj) {
|
||||
// dd($obj->dokumen_persetujuan);
|
||||
if($obj->dokumen_persetujuan && Storage::disk('public')->exists($obj->dokumen_persetujuan))
|
||||
{
|
||||
if ($obj->dokumen_persetujuan && Storage::disk('public')->exists($obj->dokumen_persetujuan)) {
|
||||
$penawrandetails_path = Storage::url($obj->dokumen_persetujuan);
|
||||
$penawrandetails[$i]->dokumen_persetujuan = $penawrandetails_path;
|
||||
$i++;
|
||||
}
|
||||
}
|
||||
|
||||
$kjpp=null;
|
||||
$kjpp = null;
|
||||
$kjpp = KJPP::pluck('name', 'id');
|
||||
$data['penawaran'] = $penawaran;
|
||||
$data['penawrandetails'] = $penawrandetails;
|
||||
@@ -157,33 +155,30 @@ class ProsesPenawaranController extends Controller
|
||||
$tindakan = null;
|
||||
if (request()->ajax()) {
|
||||
$validator = ProsesPenawaranController::rulesEditnya($request, $id);
|
||||
|
||||
|
||||
if ($validator['fails']) {
|
||||
$data['message'] = $validator['errors'];
|
||||
$data['status'] = 'error';
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
try {
|
||||
|
||||
$dataku = ['updated_by' => Auth::id(),
|
||||
'updated_at' => now(),
|
||||
'biaya_penawaran' => str_replace(".","",$request->biaya_penawaran)
|
||||
];
|
||||
$dataku = [
|
||||
'updated_by' => Auth::id(),
|
||||
'updated_at' => now(),
|
||||
'biaya_penawaran' => str_replace(".", "", $request->biaya_penawaran)
|
||||
];
|
||||
|
||||
if ($request->hasFile('dokumen_persetujuan'))
|
||||
{
|
||||
if ($request->hasFile('dokumen_persetujuan')) {
|
||||
$file_tmp = $request->file('dokumen_persetujuan');
|
||||
$folderPath = 'uploads/penawaran/';
|
||||
if ($file_tmp->isValid())
|
||||
{
|
||||
$myFile=$file_tmp->getClientOriginalName(); // nama file with extension
|
||||
if ($file_tmp->isValid()) {
|
||||
$myFile = $file_tmp->getClientOriginalName(); // nama file with extension
|
||||
$file_name = pathinfo($myFile, PATHINFO_FILENAME); // nama file without extension
|
||||
|
||||
$extension = $file_tmp->getClientOriginalExtension();
|
||||
// kjppID_penawaranID_namaFile_userID_time
|
||||
$newFileName = $request->kjpp_rekanan_id.'_'.$id.'_'.$file_name.'_'.Auth::user()->id."_".time() .'.'. $extension;
|
||||
Storage::disk('public')->put($folderPath.'/'.$newFileName,file_get_contents($file_tmp));
|
||||
$newFileName = $request->kjpp_rekanan_id . '_' . $id . '_' . $file_name . '_' . Auth::user()->id . "_" . time() . '.' . $extension;
|
||||
Storage::disk('public')->put($folderPath . '/' . $newFileName, file_get_contents($file_tmp));
|
||||
|
||||
$newFileNameWithPath = $folderPath . $newFileName;
|
||||
$dataku['attachment'] = $myFile;
|
||||
@@ -195,26 +190,20 @@ class ProsesPenawaranController extends Controller
|
||||
$data['status'] = 'success';
|
||||
$data['detailpenawaran_id'] = $id;
|
||||
$data['message'] = 'Proses Penawarn KJPP successfully';
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
$data['status'] = 'error';
|
||||
$data['message'] = 'Silahkan upload file pdf';
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
$data['status'] = 'error';
|
||||
$data['message'] = 'Silahkan upload file';
|
||||
}
|
||||
|
||||
} catch (Exception $e) {
|
||||
|
||||
|
||||
$data['status'] = 'error';
|
||||
$data['message'] = 'Proses Penawarn KJPP failed.';
|
||||
}
|
||||
}
|
||||
|
||||
} else {
|
||||
$data['status'] = 'error';
|
||||
$data['message'] = 'no ajax request';
|
||||
@@ -251,58 +240,51 @@ class ProsesPenawaranController extends Controller
|
||||
*/
|
||||
public function updateAll(Request $request, $id): JsonResponse
|
||||
{
|
||||
// init
|
||||
// init
|
||||
$data = array();
|
||||
$dataku = array();
|
||||
$model = PenawaranTender::findOrFail($id);
|
||||
$checkActiveDateRange = $this->checkActiveDateRangePenawaran($model->start_date, $model->end_date);
|
||||
|
||||
|
||||
// cek masa aktif penawaran
|
||||
if($checkActiveDateRange)
|
||||
{
|
||||
|
||||
$checkKelengkapanDetailKJPP = $this->checkKelengkapanDetailKJPP($id);
|
||||
if($checkKelengkapanDetailKJPP)
|
||||
{
|
||||
if ($checkActiveDateRange) {
|
||||
|
||||
$checkKelengkapanDetailKJPP = $this->checkKelengkapanDetailKJPP($id);
|
||||
if ($checkKelengkapanDetailKJPP) {
|
||||
DB::beginTransaction();
|
||||
try {
|
||||
$dataku = ['status' => 'tendered',
|
||||
$dataku = [
|
||||
'status' => 'tendered',
|
||||
'updated_by' => Auth::id(),
|
||||
'updated_at' => now()
|
||||
];
|
||||
|
||||
$dataPermohonan = ['status' => 'tendered',
|
||||
|
||||
$dataPermohonan = [
|
||||
'status' => 'tendered',
|
||||
'updated_by' => Auth::id(),
|
||||
'updated_at' => now()
|
||||
];
|
||||
|
||||
$permohonan = Permohonan::where('nomor_registrasi','=', $model->nomor_registrasi)->first();
|
||||
|
||||
$model->update($dataku);
|
||||
$permohonan->update($dataPermohonan);
|
||||
|
||||
|
||||
$permohonan = Permohonan::where('nomor_registrasi', '=', $model->nomor_registrasi)->first();
|
||||
|
||||
$model->update($dataku);
|
||||
$permohonan->update($dataPermohonan);
|
||||
|
||||
DB::commit();
|
||||
|
||||
$data['message'] = "Sukses melakukan Proses Penawaran";
|
||||
$data['status'] = 'success';
|
||||
|
||||
} catch (Exception $e) {
|
||||
DB::rollBack();
|
||||
// dd($e);
|
||||
$data['message'] = "Gagal melakukan Proses Penawaran";
|
||||
$data['status'] = 'error';
|
||||
}
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
$data['message'] = "Silahkan lengkapi data KJPP";
|
||||
$data['status'] = 'error';
|
||||
}
|
||||
|
||||
}
|
||||
else
|
||||
{
|
||||
} else {
|
||||
$data['message'] = "Penawaran sudah di tutup";
|
||||
$data['status'] = 'error';
|
||||
}
|
||||
@@ -316,57 +298,48 @@ class ProsesPenawaranController extends Controller
|
||||
$end_date = strtotime($end_date1);
|
||||
$todays_date = strtotime(now());
|
||||
|
||||
$allow=true;
|
||||
if ($todays_date >= $start_date && $todays_date <= $end_date)
|
||||
{
|
||||
$allow = true;
|
||||
if ($todays_date >= $start_date && $todays_date <= $end_date) {
|
||||
//Penawaran dibuka
|
||||
$allow=true;
|
||||
}
|
||||
else
|
||||
{
|
||||
if($todays_date < $start_date)
|
||||
{
|
||||
$allow = true;
|
||||
} else {
|
||||
if ($todays_date < $start_date) {
|
||||
//Penawaran Belum dibuka
|
||||
$allow=true;
|
||||
}
|
||||
else
|
||||
{
|
||||
$allow = true;
|
||||
} else {
|
||||
//Penawaran sudah ditutup
|
||||
$allow=false;
|
||||
$allow = false;
|
||||
}
|
||||
}
|
||||
|
||||
return $allow;
|
||||
|
||||
return $allow;
|
||||
}
|
||||
|
||||
public function checkKelengkapanDetailKJPP($id)
|
||||
{
|
||||
$allow=true;
|
||||
$allow = true;
|
||||
// DB::enableQueryLog();
|
||||
// detail_penawaran apakah isian biaya_penawaran, attachment, dokumen_persetujuan sudah lengkap?
|
||||
$query = PenawaranDetailTender::select('id')
|
||||
->where('penawaran_id','=',$id)
|
||||
->where(function($query) {
|
||||
$query->orWhere('biaya_penawaran', '', "");
|
||||
$query->orWhereNull('biaya_penawaran');
|
||||
|
||||
$query->orWhere('attachment', '', "");
|
||||
$query->orWhereNull('attachment');
|
||||
->where('penawaran_id', '=', $id)
|
||||
->where(function ($query) {
|
||||
$query->orWhere('biaya_penawaran', '', "");
|
||||
$query->orWhereNull('biaya_penawaran');
|
||||
|
||||
$query->orWhere('dokumen_persetujuan', '', "");
|
||||
$query->orWhereNull('dokumen_persetujuan');
|
||||
})->get();
|
||||
// $sql = DB::getQueryLog();
|
||||
|
||||
|
||||
if (sizeof($query)>0)
|
||||
{
|
||||
$allow=false;
|
||||
}
|
||||
$query->orWhere('attachment', '', "");
|
||||
$query->orWhereNull('attachment');
|
||||
|
||||
$query->orWhere('dokumen_persetujuan', '', "");
|
||||
$query->orWhereNull('dokumen_persetujuan');
|
||||
})->get();
|
||||
// $sql = DB::getQueryLog();
|
||||
|
||||
|
||||
if (sizeof($query) > 0) {
|
||||
$allow = false;
|
||||
}
|
||||
|
||||
return $allow;
|
||||
|
||||
}
|
||||
|
||||
public function updateStatusPenawaranKJPP(Request $request, $id): JsonResponse
|
||||
@@ -377,19 +350,20 @@ class ProsesPenawaranController extends Controller
|
||||
|
||||
try {
|
||||
$model = PenawaranDetailTender::findOrFail($id);
|
||||
$data['id']=$id;
|
||||
$data['id'] = $id;
|
||||
|
||||
$dataku = ['status' => '0',
|
||||
$dataku = [
|
||||
'status' => '0',
|
||||
'updated_by' => Auth::id(),
|
||||
'updated_at' => now()
|
||||
];
|
||||
|
||||
$model->update($dataku);
|
||||
$model->update($dataku);
|
||||
|
||||
$data['message'] = "Sukses delete Penawaran KJPP";
|
||||
$data['status'] = 'success';
|
||||
} catch (Exception $e) {
|
||||
|
||||
|
||||
// dd($e);
|
||||
$data['message'] = "Gagal delete Penawaran KJPP";
|
||||
$data['status'] = 'error';
|
||||
@@ -400,6 +374,6 @@ class ProsesPenawaranController extends Controller
|
||||
public function show($id)
|
||||
{
|
||||
$prosespenawaran = PenawaranTender::find($id);
|
||||
return view('lpj::prosespenawaran.show', compact('id','prosespenawaran'));
|
||||
return view('lpj::prosespenawaran.show', compact('id', 'prosespenawaran'));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,6 +7,22 @@ use Illuminate\Http\RedirectResponse;
|
||||
use Illuminate\Http\Request;
|
||||
use Illuminate\Http\Response;
|
||||
use Modules\Lpj\Models\Permohonan;
|
||||
use Modules\Lpj\Models\Branch;
|
||||
use Modules\Lpj\Models\Surveyor;
|
||||
use Modules\Lpj\Models\BentukTanah;
|
||||
use Modules\Lpj\Models\KonturTanah;
|
||||
use Modules\Location\Models\Province;
|
||||
use Modules\Lpj\Models\PosisiKavling;
|
||||
use Modules\Lpj\Models\KondisiFisikTanah;
|
||||
use Modules\Lpj\Models\KetinggianTanah;
|
||||
use Modules\Lpj\Models\SifatBangunan;
|
||||
use Modules\Lpj\Models\JenisBangunan;
|
||||
use Modules\Lpj\Models\KondisiBangunan;
|
||||
use Modules\Lpj\Models\SpekBangunan;
|
||||
use Modules\Lpj\Models\SpekKategoritBangunan;
|
||||
use Modules\Lpj\Models\SaranaPelengkap;
|
||||
use Modules\Lpj\Models\ArahMataAngin;
|
||||
use Modules\Lpj\Http\Requests\SurveyorRequest;
|
||||
|
||||
class SurveyorController extends Controller
|
||||
{
|
||||
@@ -19,21 +35,7 @@ class SurveyorController extends Controller
|
||||
return view('lpj::surveyor.index');
|
||||
}
|
||||
|
||||
/**
|
||||
* Show the form for creating a new resource.
|
||||
*/
|
||||
public function create()
|
||||
{
|
||||
return view('lpj::create');
|
||||
}
|
||||
|
||||
/**
|
||||
* Store a newly created resource in storage.
|
||||
*/
|
||||
public function store(Request $request): RedirectResponse
|
||||
{
|
||||
//
|
||||
}
|
||||
|
||||
/**
|
||||
* Show the specified resource.
|
||||
@@ -49,10 +51,46 @@ class SurveyorController extends Controller
|
||||
'debiture.village',
|
||||
'branch',
|
||||
'tujuanPenilaian',
|
||||
'penilaian'
|
||||
'penilaian',
|
||||
'documents',
|
||||
],
|
||||
)->findOrFail($id);
|
||||
return view('lpj::surveyor.detail', compact('permohonan'));
|
||||
|
||||
$surveyor = $id;
|
||||
$branches = Branch::all();
|
||||
$provinces = Province::all();
|
||||
$bentukTanah = BentukTanah::all();
|
||||
$konturTanah = KonturTanah::all();
|
||||
$posisiKavling = PosisiKavling::all();
|
||||
$ketinggianTanah = KetinggianTanah::all();
|
||||
$kondisiFisikTanah = KondisiFisikTanah::all();
|
||||
$jenisBangunan = JenisBangunan::all();
|
||||
$kondisiBangunan = KondisiBangunan::all();
|
||||
$sifatBangunan = SifatBangunan::all();
|
||||
$spekKategoriBagunan = SpekKategoritBangunan::all();
|
||||
$spekBangunan = SpekBangunan::all();
|
||||
$saranaPelengkap = SaranaPelengkap::all();
|
||||
$arahMataAngin = ArahMataAngin::all();
|
||||
|
||||
|
||||
return view('lpj::surveyor.detail', compact(
|
||||
'permohonan',
|
||||
'surveyor',
|
||||
'branches',
|
||||
'provinces',
|
||||
'bentukTanah',
|
||||
'konturTanah',
|
||||
'posisiKavling',
|
||||
'kondisiFisikTanah',
|
||||
'ketinggianTanah',
|
||||
'kondisiBangunan',
|
||||
'jenisBangunan',
|
||||
'sifatBangunan',
|
||||
'spekKategoriBagunan',
|
||||
'spekBangunan',
|
||||
'saranaPelengkap',
|
||||
'arahMataAngin',
|
||||
));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -131,10 +169,372 @@ class SurveyorController extends Controller
|
||||
]);
|
||||
}
|
||||
/**
|
||||
* Remove the specified resource from storage.
|
||||
* Form inspeksi.
|
||||
*/
|
||||
public function destroy($id)
|
||||
|
||||
public function formInspeksi($id)
|
||||
{
|
||||
//
|
||||
$permohonan = Permohonan::with(
|
||||
[
|
||||
'user',
|
||||
'debiture.province',
|
||||
'debiture.city',
|
||||
'debiture.district',
|
||||
'debiture.village',
|
||||
'branch',
|
||||
'tujuanPenilaian',
|
||||
'penilaian'
|
||||
],
|
||||
)->findOrFail($id);
|
||||
$branches = Branch::all();
|
||||
$provinces = Province::all();
|
||||
|
||||
return view('lpj::surveyor.detail', compact('permohonan', 'branches', 'provinces'));
|
||||
}
|
||||
|
||||
/**
|
||||
* Denah.
|
||||
*/
|
||||
|
||||
public function denah($id)
|
||||
{
|
||||
$permohonan = Permohonan::with(
|
||||
[
|
||||
'user',
|
||||
'debiture.province',
|
||||
'debiture.city',
|
||||
'debiture.district',
|
||||
'debiture.village',
|
||||
'branch',
|
||||
'tujuanPenilaian',
|
||||
'penilaian'
|
||||
],
|
||||
)->findOrFail($id);
|
||||
$surveyor = $id;
|
||||
$branches = Branch::all();
|
||||
$provinces = Province::all();
|
||||
|
||||
return view('lpj::surveyor.detail', compact('permohonan', 'surveyor', 'branches', 'provinces'));
|
||||
}
|
||||
|
||||
/**
|
||||
* Foto.
|
||||
*/
|
||||
|
||||
public function foto($id)
|
||||
{
|
||||
$permohonan = Permohonan::with(
|
||||
[
|
||||
'user',
|
||||
'debiture.province',
|
||||
'debiture.city',
|
||||
'debiture.district',
|
||||
'debiture.village',
|
||||
'branch',
|
||||
'tujuanPenilaian',
|
||||
'penilaian'
|
||||
],
|
||||
)->findOrFail($id);
|
||||
$surveyor = $id;
|
||||
$branches = Branch::all();
|
||||
$provinces = Province::all();
|
||||
|
||||
return view('lpj::surveyor.detail', compact('permohonan', 'surveyor', 'branches', 'provinces'));
|
||||
}
|
||||
|
||||
/**
|
||||
* Data pembanding.
|
||||
*/
|
||||
|
||||
public function dataPembanding($id)
|
||||
{
|
||||
$permohonan = Permohonan::with(
|
||||
[
|
||||
'user',
|
||||
'debiture.province',
|
||||
'debiture.city',
|
||||
'debiture.district',
|
||||
'debiture.village',
|
||||
'branch',
|
||||
'tujuanPenilaian',
|
||||
'penilaian'
|
||||
],
|
||||
)->findOrFail($id);
|
||||
$surveyor = $id;
|
||||
$branches = Branch::all();
|
||||
$provinces = Province::all();
|
||||
|
||||
return view('lpj::surveyor.detail', compact('permohonan', 'surveyor', 'branches', 'provinces'));
|
||||
}
|
||||
|
||||
|
||||
public function data(Request $request)
|
||||
{
|
||||
|
||||
$type = $request->route('type');
|
||||
|
||||
$headers = [
|
||||
'bentuk-tanah' => ['Bentuk Tanah', 'bentuk-tanah'],
|
||||
'kontur-tanah' => ['Kontur Tanah', 'kontur-tanah'],
|
||||
'posisi-kavling' => ['Posisi Kavling', 'posisi-kavling'],
|
||||
'ketinggian-tanah' => ['Ketinggian Tanah', 'ketinggian-tanah'],
|
||||
'kondisi-fisik-tanah' => ['Kondisi Fisik Tanah', 'kondisi-fisik-tanah'],
|
||||
'jenis-bangunan' => ['Jenis Bangunan', 'jenis-bangunan'],
|
||||
'kondisi-bangunan' => ['Kondisi Bangunan', 'kondisi-bangunan'],
|
||||
'sifat-bangunan' => ['Sifat Bangunan', 'sifat-bangunan'],
|
||||
'sarana-pelengkap' => ['Sarana Pelengkap', 'sarana-pelengkap'],
|
||||
];
|
||||
|
||||
$header = $headers[$type] ?? '';
|
||||
|
||||
return view('lpj::surveyor.data.index', compact('header'));
|
||||
}
|
||||
|
||||
|
||||
public function createData($type)
|
||||
{
|
||||
|
||||
$headers = [
|
||||
'bentuk-tanah' => ['Bentuk Tanah', 'bentuk-tanah'],
|
||||
'kontur-tanah' => ['Kontur Tanah', 'kontur-tanah'],
|
||||
'posisi-kavling' => ['Posisi Kavling', 'posisi-kavling'],
|
||||
'ketinggian-tanah' => ['Ketinggian Tanah', 'ketinggian-tanah'],
|
||||
'kondisi-fisik-tanah' => ['Kondisi Fisik Tanah', 'kondisi-fisik-tanah'],
|
||||
'jenis-bangunan' => ['Jenis Bangunan', 'jenis-bangunan'],
|
||||
'kondisi-bangunan' => ['Kondisi Bangunan', 'kondisi-bangunan'],
|
||||
'sifat-bangunan' => ['Sifat Bangunan', 'sifat-bangunan'],
|
||||
'sarana-pelengkap' => ['Sarana Pelengkap', 'sarana-pelengkap'],
|
||||
];
|
||||
|
||||
|
||||
$header = $headers[$type] ?? '';
|
||||
return view('lpj::surveyor.data.form', compact('header'));
|
||||
}
|
||||
|
||||
|
||||
public function storeData(SurveyorRequest $request, $type)
|
||||
{
|
||||
|
||||
$validate = $request->validated();
|
||||
if ($validate) {
|
||||
|
||||
$type = $request->route('type');
|
||||
|
||||
$modelClasses = [
|
||||
'bentuk-tanah' => BentukTanah::class,
|
||||
'kontur-tanah' => KonturTanah::class,
|
||||
'posisi-kavling' => PosisiKavling::class,
|
||||
'bentuk-tanah' => BentukTanah::class,
|
||||
'kontur-tanah' => KonturTanah::class,
|
||||
'posisi-kavling' => PosisiKavling::class,
|
||||
'ketinggian-tanah' => KetinggianTanah::class,
|
||||
'kondisi-fisik-tanah' => KondisiFisikTanah::class,
|
||||
'jenis-bangunan' => JenisBangunan::class,
|
||||
'kondisi-bangunan' => KondisiBangunan::class,
|
||||
'sifat-bangunan' => SifatBangunan::class,
|
||||
'sarana-pelengkap' => SaranaPelengkap::class,
|
||||
];
|
||||
|
||||
if (!array_key_exists($type, $modelClasses)) {
|
||||
return redirect()
|
||||
->route('basicdata.'. $type .'.index')
|
||||
->with('error', 'Invalid type specified.');
|
||||
}
|
||||
|
||||
$modelClass = $modelClasses[$type];
|
||||
$data = $request->all();
|
||||
$data['status'] = true;
|
||||
$modelClass::create($data);
|
||||
|
||||
return redirect()
|
||||
->route('basicdata.' . $type .'.index')
|
||||
->with('success', 'created successfully');
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
public function editData($type, $id)
|
||||
{
|
||||
$dataMap = [
|
||||
'bentuk-tanah' => ['Bentuk Tanah', 'bentuk-tanah', BentukTanah::class],
|
||||
'kontur-tanah' => ['Kontur Tanah', 'kontur-tanah', KonturTanah::class],
|
||||
'posisi-kavling' => ['Posisi Kavling', 'posisi-kavling', PosisiKavling::class],
|
||||
'ketinggian-tanah' => ['Ketinggian Tanah', 'ketinggian-tanah', KetinggianTanah::class],
|
||||
'kondisi-fisik-tanah' => ['Kondisi Fisik Tanah', 'kondisi-fisik-tanah', KondisiFisikTanah::class],
|
||||
'jenis-bangunan' => ['Jenis Bangunan', 'jenis-bangunan', JenisBangunan::class],
|
||||
'kondisi-bangunan' => ['Kondisi Bangunan', 'kondisi-bangunan', KondisiBangunan::class],
|
||||
'sifat-bangunan' => ['Sifat Bangunan', 'sifat-bangunan', SifatBangunan::class],
|
||||
'spek-bangunan' => ['Spek Bangunan', 'spek-bangunan', SpekBangunan::class],
|
||||
'spek-kategori-bangunan' => ['Spek Kategori Bangunan', 'spek-kategori-bangunan', SpekKategoritBangunan::class],
|
||||
'sarana-pelengkap' => ['Sarana Pelengkap', 'sarana-pelengkap', SaranaPelengkap::class],
|
||||
];
|
||||
|
||||
|
||||
if (!array_key_exists($type, $dataMap)) {
|
||||
return redirect()->back()->with('error', 'Invalid type specified.');
|
||||
}
|
||||
|
||||
[$headers, $routeName, $modelClass] = $dataMap[$type];
|
||||
|
||||
$header = $dataMap[$type] ?? '';
|
||||
$model = $modelClass::findOrFail($id);
|
||||
|
||||
return view('lpj::surveyor.data.form', compact('header', 'model'));
|
||||
}
|
||||
|
||||
|
||||
public function updateData(SurveyorRequest $request, $type, $id)
|
||||
{
|
||||
$validate = $request->validated();
|
||||
if ($validate) {
|
||||
$modelClasses = [
|
||||
'bentuk-tanah' => BentukTanah::class,
|
||||
'kontur-tanah' => KonturTanah::class,
|
||||
'posisi-kavling' => PosisiKavling::class,
|
||||
'ketinggian-tanah' => KetinggianTanah::class,
|
||||
'kondisi-fisik-tanah' => KondisiFisikTanah::class,
|
||||
'jenis-bangunan' => JenisBangunan::class,
|
||||
'kondisi-bangunan' => KondisiBangunan::class,
|
||||
'sifat-bangunan' => SifatBangunan::class,
|
||||
'sarana-pelengkap' => SaranaPelengkap::class,
|
||||
|
||||
];
|
||||
|
||||
// Check if the provided type exists in the modelClasses
|
||||
if (!array_key_exists($type, $modelClasses)) {
|
||||
return redirect()
|
||||
->route('basicdata.' . $type . '.index')
|
||||
->with('error', 'Invalid type specified.');
|
||||
}
|
||||
$modelClass = $modelClasses[$type];
|
||||
$model = $modelClass::findOrFail($id);
|
||||
$model->update($validate);
|
||||
|
||||
// Redirect back with a success message
|
||||
return redirect()
|
||||
->route('basicdata.' . $type . '.index')
|
||||
->with('success', 'Updated successfully');
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
public function dataForDatatablesData(Request $request, $type)
|
||||
{
|
||||
if (is_null($this->user) || !$this->user->can('jenis_aset.view')) {
|
||||
//abort(403, 'Sorry! You are not allowed to view users.');
|
||||
}
|
||||
|
||||
// Retrieve data from the database
|
||||
|
||||
$models = [
|
||||
'Bentuk Tanah' => BentukTanah::class,
|
||||
'Kontur Tanah' => KonturTanah::class,
|
||||
'Posisi Kavling' => PosisiKavling::class,
|
||||
'Ketinggian Tanah' => KetinggianTanah::class,
|
||||
'Kondisi Fisik Tanah' => KondisiFisikTanah::class,
|
||||
'Jenis Bangunan' => JenisBangunan::class,
|
||||
'Kondisi Bangunan' => KondisiBangunan::class,
|
||||
'Sifat Bangunan' => SifatBangunan::class,
|
||||
// 'Spek Kategori Bangunan' => SpekKategoritBangunan::class,
|
||||
// 'Spek Bangunan' => SpekBangunan::class,
|
||||
'Sarana Pelengkap' => SaranaPelengkap::class,
|
||||
];
|
||||
|
||||
|
||||
if (array_key_exists($type, $models)) {
|
||||
$query = $models[$type]::query();
|
||||
} else {
|
||||
throw new InvalidArgumentException("Invalid type: $type");
|
||||
}
|
||||
|
||||
|
||||
// Apply search filter if provided
|
||||
if ($request->has('search') && !empty($request->get('search'))) {
|
||||
$search = $request->get('search');
|
||||
$query->where(function ($q) use ($search) {
|
||||
$q->where('code', 'LIKE', "%$search%");
|
||||
$q->orWhere('name', 'LIKE', "%$search%");
|
||||
});
|
||||
}
|
||||
|
||||
// Apply sorting if provided
|
||||
if ($request->has('sortOrder') && !empty($request->get('sortOrder'))) {
|
||||
$order = $request->get('sortOrder');
|
||||
$column = $request->get('sortField');
|
||||
$query->orderBy($column, $order);
|
||||
}
|
||||
|
||||
// Get the total count of records
|
||||
$totalRecords = $query->count();
|
||||
|
||||
// Apply pagination if provided
|
||||
if ($request->has('page') && $request->has('size')) {
|
||||
$page = $request->get('page');
|
||||
$size = $request->get('size');
|
||||
$offset = ($page - 1) * $size; // Calculate the offset
|
||||
|
||||
$query->skip($offset)->take($size);
|
||||
}
|
||||
|
||||
// Get the filtered count of records
|
||||
$filteredRecords = $query->count();
|
||||
|
||||
// Get the data for the current page
|
||||
$data = $query->get();
|
||||
|
||||
// Calculate the page count
|
||||
$pageCount = ceil($totalRecords / $request->get('size'));
|
||||
|
||||
// Calculate the current page number
|
||||
$currentPage = 0 + 1;
|
||||
|
||||
// Return the response data as a JSON object
|
||||
return response()->json([
|
||||
'draw' => $request->get('draw'),
|
||||
'recordsTotal' => $totalRecords,
|
||||
'recordsFiltered' => $filteredRecords,
|
||||
'pageCount' => $pageCount,
|
||||
'page' => $currentPage,
|
||||
'totalCount' => $totalRecords,
|
||||
'data' => $data,
|
||||
]);
|
||||
}
|
||||
|
||||
public function destroy($id, $type)
|
||||
{
|
||||
try {
|
||||
|
||||
$modelClasses = [
|
||||
'bentuk-tanah' => BentukTanah::class,
|
||||
'kontur-tanah' => KonturTanah::class,
|
||||
'posisi-kavling' => PosisiKavling::class,
|
||||
'ketinggian-tanah' => KetinggianTanah::class,
|
||||
'kondisi-fisik-tanah' => KondisiFisikTanah::class,
|
||||
'jenis-bangunan' => JenisBangunan::class,
|
||||
'kondisi-bangunan' => KondisiBangunan::class,
|
||||
'sifat-bangunan' => SifatBangunan::class,
|
||||
'sarana-pelengkap' => SaranaPelengkap::class,
|
||||
];
|
||||
|
||||
|
||||
if (!array_key_exists($type, $modelClasses)) {
|
||||
return response()->json(['success' => false, 'message' => 'Invalid type specified.'], 400);
|
||||
}
|
||||
|
||||
$modelClass = $modelClasses[$type];
|
||||
$model = $modelClass::findOrFail($id);
|
||||
|
||||
$model->delete();
|
||||
return response()->json(['success' => true, 'message' => 'deleted successfully']);
|
||||
} catch (ModelNotFoundException $e) {
|
||||
return response()->json(['success' => false, 'message' => 'not found.'], 404);
|
||||
} catch (Exception $e) {
|
||||
return response()->json(['success' => false, 'message' => 'Failed to delete.'], 500);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -395,11 +395,6 @@ class TenderController extends Controller
|
||||
]);
|
||||
}
|
||||
|
||||
public function proses_penawaran_index()
|
||||
{
|
||||
return view('lpj::proses_penawaran/index');
|
||||
}
|
||||
|
||||
// Tambahkan method untuk API di controller
|
||||
public function checkPenawaranExistence($nomor_registrasi)
|
||||
{
|
||||
|
||||
64
app/Http/Requests/SurveyorRequest.php
Normal file
64
app/Http/Requests/SurveyorRequest.php
Normal file
@@ -0,0 +1,64 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Http\Requests;
|
||||
|
||||
use Illuminate\Foundation\Http\FormRequest;
|
||||
|
||||
class SurveyorRequest extends FormRequest
|
||||
{
|
||||
/**
|
||||
* Get the validation rules that apply to the request.
|
||||
*/
|
||||
public function rules()
|
||||
: array
|
||||
{
|
||||
|
||||
$action = $this->input('action');
|
||||
|
||||
$uniqueTable = [
|
||||
'bentuk-tanah' => 'bentuk_tanah',
|
||||
'kontur-tanah' => 'kontur_tanah',
|
||||
'posisi-kavling' => 'posisi_kavling',
|
||||
'ketinggian-tanah' => 'ketinggian_tanah',
|
||||
'kondisi-fisik-tanah' => 'kondisi_fisik_tanah',
|
||||
'kondisi-bangunan' => 'kondisi_bangunan',
|
||||
'sifat-bangunan' => 'sifat_bangunan',
|
||||
'sarana-pelengkap' => 'sarana_pelengkap',
|
||||
'lalu_lintas_lokasi' => 'lalu_lintas_lokasi',
|
||||
'tingkat-keramaian' => 'tingkat_keramaian',
|
||||
];
|
||||
|
||||
|
||||
|
||||
$rules = [
|
||||
'name' => 'required|max:255',
|
||||
|
||||
];
|
||||
|
||||
$id = $this->route('id');
|
||||
|
||||
if ($this->method() == 'PUT' || $this->method() == 'PATCH') {
|
||||
$rules['code'] = 'required|max:50|unique:' . $uniqueTable[$action] . ',code,' . $id;
|
||||
} else {
|
||||
|
||||
$rules['code'] = 'required|max:50|unique:' . $uniqueTable[$action] . ',code';
|
||||
}
|
||||
return $rules;
|
||||
}
|
||||
|
||||
/**
|
||||
* Determine if the user is authorized to make this request.
|
||||
*/
|
||||
public function authorize()
|
||||
: bool
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
protected function prepareForValidation()
|
||||
{
|
||||
$this->merge([
|
||||
'status' => true,
|
||||
]);
|
||||
}
|
||||
}
|
||||
24
app/Models/BentukTanah.php
Normal file
24
app/Models/BentukTanah.php
Normal file
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\BentukTanahFactory;
|
||||
|
||||
class BentukTanah extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'bentuk_tanah';
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
|
||||
protected static function newFactory(): BentukTanahFactory
|
||||
{
|
||||
//return BentukTanahFactory::new();
|
||||
}
|
||||
}
|
||||
22
app/Models/GolonganMasySekitar.php
Normal file
22
app/Models/GolonganMasySekitar.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\GolonganMasySekitarFactory;
|
||||
|
||||
class GolonganMasySekitar extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = [];
|
||||
|
||||
protected static function newFactory(): GolonganMasySekitarFactory
|
||||
{
|
||||
//return GolonganMasySekitarFactory::new();
|
||||
}
|
||||
}
|
||||
23
app/Models/JenisBangunan.php
Normal file
23
app/Models/JenisBangunan.php
Normal file
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\JenisBangunanFactory;
|
||||
|
||||
class JenisBangunan extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'jenis_bangunan';
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
protected static function newFactory(): JenisBangunanFactory
|
||||
{
|
||||
//return JenisBangunanFactory::new();
|
||||
}
|
||||
}
|
||||
24
app/Models/KetinggianTanah.php
Normal file
24
app/Models/KetinggianTanah.php
Normal file
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\KetinggianTanahFactory;
|
||||
|
||||
class KetinggianTanah extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'ketinggian_tanah';
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
protected static function newFactory(): KetinggianTanahFactory
|
||||
{
|
||||
//return KetinggianTanahFactory::new();
|
||||
}
|
||||
}
|
||||
23
app/Models/KondisiBangunan.php
Normal file
23
app/Models/KondisiBangunan.php
Normal file
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\KondisiBangunanFactory;
|
||||
|
||||
class KondisiBangunan extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'kondisi_bangunan';
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = [];
|
||||
|
||||
protected static function newFactory(): KondisiBangunanFactory
|
||||
{
|
||||
//return KondisiBangunanFactory::new();
|
||||
}
|
||||
}
|
||||
23
app/Models/KondisiFisikTanah.php
Normal file
23
app/Models/KondisiFisikTanah.php
Normal file
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\KondisiFisikTanahFactory;
|
||||
|
||||
class KondisiFisikTanah extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'kondisi_fisik_tanah';
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
protected static function newFactory(): KondisiFisikTanahFactory
|
||||
{
|
||||
//return KondisiFisikTanahFactory::new();
|
||||
}
|
||||
}
|
||||
23
app/Models/KonturTanah.php
Normal file
23
app/Models/KonturTanah.php
Normal file
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\KonturTanahFactory;
|
||||
|
||||
class KonturTanah extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'kontur_tanah';
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
protected static function newFactory(): KonturTanahFactory
|
||||
{
|
||||
//return KonturTanahFactory::new();
|
||||
}
|
||||
}
|
||||
23
app/Models/LaluLintasLokasi.php
Normal file
23
app/Models/LaluLintasLokasi.php
Normal file
@@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\LaluLintasLokasiFactory;
|
||||
|
||||
class LaluLintasLokasi extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
protected $table = 'lalu_lintas_lokasi';
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
protected static function newFactory(): LaluLintasLokasiFactory
|
||||
{
|
||||
//return LaluLintasLokasiFactory::new();
|
||||
}
|
||||
}
|
||||
@@ -3,6 +3,7 @@
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Modules\Lpj\Models\TujuanPenilaianKJPP;
|
||||
use Modules\Lpj\Models\PenawaranDetailTender;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Illuminate\Database\Eloquent\Relations\HasMany; // andy add
|
||||
@@ -17,7 +18,7 @@ class PenawaranTender extends Model
|
||||
protected $table = 'penawaran';
|
||||
|
||||
protected $guarded = ['id'];
|
||||
|
||||
|
||||
// andy add
|
||||
public function penawarandetails(): HasMany
|
||||
{
|
||||
@@ -29,4 +30,10 @@ class PenawaranTender extends Model
|
||||
{
|
||||
return $this->hasMany(PenawaranDetailTender::class, 'penawaran_id');
|
||||
}
|
||||
|
||||
// menambahkan relasi tujuan penilaian KJPP
|
||||
public function tujuanPenilaianKJPP()
|
||||
{
|
||||
return $this->hasMany(TujuanPenilaianKJPP::class, 'id', 'tujuan_penilaian_kjpp_id');
|
||||
}
|
||||
}
|
||||
|
||||
22
app/Models/PerkerasanJalan.php
Normal file
22
app/Models/PerkerasanJalan.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\PerkerasanJalanFactory;
|
||||
|
||||
class PerkerasanJalan extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
protected static function newFactory(): PerkerasanJalanFactory
|
||||
{
|
||||
//return PerkerasanJalanFactory::new();
|
||||
}
|
||||
}
|
||||
24
app/Models/PosisiKavling.php
Normal file
24
app/Models/PosisiKavling.php
Normal file
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\PosisiKavlingFactory;
|
||||
|
||||
class PosisiKavling extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'posisi_kavling';
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
protected static function newFactory(): PosisiKavlingFactory
|
||||
{
|
||||
//return PosisiKavlingFactory::new();
|
||||
}
|
||||
}
|
||||
24
app/Models/SaranaPelengkap.php
Normal file
24
app/Models/SaranaPelengkap.php
Normal file
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\SaranaPelengkapFactory;
|
||||
|
||||
class SaranaPelengkap extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'sarana_pelengkap';
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
protected static function newFactory(): SaranaPelengkapFactory
|
||||
{
|
||||
//return SaranaPelengkapFactory::new();
|
||||
}
|
||||
}
|
||||
24
app/Models/SifatBangunan.php
Normal file
24
app/Models/SifatBangunan.php
Normal file
@@ -0,0 +1,24 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\SifatBangunanFactory;
|
||||
|
||||
class SifatBangunan extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'sifat_bangunan';
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
protected static function newFactory(): SifatBangunanFactory
|
||||
{
|
||||
//return SifatBangunanFactory::new();
|
||||
}
|
||||
}
|
||||
31
app/Models/SpekBangunan.php
Normal file
31
app/Models/SpekBangunan.php
Normal file
@@ -0,0 +1,31 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\SpekBangunanFactory;
|
||||
|
||||
class SpekBangunan extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'spek_bangunan';
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = [];
|
||||
|
||||
|
||||
|
||||
public function bangunanKategori(){
|
||||
return $this->belongsTo(SpekKategoriBangunan::class, 'spek_kategori_bangunan_id');
|
||||
}
|
||||
|
||||
protected static function newFactory(): SpekBangunanFactory
|
||||
{
|
||||
//return SpekBangunanFactory::new();
|
||||
}
|
||||
|
||||
}
|
||||
28
app/Models/SpekKategoritBangunan.php
Normal file
28
app/Models/SpekKategoritBangunan.php
Normal file
@@ -0,0 +1,28 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\SpekKategoritBangunanFactory;
|
||||
|
||||
class SpekKategoritBangunan extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
protected $table = 'spek_kategori_bangunan';
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = [];
|
||||
|
||||
|
||||
public function bangunan()
|
||||
{
|
||||
return $this->hasMany(SpekBangunan::class, 'spek_kategori_bangunan_id');
|
||||
}
|
||||
protected static function newFactory(): SpekKategoritBangunanFactory
|
||||
{
|
||||
//return SpekKategoritBangunanFactory::new();
|
||||
}
|
||||
}
|
||||
22
app/Models/TingkatKeramaian.php
Normal file
22
app/Models/TingkatKeramaian.php
Normal file
@@ -0,0 +1,22 @@
|
||||
<?php
|
||||
|
||||
namespace Modules\Lpj\Models;
|
||||
|
||||
use Illuminate\Database\Eloquent\Model;
|
||||
use Illuminate\Database\Eloquent\Factories\HasFactory;
|
||||
use Modules\Lpj\Database\Factories\TingkatKeramaianFactory;
|
||||
|
||||
class TingkatKeramaian extends Model
|
||||
{
|
||||
use HasFactory;
|
||||
|
||||
/**
|
||||
* The attributes that are mass assignable.
|
||||
*/
|
||||
protected $fillable = ['code', 'name', 'status'];
|
||||
|
||||
protected static function newFactory(): TingkatKeramaianFactory
|
||||
{
|
||||
//return TingkatKeramaianFactory::new();
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class () extends Migration {
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('bentuk_tanah', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('bentuk_tanah');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('kontur_tanah', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('kontur_tanah');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('ketinggian_tanah', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('ketinggian_tanah');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('kontur_jalan', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('kontur_jalan');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('posisi_kavling', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('posisi_kavling');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('kondisi_fisik_tanah', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('kondisi_fisik_tanah');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('jenis_bangunan', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('jenis_bangunan');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('kondisi_bangunan', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('kondisi_bangunan');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('sifat_bangunan', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('sifat_bangunan');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,36 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class () extends Migration {
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('spek_kategori_bangunan', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('spek_kategori_bangunan');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,42 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('spek_bangunan', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->foreignId('spek_kategori_bangunan_id')->constrained('spek_kategori_bangunan')->onDelete('cascade');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::table('spek_bangunan', function (Blueprint $table) {
|
||||
$table->dropForeign(['spek_kategori_bangunan_id']);
|
||||
});
|
||||
Schema::dropIfExists('spek_bangunan');
|
||||
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('sarana_pelengkap', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('sarana_pelengkap');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('perkerasan_jalan', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('perkerasan_jalan');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('lalu_lintas_lokasi', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('lalu_lintas_lokasi');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('gol_mas_sekitar', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('gol_mas_sekitar');
|
||||
}
|
||||
};
|
||||
@@ -0,0 +1,37 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*/
|
||||
public function up(): void
|
||||
{
|
||||
Schema::create('tingkat_keramaian', function (Blueprint $table) {
|
||||
$table->id();
|
||||
$table->string('code')->unique()->index();
|
||||
$table->string('name');
|
||||
$table->boolean('status')->default(true);
|
||||
$table->char('authorized_status', 1)->nullable();
|
||||
$table->timestamps();
|
||||
$table->timestamp('authorized_at')->nullable();
|
||||
$table->unsignedBigInteger('authorized_by')->nullable();
|
||||
$table->softDeletes();
|
||||
$table->unsignedBigInteger('created_by')->nullable();
|
||||
$table->unsignedBigInteger('updated_by')->nullable();
|
||||
$table->unsignedBigInteger('deleted_by')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*/
|
||||
public function down(): void
|
||||
{
|
||||
Schema::dropIfExists('tingkat_keramaian');
|
||||
}
|
||||
};
|
||||
123
module.json
123
module.json
@@ -6,7 +6,9 @@
|
||||
"keywords": [],
|
||||
"priority": 0,
|
||||
"providers": ["Modules\\Lpj\\Providers\\LpjServiceProvider"],
|
||||
"files": [],
|
||||
"files": [
|
||||
"app/Helpers/Lpj.php"
|
||||
],
|
||||
"menu": {
|
||||
"main": [
|
||||
{
|
||||
@@ -96,7 +98,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["administrator", "so"]
|
||||
"roles": ["administrator", "senior-officer"]
|
||||
},
|
||||
{
|
||||
"title": "Team Activity",
|
||||
@@ -105,7 +107,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["so"]
|
||||
"roles": ["senior-officer"]
|
||||
},
|
||||
{
|
||||
"title": "Otorisator",
|
||||
@@ -114,7 +116,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["so"],
|
||||
"roles": ["senior-officer"],
|
||||
"sub": [
|
||||
{
|
||||
"title": "Pelaporan",
|
||||
@@ -122,7 +124,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["so"]
|
||||
"roles": ["senior-officer"]
|
||||
},
|
||||
{
|
||||
"title": "Pembayaran",
|
||||
@@ -130,7 +132,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["so"]
|
||||
"roles": ["senior-officer"]
|
||||
},
|
||||
{
|
||||
"title": "Pembatalan",
|
||||
@@ -138,7 +140,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["so"]
|
||||
"roles": ["senior-officer"]
|
||||
},
|
||||
{
|
||||
"title": "SLA",
|
||||
@@ -146,10 +148,19 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["so"]
|
||||
"roles": ["ssenior-officero"]
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
"title": "Surveyor",
|
||||
"path": "surveyor",
|
||||
"icon": "ki-filled ki-questionnaire-tablet text-lg",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
},
|
||||
|
||||
{
|
||||
"title": "Activity",
|
||||
@@ -158,7 +169,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["administrator", "pemohon-ao", "pemohon-eo", "admin"]
|
||||
"roles": ["administrator", "pemohon-ao", "pemohon-eo", "admin","surveyor"]
|
||||
},
|
||||
{
|
||||
"title": "Laporan",
|
||||
@@ -167,7 +178,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["administrator", "pemohon-ao", "pemohon-eo", "admin", "so"]
|
||||
"roles": ["administrator", "pemohon-ao", "pemohon-eo", "admin", "senior-officer"]
|
||||
}
|
||||
],
|
||||
"master": [
|
||||
@@ -178,7 +189,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["administrator", "pemohon-ao", "pemohon-eo", "admin"],
|
||||
"roles": ["administrator", "pemohon-ao", "pemohon-eo", "admin", "surveyor"],
|
||||
"sub": [
|
||||
{
|
||||
"title": "Cabang",
|
||||
@@ -282,7 +293,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["administrator", "admin", "so"]
|
||||
"roles": ["administrator", "admin", "senior-officer"]
|
||||
},
|
||||
{
|
||||
"title": "Staff Appraisal",
|
||||
@@ -290,7 +301,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["administrator", "so"]
|
||||
"roles": ["administrator", "senior-officer"]
|
||||
},
|
||||
{
|
||||
"title": "Jenis Penilaian",
|
||||
@@ -298,7 +309,7 @@
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["administrator", "admin", "so"]
|
||||
"roles": ["administrator", "admin", "senior-officer"]
|
||||
},
|
||||
{
|
||||
"title": "KJPP",
|
||||
@@ -308,6 +319,14 @@
|
||||
"permission": "",
|
||||
"roles": ["administrator", "admin"]
|
||||
},
|
||||
{
|
||||
"title": "Jenis Laporan",
|
||||
"path": "basicdata.jenis_laporan",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["Administrator", "admin"]
|
||||
},
|
||||
{
|
||||
"title": "Tujuan Penilaian KJPP",
|
||||
"path": "basicdata.tujuan_penilaian_kjpp",
|
||||
@@ -323,7 +342,81 @@
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["administrator", "admin"]
|
||||
}
|
||||
},
|
||||
{
|
||||
"title": "Bentuk Tanah",
|
||||
"path": "basicdata.bentuk-tanah",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
},
|
||||
{
|
||||
"title": "Kontur Tanah",
|
||||
"path": "basicdata.kontur-tanah",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
},
|
||||
{
|
||||
"title": "Posisi Kavling",
|
||||
"path": "basicdata.posisi-kavling",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
},
|
||||
{
|
||||
"title": "Ketinggian Tanah",
|
||||
"path": "basicdata.ketinggian-tanah",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
},
|
||||
{
|
||||
"title": "Kondisi Fisik Tanah",
|
||||
"path": "basicdata.kondisi-fisik-tanah",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
},
|
||||
{
|
||||
"title": "Jenis Bangunan",
|
||||
"path": "basicdata.jenis-bangunan",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
},
|
||||
{
|
||||
"title": "Kondisi Bangunan",
|
||||
"path": "basicdata.kondisi-bangunan",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
},
|
||||
{
|
||||
"title": "Sifat Bangunan",
|
||||
"path": "basicdata.sifat-bangunan",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
},
|
||||
|
||||
{
|
||||
"title": "Sarana Pelengkap",
|
||||
"path": "basicdata.sarana-pelengkap",
|
||||
"classes": "",
|
||||
"attributes": [],
|
||||
"permission": "",
|
||||
"roles": ["surveyor"]
|
||||
}
|
||||
|
||||
]
|
||||
}
|
||||
],
|
||||
|
||||
@@ -68,7 +68,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -58,7 +58,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
<script type="module" src="https://cdnjs.cloudflare.com/ajax/libs/toastr.js/latest/toastr.min.js"></script>
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script tipe="module">
|
||||
<script>
|
||||
function removeErrorCssMsg() {
|
||||
$(".inputku").removeClass("border-danger");
|
||||
$("em").text('');
|
||||
@@ -9,14 +7,14 @@ function removeErrorCssMsg() {
|
||||
function tandaPemisahTitik(b){
|
||||
var _minus = false;
|
||||
if (b<0) _minus = true;
|
||||
|
||||
|
||||
b = b.toString();
|
||||
b=b.replace(".","");
|
||||
b=b.replace("-","");
|
||||
c = "";
|
||||
panjang = b.length;
|
||||
j = 0;
|
||||
|
||||
|
||||
for (i = panjang; i > 0; i--){
|
||||
j = j + 1;
|
||||
if (((j % 3) == 1) && (j != 1)){
|
||||
@@ -25,15 +23,15 @@ function tandaPemisahTitik(b){
|
||||
c = b.substr(i-1,1) + c;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (_minus) c = "-" + c ;
|
||||
|
||||
|
||||
return c;
|
||||
}
|
||||
|
||||
function numbersonly(ini, e){
|
||||
if (e.keyCode>=49){
|
||||
|
||||
|
||||
if(e.keyCode<=57){
|
||||
a = ini.value.toString().replace(".","");
|
||||
b = a.replace(/[^\d]/g,"");
|
||||
@@ -56,7 +54,7 @@ function numbersonly(ini, e){
|
||||
}
|
||||
}
|
||||
else {
|
||||
return false;
|
||||
return false;
|
||||
}
|
||||
}else if (e.keyCode==48){
|
||||
a = ini.value.replace(".","") + String.fromCharCode(e.keyCode);
|
||||
@@ -83,7 +81,7 @@ function numbersonly(ini, e){
|
||||
a = ini.value.replace(".","");
|
||||
b = a.replace(/[^\d]/g,"");
|
||||
b = b.substr(0,b.length -1);
|
||||
|
||||
|
||||
if (tandaPemisahTitik(b)!=""){
|
||||
ini.value = tandaPemisahTitik(b);
|
||||
} else {
|
||||
@@ -101,4 +99,4 @@ function numbersonly(ini, e){
|
||||
}
|
||||
|
||||
}
|
||||
</script>
|
||||
</script>
|
||||
|
||||
@@ -74,7 +74,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="module">
|
||||
const element = document.querySelector('#authorization-table');
|
||||
const searchInput = document.getElementById('search');
|
||||
|
||||
@@ -62,7 +62,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -66,7 +66,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -10,7 +10,10 @@
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="hidden" name="debiture_id" value="{{ $debitur->id ?? '' }}">
|
||||
<p class="text-base text-gray-700">{{ $debitur->name }} | {{ $debitur->address.', '.$debitur->village->name.', '.$debitur->city->name.', '.$debitur->province->name.', '.$debitur->postal_code }}</p>
|
||||
<p class="text-base text-gray-700">
|
||||
{{ $debitur->name }} |
|
||||
{{ formatAlamat($debitur) }}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
@@ -78,45 +81,46 @@
|
||||
</div>
|
||||
|
||||
@if(isset($document->id))
|
||||
@foreach($document->detail as $detail)
|
||||
<input type="hidden" name="detail_dokumen_jaminan_id[]" value="{{ $detail->id }}">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56 font-bold">
|
||||
{{ $loop->index + 1 }}. {{ $detail->jenisLegalitasJaminan->name }}
|
||||
</label>
|
||||
<input type="hidden" name="jenis_legalitas_jaminan_id[]" value=" {{ $detail->jenis_legalitas_jaminan_id }}">
|
||||
</div>
|
||||
@foreach($document->detail as $detail)
|
||||
<input type="hidden" name="detail_dokumen_jaminan_id[]" value="{{ $detail->id }}">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56 font-bold">
|
||||
{{ $loop->index + 1 }}. {{ $detail->jenisLegalitasJaminan->name }}
|
||||
</label>
|
||||
<input type="hidden" name="jenis_legalitas_jaminan_id[]" value=" {{ $detail->jenis_legalitas_jaminan_id }}">
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Nama Dokumen
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input class="input " type="text" id="name" name="name[]" value="{{ $detail->name ?? "" }}" placeholder="Nama Dokumen">
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Nama Dokumen
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input class="input " type="text" id="name" name="name[]" value="{{ $detail->name ?? "" }}" placeholder="Nama Dokumen">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Dokumen Jaminan
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input class="file-input" type="file" name="dokumen_jaminan[]" value="">
|
||||
@if(isset($detail->dokumen_jaminan))
|
||||
<a href="{{ route('debitur.jaminan.download',['id'=>$debitur->id,'dokumen'=>$detail->id]) }}" class="badge badge-sm badge-outline mt-2">{{ basename($detail->dokumen_jaminan) }} <i class="ki-filled ki-cloud-download"></i></a>
|
||||
@endif
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Dokumen Jaminan
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input class="file-input" type="file" name="dokumen_jaminan[]" value="">
|
||||
@if(isset($detail->dokumen_jaminan))
|
||||
<a href="{{ route('debitur.jaminan.download',['id'=>$debitur->id,'dokumen'=>$detail->id]) }}" class="badge badge-sm badge-outline mt-2">{{ basename($detail->dokumen_jaminan) }}
|
||||
<i class="ki-filled ki-cloud-download"></i></a>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Keterangan
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea" rows="3" type="number" name="keterangan[]">{{ $detail->keterangan ?? "" }}</textarea>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Keterangan
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea" rows="3" type="number" name="keterangan[]">{{ $detail->keterangan ?? "" }}</textarea>
|
||||
</div>
|
||||
@endforeach
|
||||
</div>
|
||||
@endforeach
|
||||
@else
|
||||
<div id="doctainer" class="grid gap-5">
|
||||
|
||||
|
||||
@@ -48,7 +48,7 @@
|
||||
alamat
|
||||
</span>
|
||||
<p class="text-2xs text-gray-600 text-right max-w-[250px]">
|
||||
{{ $document->address.', '.$document->village->name.', '.$document->city->name.', '.$document->province->name.', '.$document->postal_code }}
|
||||
{{ formatAlamat($document) }}
|
||||
</p>
|
||||
</div>
|
||||
<div class="border-t border-gray-300 border-dashed">
|
||||
@@ -128,7 +128,6 @@
|
||||
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -85,7 +85,7 @@
|
||||
alamat
|
||||
</span>
|
||||
<p class="text-2xs text-gray-600 text-right max-w-[250px]">
|
||||
{{ $pemilik->address ?? '' }}, {{ $pemilik->village->name ?? ''}}, {{ $pemilik->city->name ?? ''}}, {{ $pemilik->province->name ?? '' }}, {{ $pemilik->postal_code ?? '' }}
|
||||
{{ $pemilik->address ?? '' }}, {{ $pemilik->village->name ?? ''}}, {{ $pemilik->city->name ?? ''}}, {{ $pemilik->province->name ?? '' }}, {{ $pemilik->postal_code ?? '' }}
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
@@ -136,7 +136,6 @@
|
||||
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -90,7 +90,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
window.addEventListener('DOMContentLoaded', function () {
|
||||
|
||||
|
||||
@@ -58,7 +58,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -58,7 +58,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -62,7 +62,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -66,7 +66,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -62,7 +62,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -62,7 +62,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -68,7 +68,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -62,7 +62,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -72,7 +72,6 @@
|
||||
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -71,7 +71,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -62,7 +62,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -168,7 +168,7 @@
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5 status-custom">
|
||||
<label class="form-label max-w-56">
|
||||
Status
|
||||
</label>
|
||||
@@ -213,5 +213,9 @@
|
||||
color: var(--tw-gray-600);
|
||||
}
|
||||
}
|
||||
|
||||
.status-custom {
|
||||
display: none
|
||||
}
|
||||
</style>
|
||||
@endpush
|
||||
|
||||
@@ -173,7 +173,7 @@
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5 status-custom">
|
||||
<label class="form-label max-w-56">
|
||||
Status
|
||||
</label>
|
||||
@@ -219,5 +219,9 @@
|
||||
color: var(--tw-gray-600);
|
||||
}
|
||||
}
|
||||
|
||||
.status-custom {
|
||||
display: none
|
||||
}
|
||||
</style>
|
||||
@endpush
|
||||
|
||||
@@ -87,7 +87,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function formatDate(date) {
|
||||
const day = date.getDate().toString().padStart(2, '0');
|
||||
|
||||
@@ -1,35 +1,3 @@
|
||||
@php
|
||||
function formatTanggalIndonesia($date)
|
||||
{
|
||||
$carbonDate = \Carbon\Carbon::parse($date);
|
||||
$indonesianMonths = [
|
||||
'Januari',
|
||||
'Februari',
|
||||
'Maret',
|
||||
'April',
|
||||
'Mei',
|
||||
'Juni',
|
||||
'Juli',
|
||||
'Agustus',
|
||||
'September',
|
||||
'Oktober',
|
||||
'November',
|
||||
'Desember',
|
||||
];
|
||||
$month = $indonesianMonths[$carbonDate->month - 1];
|
||||
return $carbonDate->format('d') . ' ' . $month . ' ' . $carbonDate->format('Y');
|
||||
}
|
||||
|
||||
function formatRupiah($number)
|
||||
{
|
||||
// Convert to float if the input is a string
|
||||
$number = (float) $number;
|
||||
|
||||
return 'Rp ' . number_format($number, 2, ',', '.');
|
||||
}
|
||||
@endphp
|
||||
|
||||
|
||||
@extends('layouts.main')
|
||||
|
||||
@section('breadcrumbs')
|
||||
@@ -199,4 +167,6 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@@ -88,7 +88,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function formatDate(date) {
|
||||
const day = date.getDate().toString().padStart(2, '0');
|
||||
|
||||
@@ -473,95 +473,6 @@
|
||||
</div>
|
||||
@endsection
|
||||
@push('scripts')
|
||||
{{-- <script>
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
let teamsSelect = document.getElementById('teams_id');
|
||||
let penilaiSelect = document.getElementById('penilaian_id');
|
||||
let surveyorSelect = document.getElementById('surveyor_id');
|
||||
let penilaiSurveyorSelect = document.getElementById('penilai_surveyor_id');
|
||||
|
||||
let selectedSurveyorId = @json($penilaian->surveyor_id ?? null);
|
||||
let selectedPenilaiId = @json($penilaian->penilaian_id ?? null);
|
||||
let selectedPenilaiSurveyorId = @json($penilaian->penilai_surveyor_id ?? null);
|
||||
|
||||
function fetchPenilai(teamId) {
|
||||
penilaiSelect.innerHTML = '<option value="">Pilih Penilai</option>';
|
||||
surveyorSelect.innerHTML = '<option value="">Pilih Surveyor</option>';
|
||||
penilaiSurveyorSelect.innerHTML = '<option value="">Pilih Penilai Surveyor</option>';
|
||||
|
||||
if (teamId) {
|
||||
fetch(`/penilaian/getUserTeams/${teamId}`)
|
||||
.then(response => response.json())
|
||||
.then(data => {
|
||||
if (data && data.length > 0) {
|
||||
data.forEach((user) => {
|
||||
let optionPenilai = document.createElement('option');
|
||||
let optionSurveyor = document.createElement('option');
|
||||
let optionPenilaiSurveyor = document.createElement('option');
|
||||
|
||||
optionPenilai.value = user.id;
|
||||
optionSurveyor.value = user.id;
|
||||
optionPenilaiSurveyor.value = user.id;
|
||||
|
||||
optionPenilai.text = user.name;
|
||||
optionSurveyor.text = user.name;
|
||||
optionPenilaiSurveyor.text = user.name;
|
||||
|
||||
// Tambahkan pengguna ke semua select
|
||||
penilaiSelect.appendChild(optionPenilai);
|
||||
surveyorSelect.appendChild(optionSurveyor);
|
||||
penilaiSurveyorSelect.appendChild(optionPenilaiSurveyor);
|
||||
|
||||
if (selectedPenilaiId && selectedPenilaiId == user.id) {
|
||||
optionPenilai.selected = true;
|
||||
}
|
||||
if (selectedSurveyorId && selectedSurveyorId == user.id) {
|
||||
optionSurveyor.selected = true;
|
||||
}
|
||||
if (selectedPenilaiSurveyorId && selectedPenilaiSurveyorId == user
|
||||
.id) {
|
||||
optionPenilaiSurveyor.selected = true;
|
||||
}
|
||||
});
|
||||
} else {
|
||||
let noUserOption = document.createElement('option');
|
||||
noUserOption.value = '';
|
||||
noUserOption.text = 'Tidak ada pengguna yang sesuai.';
|
||||
penilaiSelect.appendChild(noUserOption);
|
||||
surveyorSelect.appendChild(noUserOption.cloneNode(true));
|
||||
penilaiSurveyorSelect.appendChild(noUserOption.cloneNode(true));
|
||||
}
|
||||
})
|
||||
.catch(error => {
|
||||
console.error('Error fetching team members:', error);
|
||||
let errorOption = document.createElement('option');
|
||||
errorOption.value = '';
|
||||
errorOption.text = 'Terjadi kesalahan.';
|
||||
penilaiSelect.appendChild(errorOption);
|
||||
surveyorSelect.appendChild(errorOption.cloneNode(true));
|
||||
penilaiSurveyorSelect.appendChild(errorOption.cloneNode(true));
|
||||
});
|
||||
} else {
|
||||
let defaultOption = document.createElement('option');
|
||||
defaultOption.value = '';
|
||||
defaultOption.text = 'Pilih tim terlebih dahulu.';
|
||||
penilaiSelect.appendChild(defaultOption);
|
||||
surveyorSelect.appendChild(defaultOption.cloneNode(true));
|
||||
penilaiSurveyorSelect.appendChild(defaultOption.cloneNode(true));
|
||||
}
|
||||
}
|
||||
|
||||
teamsSelect.addEventListener('change', function() {
|
||||
let teamId = this.value;
|
||||
fetchPenilai(teamId);
|
||||
});
|
||||
|
||||
let selectedTeamId = teamsSelect.value;
|
||||
if (selectedTeamId) {
|
||||
fetchPenilai(selectedTeamId);
|
||||
}
|
||||
});
|
||||
</script> --}}
|
||||
|
||||
<script>
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
|
||||
@@ -86,7 +86,6 @@
|
||||
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="module">
|
||||
const element = document.querySelector('#permohonan-table');
|
||||
const searchInput = document.getElementById('search');
|
||||
|
||||
@@ -86,7 +86,6 @@
|
||||
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="module">
|
||||
const element = document.querySelector('#permohonan-table');
|
||||
const searchInput = document.getElementById('search');
|
||||
|
||||
0
resources/views/penilaian/resume/index.blade.php
Normal file
0
resources/views/penilaian/resume/index.blade.php
Normal file
@@ -82,7 +82,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -81,7 +81,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
window.addEventListener('DOMContentLoaded', function () {
|
||||
|
||||
|
||||
@@ -86,7 +86,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -1,22 +0,0 @@
|
||||
@extends('layouts.main')
|
||||
|
||||
@section('breadcrumbs')
|
||||
{{ Breadcrumbs::render('tender.proses.penawaran') }}
|
||||
@endsection
|
||||
|
||||
@section('content')
|
||||
<div class="w-full grid gap-5 lg:gap-7.5 mx-auto">
|
||||
|
||||
<div class="card pb-2.5">
|
||||
<div class="card-header" id="basic_settings">
|
||||
<h3 class="card-title">
|
||||
Data Proses Penawaran
|
||||
</h3>
|
||||
|
||||
</div>
|
||||
<div class="card-body">
|
||||
{{-- @include('lpj::debitur.form') --}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
@@ -6,7 +6,9 @@
|
||||
|
||||
@section('content')
|
||||
<div class="grid">
|
||||
<div class="card card-grid min-w-full" data-datatable="false" data-datatable-page-size="5" data-datatable-state-save="false" id="prosespenawaran-table" data-api-url="{{ route('tender.prosespenawaran.datatables') }}">
|
||||
<div class="card card-grid min-w-full" data-datatable="false" data-datatable-page-size="5"
|
||||
data-datatable-state-save="false" id="prosespenawaran-table"
|
||||
data-api-url="{{ route('tender.prosespenawaran.datatables') }}">
|
||||
<div class="card-header py-5 flex-wrap">
|
||||
<h3 class="card-title">
|
||||
Daftar Proses Penawaran
|
||||
@@ -25,42 +27,44 @@
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="scrollable-x-auto">
|
||||
<table class="table table-auto table-border align-middle text-gray-700 font-medium text-sm" data-datatable-table="true">
|
||||
<table class="table table-auto table-border align-middle text-gray-700 font-medium text-sm"
|
||||
data-datatable-table="true">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="w-14">
|
||||
<input class="checkbox checkbox-sm" data-datatable-check="true" type="checkbox"/>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="nomor_registrasi">
|
||||
<span class="sort"> <span class="sort-label"> Nomor Registrasi </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="code">
|
||||
<span class="sort"> <span class="sort-label"> Kode Penawaran </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="start_date">
|
||||
<span class="sort"> <span class="sort-label"> Tanggal Penawaran </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="tujuan_penilaian_kjpp_id">
|
||||
<span class="sort"> <span class="sort-label"> Tujuan Penilaian </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="penawarandetails_count">
|
||||
<span class="sort"> <span class="sort-label"> Total KJPP </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="status">
|
||||
<span class="sort"> <span class="sort-label"> Status </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[50px] text-center" data-datatable-column="actions">Action</th>
|
||||
</tr>
|
||||
<tr>
|
||||
<th class="w-14">
|
||||
<input class="checkbox checkbox-sm" data-datatable-check="true" type="checkbox" />
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="nomor_registrasi">
|
||||
<span class="sort"> <span class="sort-label"> Nomor Registrasi </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="code">
|
||||
<span class="sort"> <span class="sort-label"> Kode Penawaran </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="start_date">
|
||||
<span class="sort"> <span class="sort-label"> Tanggal Penawaran </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="tujuan_penilaian_kjpp_id">
|
||||
<span class="sort"> <span class="sort-label"> Tujuan Penilaian KJPP </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="penawarandetails_count">
|
||||
<span class="sort"> <span class="sort-label"> Total KJPP </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[150px]" data-datatable-column="status">
|
||||
<span class="sort"> <span class="sort-label"> Status </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[50px] text-center" data-datatable-column="actions">Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
<div class="card-footer justify-center md:justify-between flex-col md:flex-row gap-3 text-gray-600 text-2sm font-medium">
|
||||
<div
|
||||
class="card-footer justify-center md:justify-between flex-col md:flex-row gap-3 text-gray-600 text-2sm font-medium">
|
||||
<div class="flex items-center gap-2">
|
||||
Show
|
||||
<select class="select select-sm w-16" data-datatable-size="true" name="perpage"> </select> per page
|
||||
@@ -78,10 +82,32 @@
|
||||
|
||||
@push('scripts')
|
||||
<script type="text/javascript">
|
||||
function showPenawaranData(regId)
|
||||
{
|
||||
var url = "{{ url('tender/prosespenawaran') }}/"+regId;
|
||||
$(location).attr('href',url);
|
||||
function formatDate(date) {
|
||||
const day = date.getDate().toString().padStart(2, '0');
|
||||
const month = (date.getMonth() + 1).toString().padStart(2, '0');
|
||||
// Months are 0-indexed
|
||||
const year = date.getFullYear();
|
||||
|
||||
return `${day} ${getIndonesianMonth(month)} ${year}`;
|
||||
}
|
||||
|
||||
function getIndonesianMonth(month) {
|
||||
const months = ['Januari', 'Februari', 'Maret', 'April', 'Mei', 'Juni',
|
||||
'Juli', 'Agustus', 'September', 'Oktober', 'November', 'Desember'
|
||||
];
|
||||
return months[month -
|
||||
1];
|
||||
}
|
||||
|
||||
function capitalizeWords(str) {
|
||||
return str.replace(/\b\w/g, function(char) {
|
||||
return char.toUpperCase();
|
||||
});
|
||||
}
|
||||
|
||||
function showPenawaranData(regId) {
|
||||
var url = "{{ url('tender/prosespenawaran') }}/" + regId;
|
||||
$(location).attr('href', url);
|
||||
}
|
||||
</script>
|
||||
<script type="module">
|
||||
@@ -111,9 +137,15 @@
|
||||
},
|
||||
start_date: {
|
||||
title: 'Tanggal Penawaran',
|
||||
render: (item, data) => {
|
||||
return `${formatDate(new Date(data.start_date))} - ${formatDate(new Date(data.end_date))}`
|
||||
}
|
||||
},
|
||||
tujuan_penilaian_kjpp_id: {
|
||||
title: 'Tujuan Penilaian',
|
||||
tujuan_penilaian_k_j_p_p: {
|
||||
title: 'Tujuan Penilaian KJPP',
|
||||
render: (item, data) => {
|
||||
return data.tujuan_penilaian_k_j_p_p[0].name
|
||||
}
|
||||
},
|
||||
penawarandetails_count: {
|
||||
title: 'Total KJPP',
|
||||
@@ -122,17 +154,20 @@
|
||||
},
|
||||
},
|
||||
status: {
|
||||
title: 'Status'
|
||||
title: 'Status',
|
||||
render: (item, data) => {
|
||||
return capitalizeWords(data.status)
|
||||
}
|
||||
},
|
||||
actions: {
|
||||
title: 'Status',
|
||||
render: (item, data) => {
|
||||
return `<div class="flex flex-nowrap justify-center">
|
||||
<a onclick="showPenawaranData(${data.id})" class="btn btn-sm btn-icon btn-clear btn-primary" title="Detail">
|
||||
<i class="ki-outline ki-abstract-26"></i>
|
||||
<i class="ki-outline ki-eye"></i>
|
||||
</a>
|
||||
<a class="btn btn-sm btn-icon btn-clear btn-info" title="Proses Penawaran" href="tender/prosespenawaran/${data.id}/edit">
|
||||
<i class="ki-outline ki-arrow-circle-right"></i>
|
||||
<i class="ki-outline ki-notepad-edit"></i>
|
||||
</a>
|
||||
</div>`;
|
||||
},
|
||||
@@ -142,12 +177,10 @@
|
||||
|
||||
let dataTable = new KTDataTable(element, dataTableOptions);
|
||||
// Custom search functionality
|
||||
searchInput.addEventListener('input', function () {
|
||||
searchInput.addEventListener('input', function() {
|
||||
const searchValue = this.value.trim();
|
||||
dataTable.search(searchValue, true);
|
||||
|
||||
});
|
||||
|
||||
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
@@ -64,7 +64,6 @@
|
||||
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -66,7 +66,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
156
resources/views/surveyor/components/apartemen-kantor.blade.php
Normal file
156
resources/views/surveyor/components/apartemen-kantor.blade.php
Normal file
@@ -0,0 +1,156 @@
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="bg-blue-600 text-white py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Analisa Unit</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
|
||||
<!-- Luas tanah -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Luas Unit</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 md:grid-cols-3 gap-4 mt-2">
|
||||
<label class="form-label flex items-center gap-3 text-nowrap">
|
||||
<input type="radio" class="radio" name="luasTanah" value="sesuai">
|
||||
<span class="ml-2">Sesuai</span>
|
||||
</label>
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="luasTanah" value="tidakSesuai">
|
||||
<span class="ml-2">Tidak Sesuai</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Jenis Unit -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Jenis Unit</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('bentuk_tanah') border-danger bg-danger-light @enderror"
|
||||
name="bentuk_tanah">
|
||||
<option value="">Select Jenis Unit</option>
|
||||
@if (isset($bentukTanah))
|
||||
@foreach ($bentukTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondidi Unit</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('konturTanah') border-danger bg-danger-light @enderror"
|
||||
name="konturTanah">
|
||||
<option value="">Select Kondidi Unit</option>
|
||||
@if (isset($konturTanah))
|
||||
@foreach ($konturTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('konturTanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Posisi Unit -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Posisi Unit</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('ketinggianTanah') border-danger bg-danger-light @enderror"
|
||||
name="ketinggianTanah">
|
||||
<option value="">Select Posisi Unit</option>
|
||||
@if (isset($ketinggianTanah))
|
||||
@foreach ($ketinggianTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('ketinggianTanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Lantai</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('posisiKavling') border-danger bg-danger-light @enderror"
|
||||
name="posisiKavling">
|
||||
<option value="">Select Lantai</option>
|
||||
@if (isset($posisiKavling))
|
||||
@foreach ($posisiKavling as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('posisiKavling')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Kondisi Fisik Tanah -->
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">View</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('kondisiFisikTanah') border-danger bg-danger-light @enderror"
|
||||
name="kondisiFisikTanah">
|
||||
<option value="">Select View</option>
|
||||
@if (isset($kondisiFisikTanah))
|
||||
@foreach ($kondisiFisikTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('kondisiFisikTanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Bentuk Unit</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('kondisiFisikTanah') border-danger bg-danger-light @enderror"
|
||||
name="kondisiFisikTanah">
|
||||
<option value="">Select Bentuk Unit</option>
|
||||
@if (isset($kondisiFisikTanah))
|
||||
@foreach ($kondisiFisikTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('kondisiFisikTanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
117
resources/views/surveyor/components/data-pembanding.blade.php
Normal file
117
resources/views/surveyor/components/data-pembanding.blade.php
Normal file
@@ -0,0 +1,117 @@
|
||||
<form action="{{ isset($debitur->id) ? route('debitur.update', $debitur->id) : route('debitur.store') }}" method="POST" class="grid gap-5">
|
||||
@if(isset($debitur->id))
|
||||
<input type="hidden" name="id" value="{{ $debitur->id }}">
|
||||
@method('PUT')
|
||||
@endif
|
||||
@csrf
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Address
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="flex flex-col lg:flex-row gap-2 w-full">
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select id="province_code" name="province_code" class="select w-full @error('province_code') border-danger bg-danger-light @enderror">
|
||||
<option value="">Select Province</option>
|
||||
@foreach($provinces as $province)
|
||||
@if(isset($debitur))
|
||||
<option value="{{ $province->code }}" {{ isset($debitur->province_code) && $debitur->province_code == $province->code?'selected' : '' }}>
|
||||
{{ $province->name }}
|
||||
</option>
|
||||
@else
|
||||
<option value="{{ $province->code }}">
|
||||
{{ $province->name }}
|
||||
</option>
|
||||
@endif
|
||||
@endforeach
|
||||
</select>
|
||||
@error('province_code')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select id="city_code" name="city_code" class="select w-full @error('city_code') border-danger bg-danger-light @enderror">
|
||||
<option value="">Select City</option>
|
||||
@if(isset($cities))
|
||||
@foreach($cities as $city)
|
||||
@if(isset($debitur))
|
||||
<option value="{{ $city->code }}" {{ isset($debitur->city_code) && $debitur->city_code == $city->code?'selected' : '' }}>
|
||||
{{ $city->name }}
|
||||
</option>
|
||||
@else
|
||||
<option value="{{ $city->code }}">
|
||||
{{ $city->name }}
|
||||
</option>
|
||||
@endif
|
||||
@endforeach
|
||||
|
||||
@endif
|
||||
</select>
|
||||
@error('city_code')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex flex-col lg:flex-row gap-2 w-full mt-2 lg:mt-5">
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select id="district_code" name="district_code" class="select w-full @error('district_code') border-danger bg-danger-light @enderror">
|
||||
<option value="">Select District</option>
|
||||
@if(isset($districts))
|
||||
@foreach($districts as $district)
|
||||
@if(isset($debitur))
|
||||
<option value="{{ $district->code }}" {{ isset($debitur->district_code) && $debitur->district_code == $district->code?'selected' : '' }}>
|
||||
{{ $district->name }}
|
||||
</option>
|
||||
@else
|
||||
<option value="{{ $district->code }}">
|
||||
{{ $district->name }}
|
||||
</option>
|
||||
@endif
|
||||
@endforeach
|
||||
|
||||
@endif
|
||||
</select>
|
||||
@error('district_code')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select id="village_code" name="village_code" class="select w-full @error('district_code') border-danger bg-danger-light @enderror">
|
||||
<option value="">Select Village</option>
|
||||
@if(isset($villages))
|
||||
@foreach($villages as $village)
|
||||
@if(isset($debitur))
|
||||
<option value="{{ $village->code }}" {{ isset($debitur->village_code) && $debitur->village_code == $village->code?'selected' : '' }}>
|
||||
{{ $village->name }}
|
||||
</option>
|
||||
@else
|
||||
<option value="{{ $village->code }}">
|
||||
{{ $village->name }}
|
||||
</option>
|
||||
@endif
|
||||
@endforeach
|
||||
|
||||
@endif
|
||||
</select>
|
||||
@error('district_code')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input class="input @error('postal_code') border-danger bg-danger-light @enderror" type="number" id="postal_code" name="postal_code" value="{{ $debitur->postal_code ?? '' }}" placeholder="Postal Code">
|
||||
@error('postal_code')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex flex-row w-full mt-2 lg:mt-5">
|
||||
<textarea class="textarea @error('address') border-danger bg-danger-light @enderror" rows="3" type="number" id="address" name="address">{{ $debitur->address ?? '' }}</textarea>
|
||||
@error('address')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
25
resources/views/surveyor/components/denah.blade.php
Normal file
25
resources/views/surveyor/components/denah.blade.php
Normal file
@@ -0,0 +1,25 @@
|
||||
<form action="{{ isset($debitur->id) ? route('debitur.update', $debitur->id) : route('debitur.store') }}" method="POST" class="grid gap-5">
|
||||
@if(isset($debitur->id))
|
||||
<input type="hidden" name="id" value="{{ $debitur->id }}">
|
||||
@method('PUT')
|
||||
@endif
|
||||
@csrf
|
||||
|
||||
<div class="mt-2">
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
|
||||
<div class="flex flex-wrap gap-4">
|
||||
<div class="flex w-full items-center justify-center gap-4">
|
||||
|
||||
<label class="form-label max-w-56">
|
||||
<span class="form-label">Upload Denah</span>
|
||||
</label>
|
||||
<input type="file" name="ruteMenujuLokasi" class="file-input file-input-bordered w-full ">
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</form>
|
||||
600
resources/views/surveyor/components/form-inspeksi.blade.php
Normal file
600
resources/views/surveyor/components/form-inspeksi.blade.php
Normal file
@@ -0,0 +1,600 @@
|
||||
@push('scripts')
|
||||
{{-- <script src="https://cdn.tailwindcss.com"></script> --}}
|
||||
@endpush
|
||||
|
||||
|
||||
<form id="debiturForm" action="{{ isset($debitur->id) ? route('debitur.update', $debitur->id) : route('debitur.store') }}" method="POST"
|
||||
class="grid gap-5">
|
||||
@if (isset($debitur->id))
|
||||
<input type="hidden" name="id" value="{{ $debitur->id }}">
|
||||
@method('PUT')
|
||||
@endif
|
||||
@csrf
|
||||
|
||||
|
||||
@if (false)
|
||||
@include('lpj::surveyor.components.apartemen-kantor')
|
||||
@else
|
||||
@include('lpj::surveyor.components.tanah-bangunan')
|
||||
@endif
|
||||
|
||||
|
||||
<div class=" bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="bg-green-600 text-white py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Analisis Lingkungan</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<!-- Jarak dari Objek Utama -->
|
||||
<div class="bg-gray-50 rounded-lg">
|
||||
<div class="grid grid-cols-3 gap-5">
|
||||
<div>
|
||||
<label class="block text-sm font-medium text-gray-700">Jarak Dari Jalan Utama</label>
|
||||
<input type="text" class="input mt-2" name="jarakDariJalan" placeholder="Km">
|
||||
</div>
|
||||
<div>
|
||||
<label class="block text-sm font-medium text-gray-700">Jarak ke CBD Point</label>
|
||||
<input type="text" class="input mt-2" name="jarakkeCbdPoint" placeholder="Km">
|
||||
</div>
|
||||
<div>
|
||||
<label class="block text-sm font-medium text-gray-700">Lebar Perkerasan Jalan Depan
|
||||
objek</label>
|
||||
<input type="text" name="lebarPerkerasanJalan" class="input mt-2" placeholder="Meter">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Perkerasan Jalan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('perkerasanJalan') border-danger bg-danger-light @enderror"
|
||||
name="perkerasanJalan">
|
||||
<option value="">Select Perkerasan Jalan</option>
|
||||
@if (isset($konturTanah))
|
||||
@foreach ($konturTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('perkerasanJalan')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Lalulintas -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Lalulintas Depan Lokasi</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('laluLintasDepanLoaksi') border-danger bg-danger-light @enderror"
|
||||
name="laluLintasDepanLoaksi">
|
||||
<option value="">Select PLalulintas Depan Lokasi</option>
|
||||
@if (isset($konturTanah))
|
||||
@foreach ($konturTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('laluLintasDepanLoaksi')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Golongan Hidup Sekitar -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Golongan Hidup Sekitar</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('golHidupSekitar') border-danger bg-danger-light @enderror"
|
||||
name="golHidupSekitar">
|
||||
<option value="">Select Golongan Hidup Sekitar</option>
|
||||
@if (isset($konturTanah))
|
||||
@foreach ($konturTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('golHidupSekitar')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Tingkat Keramaian -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tingkat Keramaian</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('tingkatKeramaian') border-danger bg-danger-light @enderror"
|
||||
name="tingkatKeramaian">
|
||||
<option value="">Select Tingkat Keramaian</option>
|
||||
@if (isset($konturTanah))
|
||||
@foreach ($konturTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('tingkatKeramaian')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Tataletak di Area -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tataletak di Area</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('tataLetakArea') border-danger bg-danger-light @enderror"
|
||||
name="tataLetakArea">
|
||||
<option value="">Select Tataletak di Area</option>
|
||||
@if (isset($konturTanah))
|
||||
@foreach ($konturTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('tataLetakArea')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Struktru tata letak -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Struktru tata letak</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 gap-4">
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="checkbox" class="checkbox" name="telahAdaBagunan" value="komersial">
|
||||
<span class="ml-2">Telah Ada Bangunan</span>
|
||||
</label>
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="checkbox" class="checkbox" name="telahAdaBagunan" value="komersial">
|
||||
<span class="ml-2">Belum Ada Bangunan</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@error('telahAdaBagunan')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Dekat Makam -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Dekat Makamh</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 gap-4 mt-2">
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="dekatMakam" value="ya">
|
||||
<span class="ml-2">Ya</span>
|
||||
</label>
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="dekatMakam" value="tidak">
|
||||
<span class="ml-2">Tidak</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Dekat Tps</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 gap-4 mt-2">
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="dekatTps" value="ya">
|
||||
<span class="ml-2">Ya</span>
|
||||
</label>
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="dekatTps" value="tidak">
|
||||
<span class="ml-2">Tidak</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Merupakan daerah</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('merupakanDaerah') border-danger bg-danger-light @enderror"
|
||||
name="merupakanDaerah">
|
||||
<option value="">Select Merupakan daerah</option>
|
||||
@if (isset($konturTanah))
|
||||
@foreach ($konturTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('merupakanDaerah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Fasilitas Umum Sekitar -->
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Fasilitas Umum dekat Object</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('fasilitasUmumDekat') border-danger bg-danger-light @enderror"
|
||||
name="fasilitasUmumDekat">
|
||||
<option value="">Select Fasilitas Umum Ddekat Object</option>
|
||||
@if (isset($konturTanah))
|
||||
@foreach ($konturTanah as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('fasilitasUmumDekat')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class=" bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="bg-blue-600 text-white py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Analisis Fakta</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Positif</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="faktorPositif" rows="3"></textarea>
|
||||
@error('faktorPositif')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Negatif</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="faktorNegatif" rows="3"></textarea>
|
||||
@error('faktorNegatif')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Rute Menuju</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="ruteMenuju" rows="3"></textarea>
|
||||
@error('ruteMenuju')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Batas batas</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 gap-4 items-center w-full">
|
||||
<div>
|
||||
<select class="select mt-2" name="BatasBatas">
|
||||
@if (isset($arahMataAngin))
|
||||
@foreach ($arahMataAngin as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
</div>
|
||||
<div>
|
||||
<input name="keteranganBatas" type="text" class="input mt-2">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@error('kondisiFisikTanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondisi lain terkait lingkungan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="kondisiLainTerkaitLingkungan" rows="3"></textarea>
|
||||
@error('kondisiLainTerkaitLingkungan')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondisi lain terkait Bangunan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="kondisiLainTerkaitBangunan" rows="3"></textarea>
|
||||
@error('kondisiLainTerkaitBangunan')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Informasi Terkait Dokumen</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="informasiTerkaitDokumen" rows="3"></textarea>
|
||||
@error('informasiTerkaitDokumen')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="container mx-auto ">
|
||||
<!-- Header -->
|
||||
<div class="bg-blue-600 text-white py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Informasi Dinas Tata Ruang</h1>
|
||||
</div>
|
||||
|
||||
<!-- Informasi Tata Ruang Form -->
|
||||
<div class="grid gap-5">
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Peruntukan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="peruntukan" class="input" placeholder="Masukkan Peruntukan">
|
||||
@error('peruntukan')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">KDB</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="kdb" class="input" placeholder="Masukkan KDB">
|
||||
@error('kdb')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">KDH</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="kdh" class="input" placeholder="Masukkan KDH">
|
||||
@error('kdh')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">GSB</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="gsb" class="input" placeholder="Masukkan GSB">
|
||||
@error('gsb')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Max Lantai</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="maxLantai" class="input" placeholder="Masukkan Max Lantai">
|
||||
@error('maxLantai')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">KLB</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="klb" class="input" placeholder="Masukkan KLB">
|
||||
@error('klb')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">GSS</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="gss" class="input" placeholder="Masukkan GSS">
|
||||
@error('gss')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Pelebaran Jalan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="pelebaranJalan" class="input"
|
||||
placeholder="Masukkan Pelebaran Jalan">
|
||||
@error('pelebaranJalan')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Nama Petugas TK</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="petugasTK" class="input" placeholder="Masukkan Petugas TK">
|
||||
@error('petugasTK')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Peta Section -->
|
||||
<div class="mt-2">
|
||||
<div class="bg-info border p-6 rounded-lg shadow-lg flex items-center justify-center" style="height: 300px">
|
||||
<iframe id="mapFrame" frameborder="0" style="width: 100%; height: 100%;"></iframe>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Upload Photo Button -->
|
||||
<div class=" flex w-full mt-2">
|
||||
<div class="input-group w-full">
|
||||
<input class="file-input" name="foto" type="file" />
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<!-- Notes Section -->
|
||||
<div class="mt-2">
|
||||
<div class="bg-white p-6 rounded-lg shadow-lg">
|
||||
<h4 class="block text-sm font-medium text-gray-700 mt-2">Catatan yang Perlu Diperhatikan</h4>
|
||||
<textarea name="notes" class="textarea mt-2" placeholder="Masukkan catatan penting" rows="3"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex justify-end gap-2" style="margin-right: 20px; margin-top: 20px">
|
||||
<button type="submit" class="btn btn-success">
|
||||
Save
|
||||
</button>
|
||||
<button type="submit" class="btn btn-primary">
|
||||
Submit
|
||||
</button>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
@push('scripts')
|
||||
|
||||
<script>
|
||||
// Fungsi untuk mengambil lokasi pengguna
|
||||
function getUserLocation() {
|
||||
if (navigator.geolocation) {
|
||||
navigator.geolocation.getCurrentPosition(showPosition, showError);
|
||||
} else {
|
||||
alert("Geolocation tidak didukung oleh browser ini.");
|
||||
}
|
||||
}
|
||||
|
||||
// Fungsi untuk menampilkan posisi
|
||||
function showPosition(position) {
|
||||
var lat = position.coords.latitude;
|
||||
var lng = position.coords.longitude;
|
||||
var mapUrl = `https://www.google.com/maps?q=${lat},${lng}&z=15&output=embed`;
|
||||
document.getElementById('mapFrame').src = mapUrl;
|
||||
}
|
||||
|
||||
// Fungsi untuk menangani error jika lokasi tidak bisa diambil
|
||||
function showError(error) {
|
||||
switch(error.code) {
|
||||
case error.PERMISSION_DENIED:
|
||||
alert("Pengguna menolak permintaan geolokasi.");
|
||||
break;
|
||||
case error.POSITION_UNAVAILABLE:
|
||||
alert("Informasi lokasi tidak tersedia.");
|
||||
break;
|
||||
case error.TIMEOUT:
|
||||
alert("Permintaan lokasi pengguna berakhir.");
|
||||
break;
|
||||
case error.UNKNOWN_ERROR:
|
||||
alert("Terjadi kesalahan yang tidak diketahui.");
|
||||
break;
|
||||
}
|
||||
}
|
||||
window.onload = getUserLocation;
|
||||
</script>
|
||||
|
||||
<script>
|
||||
// Fungsi untuk menyimpan data ke localStorage saat ada perubahan input
|
||||
|
||||
|
||||
const formElement = document.getElementById('debiturForm');
|
||||
|
||||
// Mengambil nilai dari localStorage saat halaman dimuat
|
||||
window.onload = () => {
|
||||
const storedData = localStorage.getItem('debiturData');
|
||||
if (storedData) {
|
||||
const formData = JSON.parse(storedData);
|
||||
// Mengisi nilai untuk elemen select
|
||||
for (const [key, value] of Object.entries(formData)) {
|
||||
const inputElement = formElement.querySelector(`[name="${key}"]`);
|
||||
if (inputElement) {
|
||||
if (inputElement.tagName === 'SELECT') {
|
||||
inputElement.value = value; // Atur nilai select
|
||||
} else if (inputElement.type === 'radio') {
|
||||
const radioButton = document.getElementById(`${key}${value.charAt(0).toUpperCase() + value.slice(1)}`);
|
||||
if (radioButton) {
|
||||
radioButton.checked = true; // Atur radio button yang sesuai sebagai checked
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
// Simpan data ke localStorage dalam bentuk JSON
|
||||
formElement.addEventListener('change', () => {
|
||||
const formData = {};
|
||||
const inputs = formElement.querySelectorAll('input, select');
|
||||
|
||||
inputs.forEach(input => {
|
||||
if (input.type === 'radio' && input.checked) {
|
||||
formData[input.name] = input.value; // Hanya ambil nilai radio yang terpilih
|
||||
} else if (input.type !== 'radio') {
|
||||
formData[input.name] = input.value; // Ambil nilai dari elemen lain
|
||||
}
|
||||
});
|
||||
|
||||
localStorage.setItem('debiturData', JSON.stringify(formData)); // Simpan objek sebagai JSON
|
||||
});
|
||||
|
||||
// Opsi: Reset localStorage saat form disubmit
|
||||
formElement.onsubmit = () => {
|
||||
localStorage.removeItem('debiturData'); // Menghapus data spesifik dari localStorage
|
||||
};
|
||||
|
||||
|
||||
// Opsi: Reset localStorage saat form disubmit
|
||||
document.getElementById('debiturForm').onsubmit = (event) => {
|
||||
event.preventDefault(); // Mencegah pengiriman form
|
||||
|
||||
// Menyimpan semua input ke localStorage
|
||||
inputs.forEach(input => {
|
||||
localStorage.setItem(input.name, input.value);
|
||||
});
|
||||
|
||||
// Opsional: Tampilkan pesan bahwa data telah disimpan
|
||||
alert('Data telah disimpan ke localStorage!');
|
||||
|
||||
// Jika ingin menghapus localStorage, uncomment baris di bawah
|
||||
// localStorage.clear();
|
||||
};
|
||||
</script>
|
||||
|
||||
@endpush
|
||||
89
resources/views/surveyor/components/foto.blade.php
Normal file
89
resources/views/surveyor/components/foto.blade.php
Normal file
@@ -0,0 +1,89 @@
|
||||
<form action="{{ isset($debitur->id) ? route('debitur.update', $debitur->id) : route('debitur.store') }}" method="POST"
|
||||
class="grid gap-5">
|
||||
@if (isset($debitur->id))
|
||||
<input type="hidden" name="id" value="{{ $debitur->id }}">
|
||||
@method('PUT')
|
||||
@endif
|
||||
@csrf
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="bg-blue-600 text-white py-4 px-6 flex items-center justify-between">
|
||||
<h1 class="text-md font-medium text-gray-900">Rute Menuju Lokasi</h1>
|
||||
<a id="btn-add" class="btn btn-primary btn-sm">
|
||||
<i class="ki-filled ki-plus text-lg"></i>
|
||||
</a>
|
||||
</div>
|
||||
<div class="flex w-ful items-center justify-center gap-4">
|
||||
<label class="form-label max-w-56">
|
||||
<span class="form-label">Foto Rute Menuju Lokasi</span>
|
||||
<input type="checkbox" name="ruteMenujuLokasi" class="checkbox">
|
||||
</label>
|
||||
<input type="file" name="ruteMenujuLokasi" class="file-input file-input-bordered w-full ">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="bg-blue-600 text-white py-4 px-6 flex items-center justify-between">
|
||||
<h1 class="text-md font-medium text-gray-900">Objeck Jaminan </h1>
|
||||
<a class="btn btn-primary btn-sm">
|
||||
<i class="ki-filled ki-plus text-lg"></i>
|
||||
</a>
|
||||
</div>
|
||||
<div class="flex flex-wrap gap-4">
|
||||
<div class="flex w-full items-center justify-center gap-4">
|
||||
|
||||
<label class="form-label max-w-56">
|
||||
<span class="form-label">Tampak Samping kiri</span>
|
||||
<input type="checkbox" name="ruteMenujuLokasi" class="checkbox">
|
||||
</label>
|
||||
<input type="file" name="ruteMenujuLokasi" class="file-input file-input-bordered w-full ">
|
||||
</div>
|
||||
<textarea name="ruteMenujuLokasi" id="" class="textarea" rows="3" rows="10"></textarea>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="bg-blue-600 text-white py-4 px-6 flex items-center justify-between">
|
||||
<h1 class="text-md font-medium text-gray-900">Linkungan </h1>
|
||||
<a class="btn btn-primary btn-sm">
|
||||
<i class="ki-filled ki-plus text-lg"></i>
|
||||
</a>
|
||||
</div>
|
||||
<div class="flex w-ful items-center justify-center gap-4">
|
||||
<label class="form-label max-w-56">
|
||||
<span class="form-label">Pendamping</span>
|
||||
<input type="checkbox" name="ruteMenujuLokasi" class="checkbox">
|
||||
</label>
|
||||
<input type="file" name="ruteMenujuLokasi" class="file-input file-input-bordered w-full ">
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</form>
|
||||
|
||||
|
||||
@push('script')
|
||||
|
||||
<script>
|
||||
|
||||
const btnAdd = document.getElementById('btn-add');
|
||||
|
||||
btnAdd.addEventListener('click', () => {
|
||||
|
||||
const div = document.createElement('div');
|
||||
div.innerHTML = `
|
||||
<div class="flex w-ful items-center justify-center gap-4">
|
||||
<label class="form-label max-w-56">
|
||||
<span class="form-label">Pendamping</span>
|
||||
<input type="checkbox" name="ruteMenujuLokasi" class="checkbox">
|
||||
</label>
|
||||
<input type="file" name="ruteMenujuLokasi" class="file-input file-input-bordered w-full ">
|
||||
</div>
|
||||
`;
|
||||
document.querySelector('.flex-wrap').appendChild(div);
|
||||
})
|
||||
|
||||
</script>
|
||||
|
||||
@endpush
|
||||
384
resources/views/surveyor/components/tanah-bangunan.blade.php
Normal file
384
resources/views/surveyor/components/tanah-bangunan.blade.php
Normal file
@@ -0,0 +1,384 @@
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="bg-blue-600 text-white py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Analisa Tanah</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
|
||||
<!-- Luas tanah -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Luas Tanah</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 md:grid-cols-3 gap-4 mt-2">
|
||||
<label class="form-label flex items-center gap-3 text-nowrap">
|
||||
<input type="radio" class="radio" name="luasTanah" value="sesuai">
|
||||
<span class="ml-2">Sesuai</span>
|
||||
</label>
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="luasTanah" value="tidakSesuai">
|
||||
<span class="ml-2">Tidak Sesuai</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Hadap Mata Angin</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('bentuk_tanah') border-danger bg-danger-light @enderror"
|
||||
name="bentuk_tanah">
|
||||
<option value="">Select Hadap Mata Angin</option>
|
||||
@if (isset($arahMataAngin))
|
||||
@foreach ($arahMataAngin as $item)
|
||||
<option value="{{ $item->name }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Bentuk Tanah -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Bentuk Tanah</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('bentuk_tanah') border-danger bg-danger-light @enderror"
|
||||
name="bentuk_tanah">
|
||||
<option value="">Select Bentuk Tanah</option>
|
||||
@if (isset($bentukTanah))
|
||||
@foreach ($bentukTanah as $item)
|
||||
<option value="{{ $item->name }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kontur Tanah</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('konturTanah') border-danger bg-danger-light @enderror"
|
||||
name="konturTanah">
|
||||
<option value="">Select Kontur Tanah</option>
|
||||
@if (isset($konturTanah))
|
||||
@foreach ($konturTanah as $item)
|
||||
<option value="{{ $item->name }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('konturTanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Beda Ketinggian Dengan Jalan -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Beda Ketinggian Dengan Jalan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('ketinggianTanah') border-danger bg-danger-light @enderror"
|
||||
name="ketinggianTanah">
|
||||
<option value="">Select Ketinggian Dengan Jalan</option>
|
||||
@if (isset($ketinggianTanah))
|
||||
@foreach ($ketinggianTanah as $item)
|
||||
<option value="{{ $item->name }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('ketinggianTanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Kontur Jalan Depan Objek -->
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kontur Jalan Depan Objek</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 md:grid-cols-3 gap-4 mt-2">
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="konturJalan" value="menurun">
|
||||
<span class="ml-2">Menurun</span>
|
||||
</label>
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="konturJalan" value="rata">
|
||||
<span class="ml-2">Rata</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Posisi Kavling</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('posisiKavling') border-danger bg-danger-light @enderror"
|
||||
name="posisiKavling">
|
||||
<option value="">Select Posisi Kavling</option>
|
||||
@if (isset($posisiKavling))
|
||||
@foreach ($posisiKavling as $item)
|
||||
<option value="{{ $item->name }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('posisiKavling')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Tusuk Sate -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tusuk Sate</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 md:grid-cols-3 gap-4 mt-2">
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="tusukSate" value="ya">
|
||||
<span class="ml-2">Ya</span>
|
||||
</label>
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="tusukSate" value="tidak">
|
||||
<span class="ml-2">Tidak</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Lockland -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Locklande</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 md:grid-cols-3 gap-4 mt-2">
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="lockland" value="ya">
|
||||
<span class="ml-2">Ya</span>
|
||||
</label>
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="lockland" value="tidak">
|
||||
<span class="ml-2">Tidak</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Kondisi Fisik Tanah -->
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondisi Fisik Tanah</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('kondisiFisikTanah') border-danger bg-danger-light @enderror"
|
||||
name="kondisiFisikTanah">
|
||||
<option value="">Select Posisi Kavling</option>
|
||||
@if (isset($kondisiFisikTanah))
|
||||
@foreach ($kondisiFisikTanah as $item)
|
||||
<option value="{{ $item->name }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('kondisiFisikTanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class=" bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="bg-blue-600 text-white py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Analisa Bangunan</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Luas Tanah</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-2 md:grid-cols-3 gap-4 mt-2">
|
||||
<label class="form-label flex items-center gap-3 text-nowrap">
|
||||
<input type="radio" class="radio" name="luasTanah" value="sesuai">
|
||||
<span class="ml-2">Sesuai</span>
|
||||
</label>
|
||||
<label class="form-label flex items-center gap-2.5 text-nowrap">
|
||||
<input type="radio" class="radio" name="luasTanah" value="tidakSesuai">
|
||||
<span class="ml-2">Tidak Sesuai</span>
|
||||
</label>
|
||||
</div>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Jenis Bangunan -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Jenis Bangunan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('jenisBangunan') border-danger bg-danger-light @enderror"
|
||||
name="jenisBangunan">
|
||||
<option value="">Select Jenis Bangunan</option>
|
||||
@if (isset($jenisBangunan))
|
||||
@foreach ($jenisBangunan as $item)
|
||||
<option value="{{ $item->name }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('jenisBangunan')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Kondisi Bangunan -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondisi Bangunan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('kondisiBangunan') border-danger bg-danger-light @enderror"
|
||||
name="kondisiBangunan">
|
||||
<option value="">Select Kondisi Bangunan</option>
|
||||
@if (isset($kondisiBangunan))
|
||||
@foreach ($kondisiBangunan as $item)
|
||||
<option value="{{ $item->name }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('kondisiBangunan')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Sifat Bangunan -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56"> Sifat Bangunan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('sifatBangunan') border-danger bg-danger-light @enderror"
|
||||
name="sifatBangunan">
|
||||
<option value="">Select Sifat Bangunan</option>
|
||||
@if (isset($sifatBangunan))
|
||||
@foreach ($sifatBangunan as $item)
|
||||
<option value="{{ $item->name }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('sifatBangunan')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- Spek Bangunan -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Spek Bangunan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
|
||||
<div class="grid grid-cols-2 md:grid-cols-3 gap-4 mt-2 w-full">
|
||||
@if (@isset($spekKategoriBagunan))
|
||||
@foreach ($spekKategoriBagunan as $item)
|
||||
<div>
|
||||
<label
|
||||
class="form-label flex items-center gap-3 text-nowrap">{{ $item->name }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('kondisiFisikTanah') border-danger bg-danger-light @enderror"
|
||||
name="kondisiFisikTanah">
|
||||
<option value="">Select {{ $item->name }}</option>
|
||||
@if (isset($spekBangunan))
|
||||
@foreach ($spekBangunan as $spek)
|
||||
@if ($spek->spek_kategori_bagunan_id == $item->id)
|
||||
<option value="{{ $spek->name }}">{{ $spek->name }}
|
||||
</option>
|
||||
@endif
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('kondisiFisikTanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
|
||||
@endif
|
||||
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<!-- Sarana pelengkap -->
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Sarana pelengkap</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('saranaPelengkap') border-danger bg-danger-light @enderror"
|
||||
name="saranaPelengkap">
|
||||
<option value="">Select Posisi Kavling</option>
|
||||
@if (isset($saranaPelengkap))
|
||||
@foreach ($saranaPelengkap as $item)
|
||||
<option value="{{ $item->id }}">{{ $item->name }}</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('saranaPelengkap')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
63
resources/views/surveyor/data/form.blade.php
Normal file
63
resources/views/surveyor/data/form.blade.php
Normal file
@@ -0,0 +1,63 @@
|
||||
@extends('layouts.main')
|
||||
|
||||
{{-- @section('breadcrumbs')
|
||||
{{ Breadcrumbs::render(request()->route()->getName()) }}
|
||||
@endsection --}}
|
||||
|
||||
@section('content')
|
||||
<div class="w-full grid gap-5 lg:gap-7.5 mx-auto">
|
||||
@if (isset($model->id))
|
||||
<form action="{{ route('basicdata.updateData', ['type' => $header[1], 'id' => $model->id]) }}" method="POST">
|
||||
<input type="hidden" name="id" value="{{ $model->id ?? '' }}">
|
||||
@method('PUT')
|
||||
@else
|
||||
<form method="POST" action="{{ route('basicdata.storeData', ['type' => $header[1]]) }}">
|
||||
@endif
|
||||
@csrf
|
||||
<div class="card pb-2.5">
|
||||
<input type="hidden" name="action" value="{{ $header[1] }}">
|
||||
<div class="card-header" id="basic_settings">
|
||||
<h3 class="card-title">
|
||||
{{ isset($jenisAset->id) ? 'Edit' : 'Tambah' }} {{ $header[0] }}
|
||||
</h3>
|
||||
<div class="flex items-center gap-2">
|
||||
<a href="{{ route('basicdata.' . $header[1] . '.index') }}" class="btn btn-xs btn-info">
|
||||
<i class="ki-filled ki-exit-left"></i> Back
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Code
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input class="input @error('code') border-danger bg-danger-light @enderror" type="text"
|
||||
name="code" value="{{ $model->code ?? '' }}" >
|
||||
@error('code')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">
|
||||
Name
|
||||
</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input class="input @error('name') border-danger bg-danger-light @enderror" type="text"
|
||||
name="name" value="{{ $model->name ?? '' }}">
|
||||
@error('name')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex justify-end">
|
||||
<button type="submit" class="btn btn-primary">
|
||||
Save
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
</div>
|
||||
@endsection
|
||||
153
resources/views/surveyor/data/index.blade.php
Normal file
153
resources/views/surveyor/data/index.blade.php
Normal file
@@ -0,0 +1,153 @@
|
||||
@extends('layouts.main')
|
||||
|
||||
{{-- @section('breadcrumbs')
|
||||
{{ Breadcrumbs::render('surveyor.bentuk-tanah') }}
|
||||
@endsection --}}
|
||||
|
||||
@section('content')
|
||||
<div class="grid">
|
||||
<div class="card card-grid min-w-full" data-datatable="false" data-datatable-page-size="5" data-datatable-state-save="false" id="data-table" data-api-url="{{ route('basicdata.datatablesSurveyory', ['type' => $header[0] ]) }}">
|
||||
<div class="card-header py-5 flex-wrap">
|
||||
<h3 class="card-title">
|
||||
Daftar {{$header[0]}}
|
||||
</h3>
|
||||
<div class="flex flex-wrap gap-2 lg:gap-5">
|
||||
<div class="flex">
|
||||
<label class="input input-sm"> <i class="ki-filled ki-magnifier"> </i>
|
||||
<input placeholder="Search {{$header[0]}}" id="search" type="text" value="">
|
||||
</label>
|
||||
</div>
|
||||
<div class="flex flex-wrap gap-2.5">
|
||||
<div class="h-[24px] border border-r-gray-200"></div>
|
||||
<a class="btn btn-sm btn-light" href=""> Export to Excel </a>
|
||||
|
||||
@php
|
||||
$href = route('basicdata.createData', ['type' => $header[1]]);
|
||||
@endphp
|
||||
|
||||
<a class="btn btn-sm btn-primary" href="{{$href}}"> Tambah {{$header[0]}} </a>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="scrollable-x-auto">
|
||||
<table class="table table-auto table-border align-middle text-gray-700 font-medium text-sm" data-datatable-table="true">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="w-14">
|
||||
<input class="checkbox checkbox-sm" data-datatable-check="true" type="checkbox"/>
|
||||
</th>
|
||||
<th class="min-w-[250px]" data-datatable-column="code">
|
||||
<span class="sort"> <span class="sort-label"> Code </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[250px]" data-datatable-column="name">
|
||||
<span class="sort"> <span class="sort-label"> Jenis Aset </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[50px] text-center" data-datatable-column="actions">Action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
</div>
|
||||
<div class="card-footer justify-center md:justify-between flex-col md:flex-row gap-3 text-gray-600 text-2sm font-medium">
|
||||
<div class="flex items-center gap-2">
|
||||
Show
|
||||
<select class="select select-sm w-16" data-datatable-size="true" name="perpage"> </select> per page
|
||||
</div>
|
||||
<div class="flex items-center gap-4">
|
||||
<span data-datatable-info="true"> </span>
|
||||
<div class="pagination" data-datatable-pagination="true">
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
title: 'Are you sure?',
|
||||
text: "You won't be able to revert this!",
|
||||
icon: 'warning',
|
||||
showCancelButton: true,
|
||||
confirmButtonColor: '#3085d6',
|
||||
cancelButtonColor: '#d33',
|
||||
confirmButtonText: 'Yes, delete it!'
|
||||
}).then((result) => {
|
||||
if (result.isConfirmed) {
|
||||
$.ajaxSetup({
|
||||
headers: {
|
||||
'X-CSRF-TOKEN': '{{ csrf_token() }}'
|
||||
}
|
||||
});
|
||||
|
||||
$.ajax(`basic-data/deleteData/${data}/{{$header[1]}}`, {
|
||||
type: 'DELETE'
|
||||
}).then((response) => {
|
||||
swal.fire('Deleted!', 'User has been deleted.', 'success').then(() => {
|
||||
window.location.reload();
|
||||
});
|
||||
}).catch((error) => {
|
||||
console.error('Error:', error);
|
||||
Swal.fire('Error!', 'An error occurred while deleting the file.', 'error');
|
||||
});
|
||||
}
|
||||
})
|
||||
}
|
||||
</script>
|
||||
<script type="module">
|
||||
const element = document.querySelector('#data-table');
|
||||
const searchInput = document.getElementById('search');
|
||||
|
||||
const header = '{{$header[1]}}';
|
||||
const apiUrl = element.getAttribute('data-api-url');
|
||||
const dataTableOptions = {
|
||||
apiEndpoint: apiUrl,
|
||||
pageSize: 5,
|
||||
columns: {
|
||||
select: {
|
||||
render: (item, data, context) => {
|
||||
const checkbox = document.createElement('input');
|
||||
checkbox.className = 'checkbox checkbox-sm';
|
||||
checkbox.type = 'checkbox';
|
||||
checkbox.value = data.id.toString();
|
||||
checkbox.setAttribute('data-datatable-row-check', 'true');
|
||||
return checkbox.outerHTML.trim();
|
||||
},
|
||||
},
|
||||
code: {
|
||||
title: 'Code',
|
||||
},
|
||||
name: {
|
||||
title: 'Jenis Aset',
|
||||
},
|
||||
actions: {
|
||||
title: 'Status',
|
||||
render: (item, data) => {
|
||||
return `<div class="flex flex-nowrap justify-center">
|
||||
<a class="btn btn-sm btn-icon btn-clear btn-info" href="basic-data/${header}/${data.id}">
|
||||
<i class="ki-outline ki-notepad-edit"></i>
|
||||
</a>
|
||||
<a onclick="deleteData(${data.id})" class="delete btn btn-sm btn-icon btn-clear btn-danger">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</a>
|
||||
</div>`;
|
||||
},
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
let dataTable = new KTDataTable(element, dataTableOptions);
|
||||
// Custom search functionality
|
||||
searchInput.addEventListener('input', function () {
|
||||
const searchValue = this.value.trim();
|
||||
dataTable.search(searchValue, true);
|
||||
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
@@ -148,15 +148,51 @@
|
||||
</div>
|
||||
|
||||
<div class="card min-w-full py-2 px-2">
|
||||
{{-- <div class="card-header">
|
||||
<h3 class="card-title">
|
||||
Data Jaminan
|
||||
</h3>
|
||||
</div> --}}
|
||||
<div class="card-header" id="basic_settings">
|
||||
<div class="card-title flex flex-row gap-1.5">
|
||||
<a href="{{ route('surveyor.show',array_merge(request()->query(),['id'=>$surveyor])) }}" class="btn btn-xs {{ request()->routeIs('surveyor.show') ? 'btn-outline btn-primary' : 'btn-light' }}" class="btn btn-xs btn-outline btn-primary">FORM INSPEKSI</a>
|
||||
|
||||
<a href="{{ route('surveyor.denah',array_merge(request()->query(),['id'=>$surveyor])) }}" class="btn btn-xs {{ request()->routeIs('surveyor.denah') ? 'btn-outline btn-primary' : 'btn-light' }}" class="btn btn-xs btn-outline btn-primary">DENAH TANAH DAN BANGUNAN</a>
|
||||
|
||||
<a href="{{ route('surveyor.foto',array_merge(request()->query(),['id'=>$surveyor])) }}" class="btn btn-xs {{ request()->routeIs('surveyor.foto') ? 'btn-outline btn-primary' : 'btn-light' }}" class="btn btn-xs btn-outline btn-primary">FOTO</a>
|
||||
|
||||
<a href="{{ route('surveyor.data-pembanding',array_merge(request()->query(),['id'=>$surveyor])) }}" class="btn btn-xs {{ request()->routeIs('surveyor.data-pembanding') ? 'btn-outline btn-primary' : 'btn-light' }}" class="btn btn-xs btn-outline btn-primary">DATA PEMBANDING</a>
|
||||
</div>
|
||||
|
||||
<div class="flex flex-col gap-5 lg:gap-7.5">
|
||||
|
||||
</div>
|
||||
<div class="card-body">
|
||||
@if(request()->routeIs('surveyor.show',$surveyor))
|
||||
@include('lpj::surveyor.components.form-inspeksi')
|
||||
|
||||
@elseif(request()->routeIs('surveyor.denah',$surveyor))
|
||||
|
||||
@include('lpj::surveyor.components.denah')
|
||||
|
||||
@elseif(request()->routeIs('surveyor.foto', $surveyor))
|
||||
@include('lpj::surveyor.components.foto')
|
||||
|
||||
@elseif(request()->routeIs('surveyor.data-pembanding', $surveyor))
|
||||
|
||||
@include('lpj::surveyor.components.data-pembanding')
|
||||
@endif
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
|
||||
<script>
|
||||
$('.card-title a').on('click', function(e) {
|
||||
e.preventDefault();
|
||||
var url = $(this).attr('href');
|
||||
|
||||
$.get(url, function(response) {
|
||||
$('.card-body').html(response);
|
||||
});
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
@endpush
|
||||
|
||||
@@ -22,13 +22,13 @@
|
||||
|
||||
<div class="w-full grid gap-5 lg:gap-7.5 mx-auto">
|
||||
<div class="card pb-2.5">
|
||||
<div class="card-header" id="basic_settings">
|
||||
<div class="card-title flex flex-row gap-1.5">
|
||||
Surveyor
|
||||
</div>
|
||||
|
||||
|
||||
<div class="card-grid min-w-full" data-datatable="false" data-datatable-page-size="5"
|
||||
data-datatable-state-save="false" id="permohonan-table" data-api-url="{{ route('surveyor.datatables') }}">
|
||||
<div class="card-header py-5 flex-wrap">
|
||||
<h3 class="card-title">
|
||||
{{-- Daftar {{}} --}}
|
||||
Surveyor
|
||||
</h3>
|
||||
<div class="flex flex-wrap gap-2 lg:gap-5">
|
||||
<div class="flex">
|
||||
@@ -44,10 +44,6 @@
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-grid min-w-full" data-datatable="false" data-datatable-page-size="5"
|
||||
data-datatable-state-save="false" id="permohonan-table" data-api-url="{{ route('surveyor.datatables') }}">
|
||||
|
||||
<div class="card-body">
|
||||
<div class="scrollable-x-auto">
|
||||
|
||||
@@ -68,7 +68,6 @@
|
||||
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -62,7 +62,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -69,7 +69,6 @@
|
||||
@endsection
|
||||
|
||||
@push('scripts')
|
||||
<script src="https://cdn.jsdelivr.net/npm/sweetalert2@11"></script>
|
||||
<script type="text/javascript">
|
||||
function deleteData(data) {
|
||||
Swal.fire({
|
||||
|
||||
@@ -416,11 +416,6 @@ Breadcrumbs::for('tender.penawaran.editPenawaran', function (BreadcrumbTrail $tr
|
||||
$trail->push('Penawaran Ulang', route('tender.penawaran.editPenawaran', $noreg));
|
||||
});
|
||||
|
||||
Breadcrumbs::for('tender.proses.penawaran', function (BreadcrumbTrail $trail) {
|
||||
$trail->parent('tender');
|
||||
$trail->push('Data Proses Penawaran', route('tender.proses_penawaran.index'));
|
||||
});
|
||||
|
||||
|
||||
Breadcrumbs::for('tender.penawaran.ulang', function (BreadcrumbTrail $trail) {
|
||||
$trail->parent('tender');
|
||||
@@ -436,6 +431,27 @@ Breadcrumbs::for('surveyor.show', function (BreadcrumbTrail $trail) {
|
||||
$trail->push('Detail');
|
||||
});
|
||||
|
||||
Breadcrumbs::for('surveyor.form-inspeksi', function (BreadcrumbTrail $trail) {
|
||||
$trail->parent('surveyor');
|
||||
$trail->push('Form Inspeksi');
|
||||
});
|
||||
|
||||
Breadcrumbs::for('surveyor.denah', function (BreadcrumbTrail $trail) {
|
||||
$trail->parent('surveyor');
|
||||
$trail->push('Denah');
|
||||
});
|
||||
|
||||
Breadcrumbs::for('surveyor.foto', function (BreadcrumbTrail $trail) {
|
||||
$trail->parent('surveyor');
|
||||
$trail->push('Form Foto');
|
||||
});
|
||||
|
||||
Breadcrumbs::for('surveyor.data-pembanding', function (BreadcrumbTrail $trail) {
|
||||
$trail->parent('surveyor');
|
||||
$trail->push('Form Pembanding');
|
||||
});
|
||||
|
||||
|
||||
Breadcrumbs::for('registrasi', function (BreadcrumbTrail $trail) {
|
||||
$trail->push('Registrasi', route('registrasi.index'));
|
||||
});
|
||||
|
||||
@@ -357,7 +357,33 @@ Route::middleware(['auth'])->group(function () {
|
||||
Route::resource('jenis_laporan', JenisLaporanController::class);
|
||||
// End Activity Jenis Laporan route
|
||||
|
||||
// basic data surveyor
|
||||
Route::get('datatablesSurveyory/{type}', [SurveyorController::class, 'dataForDatatablesData'])->name('datatablesSurveyory');
|
||||
Route::get('createData/{type}', [SurveyorController::class, 'createData'])->name('createData');
|
||||
Route::get('/{type}/{id}', [SurveyorController::class, 'editData'])->name('editData');
|
||||
Route::post('storeData/{type}', [SurveyorController::class, 'storeData'])->name('storeData');
|
||||
Route::put('updateData/{type}/{id}', [SurveyorController::class, 'updateData'])->name('updateData');
|
||||
Route::delete('deleteData/{id}/{type}', [SurveyorController::class, 'destroy'])->name('deleteData');
|
||||
|
||||
$headers = [
|
||||
'bentuk-tanah' => 'Bentuk Tanah',
|
||||
'kontur-tanah' => 'Kontur Tanah',
|
||||
'posisi-kavling' => 'Posisi Kavling',
|
||||
'ketinggian-tanah' => 'Ketinggian Tanah',
|
||||
'kondisi-fisik-tanah' => 'Kondisi Fisik Tanah',
|
||||
'jenis-bangunan' => 'Jenis Bangunan',
|
||||
'kondisi-bangunan' => 'Kondisi Bangunan',
|
||||
'sifat-bangunan' => 'Sifat Bangunan',
|
||||
// 'spek-bangunan' => 'Speksifikasi Bangunan',
|
||||
// 'spek-kategori-bagunan' => 'Speksifikasi Kategori Bangunan',
|
||||
'sarana-pelengkap' => 'Sarana Pelengkap',
|
||||
];
|
||||
|
||||
foreach ($headers as $type => $header) {
|
||||
Route::get($type, [SurveyorController::class, 'data'])
|
||||
->name($type . '.index')
|
||||
->defaults('type', $type);
|
||||
}
|
||||
});
|
||||
|
||||
Route::name('permohonan.')->prefix('permohonan')->group(function () {
|
||||
@@ -439,11 +465,6 @@ Route::middleware(['auth'])->group(function () {
|
||||
Route::get('penawaran/ulang/datatables', [TenderController::class, 'datatablesPenawaranUlang'])->name(
|
||||
'penawaran.ulang.datatables',
|
||||
);
|
||||
|
||||
// Proses Penawaran
|
||||
Route::get('proses_penawaran', [TenderController::class, 'proses_penawaran_index'])->name(
|
||||
'proses_penawaran.index',
|
||||
);
|
||||
});
|
||||
|
||||
Route::name('penilaian.')->prefix('penilaian')->group(function () {
|
||||
@@ -495,6 +516,18 @@ Route::middleware(['auth'])->group(function () {
|
||||
Route::get('/datatables/{otorisator}', [PenilaianController::class, 'dataForAuthorization'])->name('datatables');
|
||||
Route::get('show/{id}', [PenilaianController::class, 'show'])->name('show');
|
||||
});
|
||||
|
||||
|
||||
|
||||
Route::name('surveyor.')->prefix('surveyor')->group(function () {
|
||||
Route::get('/', [SurveyorController::class, 'index'])->name('index');
|
||||
Route::get('{id}/show', [SurveyorController::class, 'show'])->name('show');
|
||||
Route::get('datatables', [SurveyorController::class, 'dataForDatatables'])->name('datatables');
|
||||
Route::get('form-inspeksi/{id}', [SurveyorController::class, 'formInspeksi'])->name('form-inspeksi');
|
||||
Route::get('denah/{id}', [SurveyorController::class, 'denah'])->name('denah');
|
||||
Route::get('foto/{id}', [SurveyorController::class, 'foto'])->name('foto');
|
||||
Route::get('data-pembanding/{id}', [SurveyorController::class, 'dataPembanding'])->name('data-pembanding');
|
||||
});
|
||||
});
|
||||
|
||||
require __DIR__ . '/registrasi.php';
|
||||
|
||||
Reference in New Issue
Block a user