@extends('admin.layout.master') @section('title', 'Frontdesk Report || ' . $report_title) @section('custom_style') @endsection @section('content') @php use App\Http\Controllers\Frontdesk\CheckInController; @endphp {{--
--}}
{{--

Daily Bill Book Summery

--}} @section('page_title', 'Reservation Report') @include('admin.layout.page_title_header_with_print')
{{-- print_preview --}} @include('frontdesk.report.report_header') {{-- checkin/booking information --}}
@if ($booking_info->resv_code)
Resv. Id: {{ $booking_info->resv_code }}
@endif @if ($booking_info->checkin_code)
Check In Code: {{ $booking_info->checkin_code }}
@if($booking_info->allotment_id != 0)
Allotment Code: {{ $booking_info->get_allotment_info->code }}
@endif @endif
Company Name: @if ($booking_info->get_company_name) {{ $booking_info->get_company_name->name }} @endif
Number of Adult: @if ($booking_info->adult) {{ $booking_info->adult }} @endif
Number of Child: @if ($booking_info->children) {{ $booking_info->children }} @endif
Agent Name: @if ($booking_info->get_agent_info) {{ $booking_info->get_agent_info->name_eng }} @endif
Status: {{ booking_status($booking_info->booking_status) }}
BookedBy: {{ user_name($booking_info->posted_by) }}
@if (!$booking_info->checkin_code)
Confirmation: @if ($booking_info->confirm_date) Confirmed @else Not Confirmed @endif @endif
@if ($booking_info->confirm_date)
Confirmation Time: {{ $booking_info->confirm_date }}
@endif
Resv. Date: @if ($booking_info->created_at) {{ date('d-m-Y h:i:sa', strtotime($booking_info->created_at)) }} @endif
@if ($booking_info->check_in_date)
Check In Date: {{ date('d-m-Y', strtotime($booking_info->check_in_date)) }}
@endif @if ($booking_info->check_out_date)
Check Out Date: {{ date('d-m-Y', strtotime($booking_info->check_out_date)) }}
@endif @if($booking_info->booking_status == 4)

CANCELLED

