Update kontrak

This commit is contained in:
Pusdatin BPKD Jkt
2022-08-03 11:45:58 +07:00
parent 5d5d8b2741
commit 4683420bf9
8 changed files with 172 additions and 184 deletions
@@ -18,7 +18,7 @@
@section('content')
<div class="card">
<div class="card-header">
<h2 class="card-title"><i class="fa fa-th-list mr-2"></i> {{ $sitesubTitle }}</h2>
<h2 class="card-title"><i class="fa fa-th-list mr-2"></i> <strong>{{ strtoupper($sitesubTitle) }}</strong></h2>
<div class="card-tools">
{{-- @if(auth()->user()->can('Tambah SKPP')) --}}
<button class="btn btn-sm btn-default" onclick="location.href='{{ url('/realisasi-belanja') }}'"><i class="fa fa-arrow-left"></i> Kembali</button>
@@ -36,7 +36,7 @@
<div class="card-body">
<div class="row">
<div class="col-6">
<strong><i class="fa fa-th-list mr-2"></i> AKB vs Realisasi</strong><hr style="margin-bottom: 0 !important;">
<strong><i class="fa fa-th-list mr-2"></i> AKB vs REALISASI</strong><hr style="margin-bottom: 0 !important;">
<div class="row">
<div class='col-12'>
<table class="table table-striped">
@@ -69,40 +69,6 @@
</div>
</div>
<div class="col-6">
<strong><i class="fa fa-th-list mr-2"></i> Data Kontrak</strong> [ <a class="modalButton" title="Input Kontrak" href="{{ url('/realisasi-belanja/'.$BelanjaRealisasi->id.'/kontrak') }}">Tambah Kontrak</a> ]<hr style="margin-bottom: 0 !important;">
<table class="table table-sm table-striped">
<thead>
<th>No</th>
<th>Nomor Kontrak</th>
<th class="text-center">Tanggal</th>
<th class="text-right">Jumlah</th>
<th class="text-center"></th>
</thead>
<tbody>
<?php
$totalKontrak = 0;
foreach($BelanjaRealisasiKontrak as $key=>$kontrak){ ?>
<tr>
<td>{{ $key+1 }}</td>
<td>{{ $kontrak->nomor_kontrak }}</td>
<td class="text-center">{{ date("d-m-Y",strtotime($kontrak->tgl_kontrak)) }}</td>
<td class="text-right">{{ separateNumberIndo($kontrak->nominal_kontrak) }}</td>
<td class="text-center">
<form class='form-delete' action='/realisasi-belanja/{{ $kontrak->id }}/kontrak' method='POST'>
<input type='hidden' name='_token' id='csrf-token' value='{{ Session::token() }}' />
<input type='hidden' name='_method' value='DELETE'>
<a class='btn btn-default btn-sm modalButton' href='/realisasi-belanja/{{ $kontrak->id }}/kontrak/update' title='Ubah Kontrak'><i class='fa fa-edit'></i></a>
<button type="submit" class="btn btn-default btn-sm" name="btnSubmit"><i class="fa fa-trash"></i></button>
</form>
</td>
</tr>
<?php $totalKontrak+=floatVal($kontrak->nominal_kontrak); } ?>
<tr >
<td colspan="3"><strong>TOTAL KONTRAK</strong></td>
<td colspan="2" class="text-right"><strong>{{ separateNumberIndo($totalKontrak) }}</strong></td>
</tr>
</tbody>
</table>
<strong><i class="fa fa-th-list mr-2"></i> SPD</strong><hr style="margin-bottom: 0 !important;">
<table class="table table-sm table-striped">
<thead>
@@ -128,7 +94,7 @@
</tr>
</tbody>
</table>
<strong><i class="fa fa-th-list mr-2"></i> SP2D</strong><hr style="margin-bottom: 0 !important;">
<strong><i class="fa fa-th-list mr-2 mt-3"></i> SP2D</strong><hr style="margin-bottom: 0 !important;">
<table class="table table-sm table-striped">
<thead>
<th>No</th>
@@ -157,6 +123,51 @@
</div>
</div>
</div>
<div class="card">
<div class="card-body">
<strong><i class="fa fa-th-list mr-2"></i> KONTRAK</strong> <?= Auth::user()->can("Create Kontrak")?'[ <a class="modalButton" title="Input Kontrak" href="'.url('/realisasi-belanja/'.$BelanjaRealisasi->id.'/kontrak') .'">Tambah Kontrak</a> ]':'' ?><hr style="margin-bottom: 0 !important;">
<table class="table table-sm table-striped">
<thead>
<th>No</th>
<th>Nomor Kontrak</th>
<th class="text-center">Tanggal</th>
<th class="text-right">Jumlah</th>
<th class="text-center">File</th>
<?php if (Auth::user()->can("Create Kontrak")){ ?>
<th class="text-center"></th>
<?php } ?>
</thead>
<tbody>
<?php
$totalKontrak = 0;
foreach($BelanjaRealisasiKontrak as $key=>$kontrak){ ?>
<tr>
<td>{{ $key+1 }}</td>
<td>{{ $kontrak->nomor_kontrak }}</td>
<td class="text-center">{{ date("d-m-Y",strtotime($kontrak->tgl_kontrak)) }}</td>
<td class="text-right">{{ separateNumberIndo($kontrak->nominal_kontrak) }}</td>
<td class="text-center"><?= empty($kontrak->file_kontrak)?"-":"<a href='".url("/realisasi-belanja/".$BelanjaRealisasi->id.'__'.$kontrak->id ."/download-kontrak")."'>".$kontrak->file_kontrak."</a>" ?></td>
<?php if (Auth::user()->can("Create Kontrak")){ ?>
<td class="text-center">
<form class='form-delete' action='/realisasi-belanja/{{ $kontrak->id }}/kontrak' method='POST'>
<input type='hidden' name='_token' id='csrf-token' value='{{ Session::token() }}' />
<input type='hidden' name='_method' value='DELETE'>
<a class='btn btn-default btn-sm modalButton' href='/realisasi-belanja/{{ $kontrak->id }}/kontrak/update' title='Ubah Kontrak'><i class='fa fa-edit'></i></a>
<button type="submit" class="btn btn-default btn-sm" name="btnSubmit"><i class="fa fa-trash"></i></button>
</form>
</td>
<?php } ?>
</tr>
<?php $totalKontrak+=floatVal($kontrak->nominal_kontrak); } ?>
<tr >
<td colspan="3"><strong>TOTAL KONTRAK</strong></td>
<td class="text-right"><strong>{{ separateNumberIndo($totalKontrak) }}</strong></td>
<td colspan="2">&nbsp;</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="card">
<div class="card-body">
<strong><i class="fa fa-th-list mr-2"></i> REALISASI</strong><hr style="margin-bottom: 0 !important;">