@extends('backend.layouts.user') @section('page-title', trans('app.shops')) @section('page-heading', trans('app.shops')) @section('content')
@include('backend.partials.messages')
@lang('app.shops')
@lang('app.filter')
@php $orders = array_combine(array_merge([''], \VanguardLTE\Shop::$values['orderby']), array_merge([''], \VanguardLTE\Shop::$values['orderby'])); @endphp {!! Form::select('order', $orders, Request::get('status'), ['id' => 'order', 'class' => 'form-control']) !!}
@php $currencies = array_combine(\VanguardLTE\Shop::$values['currency'], \VanguardLTE\Shop::$values['currency']); @endphp {!! Form::select('currency', $currencies, Request::get('currency'), ['id' => 'currency', 'class' => 'form-control']) !!}
{!! Form::select('categories[]', $categories->pluck('title','id'), Request::get('categories'), ['id' => 'type', 'class' => 'form-control select2', 'multiple' => true, 'style' => 'width: 100%;']) !!}
{!! Form::select('status', ['' => __('app.all'), '1' => __('app.active'), '0' => __('app.disabled')], Request::get('status'), ['id' => 'type', 'class' => 'form-control']) !!}
@if(auth()->user()->hasRole('admin'))
{!! Form::select('users', ['' => '---'] + $agents + $distributors, Request::get('users'), ['id' => 'users', 'class' => 'form-control select2']) !!}
@endif @if(auth()->user()->hasRole(['agent']))
{!! Form::select('users', ['' => '---'] + $distributors, Request::get('users'), ['id' => 'users', 'class' => 'form-control select2']) !!}
@endif
@if (count($shops)) @foreach ($shops as $shop) @include('backend.shops.partials.row-distributor') @endforeach @else @endif {{ $shops->links() }}
{{ number_format( $stats['credit'], 2 ) }}
@lang('app.total_credit')
{{ $stats['shops'] }}
@lang('app.total_shops')
@if(auth()->user()->hasRole('admin'))
{{ ($stats['agents']) }}
@lang('app.total_agents')
@endif @if(auth()->user()->hasRole(['admin','agent']))
{{ ($stats['distributors']) }}
@lang('app.total_distributors')
@endif @if(auth()->user()->hasRole(['agent','distributor']))
{{ ($stats['managers']) }}
@lang('app.total_managers')
@endif @if(auth()->user()->hasRole(['distributor','manager']))
{{ ($stats['cashiers']) }}
@lang('app.total_cashiers')
@endif @if(auth()->user()->hasRole(['manager','cashier']))
{{ ($stats['users']) }}
@lang('app.total_users')
@endif
@stop @section('scripts') @stop