@if(isset($invoiceSettings->client_first_name))
@if( isset( $invoiceSettings ) && $invoiceSettings->logo == 1 ) @if( isset( $invoiceSettings->business_logo ) && $invoiceSettings->business_logo != "" && File::exists(public_path($invoiceSettings->business_logo))) @endif @elseif( isset( $invoiceSettings ) && $invoiceSettings->logo == 0 ) @else @if( isset($invoiceSettings->business_logo) && $invoiceSettings->business_logo != "" && File::exists(public_path($invoiceSettings->business_logo))) @endif @endif

{{$invoiceSettings->practitioner_first_name ?? ""}} {{$invoiceSettings->practitioner_last_name ?? ""}}

@if( isset( $invoiceSettings ) && $invoiceSettings->profession == 1 ) {{-- --}} @endif
@if( isset( $invoiceSettings ) && $invoiceSettings->practitioner_provider_number==1 ) @if($invoiceSettings->registartion_number)

Registration number: {{$invoiceSettings->registartion_number ?? ""}}

@endif @elseif( isset( $invoiceSettings ) && $invoiceSettings->practitioner_provider_number==0 ) @else @if($invoiceSettings->registartion_number)

Registration number: {{$invoiceSettings->registartion_number ?? ""}}

@endif @endif @if($display == 1 && isset($phf) && isset($chf))

{{$invoiceSettings->provider_name ?? ""}} {{$invoiceSettings->provider_number ?? ""}}

@endif @if($invoice->bill_to =='company' && $invoiceSettings->claim_bill_to == 1 && $invoiceSettings->claim_number !="" && $invoiceSettings->claim_number != NULL)

Claim no: {{$invoiceSettings->claim_number ?? ""}}

@endif
@if( !empty( $invoiceSettings->abn_number ) ) @endif
@php $title = 'Refund Note'; @endphp

{{$title}}

ABN: {{$invoiceSettings->abn_number?? ""}}

@if( isset($invoiceSettings) && $invoiceSettings->company_name==1 )

{{$invoiceSettings->business_name ?? ""}}

@elseif( isset($invoiceSettings) && $invoiceSettings->company_name==0 ) @else

{{$invoiceSettings->business_name ?? ""}}

@endif
@if( isset( $invoiceSettings ) && $invoiceSettings->is_replace_business_address == 1 )

{{ $invoiceSettings->address1 }}

@if(!empty($invoiceSettings->address2))

{{ $invoiceSettings->address2 }}

@endif

{{ $invoiceSettings->suburb.' '.$invoiceSettings->state.' '.$invoiceSettings->postcode }}

{{ $invoiceSettings->country }}

@elseif( isset( $invoiceSettings ) && $invoiceSettings->address == 1 )

{{ $invoiceSettings->business_address }}

@if(!empty($invoiceSettings->business_address_2))

{{ $invoiceSettings->business_address_2 }}

@endif

{{ $invoiceSettings->business_suburb.' '.$invoiceSettings->business_state.' '.$invoiceSettings->business_postcode }}

{{ $invoiceSettings->business_country }}

@endif
@if( isset($invoiceSettings) && $invoiceSettings->phone_number==1 )

{{$invoiceSettings->business_office_phone ?? ""}}

@elseif( isset($invoiceSettings) && $invoiceSettings->phone_number==0 ) @else

{{$invoiceSettings->business_office_phone ?? ""}}

@endif

@if( isset( $invoiceSettings ) && $invoiceSettings->email == 1 )

{{$invoiceSettings->business_email ?? ""}}

@elseif( isset( $invoiceSettings ) && $invoiceSettings->email == 0 ) @else

{{$invoiceSettings->business_email ?? ""}}

@endif

@if( isset( $invoiceSettings ) && $invoiceSettings->website == 1 )

{{$invoiceSettings->business_website ?? ""}}

@elseif( isset( $invoiceSettings ) && $invoiceSettings->website == 0 ) @else

{{$invoiceSettings->business_website ?? ""}}

@endif
@php $header_discount = 0; @endphp @if($pii) @foreach( $pii as $tid ) @php $header_discount += $tid->item_discount; @endphp @endforeach @endif @if($pip1) @foreach( $pip1 as $prod ) @php $header_discount += $prod->product_discount; @endphp @endforeach @endif @if($packagesData) @foreach( $packagesData as $package ) @php $header_discount += $package->package_discount; @endphp @endforeach @endif @if($courseData) @php $header_discount += $courseData->discount; @endphp @endif @if($invoiceSettings->claim_bill_to == 1 && $invoice->bill_to =='company') @endif

