Esempio n. 1
0
<?php

use yii\helpers\Html;
use yii\helpers\Url;
use yii\widgets\Menu;
use common\models\PokerFantasy;
$this->title = 'Poker fantasy';
$current_events_url = Url::to(['poker-fantasy/' . $current_action, 'type' => 'all']);
$futured_events_url = Url::to(['poker-fantasy/' . $current_action]);
$fantasy_type_list = [];
$fantasy_type_list_ = PokerFantasy::getTypeList();
foreach ($fantasy_type_list_ as $k => $val) {
    $url = Url::to(['poker-fantasy/' . $current_action, 'type' => $k]);
    $fantasy_type_list[$url] = $val;
}
$active_fantasy_type = Url::to(['poker-fantasy/' . $current_action, 'type' => $fantasy_type]);
$event_type_params = ['id' => 'fantasy-type', 'class' => 'width-150'];
if ($current_action == 'stat') {
    $event_type_params['disabled'] = 'disabled';
}
?>

<?php 
//echo $this->render('_fantasy-section-head', ['current_action' => $current_action, 'fantasy_type' => $fantasy_type,]);
?>

<div class="section-head head-menu">

    <?php 
echo Html::dropDownList('event-type', $active_fantasy_type, $fantasy_type_list, $event_type_params);
?>
Esempio n. 2
0
 public function beforeValidate()
 {
     $this->prize_pool_real = $this->prize_pool;
     return parent::beforeValidate();
 }