<?php
session_start();
include "./var.php";
$tablagastos = getgastos($_SESSION['id_estrategia']);
$id_usuario = $_SESSION['id_estrategia'];
$clientesoptions = getclientesoption();
$lineasdenegocio = getoptionlienaneg();
$tipologias = getoptiotipologia();
$checksetapas = getchecketapas();

$adicionales=<<<sss
<script src="../js/scripttable.js"></script>
<script>

var idusuario = $id_usuario;
$('#example2').DataTable();
var table = $('#example2').DataTable();

$('#example2 tbody').on( 'click', 'tr', function () {
    if ( $(this).hasClass('selected') ) {
        $(this).removeClass('selected');
    }
    else {
        table.$('tr.selected').removeClass('selected');
        $(this).addClass('selected');
    }
} );

$('#example3').DataTable();
var table = $('#example3').DataTable();

$('#example3 tbody').on( 'click', 'tr', function () {
    if ( $(this).hasClass('selected') ) {
        $(this).removeClass('selected');
    }
    else {
        table.$('tr.selected').removeClass('selected');
        $(this).addClass('selected');
    }
} );

</script>
sss;
echo $varfirst;

echo $var=<<<llll
<div class="right_col" role="main">
<div class="right_col" role="main">
                <div class="col-md-12 col-xs-12">
                  <div class="x_panel">
                    <div class="x_title">
                      <h2><strong>Agregar Usuarios:</strong> <small></small></h2>
                      <ul class="nav navbar-right panel_toolbox">
                        <li><a class="collapse-link"><i class="fa fa-chevron-up"></i></a>
                        </li>
                      </ul>
                      <div class="clearfix"></div>
                    </div>
                    <div class="x_content">
                      <br />
                      <form id="demo-form2" data-parsley-validate class="form-horizontal form-label-left">

                        <div class="form-group">
                          <label class="control-label col-md-3 col-sm-3 col-xs-12" for="first-name">Nombre
                          </label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input type="text" id="nombre" required="required" class="form-control col-md-7 col-xs-12">
                          </div>
                        </div>
                        <div class="form-group">
                          <label class="control-label col-md-3 col-sm-3 col-xs-12" for="last-name">Apellidos
                          </label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input type="text" id="Apellidos" name="Apellidos" required="required" class="form-control col-md-7 col-xs-12">
                          </div>
                        </div>
                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Correo</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="correo" class="form-control col-md-7 col-xs-12" type="mail" name="correo" required="required">
                          </div>
                        </div>

                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Telefono</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="Telefono" class="form-control col-md-7 col-xs-12" type="text" name="Telefono" required="required">
                          </div>
                        </div>

                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Usuario</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="usuario" class="form-control col-md-7 col-xs-12" type="text" name="usuario" required="required">
                          </div>
                        </div>
                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Contraseña</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="contrasena" class="form-control col-md-7 col-xs-12" type="password" name="contrasena" required="required">
                          </div>
                        </div>
                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Repita contraseña</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="contrasena2" class="form-control col-md-7 col-xs-12" type="password" name="contrasena2" required="required">
                          </div>
                        </div>
                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Fecha de Nacimiento</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="fecnac" class="form-control col-md-7 col-xs-12" type="date" name="fecnac" required="required">
                          </div>
                        </div>

                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Puesto</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="puesto" class="form-control col-md-7 col-xs-12" type="text" name="puesto" required="required">
                          </div>
                        </div>

                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Tipo de Sueldo</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <select class="form-control" id="tsueldo" required="required">
                              <option value="">Seleccione Tipo de Sueldo</option>
                              <option value="Nomina">Nomina</option>
                              <option value="Por horas">Por horas</option>
                            </select>
                          </div>
                        </div>
                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Sueldo</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="sueldo" class="form-control col-md-7 col-xs-12" type="number" name="sueldo" required="required">
                          </div>
                        </div>
                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Estado</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <select class="form-control" required="required" id="estado">
                              <option value="">Seleccione Estado de Usuario</option>
                              <option value="1">Habilitado</option>
                              <option value="0">Deshabilitar</option>
                            </select>
                          </div>
                        </div>
                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Horas trabajadas al día</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="horas" class="form-control col-md-7 col-xs-12" type="number" name="sueldo" required="required">
                          </div>
                        </div>
                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Costo /hora</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <input id="costohoras" class="form-control col-md-7 col-xs-12" type="number"  required="required">
                          </div>
                        </div>
                        <div class="form-group">
                          <label for="middle-name" class="control-label col-md-3 col-sm-3 col-xs-12">Perfil</label>
                          <div class="col-md-6 col-sm-6 col-xs-12">
                            <select class="form-control" required="required" id="perfil">
                              <option value="">Seleccione Perfil de Usuario </option>
                              <option value="1">Administrativo</option>
                              <option value="2">Operdor</option>
                            </select>
                          </div>
                        </div>
                        
                        <div class="ln_solid"></div>
                        <div class="form-group">
                          <div class="col-md-6 col-sm-6 col-xs-12 col-md-offset-3">
                            <button id="limpiar" class="btn btn-primary" type="reset">Limpiar</button>
                            <button type="button" class="btn btn-success" onclick="agregarusuario();">Guardar</button>
                          </div>
                        </div>

                      </form>
                    </div>
                  </div>
              </div>
  

</div>
llll;
echo $varend;
echo $adicionales;
echo $cerrarend;
?>