{{$invoiceSettings->client_first_name ?? ""}} {{$invoiceSettings->client_middle_name ?? ""}} {{$invoiceSettings->client_last_name ?? ""}}

@if( isset( $invoiceSettings ) && $invoiceSettings->client_name == 1 )

{{$invoiceSettings->client_email_text ?? ""}}

@elseif( isset( $invoiceSettings ) && $invoiceSettings->client_name == 0 ) @else

{{$invoiceSettings->client_email_text ?? ""}}

@endif
@if( isset( $invoiceSettings ) && $invoiceSettings->client_address == 1 )

{{ ucwords( $invoiceSettings->client_address1 ) ?? ""}}

{{ ucwords( $invoiceSettings->client_address2 ) ?? ""}}

{{ ucwords( $invoiceSettings->client_suburb ) ?? ""}} {{ ucwords( $invoiceSettings->client_city ) ?? ""}} {{ ucwords( $invoiceSettings->client_postcode ) ?? ""}}

{{ ucwords( $invoiceSettings->client_country ) ?? ""}}

@elseif( isset($invoiceSettings) && $invoiceSettings->client_address==0 ) @else

{{ ucwords( $client->address ) ?? ""}}

@endif
@if( isset( $invoiceSettings ) && $invoiceSettings->client_dob == 1 )

@if(isset($invoiceSettings->client_date_of_birth)) DOB: {{\Carbon\Carbon::parse($invoiceSettings->client_date_of_birth)->format('d/m/Y')}} @else {{""}} @endif

@elseif( isset( $invoiceSettings ) && $invoiceSettings->client_dob == 0 ) @else

@if(isset($invoiceSettings->client_date_of_birth)) DOB: {{\Carbon\Carbon::parse($invoiceSettings->client_date_of_birth)->format('d/m/Y')}} @else {{""}} @endif

@endif

Bill to:

{{ $invoiceSettings->claim_company_name ?? "" }}

{{ ucwords( $invoiceSettings->claim_owner_first_name) ?? ""}} {{ ucwords( $invoiceSettings->claim_owner_last_name) ?? ""}}

{{ $invoiceSettings->claim_owner_email ?? ""}}

