$bplot->SetFillGradient("navy","lightsteelblue",GRAD_MIDVER);
$graph->Add($bplot);
-
+
$graph->Stroke();
}
?>
$s = new Survey($g, $survey_id);
if (!$s || !is_object($s)) {
- echo "<h3>"._('Error'). ' Can not get Survey' ."</h3>";
- $sh->footer(array());
- exit;
+ echo "<h3>"._('Error'). ' Can not get Survey' ."</h3>";
+ $sh->footer(array());
+ exit;
} else if ( $s->isError()) {
- echo "<h3>"._('Error'). $s->getErrorMessage() ."</h3>";
- $sh->footer(array());
- exit;
+ echo "<h3>"._('Error'). $s->getErrorMessage() ."</h3>";
+ $sh->footer(array());
+ exit;
}
/* A specific question */
$question_id = getIntFromRequest('question_id');
if ($question_id) {
- /* Create a Survey Question for general purpose */
- $sq = new SurveyQuestion($g, $question_id);
- if (!$sq || !is_object($sq)) {
- echo "<h3>"._('Error'). ' Can not get Survey Question' ."</h3>";
- } else if ( $sq->isError()) {
- echo "<h3>"._('Error'). $sq->getErrorMessage() ."</h3>";
- } else {
- showResult($sh, $s, $sq, 1, 0, $graph);
- }
+ /* Create a Survey Question for general purpose */
+ $sq = new SurveyQuestion($g, $question_id);
+ if (!$sq || !is_object($sq)) {
+ echo "<h3>"._('Error'). ' Can not get Survey Question' ."</h3>";
+ } else if ( $sq->isError()) {
+ echo "<h3>"._('Error'). $sq->getErrorMessage() ."</h3>";
+ } else {
+ showResult($sh, $s, $sq, 1, 0, $graph);
+ }
} else {
- echo '<h2>'.$s->getTitle().' ( '. $s->getNumberOfVotes() .' Votes )</h2><p/>';
+ echo '<h2>'.$s->getTitle().' ( '. $s->getNumberOfVotes() .' Votes )</h2><p/>';
- /* Get questions of this survey */
- $questions = & $s->getQuestionInstances();
+ /* Get questions of this survey */
+ $questions = & $s->getQuestionInstances();
- $question_number = 1;
- for ($i=0; $i<count($questions); $i++) {
- if ($questions[$i]->isError()) {
- echo $questions[$i]->getErrorMessage();
- } else {
- if ($questions[$i]->getQuestionType()!='4') {
- showResult($sh, $s, $questions[$i], $show_comment, $question_number++, $graph);
+ $question_number = 1;
+ for ($i=0; $i<count($questions); $i++) {
+ if ($questions[$i]->isError()) {
+ echo $questions[$i]->getErrorMessage();
+ } else {
+ if ($questions[$i]->getQuestionType()!='4') {
+ showResult($sh, $s, $questions[$i], $show_comment, $question_number++, $graph);
+ }
+ }
}
- }
- }
}
}
<input type="text" name="name" value="<?php echo $ac->getName(); ?>" /></p>
<p>
<?php if ($ac->getType() == ARTIFACT_EXTRAFIELDTYPE_TEXTAREA) { ?>
- <b><?php echo _('Text Area Rows'); ?></b><br />
- <input type="text" name="attribute1" value="<?php echo $ac->getAttribute1(); ?>" size="2" maxlength="2" />
- </p><p>
- <b><?php echo _('Text Area Columns'); ?></b><br />
- <input type="text" name="attribute2" value="<?php echo $ac->getAttribute2(); ?>" size="2" maxlength="2" />
+ <b><?php echo _('Text Area Rows'); ?></b><br />
+ <input type="text" name="attribute1" value="<?php echo $ac->getAttribute1(); ?>" size="2" maxlength="2" />
+ </p><p>
+ <b><?php echo _('Text Area Columns'); ?></b><br />
+ <input type="text" name="attribute2" value="<?php echo $ac->getAttribute2(); ?>" size="2" maxlength="2" />
<?php } elseif ($ac->getType() == ARTIFACT_EXTRAFIELDTYPE_TEXT || $ac->getType() == ARTIFACT_EXTRAFIELDTYPE_RELATION) {?>
- <b><?php echo _('Text Field Size'); ?></b><br />
- <input type="text" name="attribute1" value="<?php echo $ac->getAttribute1(); ?>" size="2" maxlength="2" />
- </p><p>
- <b><?php echo _('Text Field Maxlength'); ?></b><br />
- <input type="text" name="attribute2" value="<?php echo $ac->getAttribute2(); ?>" size="2" maxlength="2" />
+ <b><?php echo _('Text Field Size'); ?></b><br />
+ <input type="text" name="attribute1" value="<?php echo $ac->getAttribute1(); ?>" size="2" maxlength="2" />
+ </p><p>
+ <b><?php echo _('Text Field Maxlength'); ?></b><br />
+ <input type="text" name="attribute2" value="<?php echo $ac->getAttribute2(); ?>" size="2" maxlength="2" />
<?php } else { ?>
<input type="hidden" name="attribute1" value="0" />
<input type="hidden" name="attribute2" value="0" />
/*
Put the result set (list of trackers for this group) into a column with folders
- */
+ */
$tablearr=array(_('Tracker'),_('Description'),_('Open'),_('Total'));
echo $HTML->listTableTop($tablearr);
}
unset($ah);
- if (!$was_error) {
- $feedback = _('Updated successfully'); }
+ if (!$was_error) {
+ $feedback = $Language->getText('tracker','updated_successful'); }
}
unset ($extra_fields_choice);
include $gfwww.'tracker/browse.php';
//admin and techs can do everything
//techs will have certain fields overridden inside the update() function call
if (!$ah->update($priority,$status_id,
- $assigned_to,$summary,$canned_response,$details,$new_artifact_type_id,$extra_fields, $description)) {
+ $assigned_to,$summary,$canned_response,$details,$new_artifact_type_id,$extra_fields, $description)) {
form_release_key(getStringFromRequest('form_key'));
$error_msg .= _('Tracker Item'). ': '.$ah->getErrorMessage();
$ah->clearError();
}
// Admin, Techs and Submitter can add files.
- if ($ath->userIsAdmin() || $ath->userIsTechnician() ||
- (session_loggedin() && ($ah->getSubmittedBy() == user_getid()))) {
+ if ($ath->userIsAdmin() || $ath->userIsTechnician() ||
+ (session_loggedin() && ($ah->getSubmittedBy() == user_getid()))) {
//
// Attach files to this Artifact.
//