From aa10f84d877ae52392b160d862a26bef759aa5b0 Mon Sep 17 00:00:00 2001 From: JT Smith Date: Thu, 22 Jun 2006 19:45:46 +0000 Subject: [PATCH] - fix: viewIndividualSurvey shows "Answer" lines in Survey mode fixed more spectre memory bugs --- docs/changelog/6.x.x.txt | 2 ++ lib/Spectre/Cron.pm | 1 + lib/Spectre/Workflow.pm | 1 + lib/WebGUI.pm | 2 +- lib/WebGUI/Asset/Wobject/Survey.pm | 2 +- 5 files changed, 6 insertions(+), 2 deletions(-) diff --git a/docs/changelog/6.x.x.txt b/docs/changelog/6.x.x.txt index f4d1e3758..7504c0d18 100644 --- a/docs/changelog/6.x.x.txt +++ b/docs/changelog/6.x.x.txt @@ -13,6 +13,8 @@ - fix: Payment in commerce system - fix: packages don't take on new pages style when deployed - fix: Payment in commerce system (Part II) + - fix: viewIndividualSurvey shows "Answer" lines in Survey mode + 6.99.4 - fix: better checking of selected template type diff --git a/lib/Spectre/Cron.pm b/lib/Spectre/Cron.pm index beac5c73a..0ebb581be 100644 --- a/lib/Spectre/Cron.pm +++ b/lib/Spectre/Cron.pm @@ -389,6 +389,7 @@ sub runJob { $request->header("X-config",$job->{config}); $self->debug("Posting schedule job ".$job->{taskId}." to $url."); $kernel->post( useragent => 'request', { request => $request, response => $session->postback('runJobResponse') }); + $kernel->post( useragent => 'shutdown'); # we'll still get the response, we're just done sending the request $self->debug("Cron job ".$job->{taskId}." posted."); } } diff --git a/lib/Spectre/Workflow.pm b/lib/Spectre/Workflow.pm index aca689f9a..d6f4ac574 100644 --- a/lib/Spectre/Workflow.pm +++ b/lib/Spectre/Workflow.pm @@ -345,6 +345,7 @@ sub runWorker { $request->header("X-instanceId",$instance->{instanceId}); $self->debug("Posting workflow instance ".$instance->{instanceId}." to $url."); $kernel->post( useragent => 'request', { request => $request, response => $session->postback('workerResponse') }); + $kernel->post( useragent => 'shutdown'); # we'll still get the response, we're just done sending the request $self->debug("Workflow instance ".$instance->{instanceId}." posted."); } diff --git a/lib/WebGUI.pm b/lib/WebGUI.pm index bcc1c9da6..703b245f1 100644 --- a/lib/WebGUI.pm +++ b/lib/WebGUI.pm @@ -83,7 +83,7 @@ sub contentHandler { ### inherit Apache request. my $r = shift; my $configFile = shift || $r->dir_config('WebguiConfig'); - ### Instantiate the API for this httpd instance. + ### nstantiate the API for this httpd instance. my $s = Apache2::ServerUtil->server; ### Open new or existing user session based on user-agent's cookie. my $session = WebGUI::Session->open($s->dir_config('WebguiRoot'),$configFile,$r, $s); diff --git a/lib/WebGUI/Asset/Wobject/Survey.pm b/lib/WebGUI/Asset/Wobject/Survey.pm index cf259ba69..b010df057 100644 --- a/lib/WebGUI/Asset/Wobject/Survey.pm +++ b/lib/WebGUI/Asset/Wobject/Survey.pm @@ -1308,7 +1308,7 @@ sub www_viewIndividualSurvey { $var->{'duration.minutes.label'} = $i18n->get(79); $var->{'duration.seconds'} = (($response->{endDate} - $response->{start})%60); $var->{'duration.seconds.label'} = $i18n->get(80); - $var->{'answer.label'} = $i18n->get(19); + $var->{'answer.label'} = $i18n->get(19) if ($self->get("mode") eq "quiz"); $var->{'response.label'} = $i18n->get(66); $var->{'comment.label'} = $i18n->get(57); my $questions = $self->session->db->read("select Survey_questionId,question,answerFieldType from Survey_question