Refund note: RN{{$invoice->credit_note->invoice_number ?? ""}}
Corresponding invoice: {{$invoice->invoice_number ?? ""}}
Invoice date: {{\Carbon\Carbon::parse($invoice->date)->format('d/m/y')}}
{{-- @if( isset($isDisplay) && ( count($pii) > 0 ) ) @if($isDisplay == 1) @else @endif @else @endif --}} @if($header_discount > 0) @endif {{-- @if( isset( $status ) && $status ) @endif --}} @php $total=0; $totals=0; $maintotal=0; $totalgst = 0; $totalgst1 = 0; $totalgstItem = 0; $totalgst1Item = 0; $appPrice=0; $productPrice=0; $gst_total1 = 0; $gst_total2 = 0; $gst_total3 = 0; $item_discount = 0; $gst = 0; @endphp @if( $pii ) @foreach( $pii as $tid ) @if( $tid->appointment_type ) @php $quantity = isset($tid->item_qty) ? $tid->item_qty : 1; $tid->app_cost = $tid->app_cost; $total += preg_replace("/[^0-9.]/", "", $tid->app_cost * $tid->item_qty ?? 0.00); $totals += preg_replace("/[^0-9.]/", "", $tid->app_cost * $tid->item_qty ?? 0.00); @endphp @if( $tid->is_gst == 'on' ) @php $totalgst += preg_replace("/[^0-9.]/", "", $tid->app_cost - $tid->item_discount ?? 0.00); @endphp {{-- GST FOR MULTIPLE QTY --}} @if( $tid->item_qty == 1 ) @php $appPrice= preg_replace("/[^0-9.]/", "", $tid->app_cost ?? 0.00); @endphp @else @php $appPrice= preg_replace("/[^0-9.]/", "", $tid->app_cost ?? 0.00)/ preg_replace("/[^0-9.]/", "", $tid->item_qty ?? 1); @endphp @endif @for( $i=1; $i<=$tid->item_qty; $i++ ) @php $totalgstItem += number_format((($appPrice - $tid->item_discount)/11),2); @endphp @endfor @else @endif @if($tid->item_discount > 0) @else @if($header_discount > 0) @endif @endif @if($tid->is_gst == "on") @php $gst_total1 += ($tid->app_cost * $quantity) - $tid->item_discount; $item_discount += $tid->item_discount; @endphp @else @php $item_discount += $tid->item_discount; @endphp @endif @endif @endforeach @endif @isset( $pip1 ) @foreach( $pip1 as $prod ) @if( $prod->product_iteams ) @php $total += preg_replace("/[^0-9.]/", "", $prod->product_cost * $prod->deduct_quantity); $totals += preg_replace("/[^0-9.]/", "", $prod->product_cost * $prod->deduct_quantity); @endphp @if( $prod->is_gst == 'on' ) @php $totalgst1 += preg_replace("/[^0-9.]/", "",$prod->product_cost - $prod->product_discount); @endphp {{-- GST FOR MULTIPLE QTY --}} @for( $i=1; $i<=$prod->deduct_quantity; $i++ ) @php $totalgst1Item += ( preg_replace("/[^0-9.]/", "",($prod->product_cost - $prod->product_discount))/11); @endphp @endfor @else @endif @if($prod->product_discount > 0) @else @if($header_discount > 0) @endif @endif @if($prod->is_gst == "on") @php $gst_total2 += ($prod->deduct_quantity * $prod->product_cost) - $prod->product_discount; $item_discount += $prod->product_discount; @endphp @else @php $item_discount += $prod->product_discount; @endphp @endif @endif @endforeach @endisset @if($packagesData) @foreach( $packagesData as $tid ) @if( $tid->package_id ) @php $quantity = isset($tid->package_quantity) ? $tid->package_quantity : 1; $tid->package_cost = $tid->package_cost; $total += preg_replace("/[^0-9.]/", "", $tid->package_cost * $tid->package_quantity ?? 0.00); $totals += preg_replace("/[^0-9.]/", "", $tid->package_cost * $tid->package_quantity ?? 0.00); @endphp @if( $tid->is_gst == 'on' ) @php $totalgst += preg_replace("/[^0-9.]/", "", $tid->package_cost - $tid->package_discount ?? 0.00); @endphp {{-- GST FOR MULTIPLE QTY --}} @if( $tid->package_quantity == 1 ) @php $appPrice= preg_replace("/[^0-9.]/", "", $tid->package_cost ?? 0.00); @endphp @else @php $appPrice= preg_replace("/[^0-9.]/", "", $tid->package_cost ?? 0.00)/ preg_replace("/[^0-9.]/", "", $tid->package_quantity ?? 1); @endphp @endif @for( $i=1; $i<=$tid->package_quantity; $i++ ) @php $totalgstItem += number_format((($appPrice - $tid->package_discount)/11),2); @endphp @endfor @else @endif @if($tid->package_discount > 0) @else @if($header_discount > 0) @endif @endif @if($tid->is_gst == "on") @php $gst_total1 += ($tid->package_cost * $quantity) - $tid->package_discount; $item_discount += $tid->package_discount; @endphp @else @php $item_discount += $tid->package_discount; @endphp @endif @endif @endforeach @endif @if($courseData) @if( $courseData->course_id ) @php $quantity = 1; $courseData->course_cost = $courseData->course_cost; $total += preg_replace("/[^0-9.]/", "", $courseData->course_cost ?? 0.00); $totals += preg_replace("/[^0-9.]/", "", $courseData->course_cost ?? 0.00); @endphp @if($courseData->is_new_takings_gst == 1) @php $totalgst += preg_replace("/[^0-9.]/", "", $courseData->course_cost - $courseData->discount ?? 0.00); $totalgstItem += number_format((($courseData->course_cost)/11),2); @endphp @else @endif @if($courseData->discount > 0) @else @if($header_discount > 0) @endif @endif @if($courseData->is_new_takings_gst == 1) @php $gst_total1 += $courseData->course_cost - $courseData->discount; $item_discount += $courseData->discount; @endphp @else @php $item_discount += $courseData->discount; @endphp @endif {{-- --}} @endif @endif {{-- @if(isset($invoice) && $invoice->course_id !=0) @if($invoice->is_new_takings_gst == 1) @php $gst_total2 += $invoice->total; @endphp @else @endif @php $total = $invoice->total; $totals = $total; @endphp @endif --}}
Description Code Code Code Cost Discount GST Price
{{ ucwords( $status ) ?? "" }} Appointment - ${{number_format( $charge, 2 ) ?? '0.00'}}
* {{$tid->services_name}} @if($quantity > 1) {{"x"}} {{ $quantity }}@endif{{$tid->services_name}} @if($quantity > 1) {{"x"}} {{ $quantity }}@endif{{$tid->code}} ${{number_format(preg_replace("/[^0-9.]/", "", $tid->app_cost ?? 0.00),2)}}${{number_format(preg_replace("/[^0-9.]/", "", $tid->item_discount ?? 0.00),2)}}10%FREE${{number_format(preg_replace("/[^0-9.]/", "", ($tid->app_cost * $quantity) - $tid->item_discount ?? 0.00),2)}}
* @if (strlen($prod->product_name) <=72) {{$prod->product_name}} {{"x"}} {{$prod->deduct_quantity}} @else {{ substr($prod->product_name, 0, 72) }}
{{ substr($prod->product_name, 72, strlen($prod->product_name)) }} {{"x"}} {{$prod->deduct_quantity}} @endif
{{-- {{$prod->product_name}} {{"x"}} {{$prod->deduct_quantity}} --}} @if (strlen($prod->product_name) <=72) {{$prod->product_name}} {{"x"}} {{$prod->deduct_quantity}} @else {{ substr($prod->product_name, 0, 72) }}
{{ substr($prod->product_name, 72, strlen($prod->product_name)) }} {{"x"}} {{$prod->deduct_quantity}} @endif
{{$prod->product_code}} ${{number_format($prod->product_cost,2)}} ${{number_format($prod->product_discount,2)}}10%FREE ${{number_format(($prod->deduct_quantity * $prod->product_cost) - $prod->product_discount,2)}}
* {{$tid->package->package_name}} @if($quantity > 1) {{"x"}} {{ $quantity }}@endif{{$tid->package->package_name}} @if($quantity > 1) {{"x"}} {{ $quantity }}@endif ${{number_format(preg_replace("/[^0-9.]/", "", $tid->package_cost ?? 0.00),2)}}${{number_format(preg_replace("/[^0-9.]/", "", $tid->package_discount ?? 0.00),2)}}10%FREE${{number_format(preg_replace("/[^0-9.]/", "", ($tid->package_cost * $quantity) - $tid->package_discount ?? 0.00),2)}}
* {{$courseData->course->course_name ?? ""}} {{$courseData->course->course_name ?? ""}} ${{number_format(preg_replace("/[^0-9.]/", "", $courseData->course_cost ?? 0.00),2)}}${{number_format(preg_replace("/[^0-9.]/", "", $courseData->discount ?? 0.00),2)}}10%FREE${{number_format(preg_replace("/[^0-9.]/", "", $courseData->course_cost ?? 0.00),2) ?? "0.00"}}${{number_format(preg_replace("/[^0-9.]/", "", ($courseData->course_cost) - $courseData->discount ?? 0.00),2)}}
Course purchased ${{number_format($invoice->total,2)}}10%FREE${{number_format($invoice->total,2)}}
@if( isset($invoice) && $invoice->shipping_cost != '' && $invoice->shipping_cost != '0.00' && $shipping_method == '') @if(isset($invoice) && $invoice->shipping_cost !='' && $shiping_cost == '') @php $$totals = $total; $total = $total + $invoice->shipping_cost; @endphp @endif @endif @if( isset( $shiping_cost ) && isset( $shipping_method ) && $shipping_method != '' ) @endif @if( $invoice->discount != '' && $invoice->discount != '0.00') @endif @if($credit_note_history) @foreach($credit_note_history as $hi) @endforeach @endif @if($invoice->credit_note->is_new_takings_gst == 1) @endif

