Skip to content

Commit 683c71b

Browse files
committed
Fix import and update of allow_multiple_options
1 parent 1350476 commit 683c71b

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

src/euphorie/client/update.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ def getSurveyTree(survey, profile=None):
2424
"euphorie.module",
2525
"euphorie.risk",
2626
"euphorie.choice",
27+
"euphorie.option",
2728
]:
2829
continue
2930
# Note that in profile.AddToTree, we pretend that an optional module
@@ -48,6 +49,11 @@ def getSurveyTree(survey, profile=None):
4849
"condition": (
4950
node.portal_type[9:] == "choice" and node.condition or None
5051
),
52+
"allow_multiple_options": (
53+
node.portal_type[9:] == "choice"
54+
and node.allow_multiple_options
55+
or False
56+
),
5157
}
5258
)
5359
if IQuestionContainer.providedBy(node):

src/euphorie/content/browser/upload.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,9 @@ def ImportChoice(self, node, module):
251251
choice.description = el_unicode(
252252
node, "description", is_etranslate_compatible=self.is_etranslate_compatible
253253
)
254-
choice.allow_multiple_options = el_bool(node, "allow-multiple-options")
254+
choice.allow_multiple_options = attr_bool(
255+
node, "allow-multiple-options", "value"
256+
)
255257
condition = el_unicode(node, "condition")
256258
if condition:
257259
self.conditions.append((choice, condition))

0 commit comments

Comments
 (0)