Esempio n. 1
0
 public function indexAction()
 {
     $this->view->coverage = Convention::getCoverageLevels();
     $query = $this->em->createQuery('SELECT c FROM Entity\\Convention c LEFT JOIN c.signups cs LEFT JOIN c.archives ca ORDER BY c.start_date DESC');
     $this->view->pager = new \DF\Paginator\Doctrine($query, $this->getParam('page', 1), 15);
 }
Esempio n. 2
0
<?php

$coverage_options_raw = \Entity\Convention::getCoverageLevels();
$coverage_options = array();
foreach ($coverage_options_raw as $c_key => $c_opt) {
    $coverage_options[$c_key] = '&nbsp;<i class="' . $c_opt['icon'] . '"></i> ' . $c_opt['text'];
}
return array('method' => 'post', 'enctype' => 'multipart/form-data', 'elements' => array('name' => array('text', array('label' => 'Convention Name', 'class' => 'half-width', 'required' => true)), 'location' => array('text', array('label' => 'Convention Location', 'class' => 'half-width', 'required' => true)), 'coverage_level' => array('radio', array('label' => 'PVL Coverage Level', 'multiOptions' => $coverage_options, 'escape' => false, 'default' => 'full', 'required' => true)), 'start_date' => array('unixDate', array('label' => 'Start Date', 'default' => time())), 'end_date' => array('unixDate', array('label' => 'End Date', 'default' => time())), 'web_url' => array('text', array('label' => 'Homepage URL', 'class' => 'half-width')), 'image_url' => array('image', array('label' => 'Convention Image', 'description' => 'Use the same size image as the main PVL banner rotator (1150x200). PNG preferred.')), 'discount_code' => array('text', array('label' => 'Discount Code for Registration', 'description' => 'If this convention offers a discount code for PVL viewers, enter it here for it to be automatically promoted.')), 'signup_enabled' => array('radio', array('label' => 'Signup Enabled?', 'description' => 'Enable the convention signup form for camera operators and other staff.', 'multiOptions' => array(0 => 'No', 1 => 'Yes'), 'default' => 1)), 'signup_notes' => array('textarea', array('label' => 'Special Signup Notes', 'description' => 'If there are special considerations for this convention, include them here and they will appear in the signup form.', 'class' => 'full-width half-height')), 'submit' => array('submit', array('type' => 'submit', 'label' => 'Save Changes', 'helper' => 'formButton', 'class' => 'ui-button'))));