sarga/packages/Webkul/Admin/src/Resources/views/sales/invoices/view.blade.php

259 lines
12 KiB
PHP
Raw Normal View History

2020-08-31 12:56:24 +00:00
@extends('admin::layouts.master')
@section('page_title')
{{ __('admin::app.sales.invoices.view-title', ['invoice_id' => $invoice->id]) }}
@stop
2020-08-31 12:56:24 +00:00
@section('content-wrapper')
2018-10-17 07:21:47 +00:00
<?php $order = $invoice->order; ?>
<div class="content full-page">
<div class="page-header">
<div class="page-title">
2019-01-29 10:35:43 +00:00
<h1>
{!! view_render_event('sales.invoice.title.before', ['order' => $order]) !!}
2021-02-12 15:26:21 +00:00
<i class="icon angle-left-icon back-link" onclick="window.location = '{{ route('admin.sales.invoices.index') }}'"></i>
2020-08-31 12:56:24 +00:00
2019-01-29 10:35:43 +00:00
{{ __('admin::app.sales.invoices.view-title', ['invoice_id' => $invoice->id]) }}
{!! view_render_event('sales.invoice.title.after', ['order' => $order]) !!}
2019-01-29 10:35:43 +00:00
</h1>
</div>
<div class="page-action">
{!! view_render_event('sales.invoice.page_action.before', ['order' => $order]) !!}
<a href="{{ route('admin.sales.invoices.print', $invoice->id) }}" class="btn btn-lg btn-primary">
{{ __('admin::app.sales.invoices.print') }}
</a>
{!! view_render_event('sales.invoice.page_action.after', ['order' => $order]) !!}
</div>
</div>
<div class="page-content">
<div class="sale-container">
<accordian :title="'{{ __('admin::app.sales.orders.order-and-account') }}'" :active="true">
2020-08-31 12:56:24 +00:00
<div slot="body">
<div class="sale-section">
<div class="secton-title">
<span>{{ __('admin::app.sales.orders.order-info') }}</span>
</div>
<div class="section-content">
<div class="row">
2020-08-31 12:56:24 +00:00
<span class="title">
{{ __('admin::app.sales.invoices.order-id') }}
</span>
<span class="value">
2019-09-11 12:04:11 +00:00
<a href="{{ route('admin.sales.orders.view', $order->id) }}">#{{ $order->increment_id }}</a>
</span>
</div>
{!! view_render_event('sales.invoice.increment_id.after', ['order' => $order]) !!}
<div class="row">
2020-08-31 12:56:24 +00:00
<span class="title">
{{ __('admin::app.sales.orders.order-date') }}
</span>
<span class="value">
{{ $order->created_at }}
</span>
</div>
{!! view_render_event('sales.invoice.created_at.after', ['order' => $order]) !!}
<div class="row">
2020-08-31 12:56:24 +00:00
<span class="title">
{{ __('admin::app.sales.orders.order-status') }}
</span>
<span class="value">
{{ $order->status_label }}
</span>
</div>
{!! view_render_event('sales.invoice.status_label.after', ['order' => $order]) !!}
<div class="row">
2020-08-31 12:56:24 +00:00
<span class="title">
{{ __('admin::app.sales.orders.channel') }}
</span>
2020-07-29 12:31:59 +00:00
2020-08-31 12:56:24 +00:00
<span class="value">
{{ $order->channel_name }}
</span>
2020-07-29 12:31:59 +00:00
</div>
2020-08-31 12:56:24 +00:00
{!! view_render_event('sales.invoice.channel_name.after', ['order' => $order]) !!}
</div>
</div>
2020-08-31 12:56:24 +00:00
<div class="sale-section">
<div class="secton-title">
<span>{{ __('admin::app.sales.orders.account-info') }}</span>
</div>
<div class="section-content">
<div class="row">
2020-07-27 15:07:19 +00:00
<span class="title">{{ __('admin::app.sales.orders.customer-name') }}</span>
2020-08-11 15:01:38 +00:00
<span class="value">{{ $invoice->order->customer_full_name }}</span>
</div>
{!! view_render_event('sales.invoice.customer_name.after', ['order' => $order]) !!}
<div class="row">
2020-07-27 15:07:19 +00:00
<span class="title">{{ __('admin::app.sales.orders.email') }}</span>
2020-08-11 15:01:38 +00:00
<span class="value">{{ $invoice->order->customer_email }}</span>
</div>
{!! view_render_event('sales.invoice.customer_email.after', ['order' => $order]) !!}
</div>
</div>
</div>
</accordian>
2020-08-11 15:01:38 +00:00
@if ($order->billing_address || $order->shipping_address)
<accordian :title="'{{ __('admin::app.sales.orders.address') }}'" :active="true">
<div slot="body" style="display: flex; overflow:auto;">
2020-08-11 15:01:38 +00:00
@if ($order->billing_address)
<div class="sale-section">
<div class="secton-title" style="width: 380px;">
<span>{{ __('admin::app.sales.orders.billing-address') }}</span>
</div>
2020-08-11 15:01:38 +00:00
<div class="section-content" style="width: 380px;">
@include ('admin::sales.address', ['address' => $order->billing_address])
2020-08-11 15:01:38 +00:00
{!! view_render_event('sales.invoice.billing_address.after', ['order' => $order]) !!}
</div>
</div>
2020-08-11 15:01:38 +00:00
@endif
2020-08-11 15:01:38 +00:00
@if ($order->shipping_address)
<div class="sale-section" style="margin: 0 0 0 300px;">
<div class="secton-title" style="width: 400px;">
<span>{{ __('admin::app.sales.orders.shipping-address') }}</span>
</div>
2018-12-20 08:07:03 +00:00
2020-08-11 15:01:38 +00:00
<div class="section-content" style="width: 400px;">
@include ('admin::sales.address', ['address' => $order->shipping_address])
{!! view_render_event('sales.invoice.shipping_address.after', ['order' => $order]) !!}
</div>
</div>
2020-08-11 15:01:38 +00:00
@endif
</div>
</accordian>
@endif
<accordian :title="'{{ __('admin::app.sales.orders.products-ordered') }}'" :active="true">
<div slot="body">
<div class="table">
<table>
<thead>
<tr>
<th>{{ __('admin::app.sales.orders.SKU') }}</th>
<th>{{ __('admin::app.sales.orders.product-name') }}</th>
<th>{{ __('admin::app.sales.orders.price') }}</th>
<th>{{ __('admin::app.sales.orders.qty') }}</th>
<th>{{ __('admin::app.sales.orders.subtotal') }}</th>
<th>{{ __('admin::app.sales.orders.tax-amount') }}</th>
@if ($invoice->base_discount_amount > 0)
<th>{{ __('admin::app.sales.orders.discount-amount') }}</th>
@endif
<th>{{ __('admin::app.sales.orders.grand-total') }}</th>
</tr>
</thead>
<tbody>
@foreach ($invoice->items as $item)
<tr>
2019-08-19 09:30:24 +00:00
<td>{{ $item->getTypeInstance()->getOrderedItem($item)->sku }}</td>
2020-08-31 12:56:24 +00:00
<td>
{{ $item->name }}
2019-08-19 09:30:24 +00:00
@if (isset($item->additional['attributes']))
<div class="item-options">
2019-08-19 09:30:24 +00:00
@foreach ($item->additional['attributes'] as $attribute)
<b>{{ $attribute['attribute_name'] }} : </b>{{ $attribute['option_label'] }}</br>
2019-08-19 09:30:24 +00:00
@endforeach
2020-08-31 12:56:24 +00:00
2019-08-19 09:30:24 +00:00
</div>
2018-10-26 04:20:43 +00:00
@endif
</td>
<td>{{ core()->formatBasePrice($item->base_price) }}</td>
2020-08-31 12:56:24 +00:00
<td>{{ $item->qty }}</td>
2020-08-31 12:56:24 +00:00
<td>{{ core()->formatBasePrice($item->base_total) }}</td>
2020-08-31 12:56:24 +00:00
<td>{{ core()->formatBasePrice($item->base_tax_amount) }}</td>
2020-08-31 12:56:24 +00:00
@if ($invoice->base_discount_amount > 0)
<td>{{ core()->formatBasePrice($item->base_discount_amount) }}</td>
@endif
2019-09-09 10:03:05 +00:00
<td>{{ core()->formatBasePrice($item->base_total + $item->base_tax_amount - $item->base_discount_amount) }}</td>
</tr>
@endforeach
2020-08-31 12:56:24 +00:00
</tbody>
</table>
</div>
<table class="sale-summary">
<tr>
<td>{{ __('admin::app.sales.orders.subtotal') }}</td>
<td>-</td>
<td>{{ core()->formatBasePrice($invoice->base_sub_total) }}</td>
</tr>
<tr>
<td>{{ __('admin::app.sales.orders.shipping-handling') }}</td>
<td>-</td>
<td>{{ core()->formatBasePrice($invoice->base_shipping_amount) }}</td>
</tr>
<tr>
<td>{{ __('admin::app.sales.orders.tax') }}</td>
<td>-</td>
<td>{{ core()->formatBasePrice($invoice->base_tax_amount) }}</td>
</tr>
@if ($invoice->base_discount_amount > 0)
<tr>
<td>{{ __('admin::app.sales.orders.discount') }}</td>
<td>-</td>
2019-09-11 14:40:59 +00:00
<td>{{ core()->formatBasePrice($invoice->base_discount_amount) }}</td>
</tr>
@endif
<tr class="bold">
<td>{{ __('admin::app.sales.orders.grand-total') }}</td>
<td>-</td>
<td>{{ core()->formatBasePrice($invoice->base_grand_total) }}</td>
</tr>
2020-07-27 15:07:19 +00:00
</table>
2020-08-31 12:56:24 +00:00
</div>
</accordian>
2020-07-27 15:07:19 +00:00
</div>
</div>
2020-08-31 12:56:24 +00:00
</div>
@stop