Commit b09e06dc by Juliper

no message

parent 6a3b18ae
...@@ -215,13 +215,19 @@ class AdminController extends Controller ...@@ -215,13 +215,19 @@ class AdminController extends Controller
$dataOw->no_rekening; $dataOw->no_rekening;
//dd('aman',$dataOw->id_akun); //dd('aman',$request['username']);
$dataUs = User::find($dataOw->id_akun); $dataUs = User::find($dataOw->id_akun);
if($request['password'] == null || $request['password'] == ' '){
$dataUs->username = $request['username']; $dataUs->password = $dataUs->password;
}else{
$dataUs->password = bcrypt($request['password']); $dataUs->password = bcrypt($request['password']);
}
//dd($dataUs); //dd($dataUs);
......
...@@ -17,9 +17,6 @@ use Illuminate\Contracts\Auth\Guard; ...@@ -17,9 +17,6 @@ use Illuminate\Contracts\Auth\Guard;
use DateTime; use DateTime;
use PhpParser\Node\Stmt\Const_; use PhpParser\Node\Stmt\Const_;
use Psy\Command\ListCommand\ConstantEnumerator; use Psy\Command\ListCommand\ConstantEnumerator;
use Illuminate\Notifications\Messages\NexmoMessage;
use SimpleSoftwareIO\SMS\Drivers\NexmoSMS;
use Nexmo\Laravel\Facade\Nexmo;
use PDF; use PDF;
......
...@@ -44,6 +44,13 @@ class GuestController extends Controller ...@@ -44,6 +44,13 @@ class GuestController extends Controller
->where('users.id','=',Auth::user()->id) ->where('users.id','=',Auth::user()->id)
->get(); ->get();
$dataPemilik = DB::table('homestay')
->join('pemilikhomestay','homestay.id_pemilik','=','pemilikhomestay.id')
->where('homestay.id','=',$request['id_homestay'])
->get();
//dd($dataPemilik[0]);
$trans = new Transaksi(); $trans = new Transaksi();
$trans->id_pelanggan = $dataPelanggan[0]->id ; $trans->id_pelanggan = $dataPelanggan[0]->id ;
...@@ -96,6 +103,16 @@ class GuestController extends Controller ...@@ -96,6 +103,16 @@ class GuestController extends Controller
$lb->save(); $lb->save();
$text = "Ada Pesanan Kamar dari Sdr/i : ";
$pesan = $text . ' ' .$dataPelanggan[0]->nama;
$newPesan = $pesan . ' '. "Silahkan Cek Sistem Informasi";
Nexmo::message()->send([
'to' => $dataPemilik[0]->no_telepon,
'from' => 'ASDASD',
'text' => $newPesan
]);
return redirect('customerHistory'); return redirect('customerHistory');
//dd($request); //dd($request);
......
...@@ -91,15 +91,14 @@ ...@@ -91,15 +91,14 @@
</div> </div>
<div class="form-group">
<!-- <div class="form-group">
<label>Password</label> <label>Password</label>
<div class="input-group"> <div class="input-group">
<div class="input-group-addon"> <div class="input-group-addon">
<input type="password" name="password" class="form-control" placeholder="Password"> <input type="password" name="password" class="form-control" placeholder="Password">
</div> </div>
</div> </div>
</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>
......
...@@ -13,13 +13,12 @@ ...@@ -13,13 +13,12 @@
<div class="box-body"> <div class="box-body">
<form action="{{url('report')}}"> <form action="{{url('report')}}">
<label>Bulan</label> <label>Bulan</label>
<input type="number" min="1" max="12" name="bulan" required > <input type="number" min="1" onchange="updateVal(this)" max="12" name="bulan" required >
<input type="submit" value="Cari" class="btn-btn info"> <input type="submit" value="Cari" class="btn-btn info">
</form> </form>
<form action="{{url('printReportOwner')}}" enctype="multipart/form-data" style="float:right;"> <form action="{{url('printReportOwner')}}" enctype="multipart/form-data" style="float:right;">
<div class="form-group" align="right"> <div class="form-group" align="right">
<label>Bulan</label> <input type="number" hidden id="print" min="1" max="12" name="bulan" display="none" required >
<input type="number" min="1" max="12" name="bulan" display="none" required >
<input type="submit" class="btn btn-warning" value="Print"> <input type="submit" class="btn btn-warning" value="Print">
</div> </div>
</form> </form>
...@@ -67,4 +66,13 @@ ...@@ -67,4 +66,13 @@
@endif @endif
</div> </div>
</div> </div>
<script>
function updateVal(object) {
var field = document.getElementById('print');
field.value = parseInt(object.value);
}
</script>
@endsection @endsection
...@@ -15,7 +15,6 @@ ...@@ -15,7 +15,6 @@
<li class="treeview "><a href="#"><i class='fa fa-list'></i> <span> Daftar 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>
</ul> </ul>
</li> </li>
<li class="treeview"><a href="#"><i class='fa fa-users'></i> <span> Pemilik Homestay </span></a> <li class="treeview"><a href="#"><i class='fa fa-users'></i> <span> Pemilik Homestay </span></a>
......
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