bzr revid: chm@openerp.com-20130305124054-5vodppd1f4vencfs
This commit is contained in:
Christophe Matthieu
2013-03-05 13:40:54 +01:00
parent ae6f953cec
commit db86fd55ff
2 changed files with 3 additions and 2 deletions
+1 -1
View File
@@ -347,7 +347,7 @@ class survey_question(osv.osv):
'sequence': fields.integer('Sequence'),
'tot_resp': fields.function(_calc_response, string="Total Answer"),
'survey': fields.related('page_id', 'survey_id', type='many2one', relation='survey', string='Survey'),
'descriptive_text': fields.text('Descriptive Text', size=255, translate=True),
'descriptive_text': fields.text('Descriptive Text', translate=True),
'column_heading_ids': fields.one2many('survey.question.column.heading', 'question_id', ' Column heading'),
'type': fields.selection([('multiple_choice_only_one_ans', 'Multiple Choice (Only One Answer)'),
('multiple_choice_multiple_ans', 'Multiple Choice (Multiple Answer)'),
+2 -1
View File
@@ -175,7 +175,8 @@ class survey_question_wiz(osv.osv_memory):
first = True
for row in que_rec.answer_choice_ids:
etree.SubElement(xml_group, 'newline')
etree.SubElement(xml_group, 'field', {'widget': 'radio', 'horizontal': '1', 'no_radiolabel': not first and '1' or '0', 'modifiers': readonly and '{"readonly": 1}' or '{}', 'name': tools.ustr(que.id) + "_selection_" + tools.ustr(row.id), 'string': to_xml(tools.ustr(row.answer))})
etree.SubElement(xml_group, 'label', {'for': tools.ustr(que.id) + "_selection_" + tools.ustr(row.id), 'string': to_xml(tools.ustr(row.answer))})
etree.SubElement(xml_group, 'field', {'widget': 'radio', 'horizontal': '1', 'no_radiolabel': not first and '1' or '0', 'modifiers': readonly and '{"readonly": 1}' or '{}', 'name': tools.ustr(que.id) + "_selection_" + tools.ustr(row.id), 'nolabel': "1"})
first = False
selection = []
for col in que_rec.column_heading_ids: