Current File : //home/tradevaly/new.tradevaly.com.bd/resources/views/backend/pages/setting.blade.php
@extends('backend.layouts.app')

@push('style')

@endpush

@section('content')
<div class="container-fluid">
  <div class="row">
    <div class="col-md-6">
      <div class="card">
        <div class="card-header card-header-icon card-header-info">
          <div class="card-icon">
            <i class="material-icons">add_task</i>
          </div>
          <h4 class="card-title">{{translate('Settings Management')}}
          </h4>
        </div>
        <div class="card-body">
          <form action="{{route('admin.settings')}}" method="POST" enctype="multipart/form-data">@csrf
            <div class="row">
              <div class="col-md-8">
                <div class="form-group">
                  <label class="bmd-label-floating">{{translate('Address')}} </label>
                  <input type="text" name="address" class="form-control" value="{!! site_setting('address') !!}" required>
                </div>
              </div>
             </div>
          
             </div>
            <button type="submit" class="btn btn-info mt-5">{{translate('Update')}}</button>
            <div class="clearfix"></div>
          </form>
        </div>
      </div>
    </div>
  </div>
</div>
@stop

@section('script')
<script>
 $(document).on('change', '[name=parent_id]', function() {
            var child_id = $(this).val();
            get_child(child_id);
        });
        
        
        function get_child(child_id) {
            $('[name="sub_id"]').html("");
            $.ajax({
                headers: {
                    'X-CSRF-TOKEN': $('meta[name="csrf-token"]').attr('content')
                },
                url: "{{ route('ajax.cat')}}",
                type: 'POST',
                data: {
                    sub_id  : child_id
                },
                success: function (response) {
                    var obj = JSON.parse(response);
                    if(obj != '') {
                        $('[name="sub_id"]').html(obj);
                    }
                }
            });
        }
</script>
@endsection