@if($invoice->is_shipping_gst_on == 1)*@endif Shipping:

${{number_format( $invoice->shipping_cost, 2 ) ?? '0.00' }}

{{ $shipping_method ?? '' }}:

${{number_format( $shiping_cost, 2 ) ?? '0.00' }}

Total:

{{-- @if($charge)${{$charge ?? '0.0'}}@else --}} @php $shiping_cost = isset( $shiping_cost ) && $shiping_cost != '' ? number_format($shiping_cost, 2) : '0.00' @endphp ${{number_format($totals?? 0, 2)}} {{-- @endif --}}

Discount:

${{number_format( $invoice->discount, 2 ) ?? '0.00' }}

{{$hi->paymentType->name ?? ''}} refund {{$hi->created_at->format('d/m/y')}}:

-${{number_format($hi->paid_amount ,2) ?? '0.00'}}

GST adjustment:

-${{ number_format( $invoice->credit_note->gst_applied,2) }}

{{-- @if( $invoice->credit_note->notes != '' )

{!! nl2br(e($invoice->credit_note->notes)) !!}

@endif --}}
@else
@if( isset( $invoiceSettings ) && $invoiceSettings->logo == 1 ) @if( isset( $businessProfile->logo ) && $businessProfile->business_image!="") {{----}} @else @endif @elseif( isset( $invoiceSettings ) && $invoiceSettings->logo == 0 ) @else @if( isset( $businessProfile->logo ) && $businessProfile->business_image!="") @else @endif @endif

