@use(Carbon\CarbonInterface) @use(App\Models\Invoice) @php($c=$o->product)
This Plan | @if($p->exists) | Proposed Plan | @endif | ||||||
---|---|---|---|---|---|---|---|---|---|
Client | Supplier | @if($p->exists) | Client | Supplier | @endif | ||||
Product | #{{ $o->product_id }}: {{ $o->product->name }} | #{{ $c->supplied->id }}: {{ $c->supplied->name_long }} | {{ $c->category_name }} | @if($p->exists)#{{ $p->id }}: {{ $p->name }} | #{{ $p->supplied->id }}: {{ $p->supplied->name_long }} | @endif | |||
Setup | ${{ number_format($b=$o->account->taxed($c->setup_charge),2) }} | ${{ number_format($a=$o->account->taxed($c->setup_cost),2) }} | {!! markup($a,$b) !!} | @if($p->exists)${{ number_format($b=$o->account->taxed($p->setup_charge),2) }} | ${{ number_format($a=$o->account->taxed($p->setup_cost),2) }} | {!! markup($a,$b) !!} | @endif|||
Billed | {{ $o->billing_interval_name }} | {{ $c->type->billing_interval_string }} | @if($p->exists) | {{ $o->billing_interval_name }} | {{ $p->type->billing_interval_string }} | @endif | |||
Billing Price | $o->is_charge_overridden])>${{ number_format($b=$o->billing_charge_taxed,2) }} | $o->is_cost_overridden])>${{ number_format($a=$o->billing_cost_taxed,2) }} | {!! markup($a,$b) !!} | @if($p->exists)is_charge_overridden)class="text-danger"@endif>${{ number_format($b=$o->account->taxed($p->base_charge),2) }} | ${{ number_format($a=$o->account->taxed($p->base_cost),2) }} | {!! markup($a,$b) !!} | @endif|||
Monthly Price | $o->is_charge_overridden])> @if($o->is_charge_overridden) ${{ number_format($b=$o->billing_charge_normalised_taxed,2) }} @else ${{ number_format($b=$o->billing_charge_normalised_taxed,2) }} @endif | $o->is_cost_overridden])> @if($o->is_cost_overridden) ${{ number_format($a=$o->billing_cost_normalised_taxed,2) }} @else ${{ number_format($a=$o->billing_cost_normalised_taxed,2) }} @endif | {!! markup($a,$b) !!} | @if($p->exists)$o->is_charge_overridden])>${{ number_format($b=$o->account->taxed($p->base_charge)*Invoice::billing_change($o->billing_interval,Invoice::BILL_MONTHLY),2) }} | $o->is_cost_overridden])>${{ number_format($a=$o->account->taxed($p->base_cost)*Invoice::billing_change($o->billing_interval,Invoice::BILL_MONTHLY),2) }} | {!! markup($a,$b) !!} | @endif|||
Contract | {{ $o->contract_term }} months | {{ $c->supplied->contract_term }} months | @if($p->exists) | {{ $p->contract_term }} months | {{ $p->supplied->contract_term }} months | @endif | |||
Min Price | ${{ number_format($b=$o->account->taxed($o->product->min_charge),2) }} | ${{ number_format($a=$o->account->taxed($c->supplied->min_cost),2) }} | {!! markup($a,$b) !!} | @if($p->exists)${{ number_format($a=$o->account->taxed($p->min_charge),2) }} | ${{ number_format($a=$o->account->taxed($p->supplied->min_cost ?? 0),2) }} | {!! markup($a,$b) !!} | @endif|||
Contract Left | @if($o->is_contracted)${{ number_format($o->billing_charge_to($o->contract_end),2) }} ({{ $o->paid_to?->format('Y-m-d') }}) | ${{ number_format($o->billing_cost_to($o->contract_end),2) }} ({{ $o->invoiced_to?->format('Y-m-d') }}) | {{ $o->contract_end->format('Y-m-d') }} ({{ $o->contract_end->diffForHumans(now(),CarbonInterface::DIFF_RELATIVE_TO_OTHER,FALSE,2) }} today) |
@else
Not on contract | @endif @if($p->exists) | @endif |