Skip to content

Commit

Permalink
Dev Styled various dialogs
Browse files Browse the repository at this point in the history
  • Loading branch information
c-schmitz committed May 20, 2016
1 parent 289a34f commit 4a2d185
Show file tree
Hide file tree
Showing 6 changed files with 244 additions and 208 deletions.
2 changes: 1 addition & 1 deletion application/controllers/admin/surveypermission.php
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,7 @@ function set($surveyid)
$usersummary .= '<div class="row"><div class="col-lg-12 content-right">';
$usersummary .= "<br />"
.CHtml::form(array("admin/surveypermission/sa/surveyright/surveyid/{$surveyid}"), 'post')
. "<table style='margin:0 auto;' class='usersurveypermissions table'><thead>\n";
. "<table class='usersurveypermissions table table-striped'><thead>\n";

$usersummary .= ""
. "<tr><th></th><th>".gT("Permission")."</th>\n"
Expand Down
4 changes: 2 additions & 2 deletions application/controllers/admin/tokens.php
Original file line number Diff line number Diff line change
Expand Up @@ -1861,8 +1861,8 @@ public function importldap($iSurveyId)
}
else
{
$filterduplicatetoken = (Yii::app()->request->getPost('filterduplicatetoken') && Yii::app()->request->getPost('filterduplicatetoken') == 'on');
$filterblankemail = (Yii::app()->request->getPost('filterblankemail') && Yii::app()->request->getPost('filterblankemail') == 'on');
$filterduplicatetoken = Yii::app()->request->getPost('filterduplicatetoken') == '1';
$filterblankemail = Yii::app()->request->getPost('filterblankemail') == '1';

$ldap_queries = Yii::app()->getConfig('ldap_queries');
$ldap_server = Yii::app()->getConfig('ldap_server');
Expand Down
112 changes: 66 additions & 46 deletions application/views/admin/export/spss_view.php
Original file line number Diff line number Diff line change
@@ -1,52 +1,72 @@
<div class='side-body <?php echo getSideBodyClass(false); ?>'>
<h3><?php eT("Export result data to SPSS");?></h3>
<div class="row">
<div class="col-lg-12 content-right">


<?php echo CHtml::form(array("admin/export/sa/exportspss/sid/{$surveyid}/"), 'post', array('id'=>'exportspss', 'class'=>'wrap2columns'));?>
<fieldset>
<ul class="list-unstyled">
<li><label for='completionstate'><?php eT("Data selection:");?></label><select class="form-control" id='completionstate' name='completionstate' onchange='this.form.submit();'>
<option value='complete' <?php echo $selecthide;?>><?php eT("Completed responses only");?></option>
<option value='all' <?php echo $selectshow;?>><?php eT("All responses");?></option>
<option value='incomplete' <?php echo$selectinc;?>><?php eT("Incomplete responses only");?></option>
</select></li>

<li><label for='spssver'><?php eT("SPSS version:");?></label><select class="form-control" id='spssver' name='spssver' onchange='this.form.submit();'>
<?php if ($spssver == 1) $selected = "selected='selected'"; else $selected = "";?>
<option value='1' <?php echo $selected;?>><?php eT("Prior to 16");?></option>
<?php if ($spssver == 2) $selected = "selected='selected'"; else $selected = ""; ?>
<option value='2' <?php echo $selected;?>><?php eT("16 or up");?></option>
</select></li>
<?php echo CHtml::form(array("admin/export/sa/exportspss/sid/{$surveyid}/"), 'post', array('id'=>'exportspss', 'class'=>''));?>
<div class="form-group row">
<label for='completionstate' class='col-sm-2 form-control-label'><?php eT("Data selection:");?></label>
<div class="col-sm-10">
<?php $this->widget('yiiwheels.widgets.buttongroup.WhButtonGroup', array(
'name' => 'completionstate',
'value'=> incompleteAnsFilterState() ,
'selectOptions'=>array(
"all"=>gT("All responses",'unescaped'),
"complete"=>gT("Complete only",'unescaped'),
"incomplete"=>gT("Incomplete only",'unescaped'),
)
));?>
</div>
</div>
<div class="form-group row">
<label for='spssver' class='col-sm-2 form-control-label'><?php eT("SPSS version:");?></label>
<div class="col-sm-10">
<?php $this->widget('yiiwheels.widgets.buttongroup.WhButtonGroup', array(
'name' => 'spssver',
'value'=> $spssver ,
'selectOptions'=>array(
"1"=>gT("Prior to 16",'unescaped'),
"2"=>gT("16 or up",'unescaped')
)
));?>
</div>
</div>
<div class="form-group row">
<label for='limit' class='col-sm-2 form-control-label'><?php eT("Limit:");?></label>
<div class="col-sm-1">
<input class="form-control" type='text' name='limit' value='<?php echo App()->getRequest()->getParam('limit');?>' />
</div>
</div>
<div class="form-group row">
<label for='offset' class='col-sm-2 form-control-label'><?php eT("Offset:");?></label>
<div class="col-sm-1">
<input class="form-control" type='text' name='offset' value='<?php echo App()->getRequest()->getParam('offset');?>' />
</div>
</div>
<div class="form-group row">
<input type='hidden' name='sid' value='<?php echo $surveyid;?>' />
<input type='hidden' name='action' value='exportspss' /></li><br/>
<li><label for='dlstructure'><?php eT("Step 1:");?></label> &nbsp;&nbsp;&nbsp; <input class="btn btn-default" type='submit' name='dlstructure' id='dlstructure' value='<?php eT("Export syntax");?>'/></li><br/>
<li><label for='dldata'/><?php eT("Step 2:");?></label>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<input class="btn btn-default" type='submit' name='dldata' id='dldata' value='<?php eT("Export data");?>'/></li>
</ul>
</fieldset>
<fieldset>
<legend><?php eT("Optional");?></legend>
<ul class="list-unstyled">
<li><label></label></li>
<li><label for='limit'><?php eT("Limit:");?></label><input type='text' name='limit' value='<?php echo App()->getRequest()->getParam('limit');?>' /></li>
<li><label for='offset'><?php eT("Offset:");?></label><input type='text' name='offset' value='<?php echo App()->getRequest()->getParam('offset');?>' /></li>
</ul>
</fieldset>
</form>

<p>
<div class="alert alert-info" role="alert"><?php eT("Instructions for the impatient");?> :
<br/><br/>
<ol>
<li><?php eT("Download the data and the syntax file");?></li>
<li><?php eT("Open the syntax file in SPSS in Unicode mode");?></li>
<li><?php echo sprintf(gT("Edit the %s line and complete the filename with a full path to the downloaded data file"),"'FILE='");?></li>
<li><?php eT("Choose 'Run/All' from the menu to run the import");?></li>
</ol>
<?php eT("Your data should be imported now");?></div>
<input type='hidden' name='action' value='exportspss' />
<label for='dlstructure' class='col-sm-1 form-control-label'><?php eT("Step 1:");?></label>
<div class="col-sm-10">
<input class="btn btn-default" type='submit' name='dlstructure' id='dlstructure' value='<?php eT("Export syntax");?>'/>
</div>
</div>
<div class="form-group row">
<label for='dldata' class='col-sm-1 form-control-label'><?php eT("Step 2:");?></label>
<div class="col-sm-10">
<input class="btn btn-default" type='submit' name='dldata' id='dldata' value='<?php eT("Export data");?>'/>
</div>
</div>
</form>

<p>
<div class="alert alert-info" role="alert"><?php eT("Instructions for the impatient");?> :
<br/><br/>
<ol>
<li><?php eT("Download the data and the syntax file.");?></li>
<li><?php eT("Open the syntax file in SPSS in Unicode mode.");?></li>
<li><?php echo sprintf(gT("Edit the %s line and complete the filename with a full path to the downloaded data file."),"'FILE='");?></li>
<li><?php eT("Choose 'Run/All' from the menu to run the import.");?></li>
</ol>
<?php eT("Your data should be imported now.");?></div>
</div>
<p>


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

0 comments on commit 4a2d185

Please sign in to comment.