58 lines
1.3 KiB
PHP
58 lines
1.3 KiB
PHP
<?php
|
|
|
|
namespace App\Http\Controllers;
|
|
|
|
use Illuminate\Http\Request;
|
|
use Spatie\Permission\Models\Role;
|
|
use Spatie\Permission\Models\Permission;
|
|
use Illuminate\Support\Facades\Auth;
|
|
use App\Models\User;
|
|
use PDF;
|
|
use App\Models\Cawangan;
|
|
use App\Models\JenisEmas;
|
|
use App\Models\JenisKarat;
|
|
|
|
use App\Models\Lelong;
|
|
use App\Models\CawanganLelong;
|
|
use App\Models\LelongBid;
|
|
use App\Models\LelongBidMarhun;
|
|
use App\Models\LelKarat;
|
|
use App\Models\LelKarat_temp;
|
|
|
|
class MarhunController extends Controller
|
|
{
|
|
/**
|
|
* Create a new controller instance.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function __construct()
|
|
{
|
|
$this->middleware('auth');
|
|
}
|
|
|
|
/**
|
|
* Show the application dashboard.
|
|
*
|
|
* @return \Illuminate\Contracts\Support\Renderable
|
|
*/
|
|
public function index()
|
|
{
|
|
$user = Auth::user();
|
|
|
|
$caw = Cawangan::where('caw_code','=',$user->kodcaw)->first();
|
|
|
|
$lelongbid = LelongBid::where('caw_id','=',$caw->id)->get();
|
|
|
|
return view('marhun.senaraimarhun',compact('lelongbid'));
|
|
}
|
|
public function show($id)
|
|
{
|
|
$lelongbid = LelongBid::where('id','=',$id)->first();
|
|
$marhun = LelongBidMarhun::where('lelongbid_id','=',$id)->get();
|
|
|
|
return view('marhun.marhun',compact('marhun','lelongbid'));
|
|
}
|
|
|
|
}
|
|
|