{{$invoice->practitioner->full_name ?? ""}}

{{-- @if( isset( $invoiceSettings ) && $invoiceSettings->profession == 1 && isset($invoiceSettings->professionData)) --}} @if( isset( $invoiceSettings ) && $invoiceSettings->profession == 1 ) @endif
@if( isset( $invoiceSettings ) && $invoiceSettings->practitioner_provider_number==1 ) @if($invoice->practitioner->registration_number)

Registration number: {{$invoice->practitioner->registration_number ?? ""}}

@endif @elseif( isset( $invoiceSettings ) && $invoiceSettings->practitioner_provider_number==0 ) @else @if($invoice->practitioner->registration_number)

Registration number: {{$invoice->practitioner->registration_number ?? ""}}

@endif @endif @if($display == 1 && isset($phf) && isset($chf))

{{$phf->healthcodes->name ?? ""}} {{$phf->provider_number ?? ""}}

@endif @if(isset($claim_details) && $invoice->bill_to =='company' && $claim_details->display_claim_details == 1 && $claim_details->claim_number !="")

Claim no: {{$claim_details->claim_number ?? ""}}

@endif
@if( !empty( $owner->bankDetail ) ) @endif
@php $title = 'Refund Note'; @endphp

{{$title}}

ABN: {{$owner->bankDetail->abn ?? ""}}

@if( isset($invoiceSettings) && $invoiceSettings->company_name==1 )

{{$businessProfile->name ?? ""}}

@elseif( isset($invoiceSettings) && $invoiceSettings->company_name==0 ) @else

{{$businessProfile->name ?? ""}}

@endif
@if( isset( $invoiceSettings ) && $invoiceSettings->is_replace_business_address == 1 )

{{ $invoiceSettings->address1 }}

@if(!empty($invoiceSettings->address2))

{{ $invoiceSettings->address2 }}

@endif

{{ $invoiceSettings->suburb.' '.$invoiceSettings->state.' '.$invoiceSettings->postcode }}

{{ $invoiceSettings->country }}

@elseif( isset( $invoiceSettings ) && $invoiceSettings->address == 1 ) @if( isset( $appointment_location ) && $appointment_location != '')

{!! $appointment_location->address ?? "" !!}

@elseif( isset( $invoice->invoicelocation ) == 1 )

{{$invoice->invoicelocation->address ?? ""}}

@if(!empty($invoice->invoicelocation->address2))

{{ $invoice->invoicelocation->address2 }}

@endif

{{ $invoice->invoicelocation->suburb.' '.$invoice->invoicelocation->state.' '.$invoice->invoicelocation->postcode }}

{{ $invoice->invoicelocation->country }}

@else

{{$businessProfile->address ?? ""}}

@endif @endif
@if( isset($invoiceSettings) && $invoiceSettings->phone_number==1 )

{{$businessProfile->office_phone ?? ""}}

@elseif( isset($invoiceSettings) && $invoiceSettings->phone_number==0 ) @else

{{$businessProfile->office_phone ?? ""}}

@endif

@if( isset( $invoiceSettings ) && $invoiceSettings->email == 1 )

{{$businessProfile->email ?? ""}}

@elseif( isset( $invoiceSettings ) && $invoiceSettings->email == 0 ) @else

{{$businessProfile->email ?? ""}}

@endif

@if( isset( $invoiceSettings ) && $invoiceSettings->website == 1 )

