package UI;

import java.math.BigDecimal;
import java.sql.Connection;
import java.sql.Date;
import java.sql.PreparedStatement;
import java.sql.ResultSet;
import java.sql.ResultSetMetaData;
import java.sql.Statement;
import java.sql.SQLException;
import java.sql.Time;
import java.sql.Timestamp;
import javax.sql.DataSource;
import org.postgresql.ds.PGSimpleDataSource;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.util.Calendar;
import java.util.List;
import RDG.*;

/**
 *
 * @author Marcel
 */
public class BoughtTickets {
    
    /**
    * Print all bought tickets (even canceled)
    * @param flight_id to which are ticket bought
    * @throws SQLException
    * @throws IOException
    * @throws Exception
    */
    public static void print(int flight_id) throws SQLException, IOException, Exception{
        var res=BoughtTicketsFinder.selectAll(flight_id);
        UI.BatchOutput.BatchPrint(res);
    }
}
