@extends('layouts.report_pdf') @section('title') {{__('Delegate')}}-{{$data['sample_collector']['name']}}-{{date('Y-m-d')}} @endsection @section('content')
{{-- --}} {{__('Delegate report')}} {{__('Delegate')}} : {{$data['sample_collector']['name']}}
{{__('Date')}} : {{date('Y-m-d H:i')}}
{{__('Date range')}} : {{date('Y-m-d H:i',strtotime($data['from']))}} - {{date('Y-m-d H:i',strtotime($data['to']))}}
@if(count($data['invoices'])&&request()->has('print.invoices')) @foreach($data['invoices'] as $invoice) @endforeach
{{__('Invoices')}}
# {{__('Date')}} {{__('Patient Name')}} {{__('Tests')}} {{__('Total')}} {{__('Commission')}} {{__('Paid')}} {{__('Due')}}
{{$invoice['id']}} {{date('d-m-Y H:i',strtotime($invoice['created_at']))}} @if(isset($invoice['patient'])) {{$invoice['patient']['name']}} @endif @foreach($invoice['tests'] as $test) @endforeach @foreach($invoice['cultures'] as $culture) @endforeach @foreach($invoice['packages'] as $package) @endforeach
{{$test['test']['name']}} {{format_money($test['price'])}}
{{$culture['culture']['name']}} {{format_money($culture['price'])}}
    @foreach($package['tests'] as $test)
  • {{$test['test']['name']}}
  • @endforeach @foreach($package['cultures'] as $culture)
  • {{$culture['culture']['name']}}
  • @endforeach
{{format_money($package['price'])}}
{{format_money($invoice['total_for_commission'])}} {{format_money($invoice['sample_collector_commission'])}} {{format_money($invoice['sample_collector_paid'])}} {{format_money($invoice['sample_collector_due'])}}
@endif @if(count($data['payouts'])&&request()->has('print.payouts')) @foreach($data['payouts'] as $payout) @endforeach
{{__('Payouts')}}
# {{__('Date')}} {{__('Amount')}} {{__('Payment method')}}
{{$payout['id']}} {{date('d-m-Y',strtotime($payout['date']))}} {{format_money($payout['amount'])}} @if(isset($payout['payment_method'])) {{$payout['payment_method']['name']}} @endif
@endif @if(count($data['tests_statistics'])&&request()->has('print.tests_statistics')) @foreach($data['tests_statistics'] as $test) @endforeach
{{__('Tests')}}
{{__('Name')}} {{__('Count')}} {{__('Total')}}
{{$test['test_name']}} {{format_money($test['count'])}} {{format_money($test['total'])}}
@endif @if(count($data['cultures_statistics'])&&request()->has('print.cultures_statistics')) @foreach($data['cultures_statistics'] as $culture) @endforeach
{{__('Cultures')}}
{{__('Name')}} {{__('Count')}} {{__('Total')}}
{{$culture['culture_name']}} {{format_money($culture['count'])}} {{format_money($culture['total'])}}
@endif @if(count($data['packages_statistics'])&&request()->has('print.packages_statistics')) @foreach($data['packages_statistics'] as $package) @endforeach
{{__('Packages')}}
{{__('Name')}} {{__('Count')}} {{__('Total')}}
{{$package['package_name']}} {{format_money($package['count'])}} {{format_money($package['total'])}}
@endif @if(request()->has('print.summary'))
{{__('Summary')}}
{{__('Total')}} {{format_money($data['total'])}}
{{__('Commission')}} {{format_money($data['commission'])}}
{{__('Paid')}} {{format_money($data['paid'])}}
{{__('Due')}} {{format_money($data['due'])}}
@endif @endsection