/**
 * @param bool $edit_page
 * @param $obsolete_flag
 */
function print_table($edit_page = false, $obsolete_flag)
{
    $specmanagement_print_api = new specmanagement_print_api();
    if ($edit_page) {
        echo '<form action="' . plugin_page('manage_versions_update') . '" method="post">';
    }
    $specmanagement_print_api->printTableTop('100');
    print_tablehead($edit_page, $obsolete_flag);
    print_tablebody($edit_page, $obsolete_flag);
    $specmanagement_print_api->printTableFoot();
    echo '</form>';
}
/**
 * @param $obsolete_flag
 * @param $show_zero_issues
 * @param $print_flag
 */
function print_table($obsolete_flag, $show_zero_issues, $print_flag)
{
    $specmanagement_print_api = new specmanagement_print_api();
    $obsolote = false;
    if ($obsolete_flag) {
        $obsolote = null;
    }
    $versions = version_get_all_rows_with_subs(helper_get_current_project(), null, $obsolote);
    $amount_stat_columns = plugin_config_get('CAmount');
    if ($amount_stat_columns > PLUGINS_SPECMANAGEMENT_MAX_COLUMNS) {
        $amount_stat_columns = PLUGINS_SPECMANAGEMENT_MAX_COLUMNS;
    }
    $specmanagement_print_api->printTableTop('90');
    print_tablehead($amount_stat_columns, $obsolete_flag, $show_zero_issues, $print_flag);
    print_tablebody($amount_stat_columns, $print_flag, $show_zero_issues, $versions);
    $specmanagement_print_api->printTableFoot();
}