Skip to content

Commit

Permalink
Dev : plural corrections
Browse files Browse the repository at this point in the history
  • Loading branch information
louis committed Oct 9, 2015
1 parent 180c153 commit 32e08c4
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 32 deletions.
29 changes: 14 additions & 15 deletions application/views/admin/survey/Question/subQuestion_view.php
Expand Up @@ -29,7 +29,7 @@

<div class="side-body" id="edit-question-body">
<h3>
<?php eT("Edit subquestions"); ?>
<?php eT("Edit subquestions"); ?>
</h3>
<div class="row">
<div class="col-lg-8 content-right">
Expand Down Expand Up @@ -57,7 +57,7 @@
$sortorderids='';
$codeids='';
?>

<div class="tab-content">
<?php foreach ($anslangs as $i => $anslang)
{ ?>
Expand Down Expand Up @@ -93,7 +93,7 @@
<?php if ($scale_id==0)
{ ?>
<th class="relevancehead"><img src='<?php echo $sImageURL; ?>subq_relevance_en.png' class='btntogglerelevance' alt='<?php eT("Edit subquestion relevance") ?>'/> <span style="display: none" class="relevance"> <?php eT("Relevance"); ?> </span> </th>
<?php } ?>
<?php } ?>
</tr></thead>
<tbody>
<?php $alternate=false;
Expand Down Expand Up @@ -138,8 +138,7 @@ class="highlight"
<?php } ?>

</td><td>
<input type='text' size='100' class='answer' id='answer_<?php echo $row->language; ?>_<?php echo $row->qid; ?>_<?php echo $row->scale_id; ?>' name='answer_<?php echo $row->language; ?>_<?php echo $row->qid; ?>_<?php echo $row->scale_id; ?>' placeholder='<?php eT("Some example subquestion","js") ?>' value="<?php echo $row->question; ?>" onkeypress=" if(event.keyCode==13) { if (event && event.preventDefault) event.preventDefault(); document.getElementById('saveallbtn_<?php echo $anslang; ?>').click(); return false;}" />

<input type='text' size='0' class='answer' id='answer_<?php echo $row->language; ?>_<?php echo $row->qid; ?>_<?php echo $row->scale_id; ?>' name='answer_<?php echo $row->language; ?>_<?php echo $row->qid; ?>_<?php echo $row->scale_id; ?>' placeholder='<?php eT("Some example subquestion","js") ?>' value="<?php echo $row->question; ?>" onkeypress=" if(event.keyCode==13) { if (event && event.preventDefault) event.preventDefault(); document.getElementById('saveallbtn_<?php echo $anslang; ?>').click(); return false;}" />
<?php echo getEditor("editanswer","answer_".$row->language."_".$row->qid."_{$row->scale_id}", "[".gT("Subquestion:", "js")."](".$row->language.")",$surveyid,$gid,$qid,'editanswer'); ?>
</td>
<?php if ($activated != 'Y' && $first)
Expand All @@ -150,24 +149,24 @@ class="highlight"
</td>
<?php } ?>



<?php if ($scale_id==0) { /* relevance column */ ?>
<td>
<?php if ($row->relevance!="1" && trim($row->relevance)!="") { ?>
<?php if ($row->relevance!="1" && trim($row->relevance)!="") { ?>
<img src='<?php echo $sImageURL; ?>subq_relevance_en.png' class='btntogglerelevance' alt='<?php eT("Edit subquestion relevance") ?>'/>
<?php } else { /* no relevance equation: icon deactivated */ ?>
<img src='<?php echo $sImageURL; ?>subq_relevance_dis.png' class='btntogglerelevance' alt='<?php eT("Edit subquestion relevance") ?>'/>
<?php } else { /* no relevance equation: icon deactivated */ ?>
<img src='<?php echo $sImageURL; ?>subq_relevance_dis.png' class='btntogglerelevance' alt='<?php eT("Edit subquestion relevance") ?>'/>
<?php }
if ($first) { /* default lang - input field */?>
if ($first) { /* default lang - input field */?>
<input style="display: none" type='text' size='20' class='relevance' id='relevance_<?php echo $row->qid; ?>_<?php echo $row->scale_id; ?>' name='relevance_<?php echo $row->qid; ?>_<?php echo $row->scale_id; ?>' value="<?php echo $row->relevance; ?>" onkeypress=" if(event.keyCode==13) { if (event && event.preventDefault) event.preventDefault(); document.getElementById('saveallbtn_<?php echo $anslang; ?>').click(); return false;}" />
<?php } else { /* additional language: just print rel. equation */ ?>
<span style="display: none" class="relevance"> <?php echo $row->relevance; ?> </span>
<?php } ?>
</td>
<?php } ?>


</tr>
<?php $position++;
}
Expand All @@ -193,7 +192,7 @@ class="highlight"
</div>
<?php } ?>
</div>

