@extends('layouts.simple.master') @section('title', 'Tickets List') @section('css') @endsection @section('style') @endsection @section('breadcrumb-title')

Tickets Management

@endsection @section('breadcrumb-items') @endsection @section('content')
@if (count($tickets) > 0) @foreach ($tickets as $index => $ticket) @if (isset($ticket->contest)) @endif @endforeach @endif
S.No Contest Number Contest Title Contest Draw Date Tickets Purchased Remaining Tickets Status Action
{{ ++$index }} {{ $ticket->contest->contest_no }} {{ $ticket->contest->title }} {{ date('d-m-Y H:i:s', strtotime($ticket->contest->draw_date)) }} {{ $ticket->ticket_count }} {{ $ticket->contest->qty - $ticket->ticket_count }} @php $ticketStatus = \DB::table('orders_tickets') ->where([ 'contest_id' => $ticket->contest_id, 'ticket_status' => 'win', ]) ->first(); @endphp @if ($ticketStatus) Winner Declared

Ticket No: {{ $ticketStatus->ticket_id }}

@else Yet to Declare Winner @endif
@if (!$ticketStatus)

Declare Winner

@endif

View More

@endsection @section('script') @endsection