Ejemplo n.º 1
0
		<?php 
}
?>
	</table>
    <?php 
$form = ActiveForm::begin(['enableClientValidation' => false, 'options' => ['enctype' => 'multipart/form-data']]);
?>
    	<?php 
echo $form->field($model, 'box_id')->dropDownList(Arrayhelper::map($boxes, 'id', 'code'));
?>
    	<?php 
echo $form->field($model, 'observation_type')->dropDownList(Observations::getObservationTypes(), ['data-observation-type' => 1]);
?>
    	<div class="observation-form-details">
			<?php 
echo $form->field($model, 'taxon_id')->dropDownList(Species::getTaxonomies(true), ['data-taxon-identifier' => 1]);
?>
			<?php 
echo $form->field($model, 'species_id')->dropDownList(ArrayHelper::map($species, 'id', 'dutch'), ['data-species-identifier' => 1]);
?>
			<div class="sight-container hidden-js">
				<?php 
echo $form->field($model, 'age')->dropDownList(Observations::getAgeOptions());
?>
				<?php 
echo $form->field($model, 'sight_quantity');
?>
			</div>
			<div class="manure-container hidden-js">
				<?php 
echo $form->field($model, 'manure_collected')->checkbox(['data-manure-collected' => 1]);
Ejemplo n.º 2
0
use yii\bootstrap\ActiveForm;
use app\models\Species;
?>
<h1><?php 
echo Yii::t('app', 'Soort');
?>
 <?php 
echo $model->isNewRecord ? Yii::t('app', 'toevoegen') : Yii::t('app', 'bewerken');
?>
</h1>
<div class="species-form">
	<?php 
$form = ActiveForm::begin(['enableClientValidation' => false]);
?>
		<?php 
echo $form->field($model, 'taxon')->dropDownList(Species::getTaxonomies());
?>
		<?php 
echo $form->field($model, 'genus');
?>
		<?php 
echo $form->field($model, 'speceus');
?>
		<?php 
echo $form->field($model, 'dutch');
?>
		<?php 
echo $form->field($model, 'url');
?>
		<div class="form-group text-right">
			<input type="submit" class="btn btn-success" value="<?php 
Ejemplo n.º 3
0
 public function getTaxonomy()
 {
     return Species::getTaxonomies()[$this->taxon_id];
 }