Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
K
konaspi2024
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Siti Aisah
konaspi2024
Commits
ed8ef0d4
Commit
ed8ef0d4
authored
Mar 14, 2024
by
Triyah Fatmawati
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add preview sebelum invoice
parent
7934d8fe
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
176 additions
and
9 deletions
+176
-9
app/Http/Controllers/RegistrasiController.php
+13
-2
resources/views/invoice.blade.php
+8
-7
resources/views/preview.blade.php
+155
-0
No files found.
app/Http/Controllers/RegistrasiController.php
View file @
ed8ef0d4
...
@@ -126,7 +126,7 @@ public function preview(Request $request){
...
@@ -126,7 +126,7 @@ public function preview(Request $request){
'totalHarga'
=>
$totalHarga
'totalHarga'
=>
$totalHarga
];
];
return
view
(
'
invoice
'
,
$data
)
->
with
(
'success'
,
'Data saved successfully'
);
return
view
(
'
preview
'
,
$data
)
->
with
(
'success'
,
'Data saved successfully'
);
}
}
catch
(
Exception
$e
){
catch
(
Exception
$e
){
...
@@ -188,7 +188,18 @@ public function store(Request $request) {
...
@@ -188,7 +188,18 @@ public function store(Request $request) {
DB
::
commit
();
DB
::
commit
();
return
redirect
()
->
route
(
'user.create'
)
->
with
(
'success'
,
'Data saved successfully'
);
// return redirect()->route('user.create')->with('success', 'Data saved successfully');
$data
=
[
'registrasi'
=>
$registrasi
,
'kegiatanpeserta'
=>
$kegiatanpeserta
,
'tglRegistrasi'
=>
$tglRegistrasi
,
'konaspi'
=>
$konaspi
,
'hargaKonferensi'
=>
$hargaKonferensi
,
'totalHarga'
=>
$totalHarga
];
return
view
(
'invoice'
,
$data
)
->
with
(
'success'
,
'Data saved successfully'
);
}
}
catch
(
Exception
$e
){
catch
(
Exception
$e
){
...
...
resources/views/invoice.blade.php
View file @
ed8ef0d4
...
@@ -6,11 +6,11 @@
...
@@ -6,11 +6,11 @@
<h1>Invoice</h1>
<h1>Invoice</h1>
<div class="
section
-
header
-
breadcrumb
">
<div class="
section
-
header
-
breadcrumb
">
<div class="
breadcrumb
-
item
"><a href="
/
">Dashboard</a></div>
<div class="
breadcrumb
-
item
"><a href="
/
">Dashboard</a></div>
<div class="
breadcrumb
-
item
"><a href="">Data Registrasi</a></div>
{{-- <div class="
breadcrumb
-
item
"><a href="">Data Registrasi</a></div> --}}
<div class="
breadcrumb
-
item
active
">Invoice</div>
<div class="
breadcrumb
-
item
active
">Invoice</div>
</div>
</div>
</div>
</div>
<form novalidate="" method="
POST
" action="
{{
route
(
'user.store'
)}}
" enctype="
multipart
/
form
-
data
">
{{-- <form novalidate="" method="
POST
" action="
{{
route
(
'user.store'
)}}
" enctype="
multipart
/
form
-
data
"> --}}
@csrf
@csrf
<div class="
section
-
body
">
<div class="
section
-
body
">
<div class="
invoice
">
<div class="
invoice
">
...
@@ -71,7 +71,7 @@
...
@@ -71,7 +71,7 @@
</tr>
</tr>
@php
@php
$no
= 2;
$no
= 2;
$initialharga
=
$konaspi
->harga
;
$initialharga
=
$konaspi
['harga']
;
$subtotal
=
$initialharga
;
$subtotal
=
$initialharga
;
$i
= 0;
$i
= 0;
@endphp
@endphp
...
@@ -80,9 +80,9 @@
...
@@ -80,9 +80,9 @@
<td>
<td>
Convention
Convention
</td>
</td>
<td class="
text
-
center
">Rp
{
{$konaspi
->harga
}
}
</td>
<td class="
text
-
center
">Rp
{
{$konaspi
['harga']
}
}
</td>
<td class="
text
-
center
">1</td>
<td class="
text
-
center
">1</td>
<td class="
text
-
right
">Rp
{
{$konaspi
->harga
}
}
</td>
<td class="
text
-
right
">Rp
{
{$konaspi
['harga']
}
}
</td>
</tr>
</tr>
@if (isset(
$hargaKonferensi
))
@if (isset(
$hargaKonferensi
))
@foreach (
$hargaKonferensi
as
$kon
)
@foreach (
$hargaKonferensi
as
$kon
)
...
@@ -145,12 +145,13 @@
...
@@ -145,12 +145,13 @@
<input type="
hidden
" id="
konaspi
" name="
konaspi
" value="
{{
json_encode
(
$konaspi
)
}}
">
<input type="
hidden
" id="
konaspi
" name="
konaspi
" value="
{{
json_encode
(
$konaspi
)
}}
">
<input type="
hidden
" id="
hargaKonferensi
" name="
hargaKonferensi
" value="
{{
json_encode
(
$hargaKonferensi
)
}}
">
<input type="
hidden
" id="
hargaKonferensi
" name="
hargaKonferensi
" value="
{{
json_encode
(
$hargaKonferensi
)
}}
">
<input type="
hidden
" id="
totalHarga
" name="
totalHarga
" value="
{{
json_encode
(
$totalHarga
)
}}
">
<input type="
hidden
" id="
totalHarga
" name="
totalHarga
" value="
{{
json_encode
(
$totalHarga
)
}}
">
<button type="
submit
" class="
btn
btn
-
primary
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
credit
-
card
"></i> Bayar</button>
{{-- <button type="
submit
" class="
btn
btn
-
primary
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
credit
-
card
"></i> Bayar</button> --}}
<a href="
{{
route
(
'user.create'
)}}
" class="
btn
btn
-
primary
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
credit
-
card
"></i> Bayar</a>
<button class="
btn
btn
-
danger
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
times
"></i> Cancel</button>
<button class="
btn
btn
-
danger
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
times
"></i> Cancel</button>
</div>
</div>
</div>
</div>
</div>
</div>
</form>
{{-- </form> --}}
</section>
</section>
@endsection
@endsection
resources/views/preview.blade.php
0 → 100644
View file @
ed8ef0d4
@
extends
(
'layouts.app'
)
@
section
(
'title'
,
'Rincian Biaya'
)
@
section
(
'content'
)
<
section
class
="
section
">
<div class="
section
-
header
">
<h1>Rincian Biaya</h1>
<div class="
section
-
header
-
breadcrumb
">
<div class="
breadcrumb
-
item
"><a href="
/
">Dashboard</a></div>
<div class="
breadcrumb
-
item
"><a href="">Data Registrasi</a></div>
<div class="
breadcrumb
-
item
active
">Rincian Biaya</div>
</div>
</div>
<form novalidate="" method="
POST
" action="
{{
route
(
'user.store'
)}}
" enctype="
multipart
/
form
-
data
">
@csrf
<div class="
section
-
body
">
<div class="
invoice
">
<div class="
invoice
-
print
">
{{-- <div class="
row
">
<div class="
col
-
lg
-
12
">
<div class="
invoice
-
title
">
<h2>Invoice</h2>
<div class="
invoice
-
number
">No. Transaksi #
{
{$registrasi['kode_registrasi']}
}
</div>
</div>
<hr>
<div class="
row
" style="
font
-
size
:
12
pt
">
<div class="
col
-
md
-
6
">
<address>
<strong>Identitas:</strong><br>
{
{$registrasi['nama']}
}
<br>
{
{$registrasi['alamat']}
}
<br>
{
{$registrasi['telepon']}
}
<br>
</address>
</div>
<div class="
col
-
md
-
6
text
-
md
-
right
">
<address>
<strong>Instansi:</strong><br>
{
{$registrasi['instansi']}
}
<br>
</address>
</div>
</div>
<div class="
row
" style="
font
-
size
:
12
pt
">
<div class="
col
-
md
-
6
">
<address>
<strong>Metode Pembayaran:</strong><br>
Virtual Account :
{
{$registrasi['kode_registrasi']}
}
<br>
</address>
</div>
<div class="
col
-
md
-
6
text
-
md
-
right
">
<address>
<strong>Tanggal Registrasi:</strong><br>
{
{$tglRegistrasi}
}
<br><br>
</address>
</div>
</div>
</div>
</div> --}}
<div class="
row
mt
-
4
">
<div class="
col
-
md
-
12
" style="
font
-
size
:
12
pt
">
<div class="
section
-
title
">Rincian</div>
<p class="
section
-
lead
">Rincian registrasi tidak bisa diubah setelah menekan tombol daftar</p>
<div class="
table
-
responsive
">
<table class="
table
table
-
striped
table
-
hover
table
-
md
">
<tr>
<th data-width="
40
">#</th>
<th>Kegiatan</th>
<th class="
text
-
center
">Harga</th>
<th class="
text
-
center
">Jumlah</th>
<th class="
text
-
right
">Total Harga</th>
</tr>
@php
$no
= 2;
$initialharga
=
$konaspi->harga
;
$subtotal
=
$initialharga
;
$i
= 0;
@endphp
<tr>
<td>1</td>
<td>
Convention
</td>
<td class="
text
-
center
">Rp
{
{$konaspi->harga}
}
</td>
<td class="
text
-
center
">1</td>
<td class="
text
-
right
">Rp
{
{$konaspi->harga}
}
</td>
</tr>
@if (isset(
$hargaKonferensi
))
@foreach (
$hargaKonferensi
as
$kon
)
@php
$subtotal
=
$subtotal
+
$kon['hargakon']
;
@endphp
<tr>
<td>
{
{$no}
}
</td>
<td>
{
{$kon['namakeg']}
}
<br> Konferensi : <b>
{
{$kon['namakon']}
}
</b>
</td>
<td class="
text
-
center
">Rp
{
{$kon['hargakon']}
}
</td>
<td class="
text
-
center
">1</td>
<td class="
text
-
right
">Rp
{
{$kon['hargakon']}
}
</td>
</tr>
@php
$i
++;
$no
++;
@endphp
@endforeach
@endif
</table>
</div>
<div class="
row
mt
-
4
">
<div class="
col
-
lg
-
8
">
{{-- <div class="
section
-
title
">Metode Pembayaran</div> --}}
{{-- <p class="
section
-
lead
" style="
font
-
size
:
12
pt
">Setelah menekan tombol bayar, maka data akan tersimpan dan lakukan pembayaran tagihan menggunakan <b>Nomor Virtual Account</b> yang tertera pada <b>Invoice</b> ini</p> --}}
{{-- <div class="
d
-
flex
">
<div class="
mr
-
2
bg
-
visa
" data-width="
61
" data-height="
38
"></div>
<div class="
mr
-
2
bg
-
jcb
" data-width="
61
" data-height="
38
"></div>
<div class="
mr
-
2
bg
-
mastercard
" data-width="
61
" data-height="
38
"></div>
<div class="
bg
-
paypal
" data-width="
61
" data-height="
38
"></div>
</div> --}}
</div>
<div class="
col
-
lg
-
4
text
-
right
">
<div class="
invoice
-
detail
-
item
">
<div class="
invoice
-
detail
-
name
">Subtotal</div>
<div class="
invoice
-
detail
-
value
">Rp
{
{$subtotal}
}
</div>
</div>
<hr class="
mt
-
2
mb
-
2
">
<div class="
invoice
-
detail
-
item
">
<div class="
invoice
-
detail
-
name
">Total</div>
<div class="
invoice
-
detail
-
value
invoice
-
detail
-
value
-
lg
">Rp
{
{$subtotal}
}
</div>
</div>
</div>
</div>
</div>
</div>
</div>
<hr>
<div class="
text
-
md
-
right
">
{{-- <div class="
float
-
lg
-
left
mb
-
lg
-
0
mb
-
3
">
<button class="
btn
btn
-
primary
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
credit
-
card
"></i> Bayar</button>
<button class="
btn
btn
-
danger
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
times
"></i> Cancel</button>
</div> --}}
{{-- <button class="
btn
btn
-
warning
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
print
"></i> Cetak</button> --}}
<input type="
hidden
" id="
registrasi
" name="
registrasi
" value="
{{
json_encode
(
$registrasi
)
}}
">
<input type="
hidden
" id="
kegiatanpeserta
" name="
kegiatanpeserta
" value="
{{
json_encode
(
$kegiatanpeserta
)
}}
">
<input type="
hidden
" id="
tglRegistrasi
" name="
tglRegistrasi
" value="
{{
json_encode
(
$tglRegistrasi
)
}}
">
<input type="
hidden
" id="
konaspi
" name="
konaspi
" value="
{{
json_encode
(
$konaspi
)
}}
">
<input type="
hidden
" id="
hargaKonferensi
" name="
hargaKonferensi
" value="
{{
json_encode
(
$hargaKonferensi
)
}}
">
<input type="
hidden
" id="
totalHarga
" name="
totalHarga
" value="
{{
json_encode
(
$totalHarga
)
}}
">
<button type="
submit
" class="
btn
btn
-
primary
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
credit
-
card
"></i> Daftar</button>
<button class="
btn
btn
-
danger
btn
-
icon
icon
-
left
"><i class="
fas
fa
-
times
"></i> Cancel</button>
</div>
</div>
</div>
</form>
</section>
@endsection
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment