@extends('seller.profile') @php $profile = auth()->user()->profile; @endphp @section('content') @php $can = App\Models\Can::where('user_id', Auth::user()->id)->first(); @endphp {{--
--}}
{{-- @session('success') @endsession --}}

Ads

Welcome to your dashboard

{{-- @if (Auth::user()->role === 'admin') Admin Dashboard @endif @php $is_approved = false @endphp @if (Auth::user()->profile->status === 'verified' && $can->stock > 0) @php $is_approved = true @endphp @endif {{-- Sell To Lovecans --}} {{-- Sell Offers --}} {{-- Lovecans Store --}} Create Ad
@php $ads = App\Models\Ad::where('user_id', Auth::user()->id) ->orderBy('id', 'desc') ->get(); $can = App\Models\Can::where('user_id', Auth::user()->id)->first(); @endphp {{--

No of Cans available: {{ $can ? $can->stock : 0 }}

--}} {{--
--}}
{{-- @session('error') @endsession --}} @foreach ($ads as $ad)
@if ($ad->promotion_expiry > now()) Promoted @else Not Promoted @endif ...

{{ $ad->title }}

Type: {{ $ad->type }}

Price: {{ $ad->price }}

Days Worn: {{ $ad->worn_days }}

@if ($ad->status == 'Unapproved') {{ $ad->status }} @endif @if ($ad->status == 'Approved')
@csrf

{{ ucfirst($ad->ad_status) }}

@endif
Edit Promote ad
@endforeach @if ($ads->count() == 0)

No Ads
@endif
{{--
--}}
@endsection