Skip to content

Commit

Permalink
fix(formanswer): load answers when validating a formanswer
Browse files Browse the repository at this point in the history
Signed-off-by: Thierry Bugier <[email protected]>
  • Loading branch information
btry committed Apr 2, 2021
1 parent 2e4edc0 commit 99844c9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions inc/formanswer.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -944,15 +944,15 @@ public function getFullForm($richText = false): string {
}

// retrieve answers
$form = $this->getForm();
$fields = $form->getFields();
$formFk = PluginFormcreatorForm::getForeignKeyField();
$fields = $this->getQuestionFields($this->fields[$formFk]);

$this->deserializeAnswers();

// TODO: code very close to PluginFormcreatorAbstractTarget::parseTags() (factorizable ?)
// compute all questions
$questionTable = PluginFormcreatorQuestion::getTable();
$sectionTable = PluginFormcreatorSection::getTable();
$formFk = PluginFormcreatorForm::getForeignKeyField();
$sectionFk = PluginFormcreatorSection::getForeignKeyField();
$questions = $DB->request([
'SELECT' => [
Expand Down

0 comments on commit 99844c9

Please sign in to comment.