@endif
{{-- Guest information --}}
Guest Information:
@forelse ($guest_info as $key=>$gi) @empty @endforelse
Sl Room/Bed Number Name Email Mobile No. Country Identity Type Identity Number
{{ $key + 1 }} {{ $gi->get_room != null ? $gi->get_room->room_number : '-' }} {{ $gi->name }} {{ $gi->email }} {{ $gi->mobile_no }} {{ $gi->get_country->name }} {{ $gi->get_identity_type->name ?? '' }} {{ $gi->identity_no }}
No Guest Info Provided
{{-- Reservation Information --}}
@if ($booking_info->checkin_code) Check In Information @else Reservation Information: @endif
{{-- @if ($booking_info->checkin_code) @endif --}} @if ($booking_info->checkin_code) @endif @if(!request()->without_bill) @endif @php $total_amount = 0; $total_vat = 0; $sub_total = 0; $total_room_bed = 0; $total_night = 0; @endphp @forelse ($booking_room_details as $key=>$brd) @php $amount = 0; @endphp @if ($booking_info->checkin_code) @if(!request()->without_bill) @php $amount = $booking_info->tax_type == 2 ? $brd->rent * $brd->qty * 1 : ($brd->rent + $brd->vat) * $brd->qty * 1; @endphp @endif @php $total_amount += $amount; $total_vat += $brd->vat * $brd->qty; @endphp @else @if(!request()->without_bill) @php $amount = $brd->rent*$brd->qty*$brd->total_night @endphp @php $vat = CheckInController::calculate_tax($amount, $booking_info->tax_percent, $booking_info->tax_type) @endphp @endif @if(!request()->without_bill) @php $total_amount += $amount; $total_vat += $vat; @endphp @endif @endif @empty @endforelse {{-- @if ($booking_info->checkin_code) @endif --}} @if(request()->without_bill) @endif @if(!request()->without_bill) @endif @if(!request()->without_bill) @if ($booking_info->checkin_code) @endif @if ($booking_info->checkin_code) @endif @if ($booking_info->checkin_code) @endif @endif
Sl Rooms/Bed Room TypeRoom/Bed NumberRoom/Bed Number Qty From Total Night ToStatusRent Amount Tax Total Amount
{{ $key + 1 }} @if ($booking_info->type == 1) Room @else Bed @endif {{ $brd->get_room_type->name }} {{ $brd->bed_id == 0? $brd->get_room_info->room_number: $brd->get_bed_info->room_number . ' [' . $brd->get_room_info->room_number . ']' }} 1 @php $total_room_bed+=1 @endphp {{ date('d-m-Y', strtotime($brd->start_date_time)) }} {{ $brd->qty }} @php $total_night+=$brd->qty @endphp {{ date('d-m-Y', strtotime($brd->end_date_time . '+1 day')) }} {!! chk_room_status($brd->check_in_status) !!} @if ($booking_info->tax_type == 2) {{ number_format($brd->rent, 2) }} @else {{ number_format($brd->rent + $brd->vat, 2) }} @endif @if ($booking_info->tax_type == 2) {{ number_format($brd->rent * $brd->qty * 1, 2) }} @else {{ number_format(($brd->rent + $brd->vat) * $brd->qty * 1, 2) }} @endif {{ number_format($brd->vat * $brd->qty, 2) }} @if ($booking_info->tax_type == 2) {{ number_format($amount + $brd->vat * $brd->qty, 2) }} @php $sub_total+=($amount+($brd->vat*$brd->qty)) @endphp @else {{ number_format($amount - $brd->vat * $brd->qty, 2) }} @php $sub_total+=($amount-($brd->vat*$brd->qty)) @endphp @endif
{{ $key + 1 }} @if ($booking_info->type == 1) Room @else Bed @endif {{ $brd->get_room_type->name ?? '-' }} {{ $brd->room->room_number ?? '-' }} {{ $brd->qty }} @php $total_room_bed+=$brd->qty @endphp {{ date('d-m-Y', strtotime($brd->start_date)) }} {{ number_format($brd->total_night, 2) }} @php $total_night+=$brd->total_night @endphp {{ date('d-m-Y', strtotime($brd->end_date)) }} {{ number_format($brd->rent, 2) }} {{ number_format($brd->rent * $brd->qty * $brd->total_night, 2) }} {{ number_format($vat, 2) }} @if ($booking_info->tax_type == 2) {{ number_format($amount + $vat, 2) }} @php $sub_total+=($amount+$vat) @endphp @else {{ number_format($amount - $vat, 2) }} @php $sub_total+=($amount-$vat) @endphp @endif
No Room Record Found
Total Room/Bed: {{ $total_room_bed }} Total Night: {{ $total_night }} Total Amount @if ($booking_info->tax_type == 1) (Including) @endif {{ number_format($total_amount, 2) }} {{ number_format($total_vat, 2) }} {{ number_format($sub_total, 2) }}
Sub Total @if ($booking_info->tax_type == 2) {{ number_format($total_amount, 2) }} @else{{ number_format($sub_total, 2) }} @endif
Tax {{ number_format($total_vat, 2) }}
Grand Total @if ($booking_info->tax_type == 2) {{ number_format($total_amount + $total_vat, 2) }} @else{{ number_format($sub_total + $total_vat, 2) }} @endif
{{-- Facility --}}
Facility
@if(!request()->without_bill) @endif @php $facility_amount=0; @endphp @forelse ($facility as $key=>$f) @if(!request()->without_bill) @endif @empty @endforelse @if(!request()->without_bill) @endif
Sl Date Facility Name QtyAmount Free/Cost Total Amount
{{ $key + 1 }} {{ date('d-m-Y h:i:sa', strtotime($f->created_at)) }} @if ($f->get_facility_name) {{ $f->get_facility_name->name_eng }} @endif {{ $f->qty }}{{ $f->amount }} @if ($f->facility_status == 2) Free @endif @if ($f->facility_status == 2) 0 @else {{ $f->qty * $f->amount }} @php $facility_amount+=$f->qty*$f->amount @endphp @endif
No Facility Found
Total Facility Amount {{ $facility_amount }}
{{-- For advance --}} @if(!request()->without_bill) @if (!$booking_info->checkin_code)
@php $resv_com_dis = 0; @endphp @php $resv_total_bill = $booking_info->tax_type == 2 ? $total_amount+$total_vat+$facility_amount : $sub_total+$total_vat+$facility_amount @endphp @if(!request()->without_comission) @php $resv_com_dis = $booking_info->discount; @endphp @endif @php // $advance_cal = $advance['adv_total']; $temp_adv_calculation = App\Models\Frontdesk\FdInvoiceDetails::where('reservation_id', $booking_info->id)->where('type',1)->where('voucher_type',1)->sum('amount'); $advance_cal = $temp_adv_calculation; @endphp @if(request()->without_comission) @php // $advance_cal = $advance['adv_total']+$booking_info->discount; $advance_cal = $temp_adv_calculation+$booking_info->discount; @endphp @endif
Total Bill @if ($booking_info->tax_type == 2) {{ number_format($total_amount + $total_vat + $facility_amount, 2) }} @else{{ number_format($sub_total + $total_vat + $facility_amount, 2) }} @endif
Discount/Commission {{ number_format($booking_info->discount, 2) }}
Advance {{ number_format($advance_cal, 2) }}
Total Due {{ number_format(($resv_total_bill - $advance_cal - $resv_com_dis), 2) }}
@endif @endif @if ($booking_info->checkin_code) {{-- when reservation charges section && receipt will not show --}} {{-- charges --}}
Charges
@if(!request()->without_bill) @endif @php $charges_amount = 0; @endphp @forelse ($charges as $key=>$charge) @if(!request()->without_bill) @endif @php $charges_amount+=$charge->amount; @endphp @empty @endforelse @if(!request()->without_bill) @endif
Sl Date Voucher DescriptionAmount
{{ $key + 1 }} {{ date('d-m-Y', strtotime($charge->created_at)) }} {{ $charge->fd_invoice->invoice_no }} {{ $charge->fd_invoice->note }} {{ number_format($charge->amount, 2) }}

