Merge branch '1.0.x' of gitorious.org:statusnet/mainline into 1.0.x
This commit is contained in:
commit
51dc0e1c9b
@ -391,7 +391,7 @@ class QnAPlugin extends MicroAppPlugin
|
||||
// Don't prompt user for an answer if the question is closed or
|
||||
// the current user posed the question in the first place
|
||||
if (empty($question->closed)) {
|
||||
if (!empty($user) && ($user->id != $question->profile_id)) {
|
||||
if (!empty($user)) {
|
||||
$profile = $user->getProfile();
|
||||
$answer = $question->getAnswer($profile);
|
||||
if (!$answer) {
|
||||
|
@ -103,9 +103,9 @@ class QnanewanswerForm extends Form
|
||||
$out = $this->out;
|
||||
$id = "question-" . $question->id;
|
||||
|
||||
$out->element('p', 'answer', $question->title);
|
||||
$out->element('p', 'answer', 'Your answer');
|
||||
$out->hidden('id', $id);
|
||||
$out->element('input', array('type' => 'text', 'name' => 'answer'));
|
||||
$out->textarea('answer', 'answer');
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -101,13 +101,11 @@ class QnareviseanswerForm extends Form
|
||||
*/
|
||||
function formData()
|
||||
{
|
||||
$out = $this->out;
|
||||
|
||||
$out->element('p', 'Your answer to:', $this->question->title);
|
||||
|
||||
$out = $this->out;
|
||||
$out->element('p', 'revise-answer', 'Your answer');
|
||||
$id = "answer-" . $this->answer->id;
|
||||
$out->hidden('id', $id);
|
||||
$out->textarea('answer', 'You said:', $this->answer->content);
|
||||
$out->textarea('answer', 'answer', $this->answer->content);
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user