<div id='labelsetbrowser' class='labelsets-update' style='display:none;'>
<div style='float:left; width:260px;'>
<label for='labelsets'><?php eT('Available label sets:'); ?></label>
Expand Down Expand Up @@ -257,9 +256,9 @@ class="highlight"
</form>



</div>
</div>
</div>
</div>


34 changes: 17 additions & 17 deletions application/views/admin/survey/listSurveys_view.php
@@ -1,14 +1,14 @@
<?php
/**
* This file render the list of surveys
* It use the Survey model search method to build the data provider.
*
* It use the Survey model search method to build the data provider.
*
* @var $model obj the QuestionGroup model
*/
?>
<?php $pageSize=Yii::app()->user->getState('pageSize',Yii::app()->params['defaultPageSize']);?>
<div class="col-lg-12 list-surveys">
<h3><?php eT('Survey list'); ?></h3>
<h3><?php eT('Surveys list'); ?></h3>

<!-- Search Box -->
<div class="row">
Expand All @@ -22,7 +22,7 @@
'class'=>'form-inline',
),
)); ?>

<!-- search input -->
<div class="form-group">
<?php echo $form->label($model, 'search: ', array('class'=>'control-label')); ?>
Expand All @@ -37,16 +37,16 @@
<option value="Y" <?php if( $model->active=="Y"){echo "selected";}?>><?php eT('Yes');?></option>
<option value="N" <?php if( $model->active=="N"){echo "selected";}?>><?php eT('No');?></option>
</select>
</div>
</div>
<?php echo CHtml::submitButton('Search', array('class'=>'btn btn-success')); ?>
<a href="<?php echo Yii::app()->createUrl('admin/survey/sa/listsurveys');?>" class="btn btn-warning"><?php eT('reset');?></a>
<a href="<?php echo Yii::app()->createUrl('admin/survey/sa/listsurveys');?>" class="btn btn-warning"><?php eT('reset');?></a>

<?php $this->endWidget(); ?>
</div>
</div>
</div>
</div>

<!-- Grid -->
<!-- Grid -->
<div class="row">
<div class="col-lg-12 content-right">
<?php
Expand All @@ -61,21 +61,21 @@
$pageSize,
Yii::app()->params['pageSizeOptions'],
array('class'=>'changePageSize form-control', 'style'=>'display: inline; width: auto')) .
gT(' rows per page'),
gT(' rows per page'),

'columns' => array(
array(
'name' => 'Survey id',
'value'=>'$data->sid',
'htmlOptions' => array('class' => 'col-md-1'),
),

array(
'name' => 'Title',
'value'=>'$data->defaultlanguage->surveyls_title',
'htmlOptions' => array('class' => 'col-md-1'),
),

array(
'name' => 'Creation date',
'value'=>'$data->creationdate',
Expand All @@ -98,19 +98,19 @@
'name' => 'Active',
'value'=>'$data->activeWord',
'htmlOptions' => array('class' => 'col-md-1'),
),
),

array(
'name' => 'Partial',
'value'=>'$data->countPartialAnswers',
'htmlOptions' => array('class' => 'col-md-1'),
),

array(
'name' => 'Full',
'value'=>'$data->countFullAnswers',
'htmlOptions' => array('class' => 'col-md-1'),
),
),

array(
'name' => 'Total',
Expand All @@ -130,7 +130,7 @@
'htmlOptions'=>array('style'=>'cursor: pointer;', 'class'=>'hoverAction'),
'selectionChanged'=>"function(id){window.location='" . Yii::app()->urlManager->createUrl('admin/survey/sa/view/surveyid' ) . '/' . "' + $.fn.yiiGridView.getSelection(id.split(',', 1));}",
'ajaxUpdate' => true,
));
));
?>
</div>
</div>
Expand All @@ -143,4 +143,4 @@
$.fn.yiiGridView.update('survey-grid',{ data:{ pageSize: $(this).val() }});
});
});
</script>
</script>

0 comments on commit 32e08c4

Please sign in to comment.