<?php

@session_start();
require_once 'inc/data.inc';
require_once 'inc/authorize.inc';
require_permission(SET_UP_PERMISSION);
// TODO: Wipe out existing data (option)
// TODO: "delete racer", "delete all racers" (as super-powers on checkin page)
require_once 'inc/import-csv.inc';
generate_import_page('Import Roster', 'Import Roster', array('js/import-roster.js'), true, array('lastname' => array('name' => "Last Name", 'required' => true), 'firstname' => array('name' => "First Name", 'required' => true), 'classname' => array('name' => group_label(), 'required' => true), 'carnumber' => array('name' => "Car Number", 'required' => false), 'carname' => array('name' => "Car Name", 'required' => false), 'subgroup' => array('name' => subgroup_label(), 'required' => false)), '<div class="footer">' . 'Or instead: <a href="import-results.php">Import results exported from another race...</a>' . '</div>');
<?php

@session_start();
require_once 'inc/data.inc';
require_once 'inc/authorize.inc';
require_permission(SET_UP_PERMISSION);
require_once 'inc/import-csv.inc';
generate_import_page('Import Results', '', array('js/import-results.js'), false, array(), '<div id="import_results_button_div" class="hidden">' . '<input type="button" id="import_results_button" data-enhanced="true" value="Import Race Results"/>' . '</div>');
<?php

@session_start();
require_once 'inc/data.inc';
require_once 'inc/authorize.inc';
require_permission(SET_UP_PERMISSION);
// TODO Button still says "Import Roster"
// TODO Failure needs some explanation
// TODO: Wipe out existing data (option)
require_once 'inc/import-csv.inc';
generate_import_page('Import Awards', 'Import Awards', array('js/import-awards.js'), true, array('awardname' => array('name' => "Award Name", 'required' => true), 'awardtype' => array('name' => "Award Type", 'required' => true), 'classname' => array('name' => group_label(), 'required' => false), 'subgroup' => array('name' => subgroup_label(), 'required' => false), 'carnumber' => array('name' => "Car Number", 'required' => false)), '');