Merge remote-tracking branch 'origin/tender' into staging
# Conflicts: # module.json
This commit is contained in:
@@ -35,7 +35,6 @@ class KJPPController extends Controller
|
||||
*/
|
||||
public function create()
|
||||
{
|
||||
$branch = Branch::all();
|
||||
$ijin_usaha = IjinUsaha::all();
|
||||
$jenis_aset = JenisJaminan::all();
|
||||
$provinces = Province::all();
|
||||
@@ -48,7 +47,7 @@ class KJPPController extends Controller
|
||||
// Combine KJPP number with branch code
|
||||
$fullKjppNumber = $kjppNumber;
|
||||
|
||||
return view('lpj::kjpp.create', compact('branch', 'ijin_usaha', 'jenis_aset', 'provinces', 'fullKjppNumber'));
|
||||
return view('lpj::kjpp.create', compact('ijin_usaha', 'jenis_aset', 'provinces', 'fullKjppNumber'));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -98,13 +97,12 @@ class KJPPController extends Controller
|
||||
$ijin_usaha = IjinUsaha::where('code', $kjpp->nomor_ijin_usaha)->get();
|
||||
$ijin_usahas = IjinUsaha::all();
|
||||
$jenis_jaminan = JenisJaminan::all();
|
||||
$branches = Branch::where('name', $kjpp->jenis_kantor)->get();
|
||||
$provinces = Province::where('code', $kjpp->province_code)->get();
|
||||
$cities = City::where('code', $kjpp->city_code)->get();
|
||||
$districts = District::where('code', $kjpp->district_code)->get();
|
||||
$villages = Village::where('code', $kjpp->village_code)->get();
|
||||
// dd($branches);
|
||||
return view('lpj::kjpp.show', compact('jenis_jaminan', 'ijin_usahas', 'ijin_usaha', 'branches', 'kjpp', 'provinces', 'cities', 'districts', 'villages'));
|
||||
return view('lpj::kjpp.show', compact('jenis_jaminan', 'ijin_usahas', 'ijin_usaha', 'kjpp', 'provinces', 'cities', 'districts', 'villages'));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -113,7 +111,6 @@ class KJPPController extends Controller
|
||||
public function edit($id)
|
||||
{
|
||||
$kjpp = KJPP::find($id);
|
||||
$branch = Branch::all();
|
||||
$ijin_usaha = IjinUsaha::all();
|
||||
$jenis_aset = JenisJaminan::all();
|
||||
$provinces = Province::all();
|
||||
@@ -121,7 +118,7 @@ class KJPPController extends Controller
|
||||
$districts = District::where('city_code', $kjpp->city_code)->get();
|
||||
$villages = Village::where('district_code', $kjpp->district_code)->get();
|
||||
|
||||
return view('lpj::kjpp.create', compact('kjpp', 'branch', 'ijin_usaha', 'jenis_aset', 'provinces', 'cities', 'districts', 'villages'));
|
||||
return view('lpj::kjpp.create', compact('kjpp', 'ijin_usaha', 'jenis_aset', 'provinces', 'cities', 'districts', 'villages'));
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -55,9 +55,12 @@ class TenderController extends Controller
|
||||
|
||||
$validated['nomor_registrasi'] = $penawaran->nomor_registrasi;
|
||||
|
||||
$validated['nama_kjpp_sebelumnya'] = json_encode($request->input('nama_kjpp_sebelumnya'));
|
||||
// Mengatasi null untuk nama_kjpp_sebelumnya, biaya_kjpp_sebelumnya, dan tanggal_penilaian_sebelumnya
|
||||
$validated['nama_kjpp_sebelumnya'] = json_encode($request->input('nama_kjpp_sebelumnya') ?? []);
|
||||
$validated['biaya_kjpp_sebelumnya'] = $request->input('biaya_kjpp_sebelumnya') ?? '';
|
||||
$validated['tanggal_penilaian_sebelumnya'] = $request->input('tanggal_penilaian_sebelumnya') ?? '';
|
||||
|
||||
dd($validated);
|
||||
// dd($validated);
|
||||
|
||||
PenawaranTender::create($validated);
|
||||
|
||||
@@ -77,7 +80,9 @@ class TenderController extends Controller
|
||||
public function penawaran_show($id)
|
||||
{
|
||||
$penawaran = PenawaranTender::find($id);
|
||||
return view('lpj::penawaran.show', compact('id', 'penawaran'));
|
||||
$kjpps = KJPP::find($id);
|
||||
|
||||
return view('lpj::penawaran.show', compact('id', 'penawaran', 'kjpps'));
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -111,7 +116,7 @@ class TenderController extends Controller
|
||||
}
|
||||
|
||||
// Retrieve data from the database
|
||||
$query = PenawaranTender::query();
|
||||
$query = PenawaranTender::query()->where('status', '=', 'Registered');
|
||||
|
||||
// Apply search filter if provided
|
||||
if ($request->has('search') && !empty($request->get('search'))) {
|
||||
|
||||
Reference in New Issue
Block a user