function build_listado_compases()
{
    // Grid de ritmos
    global $ins, $dic;
    $searchbox = $ins['searchbox'] ? $ins['searchbox'] : false;
    $sqlData = select_compases($searchbox);
    $y = 0;
    if ($sqlData) {
        foreach ($sqlData as $row) {
            $seccion = 'compases';
            $id = $row[id_compas];
            $valor = $row[compas];
            $tblData[$y] = $row;
            unset($tblData[$y][combo]);
            $tblData[$y][compas] = '<span class="editar campo-editable" data-pk="' . $id . '" data-title="' . $dic[ico][editar] . '" title="' . $dic[ico][editar] . '">' . $valor . '</span> <span id="frm-msj_' . $id . '"></span>';
            $tblData[$y][quitar] = ico_eliminar($id, "activate('frm-captura-" . $seccion . "','" . $seccion . "'," . $id . ');');
            $y++;
        }
    }
    return build_grid_paginado($tblData, $titulos);
}
function dropdown_compases($data = array())
{
    global $dic;
    $requerido = $data[requerido] ? true : false;
    $name = $data[name] ? $data[name] : 'lts_compases';
    $lst_data = select_compases();
    $dataDropdown = array('data' => $lst_data, 'name' => $name, 'value' => 'id_compas', 'text' => 'compas', 'requerido' => $requerido, 'class' => $data[clase], 'multiple' => $data[multiple], 'width' => '200', 'selected' => $data[id_selected], 'title' => $dic[tooltips][lst_compases]);
    return drop_down_select($dataDropdown);
}