No Charges Yet

Total Charges Amount {{ number_format($charges_amount, 2) }}
{{-- receipt --}} @if(!request()->without_bill)
@if(!request()->without_comission)
Receipt
@endif @if(!request()->without_comission) @endif @php $total_receive=0; @endphp @if(!request()->without_comission) @forelse ($receipt as $key=>$r) @php $total_receive+=$r->amount @endphp @empty @endforelse @endif @if(!request()->without_comission) @endif @if ($accounts_info['total_refund'] > 0) @endif
Sl Voucher Description Received Mode Received Date Amount
{{ $key + 1 }} {{ $r->fd_invoice->invoice_no }} {{ $r->note }} {{ $r->cash_bank->name_eng }} {{ date('d-m-Y', strtotime($r->date)) }} {{ number_format($r->amount, 2) }}
No Receive Found
Total Bill {{ number_format($accounts_info['total_bill'], 2) }}
Total Discount {{ number_format($accounts_info['total_discount'], 2) }}
Total Commission {{ number_format($accounts_info['total_commission'], 2) }}
Total Paid @if(!request()->without_comission) {{ number_format($total_receive, 2) }} @else {{ number_format(($receipt->sum('amount')+$accounts_info['total_commission']+$accounts_info['total_discount']), 2) }} @endif
Advance Adjust(-) {{ number_format($accounts_info['total_advance_deduct'], 2) }}
Total Refund {{ number_format($accounts_info['total_refund'], 2) }}
Due {{ number_format($accounts_info['total_due'] + $accounts_info['total_refund'], 2) }}
@endif @endif
@include('frontdesk.report.report_footer') @endsection