Commit d5b22270 by Palti Sinaga

H-2 lagi

parent 9d375733
...@@ -26,37 +26,51 @@ class OwnerController extends Controller ...@@ -26,37 +26,51 @@ class OwnerController extends Controller
{ {
//coba //coba
$dataPemilik = DB::table('pemilikhomestay') // $dataPemilik = DB::table('pemilikhomestay')
// ->select('pemilikhomestay.*')
// ->where('pemilikhomestay.id_akun','=',Auth::user()->id)
// ->get();
//
// $data = DB::table('homestay')
// ->join('pemilikhomestay','homestay.id_pemilik','pemilikhomestay.id')
// ->join('kamar','homestay.id','=','kamar.id_homestay')
// ->select('kamar.*')
// ->where('pemilikhomestay.id','=',$dataPemilik[0]->id)
// ->get();
//
// $dataHomestay = DB::table('homestay')
// ->join('pemilikhomestay','homestay.id_pemilik','pemilikhomestay.id')
// ->select('homestay.id')
// ->where('pemilikhomestay.id','=',$dataPemilik[0]->id)
// ->get();
//
// $dataListOfBook = DB::table('daftar_book')
// ->select('daftar_book.*')
// ->where('daftar_book.homestay','=',$dataHomestay[0]->id)
// ->get();
//
// $dataFeedback = DB::table('feedback')
// ->join('pelanggan','feedback.id_pelanggan','pelanggan.id')
// ->select('feedback.*','pelanggan.nama')
// ->where('feedback.id_pemilik_homestay','=',$dataPemilik[0]->id)
// ->get();
//coba
$dataPel = DB::table('pemilikhomestay')
->select('pemilikhomestay.*') ->select('pemilikhomestay.*')
->where('pemilikhomestay.id_akun','=',Auth::user()->id) ->where('pemilikhomestay.id_akun','=',Auth::user()->id)
->get(); ->get();
$data = DB::table('homestay') $data = DB::table('homestay')
->join('pemilikhomestay','homestay.id_pemilik','pemilikhomestay.id') ->join('pemilikhomestay','homestay.id_pemilik','=','pemilikhomestay.id')
->join('kamar','homestay.id','=','kamar.id_homestay') ->join('transaksi','homestay.id','=','transaksi.id_homestay')
->select('kamar.*') ->join('pelanggan','transaksi.id_pelanggan','=','pelanggan.id')
->where('pemilikhomestay.id','=',$dataPemilik[0]->id) ->select('transaksi.*','pelanggan.nama','pelanggan.alamat','pelanggan.no_telepon')
->get(); ->where('homestay.id_pemilik','=',$dataPel[0]->id)
->orderBy('transaksi.id','desc')
$dataHomestay = DB::table('homestay')
->join('pemilikhomestay','homestay.id_pemilik','pemilikhomestay.id')
->select('homestay.id')
->where('pemilikhomestay.id','=',$dataPemilik[0]->id)
->get();
$dataListOfBook = DB::table('daftar_book')
->select('daftar_book.*')
->where('daftar_book.homestay','=',$dataHomestay[0]->id)
->get();
$dataFeedback = DB::table('feedback')
->join('pelanggan','feedback.id_pelanggan','pelanggan.id')
->select('feedback.*','pelanggan.nama')
->where('feedback.id_pemilik_homestay','=',$dataPemilik[0]->id)
->get(); ->get();
//coba
return view('adminlte::layouts.owner.home')->with('count',$data->count())->with('count1',$dataListOfBook->count())->with('count2',$dataFeedback->count()); return view('adminlte::layouts.owner.listPesanan')->with('data',$data)->with('count',$data->count());
// return view('adminlte::layouts.owner.listPesanan')->with('count',$data->count())->with('count1',$dataListOfBook->count())->with('count2',$dataFeedback->count())->with('dataF',$dataFeedback);
} }
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
@section('main-content') @section('main-content')
<div class="box box-primary"> <div class="box box-primary">
<div class="box-header with-border"> <div class="box-header with-border">
<h3 class="box-title"> REQUEST FASILITAS </h3> <h3 class="box-title"> PERMINTAAN FASILITAS </h3>
@if (count($errors) > 0) @if (count($errors) > 0)
<div class="alert alert-danger"> <div class="alert alert-danger">
<strong>Whoops!</strong> {{ trans('adminlte_lang::message.someproblems') }}<br><br> <strong>Whoops!</strong> {{ trans('adminlte_lang::message.someproblems') }}<br><br>
......
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
<div class="icon"> <div class="icon">
<i class="fa fa-bed"></i> <i class="fa fa-bed"></i>
</div> </div>
<a href="#" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a> <a href="/daftarKamar" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a>
</div> </div>
</div> </div>
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
<div class="icon"> <div class="icon">
<i class="fa fa-list"></i> <i class="fa fa-list"></i>
</div> </div>
<a href="#" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a> <a href="/pesanan" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a>
</div> </div>
</div> </div>
...@@ -53,7 +53,7 @@ ...@@ -53,7 +53,7 @@
<div class="icon"> <div class="icon">
<i class="fa fa-edit"></i> <i class="fa fa-edit"></i>
</div> </div>
<a href="#" class="small-box-footer">More info <i class="fa fa-arrow-circle-right"></i></a> <a href="/listFeedback" class="small-box-footer">More info <i class="fa fa-arrow-circle-right"></i></a>
</div> </div>
</div> </div>
...@@ -81,108 +81,48 @@ ...@@ -81,108 +81,48 @@
<!-- Left col --> <!-- Left col -->
<section class="col-lg-7 connectedSortable"> <section class="col-lg-7 connectedSortable">
<!-- Custom tabs (Charts with tabs)--> <!-- Custom tabs (Charts with tabs)-->
<div class="nav-tabs-custom">
<!-- Tabs within a box -->
<ul class="nav nav-tabs pull-right">
<li class="active"><a href="#revenue-chart" data-toggle="tab">Area</a></li>
<li><a href="#sales-chart" data-toggle="tab">Donut</a></li>
<li class="pull-left header"><i class="fa fa-inbox"></i> Sales</li>
</ul>
<div class="tab-content no-padding">
<!-- Morris chart - Sales -->
<div class="chart tab-pane active" id="revenue-chart" style="position: relative; height: 300px;"></div>
<div class="chart tab-pane" id="sales-chart" style="position: relative; height: 300px;"></div>
</div>
</div>
<!-- /.nav-tabs-custom --> <!-- /.nav-tabs-custom -->
<!-- Chat box --> <!-- Chat box -->
<div class="box box-success"> <div class="box box-success">
<div class="box-header"> <div class="box-header">
<i class="fa fa-comments-o"></i> <i class="fa fa-comments-o"></i>
<h3 class="box-title">Feedback</h3>
<h3 class="box-title">Chat</h3>
<div class="box-tools pull-right" data-toggle="tooltip" title="Status"> <div class="box-tools pull-right" data-toggle="tooltip" title="Status">
<div class="btn-group" data-toggle="btn-toggle"> <div class="btn-group" data-toggle="btn-toggle">
<button type="button" class="btn btn-default btn-sm active"><i class="fa fa-square text-green"></i> <a href="/listFeedback" style="btn btn-primary btn-sm btn-flat">Lihat</a>
</button>
<button type="button" class="btn btn-default btn-sm"><i class="fa fa-square text-red"></i></button>
</div> </div>
</div> </div>
</div> </div>
<div class="box-body chat" id="chat-box"> <div class="box-body chat" id="chat-box">
<!-- chat item --> <!--Chat item -->
@foreach($dataF as $a)
<div class="item"> <div class="item">
<img src="dist/img/user4-128x128.jpg" alt="user image" class="online"> <img src="" alt="user image" class="offline" style="display:none">
<p class="message"> <p class="message">
<a href="#" class="name"> <a href="#" class="name">
<small class="text-muted pull-right"><i class="fa fa-clock-o"></i> 2:15</small> <small class="text-muted pull-right"><i class="fa fa-clock-o"></i> {{$a->created_at}}</small>
Mike Doe {{$a->nama}}
</a> </a>
I would like to meet you to discuss the latest news about
the arrival of the new theme. They say it is going to be one the
best themes on the market
</p>
<div class="attachment">
<h4>Attachments:</h4>
<p class="filename">
Theme-thumbnail-image.jpg
</p> </p>
<div class="pull-right">
<button type="button" class="btn btn-primary btn-sm btn-flat">Open</button>
</div> </div>
</div> <tr>
<!-- /.attachment --> <td>{{$a->nama}}</td>
</div> <td>{{$a->feedback}}</td>
<!-- /.item --> </tr>
<!-- chat item --> @endforeach
<div class="item"> <!--Chat item -->
<img src="dist/img/user3-128x128.jpg" alt="user image" class="offline">
<p class="message">
<a href="#" class="name">
<small class="text-muted pull-right"><i class="fa fa-clock-o"></i> 5:15</small>
Alexander Pierce
</a>
I would like to meet you to discuss the latest news about
the arrival of the new theme. They say it is going to be one the
best themes on the market
</p>
</div>
<!-- /.item -->
<!-- chat item -->
<div class="item">
<img src="dist/img/user2-160x160.jpg" alt="user image" class="offline">
<p class="message">
<a href="#" class="name">
<small class="text-muted pull-right"><i class="fa fa-clock-o"></i> 5:30</small>
Susan Doe
</a>
I would like to meet you to discuss the latest news about
the arrival of the new theme. They say it is going to be one the
best themes on the market
</p>
</div>
<!-- /.item -->
</div>
<!-- /.chat -->
<div class="box-footer"> <div class="box-footer">
<div class="input-group"> <div class="input-group">
<input class="form-control" placeholder="Type message...">
<div class="input-group-btn">
<button type="button" class="btn btn-success"><i class="fa fa-plus"></i></button>
</div>
</div> </div>
</div> </div>
</div> </div>
<!-- /.box (chat box) --> <!-- /.box (chat box) -->
<br>
<!-- TO DO List --> <!-- TO DO List -->
<div class="box box-primary"> <div class="box box-primary">
<div class="box-header"> <div class="box-header">
......
...@@ -35,11 +35,13 @@ ...@@ -35,11 +35,13 @@
<tr> <tr>
<th>Nama Pelanggan</th> <th>Nama Pelanggan</th>
<th>Feedback</th> <th>Feedback</th>
<th>Tanggal Dikirim</th>
</tr> </tr>
@foreach($data as $a) @foreach($data as $a)
<tr> <tr>
<td>{{$a->nama}}</td> <td>{{$a->nama}}</td>
<td>{{$a->feedback}}</td> <td>{{$a->feedback}}</td>
<td>{{$a->created_at}}</td>
</tr> </tr>
@endforeach @endforeach
</table> </table>
......
...@@ -78,6 +78,14 @@ ...@@ -78,6 +78,14 @@
<input type="Number" class="form-control" value="{{$data->no_rekening}}" placeholder="noRekening" name=""/> <input type="Number" class="form-control" value="{{$data->no_rekening}}" placeholder="noRekening" name=""/>
</div> </div>
</div> </div>
<div class="form-group">
<label>Foto </label>
<div class="input-group">
<input type="file" value="Browse" name="foto" id="picture" >
</div>
</div>
<div class="form-group" align="right" style="color: black;"> <div class="form-group" align="right" style="color: black;">
<button type="submit" class="btn btn-primary ">Update</button> <button type="submit" class="btn btn-primary ">Update</button>
</div> </div>
......
...@@ -12,7 +12,7 @@ ...@@ -12,7 +12,7 @@
@if(Auth::user()->role =="DinasPariwisata") @if(Auth::user()->role =="DinasPariwisata")
<!-- Optionally, you can add icons to the links --> <!-- Optionally, you can add icons to the links -->
<li class="treeview "><a href="#"><i class='fa fa-list'></i> <span> List Request </span> </a> <li class="treeview "><a href="#"><i class='fa fa-list'></i> <span> Daftar Request </span> </a>
<ul class="treeview-menu" style="display: none;"> <ul class="treeview-menu" style="display: none;">
<li><a href="{{url('requestFasilitas')}}"><i class='fa fa-television'></i> <span>Acc Request Fasilitas</span></a></li> <li><a href="{{url('requestFasilitas')}}"><i class='fa fa-television'></i> <span>Acc Request Fasilitas</span></a></li>
<li><a href="{{url('requestHomestay')}}"><i class='fa fa-home'></i> <span>Acc Pengajuan Homestay</span></a></li> <li><a href="{{url('requestHomestay')}}"><i class='fa fa-home'></i> <span>Acc Pengajuan Homestay</span></a></li>
...@@ -32,7 +32,7 @@ ...@@ -32,7 +32,7 @@
<i class="fa fa-angle-left pull-right"></i> <i class="fa fa-angle-left pull-right"></i>
</span></a> </span></a>
<ul class="treeview-menu" style="display : none;"> <ul class="treeview-menu" style="display : none;">
<li><a href="{{url('reqFasilitas')}}"><i class='fa fa-external-link-square'></i> <span>Request Fasilitas</span></a></li> <li><a href="{{url('reqFasilitas')}}"><i class='fa fa-external-link-square'></i> <span>Daftar Permintaan Fasilitas</span></a></li>
<li><a href="{{url('listPengajuanFasilitas')}}"><i class='fa fa-list'></i> <span>Daftar Pengajuan Fasilitas</span></a></li> <li><a href="{{url('listPengajuanFasilitas')}}"><i class='fa fa-list'></i> <span>Daftar Pengajuan Fasilitas</span></a></li>
</ul> </ul>
</li> </li>
......
...@@ -78,6 +78,7 @@ Route::group(['middleware' => 'owner'], function () { ...@@ -78,6 +78,7 @@ Route::group(['middleware' => 'owner'], function () {
Route::get('listPengajuan','OwnerController@listPengajuan'); Route::get('listPengajuan','OwnerController@listPengajuan');
Route::get('listPengajuanFasilitas','OwnerController@listPengajuanFasilitas'); Route::get('listPengajuanFasilitas','OwnerController@listPengajuanFasilitas');
Route::get('listFeedback','OwnerController@feddback'); Route::get('listFeedback','OwnerController@feddback');
Route::get('home','OwnerController@index');
}); });
Route::get('detailhomestay/{id}','GuestController@detailhomestay'); Route::get('detailhomestay/{id}','GuestController@detailhomestay');
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment