<?php $errorImage = asset('img/profile/' . (($persona->gener == 'M') ? "man" : "women") . ".png"); ?>
<div class="pm-overview c-overflow">
    <div class="pmo-pic">
        <div class="p-relative">
            <div class="div-picture-personal">
                <div class="show-image-profile show-photo-profile">
                    <?php echo e(Html::image(loadPhotoProfile($persona->foto,$persona->gener), $persona->apellidos_nombres,['class'=>'','onerror'=>"this.src='".$errorImage."'"])); ?>

                </div>
                <a href="javascript:;" class="pmop-edit href-form-image">
                    <i class="zmdi zmdi-camera"></i> <span class="hidden-xs">Actualizar Foto</span>
                </a>
            </div>

            <div class="form-image hidden">
                <div class="form-group m-b-0">
                    <div class="text-center">
                        <?php echo Form::open(['route'=>['admin.perfil.foto',$persona->id], 'class'=>'', 'id'=>'form-upload-picture', 'files'=>true]); ?>


                        <div class="fileinput fileinput-exists p-r-0" data-provides="fileinput" style="width: 100%">
                            <div class="fileinput-preview thumbnail show-photo-profile" data-trigger="fileinput"></div>
                            <div class="text-center">
                                <span class="btn btn-info btn-file">
                                    <span class="fileinput-new">Seleccionar</span>
                                    <span class="fileinput-exists">Otra</span>
                                    <input type="file" name="foto" accept="image/x-png,image/jpeg"
                                           class="file-form-image">
                                </span>
                                <a href="javascript:;"
                                   class="btn btn-danger btn-icon fileinput-exists fileinput-delete-profile close-photo"
                                   data-dismiss="fileinput">
                                    <i class="zmdi zmdi-close"></i>
                                </a>
                                <button type="submit"
                                        class="btn btn-success fileinput-exists btn-cloud-upload">
                                    <i class="zmdi zmdi-cloud-upload"></i> Subir
                                </button>
                            </div>
                        </div>
                        <?php echo Form::close(); ?>

                    </div>
                </div>
            </div>
        </div>
        <div class="pmo-stat">
            <h2 class="m-0 c-white">
                <?php echo e(($persona->telefono_empresa!=null || $persona->telefono_empresa !="")? $persona->telefono_empresa : $persona->telefono_personal); ?>

            </h2>
            <?php echo e($persona->apellidos_nombres); ?>

        </div>
        <div class="text-center m-t-5">
            <a href="<?php echo e(route("admin.cambiarpassword")); ?>"
               class=" btn btn-primary"
               data-toggle="modal" data-target="#openModal" data-tamanio="sm">
                <i class="zmdi zmdi-key"></i>
                CAMBIAR CONTRASEÑA
            </a>
        </div>
    </div>
</div>
<style>
    .close-photo {
        position: absolute;
        top: 0;
        right: 0;
    }
</style>