@extends(\Auth::user()->role != 10 ? 'layout' : 'layoutfrontdesk') @section('title', 'Company Bill | Tambah Company Bill') @section('css') @endsection @section('content')
@csrf
@php ($no = 1)@endphp @foreach($invoices as $invoice) @php $nominalpembayaran = 0; $nominalrefund = 0; $balance_total = 0; $nominaltransaksishop = 0; $nominalinvoice = $invoice->total - $invoice->total_deposit; if (count($invoice->shop_transaction)) { foreach ($invoice->shop_transaction as $transaction) { $nominaltransaksishop += $transaction->grand_total; } } $balance_total = $nominalinvoice + $nominaltransaksishop - $nominalpembayaran; $balance_total = $balance_total + $nominalrefund; @endphp @if ($invoice->invoicecompanydetail) @foreach (@$invoice->invoicecompanydetail as $id_com) @if (@$id_com->invoice_company_id != $id_in_company) @endif @endforeach @else @endif @php $no++; @endphp @endforeach @foreach($cartrestos as $cartresto) @if($cartresto->invoicecompanydetail) @foreach(@$cartresto->invoicecompanydetail as $id_com) @if (@$id_com->invoice_company_id != $id_in_company) @endif @endforeach @else @endif @php $no++; @endphp @endforeach
# Hotel No Invoice Nama Company Nama Pelanggan Total
invoicecompanydetail as $id_com) @if (@$id_com->invoice_company_id == $id_in_company ) {{@$invoice->in_invoices_company == '1' ? 'checked' : ''}} @else {{@$invoice->in_invoice_company == '' ? 'disabled' : ''}} @endif @endforeach >
in_invoices_company) @foreach (@$invoice->invoicecompanydetail as $id_com) @if (@$id_com->invoice_company_id != $id_in_company) {{@$invoice->in_invoices_company == '1' ? 'disabled' : 'disabled'}} @endif @endforeach @else disabled @endif > {{-- --}}
{{$invoice->hotel->nama}} {{$invoice->no_invoice}} {{$invoice->bookings->company ? $invoice->bookings->company->comp_title.' '.$invoice->bookings->company->name : ''}} {{$invoice->nama_pelanggan}} {{ribuan($balance_total)}}
invoicecompanydetail as $id_com) @if (@$id_com->invoice_company_id == $id_in_company ) {{@$cartresto->in_invoices_company == '1' ? 'checked' : ''}} @else {{@$cartresto->in_invoice_company == '' ? 'disabled' : ''}} @endif @endforeach >
in_invoices_company) @foreach (@$cartresto->invoicecompanydetail as $id_com) @if (@$id_com->invoice_company_id != $id_in_company) {{@$cartresto->in_invoices_company == '1' ? 'disabled' : 'disabled'}} @endif @endforeach @else disabled @endif > {{-- --}}
{{@$cartresto->shop->hotel->nama}} {{$cartresto->order_flag}} {{$cartresto->ledger ? $cartresto->ledger->comp_title.' '.$cartresto->ledger->name : ''}} {{$cartresto->nama_pelanggan}} {{ribuan($cartresto->total_payment_pos)}}
@endsection @section('js') @endsection