@extends('user-layouts.user_template')
@section('content')
    <style>
        .hide-bullets {
            list-style:none;
            margin-left: -40px;
            margin-top:20px;
        }
    </style>
    <div class="content-wrapper" style="min-height: 916px;">
        <!-- Content Header (Page header) -->
        <section class="content-header">
            <h1>
                Store Item
                <small>{{ $product_array[0]->ProductName }}</small>
            </h1>
            <ol class="breadcrumb">
                <li><a href="{{ url('user') }}"><i class="fa fa-home"></i> Home</a></li>
                <li><a href="{{ url('user/store-items') }}"><i class="fa fa-th"></i> Store Items</a></li>
                <li class="active">{{ $product_array[0]->ProductName }}</li>
            </ol>
        </section>

        <!-- Main content -->
        <section class="content">
            <div class="row">
                <div class="col-md-7">
                    <div class="box box-primary">
                        <!-- <div class="box-header with-border">
                            <a href="" type="button" class="btn btn-default pull-right"><i class="fa fa-trash"></i> Edit Design</a>
                        </div> -->
                        <div class="box-body custom-box-body">
                            <div class="row">
                                <div class="col-md-12">
                                    <div class="row">
                                        <div class="col-md-12 text-center">
                                            @foreach($thumbnails_array as $thumbnail)
                                                @if($thumbnail->ImageClass == 'active')  
                                                    <img style="height:400px" src="http://{{ config('site_config.prod_private_server_ip')  }}/images/{{ $thumbnail->Image }}" id="main-thumbnail">
                                                @endif
                                            @endforeach
                                        </div>
                                    </div>
                                    <div class="row">
                                        <div class="col-md-12">
                                            <ul class="hide-bullets">
                                                @foreach($thumbnails_array as $thumbnail)
                                                    <li class="col-sm-3 col-xs-3">
                                                        <a class="thumbnail a_thumbnail {{ $thumbnail->ImageClass }}">
                                                            <img class="img img-responsive product-center image-thumbnails" style="height: 59.45px;" src="http://{{ config('site_config.prod_private_server_ip')  }}/images/{{ $thumbnail->Image }}"/>
                                                        </a>
                                                    </li>
                                                @endforeach
                                            </ul>       
                                        </div>
                                    </div>
                                </div>
                                <!-- <div class="col-md-5">
                                    asdasdadadsaad
                                </div> -->
                            </div>
                        </div>
                    </div>
                </div>
                <div class="col-md-5">
                    <div class="box box-primary">
                        <div class="box-header with-border">
                            <h3 class="box-title">
                                Item Details
                            </h3>
                        </div>
                        <form id="frm-item-details">
                            <!-- <input type="hidden" name="design_code" class="form-control" value=""> -->
                            <div class="box-body custom-box-body">
                                <div class="row">
                                    <div class="col-md-12">
                                        <input type="hidden" class="form-control" name="item_url" value="{{ $product_array[0]->ProductURL }}"  placeholder="Item Name">
                                        <div class="form-group">
                                            <label>Item Name</label>
                                            <input type="text" class="form-control" name="itemName" value="{{ $product_array[0]->ProductName }}"  placeholder="Item Name">
                                        </div>
                                        <div class="form-group">
                                            <label>Item Desription</label>
                                            <textarea  class="form-control" name="itemDescription">{{ $product_array[0]->ProductDescription }}</textarea>
                                        </div>
                                        <!-- <div class="form-group">
                                        
                                            <div class="checkbox checkbox-inline">
                                                <input type="checkbox" class="styled" id="sale_chk" name="sale_chk" checked >
                                                <label for="sale_chk"> Sell Item</label>
                                            </div>
                                        
                                            <div class="checkbox checkbox-inline">
                                                <input type="checkbox" class="styled" id="publish_chk" name="publish_chk" >
                                                <label for="publish_chk"> Publish Design</label>
                                            </div>
                                            
                                        </div> -->
                                        <div class="form-group">
                                            <label>Item Price</label>
                                            <input id="item_price" name="item_price" class="form-control price_format" type="text" value="{{ $product_array[0]->ProductPrice }}" data-error="#err-price" />  
                                        </div>
                                        <div class="form-group">
                                            <label>Item Privacy</label>
                                            <select class="form-control" name="item_privacy">
                                                <option value="public"  @if($product_array[0]->PrivacyStatus == "public") selected  @endif>Public</option>
                                                <option value="private" @if($product_array[0]->PrivacyStatus == "private") selected  @endif">Private</option>
                                            </select>
                                        </div>
                                    </div>
                                </div>
                            </div>
                            <div class="box-footer">
                                <!-- <button type="submit" class="btn btn-default">Cancel</button> -->
                                <button type="submit" class="btn btn-primary pull-right">Save changes</button>
                            </div>
                        </form>
                    </div>
                </div>

            </div>
        </section>
    <!-- /.content -->
    </div>
@endsection