{{$businessProfile->website ?? ""}}

@elseif( isset( $invoiceSettings ) && $invoiceSettings->website == 0 ) @else

{{$businessProfile->website ?? ""}}

@endif
@php $header_discount = 0; @endphp @if($pii) @foreach( $pii as $tid ) @php $header_discount += $tid->item_discount; @endphp @endforeach @endif @if($pip1) @foreach( $pip1 as $prod ) @php $header_discount += $prod->product_discount; @endphp @endforeach @endif @if($packagesData) @foreach( $packagesData as $package ) @php $header_discount += $package->package_discount; @endphp @endforeach @endif @if($courseData) @php $header_discount += $courseData->discount; @endphp @endif @if(isset($claim_details) && $claim_details->display_claim_details == 1 && $invoice->bill_to =='company') @endif

{{$client->full_name ?? ""}}

@if( isset( $invoiceSettings ) && $invoiceSettings->client_name == 1 )

{{$client->email ?? ""}}

@elseif( isset( $invoiceSettings ) && $invoiceSettings->client_name == 0 ) @else

{{$client->email ?? ""}}

@endif
@if( isset( $invoiceSettings ) && $invoiceSettings->client_address == 1 )

{{ ucwords( $client->address ) ?? ""}}

{{ ucwords( $client->address2 ) ?? ""}}

{{ ucwords( $client->suburb_state_postcode ) ?? ""}}

{{ ucwords( $client->country ) ?? ""}}

@elseif( isset($invoiceSettings) && $invoiceSettings->client_address==0 ) @else

{{ ucwords( $client->address ) ?? ""}}

@endif
@if( isset( $invoiceSettings ) && $invoiceSettings->client_dob == 1 )

@if(isset($client->date_of_birth)) DOB: {{$client->date_of_birth->format('d/m/Y')}} @else {{""}} @endif

@elseif( isset( $invoiceSettings ) && $invoiceSettings->client_dob == 0 ) @else

@if(isset($client->date_of_birth)) DOB: {{$client->date_of_birth->format('d/m/Y')}} @else {{""}} @endif

@endif

Bill to:

{{$claim_details->company_name ?? ""}}

{{$claim_details->owner_first_name ?? ""}} {{$claim_details->owner_last_name ?? ""}}

{{$claim_details->owner_email ?? ""}}

