</div> <div class='control-group'> <label>Descripcion</label> <input class='form-control' placeholder='Descripcion' id='descripcion' name='descripcion' /> </div> <div class='control-group'> <p></p> <button type='button' class='btn btn-primary' onclick='save()'>Guardar</button> <button type='reset' class='btn'>Limpiar</button> </div> </form> <hr/> <?php include_once 'nucleo/grupo_conductor.php'; $obj = new grupo_conductor(); $objs = $obj->listDB(); ?> <div class='contenedor-tabla'> <table id='tb' class='display' cellspacing='0' width='100%'> <thead> <tr> <th>Id</th><th>Nombre</th><th>Descripcion</th> <th>OPC</th> </tr> </thead> <tbody> <?php if (is_array($objs)) { foreach ($objs as $o) { ?> <tr><td><?php
echo json_encode($objgrupo_conductor->updateDB()); break; case 'del': $objgrupo_conductor->setVar('id', $_POST['id']); echo json_encode($objgrupo_conductor->deleteDB()); break; case 'get': $res = $objgrupo_conductor->searchDB($_POST['id'], 'id', 1); if (is_array($res)) { echo json_encode($res[0]); } else { echo json_encode(0); } break; case 'list': $res = $objgrupo_conductor->listDB(); if (is_array($res)) { echo json_encode($res); } else { echo json_encode(0); } break; case 'search': $res = $objgrupo_conductor->searchDB($_POST['data'], $_POST['value'], $_POST['type']); if (is_array($res)) { echo json_encode($res); } else { echo json_encode(0); } break; }