This question has been flagged
1 Reply
3886 Views

I am trying to create a new survey, but i found that the number of characters are very limited in all fields such as descriptive text and matrix of choices. Although the pre saved survey such as employee opinion contains a descriptive text with much more characters. How can i increase those characters? Thank you

Avatar
Discard
Best Answer

Survey Module, survey_type object increase the size of 'title' field.

Field info: 'title': fields.char('Survey Title', size=128, required=1),

Increase the size of title field:

'title': fields.char('Survey Title', size=256, required=1),

and save it.

Avatar
Discard
Author

Thank you for your response, but i am a new user in that application. Please set me the steps, from where can i get this fields

Author

in the models - survey - fields - title then i edit the size to 256 (it was 0) then save. the following error appeared (Properties of base fields cannot be altered in this manner! Please modify them through Python code, preferably through a custom addon! )

In OpenERP v7.0 code, Open Survey Module -> inside this module 'survey.py' file is there and open the file -> In that one class is define. class survey(osv.osv): -> inside the survey class, _columns={} in 'title' field is display like 'title': fields.char('Survey Title', size=128, required=1), . You can change the size of this field 128 to 256 and save it. Then start the server and check the title field.

Author

Thank you for your response, i tried what you say but it didn't work. When i make right-click on the field named Answer after i posted a question with Matrix of choices (one per row) in goggle chrome and make inspect element this text appeared <span class="oe_form_field oe_form_field_char oe_form_required" data-fieldname="answer" style="width: 661px; min-height: 44px; top: 281px; left: 63px;">

        <input maxlength="128" type="text" style="height: 44px; width: 661px;">


</span>

You have to update 'title' field size from 'survey.py' file. 'title': fields.char('Survey Title', size=128, required=1), . You can change the size of this field 128 to 256 and save it. Then start the server and check the title field.