Refund note: RN{{$invoice->credit_note->invoice_number ?? ""}}
Corresponding invoice: {{$invoice->invoice_number ?? ""}}
Invoice date: {{\Carbon\Carbon::parse($invoice->date)->format('d/m/y')}}
@if($header_discount > 0) @endif @php $total=0; $totals=0; $maintotal=0; $totalgst = 0; $totalgst1 = 0; $totalgstItem = 0; $totalgst1Item = 0; $appPrice=0; $productPrice=0; $gst_total1 = 0; $gst_total2 = 0; $gst_total3 = 0; $item_discount = 0; $gst = 0; @endphp @if( $pii ) @foreach( $pii as $tid ) @if( $tid->appointment_type ) @php $quantity = isset($tid->item_qty) ? $tid->item_qty : 1; $tid->app_cost = $tid->app_cost; $total += preg_replace("/[^0-9.]/", "", $tid->app_cost * $tid->item_qty ?? 0.00); $totals += preg_replace("/[^0-9.]/", "", $tid->app_cost * $tid->item_qty ?? 0.00); @endphp @if( $tid->appointment_type->is_gst == 'on' ) @php $totalgst += preg_replace("/[^0-9.]/", "", $tid->app_cost - $tid->item_discount ?? 0.00); @endphp {{-- GST FOR MULTIPLE QTY --}} @if( $tid->item_qty == 1 ) @php $appPrice= preg_replace("/[^0-9.]/", "", $tid->app_cost ?? 0.00); @endphp @else @php $appPrice= preg_replace("/[^0-9.]/", "", $tid->app_cost ?? 0.00)/ preg_replace("/[^0-9.]/", "", $tid->item_qty ?? 1); @endphp @endif @for( $i=1; $i<=$tid->item_qty; $i++ ) @php $totalgstItem += number_format((($appPrice - $tid->item_discount)/11),2); @endphp @endfor @else @endif @if($tid->item_discount > 0) @else @if($header_discount > 0) @endif @endif @if($tid->appointment_type->is_gst == "on") @php $gst_total1 += ($tid->app_cost * $quantity) - $tid->item_discount; $item_discount += $tid->item_discount; @endphp @else @php $item_discount += $tid->item_discount; @endphp @endif @endif @endforeach @endif @isset( $pip1 ) @foreach( $pip1 as $prod ) @if( $prod->product_iteams ) @php $total += preg_replace("/[^0-9.]/", "", $prod->product_cost * $prod->deduct_quantity); $totals += preg_replace("/[^0-9.]/", "", $prod->product_cost * $prod->deduct_quantity); @endphp @if( $prod->product_iteams->is_gst == 'on' ) @php $totalgst1 += preg_replace("/[^0-9.]/", "",$prod->product_cost - $prod->product_discount); @endphp {{-- GST FOR MULTIPLE QTY --}} @for( $i=1; $i<=$prod->deduct_quantity; $i++ ) @php $totalgst1Item += ( preg_replace("/[^0-9.]/", "",($prod->product_cost - $prod->product_discount))/11); @endphp @endfor @else @endif @if($prod->product_discount > 0) @else @if($header_discount > 0) @endif @endif @if($prod->product_iteams->is_gst == "on") @php $gst_total2 += ($prod->deduct_quantity * $prod->product_cost) - $prod->product_discount; $item_discount += $prod->product_discount; @endphp @else @php $item_discount += $prod->product_discount; @endphp @endif @endif @endforeach @endisset @if($packagesData) @foreach( $packagesData as $tid ) @if( $tid->package_id ) @php $quantity = isset($tid->package_quantity) ? $tid->package_quantity : 1; $tid->package_cost = $tid->package_cost; $total += preg_replace("/[^0-9.]/", "", $tid->package_cost * $tid->package_quantity ?? 0.00); $totals += preg_replace("/[^0-9.]/", "", $tid->package_cost * $tid->package_quantity ?? 0.00); @endphp @if( $tid->is_gst == 'on' ) @php $totalgst += preg_replace("/[^0-9.]/", "", $tid->package_cost - $tid->package_discount ?? 0.00); @endphp {{-- GST FOR MULTIPLE QTY --}} @if( $tid->package_quantity == 1 ) @php $appPrice= preg_replace("/[^0-9.]/", "", $tid->package_cost ?? 0.00); @endphp @else @php $appPrice= preg_replace("/[^0-9.]/", "", $tid->package_cost ?? 0.00)/ preg_replace("/[^0-9.]/", "", $tid->package_quantity ?? 1); @endphp @endif @for( $i=1; $i<=$tid->package_quantity; $i++ ) @php $totalgstItem += number_format((($appPrice - $tid->package_discount)/11),2); @endphp @endfor @else @endif @if($tid->package_discount > 0) @else @if($header_discount > 0) @endif @endif @if($tid->is_gst == "on") @php $gst_total1 += ($tid->package_cost * $quantity) - $tid->package_discount; $item_discount += $tid->package_discount; @endphp @else @php $item_discount += $tid->package_discount; @endphp @endif @endif @endforeach @endif @if($courseData) @if( $courseData->course_id ) @php $quantity = 1; $courseData->course_cost = $courseData->course_cost; $total += preg_replace("/[^0-9.]/", "", $courseData->course_cost ?? 0.00); $totals += preg_replace("/[^0-9.]/", "", $courseData->course_cost ?? 0.00); @endphp @if($courseData->is_new_takings_gst == 1) @php $totalgst += preg_replace("/[^0-9.]/", "", $courseData->course_cost - $courseData->discount ?? 0.00); $totalgstItem += number_format((($courseData->course_cost)/11),2); @endphp @else @endif @if($courseData->discount > 0) @else @if($header_discount > 0) @endif @endif @if($courseData->is_new_takings_gst == 1) @php $gst_total1 += $courseData->course_cost - $courseData->discount; $item_discount += $courseData->discount; @endphp @else @php $item_discount += $courseData->discount; @endphp @endif @endif @endif
Description Code Cost Discount GST Price
* {{$tid->appointment_type->appointment_type}} @if($quantity > 1) {{"x"}} {{ $quantity }}@endif{{$tid->appointment_type->appointment_type}} @if($quantity > 1) {{"x"}} {{ $quantity }}@endif{{$tid->appointment_type->code}} ${{number_format(preg_replace("/[^0-9.]/", "", $tid->app_cost ?? 0.00),2)}}${{number_format(preg_replace("/[^0-9.]/", "", $tid->item_discount ?? 0.00),2)}}10%FREE${{number_format(preg_replace("/[^0-9.]/", "", ($tid->app_cost * $quantity) - $tid->item_discount ?? 0.00),2)}}
* @if (strlen($prod->product_iteams->product_name) <=72) {{$prod->product_iteams->product_name}} {{"x"}} {{$prod->deduct_quantity}} @else {{ substr($prod->product_iteams->product_name, 0, 72) }}
{{ substr($prod->product_iteams->product_name, 72, strlen($prod->product_iteams->product_name)) }} {{"x"}} {{$prod->deduct_quantity}} @endif
{{-- {{$prod->product_iteams->product_name}} {{"x"}} {{$prod->deduct_quantity}} --}} @if (strlen($prod->product_iteams->product_name) <=72) {{$prod->product_iteams->product_name}} {{"x"}} {{$prod->deduct_quantity}} @else {{ substr($prod->product_iteams->product_name, 0, 72) }}
{{ substr($prod->product_iteams->product_name, 72, strlen($prod->product_iteams->product_name)) }} {{"x"}} {{$prod->deduct_quantity}} @endif
{{$prod->product_iteams->product_code}} ${{number_format($prod->product_cost,2)}} ${{number_format($prod->product_discount,2)}}10%FREE ${{number_format(($prod->deduct_quantity * $prod->product_cost) - $prod->product_discount,2)}}
* {{$tid->package->package_name}} @if($quantity > 1) {{"x"}} {{ $quantity }}@endif{{$tid->package->package_name}} @if($quantity > 1) {{"x"}} {{ $quantity }}@endif ${{number_format(preg_replace("/[^0-9.]/", "", $tid->package_cost ?? 0.00),2)}}${{number_format(preg_replace("/[^0-9.]/", "", $tid->package_discount ?? 0.00),2)}}10%FREE${{number_format(preg_replace("/[^0-9.]/", "", ($tid->package_cost * $quantity) - $tid->package_discount ?? 0.00),2)}}
* {{$courseData->course->course_name ?? ""}} {{$courseData->course->course_name ?? ""}} ${{number_format(preg_replace("/[^0-9.]/", "", $courseData->course_cost ?? 0.00),2)}}${{number_format(preg_replace("/[^0-9.]/", "", $courseData->discount ?? 0.00),2)}}10%FREE${{number_format(preg_replace("/[^0-9.]/", "", ($courseData->course_cost) - $courseData->discount ?? 0.00),2)}}
@if( isset($invoice) && $invoice->shipping_cost != '' && $invoice->shipping_cost != '0.00' && $shipping_method == '') @if(isset($invoice) && $invoice->shipping_cost !='' && $shiping_cost == '') @php $$totals = $total; $total = $total + $invoice->shipping_cost; @endphp @endif @endif @if( isset( $shiping_cost ) && isset( $shipping_method ) && $shipping_method != '' ) @endif @if( $invoice->discount != '' && $invoice->discount != '0.00') @endif @if($credit_note_history) @foreach($credit_note_history as $hi) @endforeach @endif @if($invoice->credit_note->is_new_takings_gst == 1) @endif

@if($invoice->is_shipping_gst_on == 1)*@endif Shipping:

${{number_format( $invoice->shipping_cost, 2 ) ?? '0.00' }}

{{ $shipping_method ?? '' }}:

${{number_format( $shiping_cost, 2 ) ?? '0.00' }}

Total:

{{-- @if($charge)${{$charge ?? '0.0'}}@else --}} @php $shiping_cost = isset( $shiping_cost ) && $shiping_cost != '' ? number_format($shiping_cost, 2) : '0.00' @endphp ${{number_format($totals?? 0, 2)}} {{-- @endif --}}

Discount:

${{number_format( $invoice->discount, 2 ) ?? '0.00' }}

{{$hi->paymentType->name ?? ''}} refund {{$hi->created_at->format('d/m/y')}}:

-${{number_format($hi->paid_amount ,2) ?? '0.00'}}

GST adjustment:

-${{ number_format( $invoice->credit_note->gst_applied,2) }}

{{-- @if( $invoice->credit_note->notes != '' )

{!! nl2br(e($invoice->credit_note->notes)) !!}

@endif --}}
@endif