From b144efbe966eec2cc264f2fb7987d517678f7f60 Mon Sep 17 00:00:00 2001 From: Daniel Supernault Date: Sun, 20 May 2018 15:50:11 -0600 Subject: [PATCH] Add basic admin dashboard views --- resources/views/admin/media/home.blade.php | 24 ++++++++ .../views/admin/partial/sidebar.blade.php | 37 +++++++++++++ .../views/admin/partial/template.blade.php | 25 +++++++++ resources/views/admin/statuses/home.blade.php | 55 +++++++++++++++++++ resources/views/admin/statuses/show.blade.php | 36 ++++++++++++ resources/views/admin/users/home.blade.php | 55 +++++++++++++++++++ 6 files changed, 232 insertions(+) create mode 100644 resources/views/admin/media/home.blade.php create mode 100644 resources/views/admin/partial/sidebar.blade.php create mode 100644 resources/views/admin/partial/template.blade.php create mode 100644 resources/views/admin/statuses/home.blade.php create mode 100644 resources/views/admin/statuses/show.blade.php create mode 100644 resources/views/admin/users/home.blade.php diff --git a/resources/views/admin/media/home.blade.php b/resources/views/admin/media/home.blade.php new file mode 100644 index 000000000..bb1d1dcc2 --- /dev/null +++ b/resources/views/admin/media/home.blade.php @@ -0,0 +1,24 @@ +@extends('admin.partial.template') + +@section('section') +
+

Media

+
+ +
+ +
+ @foreach($media as $status) +
+ + + +
+ @endforeach +
+ +
+
+ {{$media->links()}} +
+@endsection \ No newline at end of file diff --git a/resources/views/admin/partial/sidebar.blade.php b/resources/views/admin/partial/sidebar.blade.php new file mode 100644 index 000000000..12440a510 --- /dev/null +++ b/resources/views/admin/partial/sidebar.blade.php @@ -0,0 +1,37 @@ +
+ +
\ No newline at end of file diff --git a/resources/views/admin/partial/template.blade.php b/resources/views/admin/partial/template.blade.php new file mode 100644 index 000000000..e207f6a99 --- /dev/null +++ b/resources/views/admin/partial/template.blade.php @@ -0,0 +1,25 @@ +@extends('layouts.app') + +@section('content') + +
+
+
+
+
+ @include('admin.partial.sidebar') +
+ @if (session('status')) +
+ {{ session('status')}} +
+ @endif + @yield('section') +
+
+
+
+
+
+ +@endsection \ No newline at end of file diff --git a/resources/views/admin/statuses/home.blade.php b/resources/views/admin/statuses/home.blade.php new file mode 100644 index 000000000..a627d6d0e --- /dev/null +++ b/resources/views/admin/statuses/home.blade.php @@ -0,0 +1,55 @@ +@extends('admin.partial.template') + +@section('section') +
+

Statuses

+
+ +
+ + + + + + + + + + + + + @foreach($statuses as $status) + + + + + @if(!$status->media_path) + + @else + + @endif + + + @endforeach + +
#UsernameCaptionStorageCreated
+ + {{$status->id}} + + {{$status->profile->username}}{{str_limit($status->caption, 30)}}0
{{$status->firstMedia()->size}}
{{$status->created_at->diffForHumans()}}
+
+ {{$statuses->links()}} +
+@endsection + +@push('scripts') + +@endpush \ No newline at end of file diff --git a/resources/views/admin/statuses/show.blade.php b/resources/views/admin/statuses/show.blade.php new file mode 100644 index 000000000..ddec8d045 --- /dev/null +++ b/resources/views/admin/statuses/show.blade.php @@ -0,0 +1,36 @@ +@extends('admin.partial.template') + +@section('section') +
+

Status #{{$status->id}}

+
+ +
+ +
+
+ + + +
+
+ + @php($item = $status) + @include('status.template') +@endsection + +@push('scripts') + +@endpush \ No newline at end of file diff --git a/resources/views/admin/users/home.blade.php b/resources/views/admin/users/home.blade.php new file mode 100644 index 000000000..d0077574f --- /dev/null +++ b/resources/views/admin/users/home.blade.php @@ -0,0 +1,55 @@ +@extends('admin.partial.template') + +@section('section') +
+

Users

+
+ +
+ + + + + + + + + + + + + + + @foreach($users as $user) + + + + + + + + + + @endforeach + +
#UsernameEmailStatusesStorageRoleCreated
+ + {{$user->id}} + + {{$user->username}}{{$user->email}}{{$user->profile->statuses->count()}}

{!!$user->is_admin ? 'admin' : 'member'!!}{{$user->created_at->diffForHumans(null, true, true)}}
+
+ {{$users->links()}} +
+@endsection + +@push('scripts') + +@endpush \ No newline at end of file