Commit 19d4353b by Palti Sinaga

12345678

parent 9174037e
......@@ -64,6 +64,8 @@ class AdminController extends Controller
return view('adminlte::layouts.admin.listhomestay')->with('data',$data);
}
public function cariPesanan(Request $request){
$dataHomestay = Homestay::where('nama_homestay',$request['nama_homestay'])->get();
......@@ -104,10 +106,15 @@ class AdminController extends Controller
$penghasilan += $biaya;
}
dd($data,$data2,$penghasilan);
// dd($data,$data2,$penghasilan);
// dd('masuk',$request['bulan'],$request['nama_homestay'],$data);
return view('adminlte::layouts.admin.resultlistpesanan')->with('data',$data);
}
public function resultlistpesanan(){
dd('masuk',$request['bulan'],$request['nama_homestay'],$data);
return view('');
}
public function Allfeedback(){
......@@ -131,9 +138,9 @@ class AdminController extends Controller
$dataFeedback = DB::table('feedback')
->join('pemilikhomestay','feedback.id_pemilik_homestay','=','pemilikhomestay.id')
->join('pelanggan','feedback.id_pelanggan','=','pelanggan.id')
->select('pemilikhomestay.id','feedback.feedback','pelanggan.nama')
->select('pemilikhomestay.id','feedback.feedback','pelanggan.nama','feedback.created_at','feedback.id')
->where('pemilikhomestay.id','=',$id)
->paginate(4);
->paginate(10);
//dd($dataFeedback);
return view('adminlte::layouts.admin.feedback')->with('data',$dataFeedback);
......@@ -151,7 +158,10 @@ class AdminController extends Controller
public function owner($id){
$data = Owner::where('id_akun',$id)->get();
$data = Owner::where('id_akun',$id)
->join('users','pemilikhomestay.id_akun','=','users.id')
->select('users.username','pemilikhomestay.*')
->get();
// dd($data[0]);
return view('adminlte::layouts.admin.updateOwner')->with('data',$data[0]);
......@@ -182,7 +192,7 @@ class AdminController extends Controller
$dataUs = User::find($dataOw->id_akun);
$dataUs->username = $request['username'];
$dataUs->password = bcrypt($request['password']);
......
......@@ -10,12 +10,6 @@
print_r(getdate());
?>/h1>
<table class="table table-user-information">
<tr>
<th>Nama </th>
<td>: </td>
<td>{{$data->nama}}</td>
</tr>
</table>
test pesanan searc
</body>
</html>
......@@ -5,7 +5,7 @@
@endsection
@section('main-content')
<div class="box box-warning">
<div class="box box-primary">
<div class="box-header with-border">
<h3 class="box-title"> DAFTAR PEMILIK HOMESTAY </h3>
@if (count($errors) > 0)
......
......@@ -21,21 +21,30 @@
</div>
<div class="box-body">
@foreach($data as $a)
<div class="col-sm-12">
<div class="box box-primary">
<div class="box-header with-border">
<h3 class="box-title">{{$a->nama}}</h3>
</div><!-- /.box-header -->
<div class="box-body">
<p>{{$a->feedback}}</p>
</div><!-- /.box-body -->
</div><!-- /.box -->
</div>
<ul class="timeline">
@foreach($data as $a)
<li>
<i class="fa fa-comment bg-aqua"></i>
<div class="timeline-item">
<span class="time"><i class="fa fa-clock-o"></i> {{$a->created_at}}</span>
<h3 class="timeline-header" style="border-bottom: 0px;"><a href="#">{{$a->nama}}</a> </h3>
<div class="timeline-body">
{{$a->feedback}}
</div>
<!-- <div class="timeline-footer">
<a class="btn btn-primary btn-xs">Read more</a>
<a class="btn btn-danger btn-xs">Delete</a>
</div> -->
</div>
</li>
@endforeach
{!! $data->render() !!}
</ul>
{!! $data->render() !!}
</div>
</div>
......
......@@ -9,71 +9,91 @@
<!-- Small boxes (Stat box) -->
<div class="row">
<a href="/listowner" class="small-box-footer">
<div class="col-lg-3 col-xs-6">
<div class="small-box bg-aqua">
<div class="inner">
<h3>{{$count}}</h3><br><br>
<p>Data Pemilik Homestay</p>
<p>Data Pemilik Homestay <i class="fa fa-arrow-circle-right"></i></p>
</div>
<div class="icon">
<i class="fa fa-users"></i>
</div>
<a href="/listowner" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a>
</div>
</div>
</a>
<a href="/listhomestay" class="small-box-footer">
<div class="col-lg-3 col-xs-6">
<!-- small box -->
<div class="small-box bg-green">
<div class="inner">
<h3>{{$countH}}</h3><br><br>
<p>Data Homestay</p>
<p>Data Homestay <i class="fa fa-arrow-circle-right"></i></p>
</div>
<div class="icon">
<i class="fa fa-home"></i>
</div>
<a href="/listhomestay" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a>
</div>
</div>
</a>
<a href="/requestFasilitas" class="small-box-footer">
<div class="col-lg-3 col-xs-6">
<div class="small-box bg-yellow">
<div class="inner">
<h3>{{$countF}}</h3><br><br>
<p>Permintaan Fasilitas</p>
<p>Permintaan Fasilitas <i class="fa fa-arrow-circle-right"></i></p>
</div>
<div class="icon">
<i class="fa fa-cubes"></i>
</div>
<a href="/requestFasilitas" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a>
</div>
</div>
</a>
<a href="/requestHomestay" class="small-box-footer">
<div class="col-lg-3 col-xs-6">
<div class="small-box bg-green">
<div class="inner">
<h3>{{$countP}}</h3><br><br>
<p>Pengajuan Homestay </p>
<p>Pengajuan Homestay <i class="fa fa-arrow-circle-right"></i></p>
</div>
<div class="icon">
<i class="fa fa-list"></i>
</div>
<a href="/requestHomestay" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a>
</div>
</div>
</a>
<a href="/listPemesanan" class="small-box-footer">
<div class="col-lg-3 col-xs-6">
<div class="small-box bg-red">
<div class="inner">
<h3>{{$countPesan}}</h3><br><br>
<p>Data Pemesanan </p>
<p>Data Pemesanan <i class="fa fa-arrow-circle-right"></i></p>
</div>
<div class="icon">
<i class="fa fa-mail-reply"></i>
</div>
<a href="/listPemesanan" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a>
</div>
</div>
</a>
<a href="/Allfeedback" class="small-box-footer">
<div class="col-lg-3 col-xs-6">
<div class="small-box bg-blue">
<div class="inner">
<h3>{{$countPesan}}</h3><br><br>
<p>Feedback Pengunjung <i class="fa fa-arrow-circle-right"></i></p>
</div>
<div class="icon">
<i class="fa fa-comment"></i>
</div>
<!-- <a href="/Allfeedback" class="small-box-footer">Lihat <i class="fa fa-arrow-circle-right"></i></a> -->
</div>
</div>
</a>
</div>
......
@extends('adminlte::layouts.app')
@section('htmlheader_title')
{{ trans('adminlte_lang::message.home') }}
@endsection
@section('main-content')
<div class="box box-warning">
<div class="box-header with-border">
<h3 class="box-title"> DATA PEMESANAN </h3>
@if (count($errors) > 0)
<div class="alert alert-danger">
<strong>Whoops!</strong> {{ trans('adminlte_lang::message.someproblems') }}<br><br>
<ul>
@foreach ($errors->all() as $error)
<li>{{ $error }}</li>
@endforeach
</ul>
</div>
@endif
</div>
<div class="box-body">
<!-- <form action="{{url('caripesanan')}}">
<div class="form-group" align="right">
<input type="submit" class="btn btn-warning" value="Print">
</div>
</form> -->
<table class="table table-striped">
<tr>
<th>Nama Homestay</th>
<th>Nama Pemilik Homestay</th>
<th>Nama Pemesan</th>
<th>Tanggal Mulai</th>
<th>Tanggal Berakhir</th>
<th>Jumlah Kamar yang dipesan</th>
</tr>
@foreach($data as $a)
<tr>
<td>{{$a->nama_homestay}}</td>
<td>{{$a->owner}}</td>
<td>{{$a->nama_pemesan}}</td>
<td>{{$a->tanggal_mulai}}</td>
<td>{{$a->tanggal_berakhir}}</td>
<td>{{$a->jumlah_kamar}}</td>
</tr>
@endforeach
</table>
</div>
</div>
@endsection
......@@ -45,7 +45,7 @@
<div class="input-group-addon">
<i class="fa fa-bookmark"></i>
</div>
<input type="text" class="form-control" placeholder="username" name="username" value="{{$dataUS->username}}">
<input type="text" class="form-control" placeholder="username" name="username" value="{{$data->username}}">
</div>
</div>
......
......@@ -134,5 +134,5 @@ Route::group(['middleware' => 'dinaspariwisata'], function () {
Route::get('home','AdminController@Home');
Route::get('detailreqFasilitas/{id}','AdminController@detailreqFasilitas');
Route::get('listhomestay','AdminController@listhomestay');
Route::get('resultlistpesanan','AdminController@listhomestay');
});
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