@extends('adm.index')
@section('productos','active')
@section('productos_true','true')
@section('productos_show','show')
@section('productos_collapsed','collapsed')
@section('form')

<style>
    form{
        margin-bottom: 40px !important;
        height: 100%;
    }
    main{
        max-height: none;
    }
</style>

<div class="container">
    <div class="row">
        <div class="col-12">
            <h2>Agregar distribuidor</h2>
        </div>
        <div class="col-12">
            <form method="POST" action="<?= route('createDistribuidor') ?>" enctype="multipart/form-data">
                @csrf
                <div class="col-md-6 col-sm-12 mb-3">
                    <label for="orden" class="form-label">Orden</label>
                    <input type="text" class="form-control" id="orden" name="orden" required>
                </div>
                <div class="col-md-6 col-sm-12 mb-3">
                    <label for="nombre" class="form-label">Nombre</label>
                    <input type="text" class="form-control" id="nombre" name="nombre" required>
                </div>
                <div class="col-md-6 col-sm-12 mb-3">
                    <label for="provincia" class="form-label">Provincia</label>
                    <input type="text" class="form-control" id="provincia" name="provincia">
                </div>
                <div class="col-md-6 col-sm-12 mb-3">
                    <label for="pais" class="form-label">Pa&iacute;s</label>
                    <input type="text" class="form-control" id="pais" name="pais" required>
                </div>
                <div class="col-md-6 col-sm-12 mb-3">
                    <label for="direccion" class="form-label">Direcci&oacute;n</label>
                    <input type="text" class="form-control" id="direccion" name="direccion" required>
                </div>
                <div class="col-sm-12 col-md-6 mb-3">
                    <label for="telefono" class="form-label">Tel&eacute;fono</label>
                    <input type="text" class="form-control" id="telefono" name="telefono" required>
                </div>
                <div class="col-sm-12 col-md-6 mb-3">
                    <label for="sitio" class="form-label">Sitio</label>
                    <input type="text" class="form-control" id="sitio" name="sitio" required>
                </div>
                <div class="col-sm-12 col-md-6 mb-3">
                    <label for="correo" class="form-label">Correo electr&oacute;nico</label>
                    <input type="text" class="form-control" id="correo" name="correo" required>
                </div>
                <div class="col-sm-12 col-md-6">
                    <label for="formFile" class="form-label">Imagen(Tama&ntilde;o recomendado: 1080 x 1080 px)</label>
                    <input class="form-control" type="file" id="formFile" name="foto">
                </div>
                <div class="col-12">
                    <button type="submit" class="btn btn-primary">Agregar distribuidor</button>
                </div>
            </form>
        </div>
    </div>
</div>

<script>
  $(document).ready(function() {
       $('textarea').summernote({
           insertTableMaxSize: {
               col: 20,
               row: 20
           },
           height: 200,
           toolbar: [
               // [groupName, [list of button]]
               ['table', ['table']],
               ['style', ['bold', 'italic', 'underline', 'clear']],
               ['font', ['strikethrough', 'superscript', 'subscript']],
               ['fontsize', ['fontsize']],
               ['color', ['color']],
               ['para', ['ul', 'ol', 'paragraph']],
               ['height', ['height']],
               ['view', ['fullscreen', 'codeview', 'help']],
            ],
       });
   });

</script>

@endsection
