diff --git a/app/Http/Controllers/Customers/Payments.php b/app/Http/Controllers/Customers/Payments.php index c1b9c571b..f908a29e4 100644 --- a/app/Http/Controllers/Customers/Payments.php +++ b/app/Http/Controllers/Customers/Payments.php @@ -21,7 +21,7 @@ class Payments extends Controller */ public function index() { - $payments = Payment::with('account', 'category')->where('customer_id', '=', Auth::user()->customer->id)->paginate(); + $payments = Payment::with(['account', 'category'])->where('customer_id', '=', Auth::user()->customer->id)->paginate(); $payment_methods = Modules::getPaymentMethods(); diff --git a/resources/views/customers/dashboard/index.blade.php b/resources/views/customers/dashboard/index.blade.php index 677120ab2..35c82402b 100644 --- a/resources/views/customers/dashboard/index.blade.php +++ b/resources/views/customers/dashboard/index.blade.php @@ -18,29 +18,24 @@
@if ($user->invoices->count()) - +
- - - - - - + + + + + @foreach($user->invoices as $item) - - - - - - + + + + + @endforeach @@ -68,26 +63,22 @@
@if ($user->revenues->count()) -
{{ trans('invoices.invoice_number') }}{{ trans_choice('general.customers', 1) }}{{ trans('invoices.total_price') }}{{ trans_choice('general.statuses', 1) }}{{ trans('invoices.invoice_date') }}{{ trans('general.actions') }}{{ trans('invoices.invoice_number') }}{{ trans('general.amount') }}{{ trans('invoices.invoice_date') }}{{ trans('invoices.due_date') }}{{ trans_choice('general.statuses', 1) }}
{{ $item->invoice_number }}{{ $item->customer_name }}@money($item->amount, $item->currency_code, true){{ $item->status->name }}{{ Date::parse($item->invoiced_at)->format($date_format) }} - {{ trans('general.show') }} - {{ trans('general.edit') }} - {{ $item->invoice_number }}@money($item->amount, $item->currency_code, true){{ Date::parse($item->invoiced_at)->format($date_format) }}{{ Date::parse($item->due_at)->format($date_format) }}{{ $item->status->name }}
+
- @foreach($user->revenues as $item) - + - @endforeach diff --git a/resources/views/customers/invoices/index.blade.php b/resources/views/customers/invoices/index.blade.php index eee259836..5258e4941 100644 --- a/resources/views/customers/invoices/index.blade.php +++ b/resources/views/customers/invoices/index.blade.php @@ -11,16 +11,16 @@ @section('content')
-
+
{!! Form::open(['url' => 'customers/invoices', 'role' => 'form', 'method' => 'GET']) !!}
- {{ trans('general.search') }}: + {!! Form::text('search', request('search'), ['class' => 'form-control input-filter input-sm', 'placeholder' => trans('general.search_placeholder')]) !!} {!! Form::select('status', $status, request('status'), ['class' => 'form-control input-filter input-sm']) !!} {!! Form::button('  ' . trans('general.filter'), ['type' => 'submit', 'class' => 'btn btn-sm btn-default btn-filter']) !!}
- {{ trans('general.show') }}: + {!! Form::select('limit', $limits, request('limit', setting('general.list_limit', '25')), ['class' => 'form-control input-filter input-sm', 'onchange' => 'this.form.submit()']) !!}
{!! Form::close() !!} @@ -28,30 +28,24 @@
-
{{ trans('general.date') }} {{ trans('general.amount') }} {{ trans_choice('general.categories', 1) }} {{ trans_choice('general.accounts', 1) }}{{ trans('general.actions') }}
{{ Date::parse($item->paid_at)->format($date_format) }}{{ Date::parse($item->paid_at)->format($date_format) }} @money($item->amount, $item->currency_code, true) {{ $item->category->name }} {{ $item->account->name }} - {{ trans('general.show') }} -
+
- - - - - - - + + + + + @foreach($invoices as $item) - - - - - - - + + + + + @endforeach diff --git a/resources/views/customers/payments/index.blade.php b/resources/views/customers/payments/index.blade.php index e7be75f8a..2c503787b 100644 --- a/resources/views/customers/payments/index.blade.php +++ b/resources/views/customers/payments/index.blade.php @@ -11,17 +11,17 @@ @section('content')
-
+
{!! Form::open(['url' => 'customers/payments', 'role' => 'form', 'method' => 'GET']) !!}
- {{ trans('general.search') }}: + {!! Form::text('search', request('search'), ['class' => 'form-control input-filter input-sm', 'placeholder' => trans('general.search_placeholder')]) !!} {!! Form::select('category_id', $categories, request('category_id'), ['class' => 'form-control input-filter input-sm']) !!} {!! Form::select('payment_method', $payment_methods, request('payment_method'), ['class' => 'form-control input-filter input-sm']) !!} {!! Form::button('  ' . trans('general.filter'), ['type' => 'submit', 'class' => 'btn btn-sm btn-default btn-filter']) !!}
- {{ trans('general.show') }}: + {!! Form::select('limit', $limits, request('limit', setting('general.list_limit', '25')), ['class' => 'form-control input-filter input-sm', 'onchange' => 'this.form.submit()']) !!}
{!! Form::close() !!} @@ -29,26 +29,22 @@
-
@sortablelink('invoice_number', trans('invoices.invoice_number'))@sortablelink('customer_name', trans_choice('general.customers', 1))@sortablelink('amount', trans('invoices.total_price'))@sortablelink('status.name', trans_choice('general.statuses', 1))@sortablelink('invoiced_at', trans('invoices.invoice_date'))@sortablelink('due_at', trans('invoices.due_date')){{ trans('general.actions') }}@sortablelink('invoice_number', trans('invoices.invoice_number'))@sortablelink('amount', trans('general.amount'))@sortablelink('invoiced_at', trans('invoices.invoice_date'))@sortablelink('due_at', trans('invoices.due_date'))@sortablelink('status.name', trans_choice('general.statuses', 1))
{{ $item->invoice_number }}{{ $item->customer_name }}@money($item->amount, $item->currency_code, true){{ $item->status->name }}{{ Date::parse($item->invoiced_at)->format($date_format) }}{{ Date::parse($item->due_at)->format($date_format) }} - {{ trans('general.show') }} - {{ $item->invoice_number }}@money($item->amount, $item->currency_code, true){{ Date::parse($item->invoiced_at)->format($date_format) }}{{ Date::parse($item->due_at)->format($date_format) }}{{ $item->status->name }}
+
- @foreach($payments as $item) - + - @endforeach diff --git a/resources/views/customers/transactions/index.blade.php b/resources/views/customers/transactions/index.blade.php index 23ccd1b8f..66b4838b3 100644 --- a/resources/views/customers/transactions/index.blade.php +++ b/resources/views/customers/transactions/index.blade.php @@ -5,15 +5,15 @@ @section('content')
-
+
{!! Form::open(['url' => 'customers/transactions', 'role' => 'form', 'method' => 'GET']) !!}
- {{ trans('general.search') }}: + {!! Form::text('search', request('search'), ['class' => 'form-control input-filter input-sm', 'placeholder' => trans('general.search_placeholder')]) !!} {!! Form::button('  ' . trans('general.filter'), ['type' => 'submit', 'class' => 'btn btn-sm btn-default btn-filter']) !!}
- {{ trans('general.show') }}: + {!! Form::select('limit', $limits, request('limit', setting('general.list_limit', '25')), ['class' => 'form-control input-filter input-sm', 'onchange' => 'this.form.submit()']) !!}
{!! Form::close() !!} @@ -21,7 +21,7 @@
-
@sortablelink('paid_at', trans('general.date')) @sortablelink('amount', trans('general.amount')) @sortablelink('category.name', trans_choice('general.categories', 1)) @sortablelink('payment_method', trans_choice('general.payment_methods', 1)){{ trans('general.actions') }}
{{ Date::parse($item->paid_at)->format($date_format) }}{{ Date::parse($item->paid_at)->format($date_format) }} @money($item->amount, $item->currency_code, true) {{ $item->category->name }} {{ $payment_methods[$item->payment_method] }} - {{ trans('general.show') }} -
+
diff --git a/resources/views/partials/admin/header.blade.php b/resources/views/partials/admin/header.blade.php index cd5b6d6b6..83a3c7d66 100644 --- a/resources/views/partials/admin/header.blade.php +++ b/resources/views/partials/admin/header.blade.php @@ -173,7 +173,9 @@ @endif

+ @if (!empty($user->name)) {{ $user->name }} + @endif {{ trans('header.last_login', ['time' => $user->last_logged_in_at]) }}

diff --git a/resources/views/partials/customer/header.blade.php b/resources/views/partials/customer/header.blade.php index 8ff336e3d..d395aecec 100644 --- a/resources/views/partials/customer/header.blade.php +++ b/resources/views/partials/customer/header.blade.php @@ -2,9 +2,9 @@
@sortablelink('paid_at', trans('general.date'))