Fix saving marhun photo file to correct directory
This commit is contained in:
@@ -517,6 +517,7 @@ class MarhunController extends Controller
|
||||
{
|
||||
|
||||
$lelongbid = LelongBid::where('id', '=', $id)->first();
|
||||
$norujukan_sag = $lelongbid->norujukan;
|
||||
$filemarhun = FileMarhun::where('lelongbid_id', '=', $lelongbid['id'])
|
||||
->where('photo_type', '=', '1')
|
||||
->first();
|
||||
@@ -537,7 +538,7 @@ class MarhunController extends Controller
|
||||
foreach ($marhun as $index) {
|
||||
$eachmarhun = FileMarhun::where('lelongbidmarhun_id', '=', $index['id'])->first();
|
||||
if (isset($eachmarhun)) {
|
||||
$index->eachmarhun_filename = route('marhun.showphotomarhun', ['lelong_id' => $lelong_id, 'filemarhun_id' => $eachmarhun]);
|
||||
$index->eachmarhun_filename = route('marhun.showphotomarhun', ['norujukan_sag' => $norujukan_sag, 'filemarhun_id' => $eachmarhun]);
|
||||
$index->eachmarhun_id = $eachmarhun->id;
|
||||
}
|
||||
|
||||
@@ -2258,7 +2259,7 @@ class MarhunController extends Controller
|
||||
public function showPhotoMarhun(Request $request)
|
||||
{
|
||||
$marhun = FileMarhun::where('id', '=', $request->filemarhun_id)->first();
|
||||
return $this->marhunPhotoService->show($request->lelong_id, $marhun);
|
||||
return $this->marhunPhotoService->show($request->norujukan_sag, $marhun);
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user