<?php
$checkbox = array('active');
$dontRender = array('id','sip_headers','sort', 'scope');

foreach ($model->attributes as $attributeName => $attributeValue) {
    if (in_array($attributeName,$dontRender)) {
        continue;
    }
    $htmlOptions = array();
    $htmlOptions ['data-translation-id'] = strtoupper('NumberTranslation').'_MODEL_'.strtoupper($attributeName);
    if (in_array($attributeName,$checkbox)) {
        echo $form->checkBoxRow($model,$attributeName);
        echo $form->dropDownListRow($model, 'scope', $model->getScopeOptions(), array('data-translation-target' => 'NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS'));
    } else {
        echo $form->textFieldRow($model,$attributeName,$htmlOptions);
    }
}




if (Yii::app()->user->translateMode) {
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_PREROUTING"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_FROM_GATEWAY"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_TO_GATEWAY"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_FROM_USER"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_TO_USER"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_FROM_QUEUE"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_TO_QUEUE"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_FROM_IVR"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_TO_IVR"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_FROM_EXTERNAL_HOST"></i>';
    echo '<i data-translation-target="NUMBERTRANSLATION_MODEL_SCOPE_OPTIONS" data-translation-id="NUMBERTRANSLATION_MODEL_SCOPE_TO_EXTERNAL_HOST"></i>';
}
?>