@extends('layouts.master')



@section('title','Ayarlar')



@section('content')



   <!-- ============================================================== -->

   <div class="main-content">

        <div class="page-content">

            <div class="container-fluid">

                <div class="row">

                    <div class="col-12">

                        <div class="page-title-box d-sm-flex align-items-center justify-content-between bg-transparent">

                            <h4 class="mb-sm-0">Ayarları Görüntüle</h4>



                            <div class="page-title-right">

                                <ol class="breadcrumb m-0">

                                    <li class="breadcrumb-item"><a href="javascript: void(0);">Ayarlar</a></li>

                                </ol>

                            </div>



                        </div>

                    </div>

                </div>

               

                <div class="row">

                        <div class="col-lg-12">

                            <div class="card">

                                <div class="card-header">

                                    <h5 class="card-title mb-0">Ayarlar</h5>

                                </div>

                                <div class="card-body">

                               <div class="col-xxl-12">
                            <div class="card">
                                <div class="card-body">
                                    <!-- Nav tabs -->
                                    <ul class="nav nav-tabs nav-justified mb-3" role="tablist">
                                        <li class="nav-item" role="presentation">
                                            <a class="nav-link active" data-bs-toggle="tab" href="#base-justified-home" role="tab" aria-selected="true">
                                                Genel Ayarları
                                            </a>
                                        </li>
                                         <li class="nav-item" role="presentation">
                                            <a class="nav-link " data-bs-toggle="tab" href="#base-justified-tasarim" role="tab" aria-selected="true">
                                                Tasarım Ayarları
                                            </a>
                                        </li>
                                        <li class="nav-item" role="presentation">
                                            <a class="nav-link" data-bs-toggle="tab" href="#base-justified-product" role="tab" aria-selected="false" tabindex="-1">
                                                Logo Ayarları
                                            </a>
                                        </li>
                                        
                                    </ul>
                                    <!-- Tab panes -->
                                    <div class="tab-content  text-muted">
                                        <div class="tab-pane active show" id="base-justified-home" role="tabpanel">
                                           
                                        <form action="{{route('settings.update')}}" method="POST"  enctype="multipart/form-data">
                                        <input type="hidden" name="_token" value="{{ csrf_token() }}" />
                                        <div class="row">
                                        @foreach($settingStepOne as $settingOne)
                                         <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">{{$settingOne->placeholder}}</label>

                                                    <input type="text" name="{{$settingOne->key}}"  value="{{$settingOne->value}}"  class="form-control" id="basiInput">

                                                </div>

                                            </div>

                                            @endforeach
                                             <div style="clear:both"></div>
                                                <input type="hidden" name="type" value="1">
                                              <button type="submit" style="margin-top:20px; margin-left:10px" class=" col-md-3 btn btn-secondary bg-gradient waves-effect waves-light float-right" style="width: 100%;" >Ayarları Düzenle</button>
                                            </div>
                                           
                                    </form>


                                        </div>
                                         <div class="tab-pane " id="base-justified-tasarim" role="tabpanel">
                                           
                                        <form action="{{route('settings.update')}}" method="POST"  enctype="multipart/form-data">
                                        <input type="hidden" name="_token" value="{{ csrf_token() }}" />
                                        <div class="row">
                                         <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">Header Style</label>
                                                    <select name="header_type" class="form-control">
                                                        <option value="0" @if($headertype->value==0) selected @endif>Header Şablon - 1</option>
                                                        <option value="1" @if($headertype->value==1) selected @endif>Header Şablon - 2</option>
                                                        <option value="2" @if($headertype->value==2) selected @endif>Header Şablon - 3</option>
                                                        <option value="3" @if($headertype->value==3) selected @endif>Header Şablon - 4</option>
                                                        <option value="4" @if($headertype->value==4) selected @endif>Header Şablon - 5</option>
                                                     </select>
                                                </div>

                                            </div>

                                              <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">Üst Manşet Modülü</label>
                                                    <select name="topheadline_type" class="form-control">
                                                        <option value="0" @if($topheadlinetype->value==0) selected @endif>Üst Manşet Modülü Pasif</option>
                                                        <option value="1" @if($topheadlinetype->value==1) selected @endif>Üst Manşet Modül - 1</option>
                                                        <option value="2" @if($topheadlinetype->value==2) selected @endif>Üst Manşet Modül - 2</option>
                                                        <option value="3" @if($topheadlinetype->value==3) selected @endif>Üst Manşet Modül - 3</option>
                                                        <option value="4" @if($topheadlinetype->value==4) selected @endif>Üst Manşet Modül - 4</option>
                                                     </select>
                                                </div>

                                            </div>


                                             <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">Manşet Slider Altı 8'li Haber Aktif mi</label>
                                                    <select name="manset_continue_status" class="form-control">
                                                        <option value="0" @if($mansetstatus->value==0) selected @endif>Manşet Slider Altı 8'li Haber Pasif</option>
                                                        <option value="1" @if($mansetstatus->value==1) selected @endif>Manşet Slider Altı 8'li Haber Aktif</option>
                                                     </select>
                                                </div>

                                            </div>


                                             <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">Yazarlar Modülü</label>
                                                    <select name="authors_status" class="form-control">
                                                        <option value="1" @if($authorsstatus->value==1) selected @endif>Yazarlar Aktif</option>
                                                        <option value="0" @if($authorsstatus->value==0) selected @endif>Yazarlar Pasif</option>
                                                     </select>
                                                </div>

                                            </div>

                                            <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">Gazeteler Modülü</label>
                                                    <select name="newspaper_status" class="form-control">
                                                        <option value="1" @if($newspaperstatus->value==1) selected @endif>Gazeteler Aktif</option>
                                                        <option value="0" @if($newspaperstatus->value==0) selected @endif>Gazeteler Pasif</option>
                                                     </select>
                                                </div>

                                            </div>

                                            <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">Vizyondakiler Modülü</label>
                                                    <select name="vision_status" class="form-control">
                                                        <option value="1" @if($visionstatus->value==1) selected @endif>Vizyondakiler Aktif</option>
                                                        <option value="0" @if($visionstatus->value==0) selected @endif>Vizyondakiler Pasif</option>
                                                     </select>
                                                </div>

                                            </div>

                                             <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">Yorum Modülü</label>
                                                    <select name="authors_status" class="form-control">
                                                        <option value="1" @if($authorsstatus->value==1) selected @endif>Yorum Modülü Aktif</option>
                                                        <option value="0" @if($authorsstatus->value==0) selected @endif>Yorum Modülü Pasif</option>
                                                     </select>
                                                </div>

                                            </div>

                                             <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">Emoji Modülü</label>
                                                    <select name="authors_status" class="form-control">
                                                        <option value="1" @if($emojistatus->value==1) selected @endif>Emoji Tepki Aktif</option>
                                                        <option value="0" @if($emojistatus->value==0) selected @endif>Emoji Tepki Pasif</option>
                                                     </select>
                                                </div>

                                            </div>

                                             <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">Etiketler Görünümü</label>
                                                    <select name="tag_status" class="form-control">
                                                        <option value="1" @if($tagstatus->value==1) selected @endif>Etiketler Görünümü Aktif</option>
                                                        <option value="0" @if($tagstatus->value==0) selected @endif>Etiketler Görünümü Pasif</option>
                                                     </select>
                                                </div>

                                            </div>

                                          
                                             <div style="clear:both"></div>
                                                <input type="hidden" name="type" value="1">
                                              <button type="submit" style="margin-top:20px; margin-left:10px" class=" col-md-3 btn btn-secondary bg-gradient waves-effect waves-light float-right" style="width: 100%;" >Ayarları Düzenle</button>
                                            </div>
                                           
                                    </form>


                                        </div>
                                        <div class="tab-pane" id="base-justified-product" role="tabpanel">
                                         <form action="{{route('settings.update')}}" method="POST"  enctype="multipart/form-data">
                                        <input type="hidden" name="_token" value="{{ csrf_token() }}" />
                                        <div class="row">
                                        @foreach($settingStepTwo as $settingOne)
                                         <div class="col-xxl-6 col-md-6" style="margin-top:20px">

                                                <div>

                                                    <label for="basiInput" class="form-label">{{$settingOne->placeholder}}</label> </br ></br >
                                                    <img src="{{ $settingOne->value }}" style="width: 200px;"></br ></br >    
                                                     <input class="form-control" name="{{$settingOne->key}}" id="formSizeDefault" type="file">

                                                </div>

                                            </div>

                                            @endforeach
                                             <div style="clear:both"></div>
                                                <input type="hidden" name="type" value="2">

                                              <button type="submit" style="margin-top:20px; margin-left:10px" class=" col-md-3 btn btn-secondary bg-gradient waves-effect waves-light float-right" style="width: 100%;" >Ayarları Düzenle</button>
                                            </div>
                                           
                                    </form>

                                        </div>
                                   
                                    
                                    </div>
                                </div><!-- end card-body -->
                            </div><!-- end card -->
                        </div>
                                </div>

                            </div>

                        </div><!--end col-->

                    </div><!--end row-->



            </div>

        </div>

    </div>

  







    @section('style')    

    <link rel="stylesheet" href="https://cdn.datatables.net/1.11.5/css/dataTables.bootstrap5.min.css" />

    <link rel="stylesheet" href="https://cdn.datatables.net/buttons/2.2.2/css/buttons.dataTables.min.css" />

    <!--datatable responsive css-->

    <link rel="stylesheet" href="https://cdn.datatables.net/responsive/2.2.9/css/responsive.bootstrap.min.css" />



    <style>

        .dropdown-item{

            cursor:pointer;

        }

      



           .colorBox {

                width: 15px;

                padding: 15px;

            }

    </style>



    @endsection

    @section('script')



    <script src="https://code.jquery.com/jquery-3.6.0.min.js" integrity="sha256-/xUj+3OJU5yExlq6GSYGSHk7tPXikynS7ogEvDej/m4=" crossorigin="anonymous"></script>





    <script src="https://cdn.datatables.net/1.11.5/js/jquery.dataTables.min.js"></script>

    <script src="https://cdn.datatables.net/1.11.5/js/dataTables.bootstrap5.min.js"></script>

    <script src="https://cdn.datatables.net/responsive/2.2.9/js/dataTables.responsive.min.js"></script>

    <script src="https://cdn.datatables.net/buttons/2.2.2/js/dataTables.buttons.min.js"></script>

    <script src="https://cdn.datatables.net/buttons/2.2.2/js/buttons.print.min.js"></script>

    <script src="https://cdn.datatables.net/buttons/2.2.2/js/buttons.html5.min.js"></script>



    <script src="/assets/js/pages/datatables.init.js"></script>



    <script type="text/javascript">



        function changeUserType(userID){

            $("#userID").val(userID);

        }



    </script>



    @endsection



@endsection

