parent
d3620f71b5
commit
34083146d1
|
@ -16,7 +16,7 @@ class History extends Controller
|
||||||
|
|
||||||
public function getDataHistory()
|
public function getDataHistory()
|
||||||
{
|
{
|
||||||
$data = Pesanan::with(['detailPesanan', 'user'])->get();
|
$data = Pesanan::with(['detailPesanan', 'user'])->orderBy('created_at', 'desc')->get();
|
||||||
$nomor = 1;
|
$nomor = 1;
|
||||||
|
|
||||||
return $datatables = datatables()
|
return $datatables = datatables()
|
||||||
|
|
|
@ -56,6 +56,7 @@ class Transaksi extends Controller
|
||||||
$pesananDatas = [
|
$pesananDatas = [
|
||||||
'kode_pesanan' => $request->orderCode,
|
'kode_pesanan' => $request->orderCode,
|
||||||
'nama_pemesan' => $request->namaPemesan,
|
'nama_pemesan' => $request->namaPemesan,
|
||||||
|
'nomor_pemesan' => $request->nomorPemesan,
|
||||||
'nomor_meja' => $request->nomorMeja,
|
'nomor_meja' => $request->nomorMeja,
|
||||||
'status_pesanan' => '1',
|
'status_pesanan' => '1',
|
||||||
'tanggal_pesanan' => date('Y-m-d H:i:s'),
|
'tanggal_pesanan' => date('Y-m-d H:i:s'),
|
||||||
|
|
|
@ -16,6 +16,7 @@ class Pesanan extends Model
|
||||||
protected $fillable = [
|
protected $fillable = [
|
||||||
'kode_pesanan',
|
'kode_pesanan',
|
||||||
'nama_pemesan',
|
'nama_pemesan',
|
||||||
|
'nomor_pemesan',
|
||||||
'status_pesanan',
|
'status_pesanan',
|
||||||
'tanggal_pesanan',
|
'tanggal_pesanan',
|
||||||
'nomor_meja',
|
'nomor_meja',
|
||||||
|
|
|
@ -28,54 +28,29 @@
|
||||||
<ul class="nav nav-tabs" id="custom-tabs-four-tab" role="tablist">
|
<ul class="nav nav-tabs" id="custom-tabs-four-tab" role="tablist">
|
||||||
@foreach ($KelompokKategori as $key => $item)
|
@foreach ($KelompokKategori as $key => $item)
|
||||||
<li class="nav-item">
|
<li class="nav-item">
|
||||||
<a class="nav-link @if ($key == 0) active @endif"
|
<a class="nav-link @if ($key == 0) active @endif" id="custom-tabs-four-{{ $item->kode_kelompok_kategori }}-tab" data-toggle="pill" href="#custom-tabs-four-{{ $item->kode_kelompok_kategori }}" role="tab" aria-controls="custom-tabs-four-{{ $item->kode_kelompok_kategori }}" aria-selected="true">{{ $item->nama_kelompok_kategori }}</a>
|
||||||
id="custom-tabs-four-{{ $item->kode_kelompok_kategori }}-tab" data-toggle="pill"
|
|
||||||
href="#custom-tabs-four-{{ $item->kode_kelompok_kategori }}" role="tab"
|
|
||||||
aria-controls="custom-tabs-four-{{ $item->kode_kelompok_kategori }}"
|
|
||||||
aria-selected="true">{{ $item->nama_kelompok_kategori }}</a>
|
|
||||||
</li>
|
</li>
|
||||||
@endforeach
|
@endforeach
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body" id="batasitinggi"
|
<div class="card-body" id="batasitinggi" style="height:720px;overflow-y:scroll;margin-bottom: 5px;padding-top: 2px;padding-bottom: 2px">
|
||||||
style="height:720px;overflow-y:scroll;margin-bottom: 5px;padding-top: 2px;padding-bottom: 2px">
|
|
||||||
<div class="tab-content" id="custom-tabs-four-tabContent">
|
<div class="tab-content" id="custom-tabs-four-tabContent">
|
||||||
@foreach ($KelompokKategori as $key => $item)
|
@foreach ($KelompokKategori as $key => $item)
|
||||||
<div class="tab-pane fade show @if ($key == 0) active @endif"
|
<div class="tab-pane fade show @if ($key == 0) active @endif" id="custom-tabs-four-{{ $item->kode_kelompok_kategori }}" role="tabpanel" aria-labelledby="custom-tabs-four-{{ $item->kode_kelompok_kategori }}-tab">
|
||||||
id="custom-tabs-four-{{ $item->kode_kelompok_kategori }}" role="tabpanel"
|
|
||||||
aria-labelledby="custom-tabs-four-{{ $item->kode_kelompok_kategori }}-tab">
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@if ($item->kode_kelompok_kategori == 'PAK-SKOM')
|
@if ($item->kode_kelompok_kategori == 'PAK-SKOM')
|
||||||
<div class="col-lg-12 col-md-6 col-sm-6" style="padding: 0px">
|
<div class="col-lg-12 col-md-6 col-sm-6" style="padding: 0px">
|
||||||
<div class="row" style="padding: 0px">
|
<div class="row" style="padding: 0px">
|
||||||
<div class="col-xl-3 col-lg-4 col-md-4 col-sm-3"
|
<div class="col-xl-3 col-lg-4 col-md-4 col-sm-3" style="margin-left: 0px;padding-left: 0px;">
|
||||||
style="margin-left: 0px;padding-left: 0px;">
|
<div class="nav flex-column nav-tabs h-100" id="vert-tabs-tab" role="tablist" aria-orientation="vertical">
|
||||||
<div class="nav flex-column nav-tabs h-100" id="vert-tabs-tab"
|
|
||||||
role="tablist" aria-orientation="vertical">
|
|
||||||
|
|
||||||
<a class="nav-link vert-nav-content active"
|
<a class="nav-link vert-nav-content active" id="vert-tabs-nasi-tab" data-toggle="pill" href="#vert-tabs-nasi" role="tab" aria-controls="vert-tabs-nasi" aria-selected="true">Nasi</a>
|
||||||
id="vert-tabs-nasi-tab" data-toggle="pill"
|
<a class="nav-link vert-nav-content" id="vert-tabs-telur-tab" data-toggle="pill" href="#vert-tabs-telur" role="tab" aria-controls="vert-tabs-telur" aria-selected="false">Telur</a>
|
||||||
href="#vert-tabs-nasi" role="tab"
|
<a class="nav-link vert-nav-content" id="vert-tabs-sambel-tab" data-toggle="pill" href="#vert-tabs-sambel" role="tab" aria-controls="vert-tabs-sambel" aria-selected="false">Sambel</a>
|
||||||
aria-controls="vert-tabs-nasi" aria-selected="true">Nasi</a>
|
<a class="nav-link vert-nav-content" id="vert-tabs-topping-tab" data-toggle="pill" href="#vert-tabs-topping" role="tab" aria-controls="vert-tabs-topping" aria-selected="false">Topping</a>
|
||||||
<a class="nav-link vert-nav-content" id="vert-tabs-telur-tab"
|
<a class="nav-link vert-nav-content" id="vert-tabs-free-tab" data-toggle="pill" href="#vert-tabs-free" role="tab" aria-controls="vert-tabs-free" aria-selected="false">Free</a>
|
||||||
data-toggle="pill" href="#vert-tabs-telur" role="tab"
|
|
||||||
aria-controls="vert-tabs-telur"
|
|
||||||
aria-selected="false">Telur</a>
|
|
||||||
<a class="nav-link vert-nav-content" id="vert-tabs-sambel-tab"
|
|
||||||
data-toggle="pill" href="#vert-tabs-sambel" role="tab"
|
|
||||||
aria-controls="vert-tabs-sambel"
|
|
||||||
aria-selected="false">Sambel</a>
|
|
||||||
<a class="nav-link vert-nav-content" id="vert-tabs-topping-tab"
|
|
||||||
data-toggle="pill" href="#vert-tabs-topping" role="tab"
|
|
||||||
aria-controls="vert-tabs-topping"
|
|
||||||
aria-selected="false">Topping</a>
|
|
||||||
<a class="nav-link vert-nav-content" id="vert-tabs-free-tab"
|
|
||||||
data-toggle="pill" href="#vert-tabs-free" role="tab"
|
|
||||||
aria-controls="vert-tabs-free"
|
|
||||||
aria-selected="false">Free</a>
|
|
||||||
|
|
||||||
<div class="card card-warning card-outline"
|
<div class="card card-warning card-outline" style="margin-top: auto;margin-right: 5px;height: auto;">
|
||||||
style="margin-top: auto;margin-right: 5px;height: auto;">
|
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<h6 class="text-sm m-0" id="nama-paket">
|
<h6 class="text-sm m-0" id="nama-paket">
|
||||||
Paket Menu Terpilih
|
Paket Menu Terpilih
|
||||||
|
@ -88,8 +63,7 @@
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
<a class="btn btn-warning disabled"
|
<a class="btn btn-warning disabled" id="select-ordered-menus" onclick="cariPaket()">Pilih
|
||||||
id="select-ordered-menus" onclick="cariPaket()">Pilih
|
|
||||||
Paket Menu
|
Paket Menu
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -98,28 +72,21 @@
|
||||||
<div class="col-xl-9 col-lg-8 col-md-8 col-sm-9" style="padding: 0px;">
|
<div class="col-xl-9 col-lg-8 col-md-8 col-sm-9" style="padding: 0px;">
|
||||||
<div class="card-body" style="height:700px;overflow-y:scroll;">
|
<div class="card-body" style="height:700px;overflow-y:scroll;">
|
||||||
<div class="tab-content" id="vert-tabs-tabContent">
|
<div class="tab-content" id="vert-tabs-tabContent">
|
||||||
<div class="tab-pane vert-tab-content fade text-left show active"
|
<div class="tab-pane vert-tab-content fade text-left show active" id="vert-tabs-nasi" role="tabpanel" aria-labelledby="vert-tabs-nasi-tab">
|
||||||
id="vert-tabs-nasi" role="tabpanel"
|
|
||||||
aria-labelledby="vert-tabs-nasi-tab">
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
||||||
@if ($kelompokKategoriPivot->produk->urutan == 1)
|
@if ($kelompokKategoriPivot->produk->urutan == 1)
|
||||||
<div
|
<div class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
||||||
class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} );changeTab('vert-tabs-telur')" class="card card-warning card-outline btn">
|
||||||
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} );changeTab('vert-tabs-telur')"
|
|
||||||
class="card card-warning card-outline btn">
|
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<h6 class="m-0 text-xs">
|
<h6 class="m-0 text-xs">
|
||||||
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
||||||
</h6>
|
</h6>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<img style="width: 100%;height: 100%;object-fit: cover;"
|
<img style="width: 100%;height: 100%;object-fit: cover;" src="{{ $kelompokKategoriPivot->produk->gambar_produk }}" alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
||||||
src="{{ $kelompokKategoriPivot->produk->gambar_produk }}"
|
|
||||||
alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
|
||||||
</div>
|
</div>
|
||||||
<a class="btn btn-warning"
|
<a class="btn btn-warning" id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">
|
||||||
id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">
|
|
||||||
Pilih Paket
|
Pilih Paket
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -128,28 +95,21 @@
|
||||||
@endforeach
|
@endforeach
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="tab-pane vert-tab-content"
|
<div class="tab-pane vert-tab-content" id="vert-tabs-telur" role="tabpanel" aria-labelledby="vert-tabs-telur-tab">
|
||||||
id="vert-tabs-telur" role="tabpanel"
|
|
||||||
aria-labelledby="vert-tabs-telur-tab">
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
||||||
@if ($kelompokKategoriPivot->produk->urutan == 2)
|
@if ($kelompokKategoriPivot->produk->urutan == 2)
|
||||||
<div
|
<div class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
||||||
class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} );changeTab('vert-tabs-sambel')" class="card card-warning card-outline btn">
|
||||||
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} );changeTab('vert-tabs-sambel')"
|
|
||||||
class="card card-warning card-outline btn">
|
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<h6 class="m-0 text-xs">
|
<h6 class="m-0 text-xs">
|
||||||
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
||||||
</h6>
|
</h6>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<img style="width: 100%;height: 100%;object-fit: cover;"
|
<img style="width: 100%;height: 100%;object-fit: cover;" src="{{ $kelompokKategoriPivot->produk->gambar_produk }}" alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
||||||
src="{{ $kelompokKategoriPivot->produk->gambar_produk }}"
|
|
||||||
alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
|
||||||
</div>
|
</div>
|
||||||
<a class="btn btn-warning"
|
<a class="btn btn-warning" id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">
|
||||||
id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">
|
|
||||||
Pilih Paket
|
Pilih Paket
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -158,28 +118,21 @@
|
||||||
@endforeach
|
@endforeach
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="tab-pane vert-tab-content"
|
<div class="tab-pane vert-tab-content" id="vert-tabs-sambel" role="tabpanel" aria-labelledby="vert-tabs-sambel-tab">
|
||||||
id="vert-tabs-sambel" role="tabpanel"
|
|
||||||
aria-labelledby="vert-tabs-sambel-tab">
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
||||||
@if ($kelompokKategoriPivot->produk->urutan == 3)
|
@if ($kelompokKategoriPivot->produk->urutan == 3)
|
||||||
<div
|
<div class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
||||||
class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} );changeTab('vert-tabs-topping')" class="card card-warning card-outline btn">
|
||||||
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} );changeTab('vert-tabs-topping')"
|
|
||||||
class="card card-warning card-outline btn">
|
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<h6 class="m-0 text-xs">
|
<h6 class="m-0 text-xs">
|
||||||
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
||||||
</h6>
|
</h6>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<img style="width: 100%;height: 100%;object-fit: cover;"
|
<img style="width: 100%;height: 100%;object-fit: cover;" src="{{ $kelompokKategoriPivot->produk->gambar_produk }}" alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
||||||
src="{{ $kelompokKategoriPivot->produk->gambar_produk }}"
|
|
||||||
alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
|
||||||
</div>
|
</div>
|
||||||
<a class="btn btn-warning"
|
<a class="btn btn-warning" id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">Pilih
|
||||||
id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">Pilih
|
|
||||||
Paket
|
Paket
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -188,28 +141,21 @@
|
||||||
@endforeach
|
@endforeach
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="tab-pane vert-tab-content"
|
<div class="tab-pane vert-tab-content" id="vert-tabs-topping" role="tabpanel" aria-labelledby="vert-tabs-topping-tab">
|
||||||
id="vert-tabs-topping" role="tabpanel"
|
|
||||||
aria-labelledby="vert-tabs-topping-tab">
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
||||||
@if ($kelompokKategoriPivot->produk->urutan == 4)
|
@if ($kelompokKategoriPivot->produk->urutan == 4)
|
||||||
<div
|
<div class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
||||||
class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} );changeTab('vert-tabs-free')" class="card card-warning card-outline btn">
|
||||||
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} );changeTab('vert-tabs-free')"
|
|
||||||
class="card card-warning card-outline btn">
|
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<h6 class="m-0 text-xs">
|
<h6 class="m-0 text-xs">
|
||||||
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
||||||
</h6>
|
</h6>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<img style="width: 100%;height: 100%;object-fit: cover;"
|
<img style="width: 100%;height: 100%;object-fit: cover;" src="{{ $kelompokKategoriPivot->produk->gambar_produk }}" alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
||||||
src="{{ $kelompokKategoriPivot->produk->gambar_produk }}"
|
|
||||||
alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
|
||||||
</div>
|
</div>
|
||||||
<a class="btn btn-warning"
|
<a class="btn btn-warning" id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">Pilih
|
||||||
id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">Pilih
|
|
||||||
Paket
|
Paket
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -218,27 +164,21 @@
|
||||||
@endforeach
|
@endforeach
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="tab-pane vert-tab-content" id="vert-tabs-free"
|
<div class="tab-pane vert-tab-content" id="vert-tabs-free" role="tabpanel" aria-labelledby="vert-tabs-free-tab">
|
||||||
role="tabpanel" aria-labelledby="vert-tabs-free-tab">
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
@foreach ($item->kelompokKategoriPivot as $key2 => $kelompokKategoriPivot)
|
||||||
@if ($kelompokKategoriPivot->produk->urutan == 5)
|
@if ($kelompokKategoriPivot->produk->urutan == 5)
|
||||||
<div
|
<div class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
||||||
class="col-xl-4 col-lg-6 col-md-4 col-sm-4">
|
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} )" class="card card-warning card-outline btn">
|
||||||
<div onclick="selectPaket( {{ $kelompokKategoriPivot->produk }} )"
|
|
||||||
class="card card-warning card-outline btn">
|
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<h6 class="m-0 text-xs">
|
<h6 class="m-0 text-xs">
|
||||||
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
||||||
</h6>
|
</h6>
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<img style="width: 100%;height: 100%;object-fit: cover;"
|
<img style="width: 100%;height: 100%;object-fit: cover;" src="{{ $kelompokKategoriPivot->produk->gambar_produk }}" alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
||||||
src="{{ $kelompokKategoriPivot->produk->gambar_produk }}"
|
|
||||||
alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
|
||||||
</div>
|
</div>
|
||||||
<a class="btn btn-warning"
|
<a class="btn btn-warning" id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">
|
||||||
id="ordered-menus-{{ $kelompokKategoriPivot->produk->id }}">
|
|
||||||
Pilih Paket
|
Pilih Paket
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
|
@ -257,8 +197,7 @@
|
||||||
{{-- Jika paket irit --}}
|
{{-- Jika paket irit --}}
|
||||||
@if ($kelompokKategoriPivot->kelompok_kategori_id == 2)
|
@if ($kelompokKategoriPivot->kelompok_kategori_id == 2)
|
||||||
<div class="col-xl-4 col-lg-6 col-md-6 col-sm-12">
|
<div class="col-xl-4 col-lg-6 col-md-6 col-sm-12">
|
||||||
<div class="card card-warning card-outline btn"
|
<div class="card card-warning card-outline btn" onclick="aadMenu( {{ $kelompokKategoriPivot->produk }} )">
|
||||||
onclick="aadMenu( {{ $kelompokKategoriPivot->produk }} )">
|
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<h6 class="m-0 text-xs">
|
<h6 class="m-0 text-xs">
|
||||||
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
||||||
|
@ -266,18 +205,14 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<img style="width: 100%;height: 100%;object-fit: cover;"
|
<img style="width: 100%;height: 100%;object-fit: cover;" src="{{ $kelompokKategoriPivot->produk->gambar_produk }}" alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
||||||
src="{{ $kelompokKategoriPivot->produk->gambar_produk }}"
|
<div class="col-md-12 mt-1" style="align-items: center;align-content: center;">
|
||||||
alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
|
||||||
<div class="col-md-12 mt-1"
|
|
||||||
style="align-items: center;align-content: center;">
|
|
||||||
<h5>
|
<h5>
|
||||||
{{ convert_to_rupiah($kelompokKategoriPivot->produk->harga_produk) }}
|
{{ convert_to_rupiah($kelompokKategoriPivot->produk->harga_produk) }}
|
||||||
</h5>
|
</h5>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<a class="col-sm-6 col-md-8 col-lg-12 btn btn-warning"
|
<a class="col-sm-6 col-md-8 col-lg-12 btn btn-warning" id="ordered-menus">Pesan</a>
|
||||||
id="ordered-menus">Pesan</a>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-12 mt-3">
|
<div class="col-md-12 mt-3">
|
||||||
|
@ -291,8 +226,7 @@
|
||||||
</div>
|
</div>
|
||||||
@else
|
@else
|
||||||
<div class="col-xl-4 col-lg-6 col-md-6 col-sm-12">
|
<div class="col-xl-4 col-lg-6 col-md-6 col-sm-12">
|
||||||
<div class="card card-warning card-outline btn"
|
<div class="card card-warning card-outline btn" onclick="aadMenu( {{ $kelompokKategoriPivot->produk }} )">
|
||||||
onclick="aadMenu( {{ $kelompokKategoriPivot->produk }} )">
|
|
||||||
<div class="card-header">
|
<div class="card-header">
|
||||||
<h6 class="m-0 text-xs">
|
<h6 class="m-0 text-xs">
|
||||||
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}
|
||||||
|
@ -300,18 +234,14 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="card-body">
|
<div class="card-body">
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<img style="width: 100%;height: 100%;object-fit: cover;"
|
<img style="width: 100%;height: 100%;object-fit: cover;" src="{{ $kelompokKategoriPivot->produk->gambar_produk }}" alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
||||||
src="{{ $kelompokKategoriPivot->produk->gambar_produk }}"
|
<div class="col-md-12 mt-1" style="align-items: center;align-content: center;">
|
||||||
alt="{{ $kelompokKategoriPivot->produk->nama_produk ?? '' }}">
|
|
||||||
<div class="col-md-12 mt-1"
|
|
||||||
style="align-items: center;align-content: center;">
|
|
||||||
<h5>
|
<h5>
|
||||||
{{ convert_to_rupiah($kelompokKategoriPivot->produk->harga_produk) }}
|
{{ convert_to_rupiah($kelompokKategoriPivot->produk->harga_produk) }}
|
||||||
</h5>
|
</h5>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<a class="col-sm-6 col-md-8 col-lg-12 btn btn-warning"
|
<a class="col-sm-6 col-md-8 col-lg-12 btn btn-warning" id="ordered-menus">Pesan</a>
|
||||||
id="ordered-menus">Pesan</a>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -386,8 +316,7 @@
|
||||||
<th class="text-center">Bayar</th>
|
<th class="text-center">Bayar</th>
|
||||||
<th colspan="3">
|
<th colspan="3">
|
||||||
<div class="input-group input-group-sm">
|
<div class="input-group input-group-sm">
|
||||||
<input type="text" name="nominal-bayar" class="form-control rounded-0"
|
<input type="text" name="nominal-bayar" class="form-control rounded-0" required id="nominal-bayar">
|
||||||
required id="nominal-bayar">
|
|
||||||
</div>
|
</div>
|
||||||
</th>
|
</th>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -404,14 +333,10 @@
|
||||||
<tr>
|
<tr>
|
||||||
<th colspan="4">
|
<th colspan="4">
|
||||||
<span class="row">
|
<span class="row">
|
||||||
<input type="text" name="nama-pemesan" class="form-control rounded-0"
|
<input type="text" name="nama-pemesan" class="form-control rounded-0 col-lg-6" placeholder="Nama Pemesan" id="nama-pemesan" required>
|
||||||
placeholder="Nama Pemesan" id="nama-pemesan" required>
|
<input type="text" name="nomor-pemesan" class="form-control rounded-0 col-lg-6" placeholder="Nomor Pemesan" id="nomor-pemesan" oninput="inputNum(this)" required>
|
||||||
<input type="number" min="1" name="nomor-meja"
|
<input type="number" min="1" name="nomor-meja" class="form-control rounded-0" placeholder="Nomor Meja" id="nomor-meja" required>
|
||||||
class="form-control rounded-0" placeholder="Nomor Meja" id="nomor-meja"
|
<input type="text" name="keterangan-pesanan" placeholder="Keterangan Pesanan" class="form-control rounded-0" id="keterangan-pesanan">
|
||||||
required>
|
|
||||||
<input type="text" name="keterangan-pesanan"
|
|
||||||
placeholder="Keterangan Pesanan" class="form-control rounded-0"
|
|
||||||
id="keterangan-pesanan">
|
|
||||||
</span>
|
</span>
|
||||||
</th>
|
</th>
|
||||||
</tr>
|
</tr>
|
||||||
|
@ -556,7 +481,7 @@
|
||||||
table.rows[index].cells[2].innerHTML = `
|
table.rows[index].cells[2].innerHTML = `
|
||||||
<td class="text-center">
|
<td class="text-center">
|
||||||
<div class="input-group input-group-sm">
|
<div class="input-group input-group-sm">
|
||||||
<input type="number" name="diskon_satuan" class="form-control rounded-0" value="${diskonSatuan}" onkeyup="diskonSatuanMenu(${params.id}, '${params.nama_produk}', this.value)">
|
<input type="number" name="diskon_satuan" oninput="inputNum(this)" class="form-control rounded-0" value="${diskonSatuan}" onkeyup="diskonSatuanMenu(${params.id}, '${params.nama_produk}', this.value)">
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
`;
|
`;
|
||||||
|
@ -593,7 +518,7 @@
|
||||||
</td>
|
</td>
|
||||||
<td class="text-center">
|
<td class="text-center">
|
||||||
<div class="input-group input-group-sm">
|
<div class="input-group input-group-sm">
|
||||||
<input type="number" name="diskon_satuan" class="form-control rounded-0" value="0" onkeyup="diskonSatuanMenu(${params.id}, '${params.nama_produk}', this.value)">
|
<input type="number" name="diskon_satuan" oninput="inputNum(this)" class="form-control rounded-0" value="0" onkeyup="diskonSatuanMenu(${params.id}, '${params.nama_produk}', this.value)">
|
||||||
</div>
|
</div>
|
||||||
</td>
|
</td>
|
||||||
<td class="text-center">
|
<td class="text-center">
|
||||||
|
@ -916,6 +841,7 @@
|
||||||
var nominalBayar = bayar.replace(/[^,\d]/g, '').toString();
|
var nominalBayar = bayar.replace(/[^,\d]/g, '').toString();
|
||||||
var kembaliHidden = document.getElementById('kembali-hidden').innerHTML;
|
var kembaliHidden = document.getElementById('kembali-hidden').innerHTML;
|
||||||
var namaPemesan = document.getElementsByName('nama-pemesan')[0].value;
|
var namaPemesan = document.getElementsByName('nama-pemesan')[0].value;
|
||||||
|
var nomorPemesan = document.getElementsByName('nomor-pemesan')[0].value;
|
||||||
var nomorMeja = document.getElementsByName('nomor-meja')[0].value;
|
var nomorMeja = document.getElementsByName('nomor-meja')[0].value;
|
||||||
|
|
||||||
if (orderMenus.length == 0) {
|
if (orderMenus.length == 0) {
|
||||||
|
@ -942,6 +868,7 @@
|
||||||
orderCode: "{{ $orderCode }}",
|
orderCode: "{{ $orderCode }}",
|
||||||
orderMenus: orderMenus,
|
orderMenus: orderMenus,
|
||||||
namaPemesan: namaPemesan,
|
namaPemesan: namaPemesan,
|
||||||
|
nomorPemesan: nomorPemesan,
|
||||||
nomorMeja: nomorMeja,
|
nomorMeja: nomorMeja,
|
||||||
keteranganPesanan: document.getElementsByName('keterangan-pesanan')[0].value,
|
keteranganPesanan: document.getElementsByName('keterangan-pesanan')[0].value,
|
||||||
diskon: diskon,
|
diskon: diskon,
|
||||||
|
@ -1154,5 +1081,15 @@
|
||||||
// aria-selected
|
// aria-selected
|
||||||
document.getElementById(tabId + '-tab').setAttribute('aria-selected', true);
|
document.getElementById(tabId + '-tab').setAttribute('aria-selected', true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
function inputNum(inputElement) {
|
||||||
|
// Hapus karakter selain angka
|
||||||
|
inputElement.value = inputElement.value.replace(/[^0-9]/g, '');
|
||||||
|
if (inputElement.value == '') {
|
||||||
|
inputElement.value = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
</script>
|
</script>
|
||||||
@endpush
|
@endpush
|
Loading…
Reference in New Issue