@extends('admin.main')
@section('content')

<style>
    .badge-danger{
        background-color: #d22727;
    }
</style>

<div class="content-wrapper">
    <!-- Content Header (Page header) -->
    <section class="content-header">
    <h1>
        Visualizer
        <!-- <small>Optional description</small> -->
    </h1>
    <ol class="breadcrumb">
        <li><a href="{{ url ('admin') }}"><i class="fa fa-dashboard"></i> Dashboard</a></li>
        <li><a href="{{ url ('admin') }}"><i class="fa fa-paint-brush"></i> Visualizer Management</a></li>
        <li class="active">Visualizer</li>
    </ol>
    </section>

    <!-- Main content -->
    <section class="content container-fluid">
        <div class="row">
            <div class="col-md-12">
                <div class="box">
                    <div class="box-header with-border">
                       <h4 class="box-title">Visualizer</h4>
                    </div>
                    <div class="box-body">
                        <div class="row">
                            <div class="col-sm-12">
                                <div class="well">
                                    <form class="form-horizontal" role="search" id="frm_search_store">
                                        <div class="col-lg-3">
                                            <div class="form-group">
                                                <div class="col-sm-12">
                                                    <label  class="control-label">Select Sports</label>
                                                    <select class="form-control" id="sportName" name="sport_name">
                                                        <option value="0">Select Sports</option>
                                                        @foreach ($sports_array as $sports)
                                                            <option value="{{ $sports->Id }}">{{ $sports->SportsName }}</option>
                                                        @endforeach
                                                    </select>
                                                </div>
                                            </div>
                                        </div>
                                        <div class="col-lg-3">
                                            <div class="form-group">
                                                <div class="col-sm-12">
                                                    <label  class="control-label">Select Sports Category </label>
                                                    <select class="form-control" id="sport_category" name="sport_category"> 

                                                    </select>
                                                </div>
                                            </div>
                                        </div>

                                        <div class="col-lg-6">
                                            <div class="form-group">
                                                <div class="col-sm-12">
                                                    <label  class="control-label">&nbsp;</label>
                                                </div>
                                                <div class="col-sm-12">
                                                    
                                                    <button class="btn btn-primary">Filter</button>
                                                </div>
                                            </div>
                                        </div>

                                        {{-- <div class="col-lg-12">
                                            <div class="form-group">
                                                <div class="col-sm-12">
                                                    <label  class="control-label">Search Visualizer: </label>
                                                    <div class="input-group">
                                                        <input type="text" class="form-control" placeholder="Search Store" value="" name="q">
                                                        <div class="input-group-btn">
                                                            <button class="btn btn-default" type="submit"><i class="fa fa-search"></i></button>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div> --}}
                                    </form>
                                    <div class="clearfix"></div>
                                </div>
                            </div>
                        </div>

                        <div class="row">
                            <div class="col-sm-12">
                                @if(count($visualizer_array) > 0)
                                    @foreach ($visualizer_array as $visualizer)
                                        <div class="item  col-xs-4 col-lg-3">
                                            <div class="thumbnail" style="padding: 5px;">
                                                <div class="store-logo">
                                                    <a href="{{ minio_url('uploads/images/' . $visualizer->Thumbnail) }}"  data-toggle="lightbox">
                                                        <img class="img_store_logo_img"  id="img_store_banner" src="{{ minio_url('uploads/images/' . $visualizer->Thumbnail) }}" style="max-width: 100%; max-height: 100%; ">
                                                    </a>
                                                </div>
                                                <div class="caption">
                                                    <h4 class="group inner list-group-item-heading" style="white-space: nowrap; overflow: hidden; text-overflow: ellipsis;">
                                                        {{ $visualizer->TemplateName }}
                                                    </h4>
                                                    <p class="group inner list-group-item-text">
                                                        <!-- Product description... Lorem ipsum dolor sit amet, consectetuer adipiscing elit,
                                                        sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. -->
                                                    </p>
                                                    <div class="row">
                                                        <div class="col-xs-12 col-md-6">
                                                            @if($visualizer->IsActive == "TRUE")
                                                                <p><span class="badge badge-success">Public</span></p>
                                                            @else
                                                                <p><span class="badge badge-danger" style="">Private</span></p>
                                                            @endif
                                                        </div>
                                                    </div>
                                                    <div class="row">
                                                        <div class="col-xs-12 col-md-12">
                                                            <a href="{{ url('admin') . '/view-visualizer/' . $visualizer->Id }}" class="btn btn-success btn-block">View / Edit</a>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    @endforeach
                                    
                                @else
                                    <div class="col-sm-12">
                                        <h3 style="color: #b5b5b5;">No Record Found</h3>
                                    </div>
                                @endif
                            </div>
                        </div>
                    <div>
                        
                    </div>
                </div>
            </div>
        </div>
    </section>
    <!-- /.content -->
</div>
@endsection