Commit 0807fc36 by Rinto

commit new

parent 11b4bad8
......@@ -12,6 +12,7 @@ use App\Users;
use App\Supir;
use App\Pemesanan;
use App\Batal;
use App\Tolak;
use App\Konfirmasi;
use App\Jadwal;
use Validator;
......@@ -139,7 +140,7 @@ class AdminController extends Controller
$supir->save();
return redirect('k_klien/supir/index')->with('message','Data Supir Berhasil di Ubah');
return redirect('k_klien/supir')->with('message','Data Supir Berhasil di Ubah');
}
public function bus()
......@@ -148,6 +149,41 @@ class AdminController extends Controller
return view('adminlte::k_klien.bus.index', compact('bus'));
}
public function busupdate(Request $request, $id)
{
$this->validate($request, [
'id' => 'required',
'nama_bus' => 'required',
'jenis_bus' => 'required',
'plat_bus' => 'required',
'deskripsi' => 'required',
]);
$bus = Bus::findOrFail($id);
$bus->id = $request['id'];
$bus->nama_bus = $request['nama_bus'];
$bus->jenis_bus = $request['jenis_bus'];
$bus->plat_bus = $request['plat_bus'];
$bus->deskripsi = $request['deskripsi'];
if($request->file('image') == "")
{
$bus->image = $bus->image;
}
else
{
$file = $request->file('image');
$fileName = $file->getClientOriginalName();
$request->file('image')->move("image/", $fileName);
$bus->gambar = $fileName;
}
$bus->save();
return redirect('k_klien/bus')->with('message','Data Bus Berhasil di Ubah');
}
public function tambahbus()
{
$bus = Bus::all();
......@@ -191,31 +227,6 @@ class AdminController extends Controller
return view('adminlte::k_klien.bus.ubahbus', compact('bus'));
}
public function busupdate(Request $request, $id)
{
$this->validate($request, [
'id'=> 'required',
'nama_bus' => 'required',
'jenis_bus' => 'required',
'pat_bus' => 'required',
'deskripsi' => 'required',
'gambar' => 'required',
]);
$bus = Bus::findOrFail($id);
$bus->id = $request['id'];
$bus->nama_bus = $request['nama_bus'];
$bus->jenis_bus = $request['jenis_bus'];
$bus->pat_bus = $request['pat_bus'];
$bus->deskripsi = $request['deskripsi'];
$bus->gambar = $request['gambar'];
$bus->save();
return redirect('k_klien/bus')->with('message','Data Bus Berhasil di Ubah');
}
public function pemesanan()
{
$pemesanan = Pemesanan::all();
......@@ -256,6 +267,46 @@ class AdminController extends Controller
return redirect('k_klien/pemesanan')->with('message','Data Pemesanan Berhasil di Konfirmasi');
}
public function tolakpesanan($id)
{
$pemesanan = Pemesanan::find($id);
return view('adminlte::k_klien.pemesanan.tolakpesanan', compact('pemesanan'));
}
public function ditolak(Request $request, $id)
{
$this->validate($request, [
'tujuan' => 'required',
'jumlah' => 'required',
'alasan' => 'required',
'berangkat' => 'required',
'kembali' => 'required',
'plat_bus' => 'required',
'name' => 'required',
'status' => 'required',
'alasan_tolak' => 'required',
'saran' => 'required',
]);
$tolak = new Tolak();
$tolak->tujuan = $request['tujuan'];
$tolak->jumlah = $request['jumlah'];
$tolak->alasan = $request['alasan'];
$tolak->berangkat = $request['berangkat'];
$tolak->kembali = $request['kembali'];
$tolak->plat_bus = $request['plat_bus'];
$tolak->name = $request['name'];
$tolak->status = $request['status'];
$tolak->alasan_tolak = $request['alasan_tolak'];
$tolak->saran = $request['saran'];
$tolak->save();
$pemesanan = Pemesanan::find($id);
$pemesanan->delete();
return redirect('history')->with('message','Penolakan Berhasil Dilakukan');
}
public function history()
{
$riwayat = Konfirmasi::all();
......
......@@ -82,7 +82,7 @@ class KlienController extends Controller
return view('adminlte::klien.batalkan.index', compact('pemesanan'));
}
public function kirim_pembatalan(Request $request, $id)
public function ditolak(Request $request, $id)
{
$this->validate($request, [
'tujuan' => 'required',
......
......@@ -21,7 +21,19 @@ class ProfilController extends Controller
{
$user = DB::table('users')->where('id', Auth::user()->id)->get();
// dd($user[0]);
return view('adminlte::setting')->with('user', $user[0]);
return view('adminlte::k_klien.setting')->with('user', $user[0]);
}
public function index2()
{
$user = DB::table('users')->where('id', Auth::user()->id)->get();
// dd($user[0]);
return view('adminlte::k_supir.setting')->with('user', $user[0]);
}
public function index3()
{
$user = DB::table('users')->where('id', Auth::user()->id)->get();
// dd($user[0]);
return view('adminlte::klien.setting')->with('user', $user[0]);
}
/**
......@@ -104,6 +116,64 @@ class ProfilController extends Controller
return redirect('home');
}
public function change2(Request $request, $id)
{
$this->validate($request, [
'name' => 'required',
'email' => 'required',
'username' => 'required',
]);
$users = User::findOrFail($id);
$users->name = $request->name;
$users->email = $request->email;
$users->username = $request->username;
if($request->file('image') == "")
{
$users->image = $users->image;
}
else
{
$file = $request->file('image');
$fileName = $file->getClientOriginalName();
$request->file('image')->move("image/", $fileName);
$users->image = $fileName;
}
$users->save();
return redirect('home');
}
public function change3(Request $request, $id)
{
$this->validate($request, [
'name' => 'required',
'email' => 'required',
'username' => 'required',
]);
$users = User::findOrFail($id);
$users->name = $request->name;
$users->email = $request->email;
$users->username = $request->username;
if($request->file('image') == "")
{
$users->image = $users->image;
}
else
{
$file = $request->file('image');
$fileName = $file->getClientOriginalName();
$request->file('image')->move("image/", $fileName);
$users->image = $fileName;
}
$users->save();
return redirect('home');
}
/**
* Remove the specified resource from storage.
......
<?php
namespace App;
use Illuminate\Database\Eloquent\Model;
class Tolak extends Model
{
protected $table = 'tolak';
protected $fillable = ['id','tujuan','jumlah','alasan','berangkat','kembali','name','plat_bus','status','alasan_tolak','saran'];
//
}
\ No newline at end of file
......@@ -49,11 +49,12 @@
</div>
<!-- /.box-footer -->
<div class="box-footer">
<form action="{{ url('busupdate', $bus->id) }}" method="POST" enctype="multipart/form-data">
<form action="{{url('busupdate',$bus->id)}}" method="POST" role="form" enctype="multipart/form-data">
{{ csrf_field() }}
<div class="form-group has-feedback">
<input class="form-control" name="gambar" value="{{ $bus->gambar}}" readonly>
<label class="col-md-6 control-label">Upload a different photo...</label>
<input class="form-control" name="image" value="{{ $bus->gambar}}" type="file">
</div>
<div class="form-group has-feedback">
......
......@@ -129,6 +129,7 @@
<button type="submit" class="btn btn-primary">
Konfirmasi
</button>
<a href="{{url('k_klien/pemesanan/tolakpesanan',$pemesanan->id)}}" class="btn btn-danger"><i class="fa fa-close"></i> Tolak</a>
</div>
</div>
</form>
......
@extends('adminlte::layouts.app')
@section('htmlheader_title')
Tolak Pemesanan
@endsection
@section('contentheader_title')
<ol class="breadcrumb"><li><a href="/"><i class="fa fa-home"></i> Home</a></li>
<li class="active"><i class="fa fa-close"></i> Tolak Pemesanan</li>
</ol><!-- breadcrumbs -->
@endsection
@section('main-content')
<div class="container-fluid spark-screen">
<div class="container">
@if(session()->has('message'))
<div class="alert alert-info">
{{session()->get('message')}}
</div>
@endif
@if(!empty($success))
<div class="alert alert-success">
{{$success}}
</div>
@endif
<div class="col-md-8 col-md-offset-2">
<div class="panel-body">
<form class="form-horizontal" action="{{ url('ditolak', $pemesanan->id) }}" method="POST">
{!! csrf_field() !!}
<div class="form-group{{ $errors->has('name') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Nama Pemesan</label>
<div class="col-md-6">
<input type="text" class="form-control" name="name" value="{{ $pemesanan->name}}" readonly>
@if ($errors->has('name'))
<span class="help-block">
<strong>{{ $errors->first('name') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('tujuan') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Tujuan</label>
<div class="col-md-6">
<input type="text" class="form-control" name="tujuan" value="{{ $pemesanan->tujuan}}" readonly>
@if ($errors->has('tujuan'))
<span class="help-block">
<strong>{{ $errors->first('tujuan') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('jumlah') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Jumlah</label>
<div class="col-md-6">
<input type="text" class="form-control" name="jumlah" value="{{ $pemesanan->jumlah}}" readonly>
@if ($errors->has('jumlah'))
<span class="help-block">
<strong>{{ $errors->first('jumlah') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('alasan') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Keperluan Keberangkatan</label>
<div class="col-md-6">
<input type="text" class="form-control" name="alasan" value="{{ $pemesanan->alasan}}" readonly>
@if ($errors->has('alasan'))
<span class="help-block">
<strong>{{ $errors->first('alasan') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('berangkat') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Tanggal Berangkat</label>
<div class="col-md-6">
<input type="text" class="form-control" name="berangkat" value="{{ $pemesanan->berangkat}}" readonly>
@if ($errors->has('berangkat'))
<span class="help-block">
<strong>{{ $errors->first('berangkat') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('kembali') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Tanggal Kembali</label>
<div class="col-md-6">
<input type="text" class="form-control" name="kembali" value="{{ $pemesanan->kembali}}" readonly>
@if ($errors->has('kembali'))
<span class="help-block">
<strong>{{ $errors->first('kembali') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('plat_bus') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Plat Kendaraan</label>
<div class="col-md-6">
<input type="text" class="form-control" name="plat_bus" value="{{ $pemesanan->plat_bus}}" readonly>
@if ($errors->has('plat_bus'))
<span class="help-block">
<strong>{{ $errors->first('plat_bus') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('status') ? ' has-error' : '' }}">
<div class="col-md-6">
<input type="hidden" class="form-control" name="status" value="Dibatalkan">
@if ($errors->has('status'))
<span class="help-block">
<strong>{{ $errors->first('status') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('alasan_batal') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Alasan Penolakan</label>
<div class="col-md-6">
<textarea class="form-control" name="alasan_batal" value="{{ $pemesanan->alasan_batal}}" required></textarea>
@if ($errors->has('alasan_batal'))
<span class="help-block">
<strong>{{ $errors->first('alasan_batal') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('saran') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Saran Anda </label>
<div class="col-md-6">
<textarea class="form-control" name="saran" value="{{ $pemesanan->saran}}" required></textarea>
@if ($errors->has('saran'))
<span class="help-block">
<strong>{{ $errors->first('saran') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group">
<div class="col-md-6 col-md-offset-4">
<button type="submit" class="btn btn-primary">
Kirim Penolakan
</button>
</div>
</div>
</form>
</div>
</div>
</div>
</div>
@endsection
......@@ -13,6 +13,7 @@
@section('main-content')
<div class="container-fluid spark-screen">
<div class="container">
<div class="col-md-6">
......@@ -67,6 +68,9 @@
<label class="col-md-4 control-label">Deskripsi</label>
<textarea class="form-control" placeholder="Berikan deskripsi disini" rows="3" name="deskripsi" readonly="">{{ $bus->deskripsi}}</textarea>
</div>
<div class="form-group has-feedback">
<a href="{{url('bus/ubahbus',$bus->id)}}" class="btn btn-success"><i class="fa fa-edit"></i> Ubah Data</a>
</div>
</form><br>
</div>
<!-- /.box-footer -->
......@@ -75,5 +79,6 @@
</div>
</div>
</div>
@endsection
......@@ -6,8 +6,8 @@
@section('contentheader_title')
<ol class="breadcrumb"><li><a href="/"><i class="fa fa-home"></i> Home</a></li>
<li class="active"><i class="fa fa-bus"></i> Riwayat</li>
<li class="active"><i class="fa fa-bus"></i> Detail Riwayat</li>
<li class="active"><i class="fa fa-reorder"></i> Riwayat</li>
<li class="active"><i class="fa fa-send"></i> Detail Riwayat</li>
</ol><!-- breadcrumbs -->
@endsection
......
......@@ -46,7 +46,6 @@
<tr>
<td>{{$pemesan->name}}</td>
<td>{{$pemesan->tujuan}}</td>
<td>{{$pemesan->jumlah}}</td>
<td>{{$pemesan->berangkat}}</td>
<td>{{$pemesan->status}}</td>
<td colspan="2">
......
@extends('adminlte::layouts.app')
@section('htmlheader_title')
Setting
@endsection
@section('contentheader_title')
Page Setting
@endsection
@section('main-content')
<!--Form Edit-->
<div class="container">
<hr>
<div class="row">
<!-- edit form column -->
<form class="form-horizontal" role="form" method="POST" action="{{ url('change2', $user->id) }}" enctype="multipart/form-data">
{!! csrf_field() !!}
<div class="col-md-9">
<!-- left column -->
<div class="col-md-3">
<div class="text-center">
<div class="user-header">
<img src="{{ asset('image/'.$user->image) }}" style="height: 100px; width: 100px;" class="img-circle" alt="User Image" />
<p>
<small>Upload a different photo...</small>
</p>
</div>
<input name="image" type="file" class="form-control">
</div>
</div>
</div>
<div class="col-md-9 personal-info">
<h3>Personal info</h3>
<div class="form-group{{ $errors->has('name') ? ' has-error' : '' }}">
<label class="col-lg-3 control-label">Nama</label>
<div class="col-lg-8">
<input name="name" class="form-control" type="text" value="{{ $user->name }}">
@if ($errors->has('name'))
<span class="help-block">
<strong>{{ $errors->first('name') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('email') ? ' has-error' : '' }}">
<label class="col-lg-3 control-label">Email</label>
<div class="col-lg-8">
<input name="email" class="form-control" type="text" value="{{ $user->email }}">
@if ($errors->has('email'))
<span class="help-block">
<strong>{{ $errors->first('email') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('username') ? ' has-error' : '' }}">
<label class="col-lg-3 control-label">Username</label>
<div class="col-lg-8">
<input name="username" class="form-control" type="text" value="{{ $user->username }}">
@if ($errors->has('username'))
<span class="help-block">
<strong>{{ $errors->first('username') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group">
<label class="col-lg-3 control-label">Status</label>
<div class="col-lg-8">
<input name="status" class="form-control" type="text" value="{{ $user->status }}" disabled>
</div>
</div>
</div>
<div class="col-md-9">
<div class="form-group">
<label class="col-md-3 control-label"></label>
<div class="col-md-8">
<input type="submit" class="btn btn-primary" value="Save Changes">
<span></span>
</div>
</div>
</div>
</form>
</div>
</div>
<hr>
@endsection
\ No newline at end of file
......@@ -6,8 +6,8 @@
@section('contentheader_title')
<ol class="breadcrumb"><li><a href="/"><i class="fa fa-home"></i> Home</a></li>
<li class="active"><i class="fa fa-bus"></i> Supir</li>
<li class="active"><i class="fa fa-bus"></i> Detail Supir</li>
<li class="active"><i class="fa fa-user"></i> Supir</li>
<li class="active"><i class="fa fa-eye"></i> Detail Supir</li>
</ol><!-- breadcrumbs -->
@endsection
......@@ -15,26 +15,60 @@
<div class="container-fluid spark-screen">
<div class="container">
<div class="col-md-8 col-md-offset-2">
<div class="panel-body">
<div class="col-md-6">
<form class="form-horizontal" action="{{ url('') }}" method="POST">
{!! csrf_field() !!}
<div class="form-group{{ $errors->has('nama_supir') ? ' has-error' : '' }}">
<label for="title" class="col-md-4 control-label">Nama Supir</label>
<div class="col-md-6">
<input type="text" class="form-control" name="nama_supir" value="{{ $supir->nama_supir}}" readonly>
@if ($errors->has('nama_supir'))
<span class="help-block">
<strong>{{ $errors->first('nama_supir') }}</strong>
</span>
@endif
</div>
<!-- Box Comment -->
<div class="box box-widget">
<div class="box-header with-border">
<div class="user-block">
<img src="{{ asset('image/'.$supir->image) }}" style="display: block;margin-left: auto;margin-right: auto;">
<span class="username">{{ $supir->nama_supir}}</span>
<span class="username"></span>
</div>
<!-- /.user-block -->
<div class="box-tools">
<button type="button" class="btn btn-box-tool" data-widget="collapse"><i class="fa fa-minus"></i></button>
</div>
</form>
<!-- /.box-tools -->
</div>
<!-- /.box-header -->
<div class="box-body">
<img style="display: block;margin-left: auto;margin-right: auto;" src="{{ asset('image/'.$supir->image) }}">
</div>
<!-- /.box-footer -->
<div class="box-footer">
<form action="" method="post">
<div class="form-group has-feedback">
<label class="col-md-4 control-label">ID Supir</label>
<input class="form-control" name="id" value="{{ $supir->id}}" readonly="" type="text">
</div>
<div class="form-group has-feedback">
<label class="col-md-4 control-label">Nama Supir</label>
<input class="form-control" name="nama_supir" value="{{ $supir->nama_supir}}" readonly="" type="text">
</div>
<div class="form-group has-feedback">
<label class="col-md-4 control-label">Tempat/Tgl Lahir</label>
<input class="form-control" name="ttl" value="{{ $supir->ttl}}" readonly="" type="text">
</div>
<div class="form-group has-feedback">
<label class="col-md-4 control-label">Alamat</label>
<input class="form-control" name="alamat" value="{{ $supir->alamat}}" readonly="" type="text">
</div>
<div class="form-group has-feedback">
<label class="col-md-4 control-label">Jenis Kelamin</label>
<input class="form-control" name="jk" value="{{ $supir->jk}}" readonly="" type="text">
</div>
<div class="form-group has-feedback">
<label class="col-md-4 control-label">Agama</label>
<input class="form-control" name="agama" value="{{ $supir->agama}}" readonly="" type="text">
</div>
</form><br>
</div>
<!-- /.box-footer -->
</div>
<!-- /.box -->
</div>
</div>
</div>
@endsection
@endsection
\ No newline at end of file
......@@ -6,7 +6,7 @@
@section('contentheader_title')
<ol class="breadcrumb"><li><a href="/"><i class="fa fa-home"></i> Home</a></li>
<li class="active"><i class="fa fa-bus"></i> Supir</li>
<li class="active"><i class="fa fa-user"></i> Supir</li>
</ol><!-- breadcrumbs -->
@endsection
......@@ -16,9 +16,9 @@
<table class="table table-striped">
<thead>
<tr>
<th>Nama Supir</th>
<th>ID Supir</th>
<th>Aksi</th>
<th>Nama Supir <i class="fa fa-book"></i> </th>
<th>ID Supir <i class="fa fa-child"></i> </th>
<th>Aksi <i class="fa fa-hand-scissors-o"></i></th>
</tr>
</thead>
......@@ -28,7 +28,7 @@
<td>{{$supi->nama_supir}}</td>
<td>{{$supi->id}}</td>
<td colspan="2">
<a href="{{url('/k_supir/supir/detail',$supi->id)}}" class="btn btn-info">Detail</a>
<a href="{{url('/k_supir/supir/detail',$supi->id)}}" class="btn btn-info"><i class="fa fa-eye"></i> Detail</a>
</td>
</tr>
</form>
......
@extends('adminlte::layouts.app')
@section('htmlheader_title')
Setting
@endsection
@section('contentheader_title')
Page Setting
@endsection
@section('main-content')
<!--Form Edit-->
<div class="container">
<hr>
<div class="row">
<!-- edit form column -->
<form class="form-horizontal" role="form" method="POST" action="{{ url('change3', $user->id) }}" enctype="multipart/form-data">
{!! csrf_field() !!}
<div class="col-md-9">
<!-- left column -->
<div class="col-md-3">
<div class="text-center">
<div class="user-header">
<img src="{{ asset('image/'.$user->image) }}" style="height: 100px; width: 100px;" class="img-circle" alt="User Image" />
<p>
<small>Upload a different photo...</small>
</p>
</div>
<input name="image" type="file" class="form-control">
</div>
</div>
</div>
<div class="col-md-9 personal-info">
<h3>Personal info</h3>
<div class="form-group{{ $errors->has('name') ? ' has-error' : '' }}">
<label class="col-lg-3 control-label">Nama</label>
<div class="col-lg-8">
<input name="name" class="form-control" type="text" value="{{ $user->name }}">
@if ($errors->has('name'))
<span class="help-block">
<strong>{{ $errors->first('name') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('email') ? ' has-error' : '' }}">
<label class="col-lg-3 control-label">Email</label>
<div class="col-lg-8">
<input name="email" class="form-control" type="text" value="{{ $user->email }}">
@if ($errors->has('email'))
<span class="help-block">
<strong>{{ $errors->first('email') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group{{ $errors->has('username') ? ' has-error' : '' }}">
<label class="col-lg-3 control-label">Username</label>
<div class="col-lg-8">
<input name="username" class="form-control" type="text" value="{{ $user->username }}">
@if ($errors->has('username'))
<span class="help-block">
<strong>{{ $errors->first('username') }}</strong>
</span>
@endif
</div>
</div>
<div class="form-group">
<label class="col-lg-3 control-label">Status</label>
<div class="col-lg-8">
<input name="status" class="form-control" type="text" value="{{ $user->status }}" disabled>
</div>
</div>
</div>
<div class="col-md-9">
<div class="form-group">
<label class="col-md-3 control-label"></label>
<div class="col-md-8">
<input type="submit" class="btn btn-primary" value="Save Changes">
<span></span>
</div>
</div>
</div>
</form>
</div>
</div>
<hr>
@endsection
\ No newline at end of file
......@@ -34,15 +34,26 @@
</a>
<ul class="dropdown-menu">
<!-- The user image in the menu -->
<div class="user-header">
<img src="{{ asset('image/'.$user->image) }}" class="profile-user-img img-responsive img-circle" alt="User Image"/>
</div>
<div class="user-header">
<img src="{{ asset('image/'.$user->image) }}" class="profile-user-img img-responsive img-circle" alt="User Image"/>
</div>
<!-- Menu Footer-->
<li class="user-footer">
<div class="pull-left">
<a href="{{ url('/setting') }}" class="btn btn-default btn-flat">{{ trans('adminlte_lang::message.profile') }}</a>
</div>
@if(Auth::user()->status=="k_klien")
<div class="pull-left">
<a href="{{ url('/setting') }}" class="btn btn-default btn-flat">{{ trans('adminlte_lang::message.profile') }}</a>
</div>
@elseif(Auth::user()->status=="k_supir")
<div class="pull-left">
<a href="{{ url('/setting2') }}" class="btn btn-default btn-flat">{{ trans('adminlte_lang::message.profile') }}</a>
</div>
@elseif(Auth::user()->status=="klien")
<div class="pull-left">
<a href="{{ url('/setting3') }}" class="btn btn-default btn-flat">{{ trans('adminlte_lang::message.profile') }}</a>
</div>
@endif
<div class="pull-right">
<a href="{{ url('/logout') }}" class="btn btn-default btn-flat"
onclick="event.preventDefault();
......
......@@ -7,6 +7,7 @@ Use App\Pemesanan;
Use App\Batal;
use App\Konfirmasi;
use App\Jadwal;
use App\Tolak;
/*
|--------------------------------------------------------------------------
| Web Routes
......@@ -63,6 +64,8 @@ Route::group(['middleware' => ['web','auth','k_klien']], function () {
Route::get('user/delete/{id}', 'AdminController@destroyuser');
Route::get('/k_klien/pemesanan','AdminController@pemesanan');
Route::get('/k_klien/pemesanan/tolakpesanan/{id}','AdminController@tolakpesanan');
Route::post('/ditolak/{id}','AdminController@ditolak');
Route::get('/k_klien/pemesanan/detailpemesanan/{id}','AdminController@detailpemesanan');
Route::post('/update/{id}','AdminController@update');
......@@ -72,8 +75,8 @@ Route::group(['middleware' => ['web','auth','k_klien']], function () {
});
Route::group(['middleware' => ['web','auth','k_supir']], function () {
Route::get('/setting', 'ProfilController@index');
Route::post('/change/{id}', 'ProfilController@change');
Route::get('/setting2', 'ProfilController@index2');
Route::post('/change2/{id}', 'ProfilController@change2');
Route::get('/k_supir/dashboard','KsupirController@dashboard');
Route::get('/k_supir/supir','KsupirController@supirs');
......@@ -103,8 +106,8 @@ Route::group(['middleware' => ['web','auth','k_supir']], function () {
Route::group(['middleware' => ['web','auth','klien']], function () {
Route::get('/setting', 'ProfilController@index');
Route::post('/change/{id}', 'ProfilController@change');
Route::get('/setting3', 'ProfilController@index3');
Route::post('/change3/{id}', 'ProfilController@change3');
Route::get('/bus','KlienController@bus');
Route::get('/bus/detail/{id}','KlienController@detailbus');
......
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