|
|
|
@ -0,0 +1,56 @@ |
|
|
|
@extends('layouts.app') |
|
|
|
|
|
|
|
@section('title', trans('invoice.list')) |
|
|
|
|
|
|
|
@section('content') |
|
|
|
|
|
|
|
<h1 class="page-header"> |
|
|
|
<div class="pull-right"> |
|
|
|
{!! FormField::formButton(['route' => 'invoice-drafts.create'], trans('invoice.create'), [ |
|
|
|
'class' => 'btn btn-success', |
|
|
|
'name' => 'create-invoice-draft', |
|
|
|
'id' => 'invoice-draft-create-button' |
|
|
|
]) !!} |
|
|
|
</div> |
|
|
|
{{ trans('invoice.list') }} |
|
|
|
</h1> |
|
|
|
|
|
|
|
<div class="panel panel-default"> |
|
|
|
<table class="table table-condensed"> |
|
|
|
<thead> |
|
|
|
<th class="text-center">{{ trans('app.table_no') }}</th> |
|
|
|
<th class="col-md-2 text-center">{{ trans('invoice.number') }}</th> |
|
|
|
<th class="col-md-2 text-center">{{ trans('app.date') }}</th> |
|
|
|
<th class="col-md-2">{{ trans('project.project') }}</th> |
|
|
|
<th class="col-md-2">{{ trans('invoice.customer') }}</th> |
|
|
|
<th class="col-md-2 text-right">{{ trans('invoice.amount') }}</th> |
|
|
|
<th class="col-md-2 text-center">{{ trans('app.action') }}</th> |
|
|
|
</thead> |
|
|
|
<tbody> |
|
|
|
@forelse($invoices as $key => $invoice) |
|
|
|
<tr> |
|
|
|
<td class="text-center">{{ 1 + $key }}</td> |
|
|
|
<td class="text-center">{{ $invoice->number }}</td> |
|
|
|
<td class="text-center">{{ $invoice->created_at->format('Y-m-d') }}</td> |
|
|
|
<td>{{ $invoice->project->nameLink() }}</td> |
|
|
|
<td>{{ $invoice->project->customer->nameLink() }}</td> |
|
|
|
<td class="text-right">{{ formatRp($invoice->amount) }}</td> |
|
|
|
<td class="text-center"> |
|
|
|
{!! html_link_to_route('invoices.show', '', [$invoice->number], ['class' => 'btn btn-info btn-xs','icon' => 'search','title' => 'Lihat ' . trans('invoice.show')]) !!} |
|
|
|
{!! html_link_to_route('invoices.pdf', '', [$invoice->number], ['class' => 'btn btn-default btn-xs','icon' => 'print','title' => trans('invoice.print'), 'target' => '_blank']) !!} |
|
|
|
</td> |
|
|
|
</tr> |
|
|
|
@empty |
|
|
|
<tr><td colspan="7">{{ trans('invoice.empty') }}</td></tr> |
|
|
|
@endforelse |
|
|
|
</tbody> |
|
|
|
<tfoot> |
|
|
|
<tr> |
|
|
|
<th colspan="5" class="text-right">{{ trans('app.total') }}</th> |
|
|
|
<th class="text-right">{{ formatRp($invoices->sum('amount')) }}</th> |
|
|
|
<th></th> |
|
|
|
</tr> |
|
|
|
</tfoot> |
|
|
|
</table> |
|
|
|
</div> |
|
|
|
@endsection |