Fabien Pinckaers 2012-07-10 18:29:52 +02:00
commit 7ddb499378
11 changed files with 423 additions and 397 deletions

View File

@ -10,12 +10,6 @@
<field name="type">form</field> <field name="type">form</field>
<field name="arch" type="xml"> <field name="arch" type="xml">
<form string="Schedule/Log a Call" version="7.0"> <form string="Schedule/Log a Call" version="7.0">
<header>
<button name="action_schedule" type="object" string="Log call" attrs="{'invisible' : [('action', '!=', 'log')]}" class="oe_highlight"/>
<button name="action_schedule" type="object" string="Schedule Call" attrs="{'invisible' : [('action', '!=', 'schedule')]}" class="oe_highlight" />
or
<button name="action_cancel" string="Cancel" class="oe_link" special="cancel" />
</header>
<group> <group>
<group> <group>
<field name="action"/> <field name="action"/>
@ -34,6 +28,12 @@
</group> </group>
</group> </group>
<field name="note" placeholder="Call Description" /> <field name="note" placeholder="Call Description" />
<footer>
<button name="action_schedule" type="object" string="Log call" attrs="{'invisible' : [('action', '!=', 'log')]}" class="oe_highlight"/>
<button name="action_schedule" type="object" string="Schedule Call" attrs="{'invisible' : [('action', '!=', 'schedule')]}" class="oe_highlight" />
or
<button name="action_cancel" string="Cancel" class="oe_link" special="cancel" />
</footer>
</form> </form>
</field> </field>
</record> </record>

View File

@ -49,7 +49,7 @@ class idea_idea(osv.osv):
'create_uid': fields.many2one('res.users', 'Creator', required=True, readonly=True), 'create_uid': fields.many2one('res.users', 'Creator', required=True, readonly=True),
'name': fields.char('Idea Summary', size=64, required=True, readonly=True, oldname='title', states={'draft':[('readonly',False)]}), 'name': fields.char('Idea Summary', size=64, required=True, readonly=True, oldname='title', states={'draft':[('readonly',False)]}),
'description': fields.text('Description', help='Content of the idea', readonly=True, states={'draft':[('readonly',False)]}), 'description': fields.text('Description', help='Content of the idea', readonly=True, states={'draft':[('readonly',False)]}),
'category_ids': fields.many2many('idea.category', 'Tags', readonly=True, states={'draft':[('readonly',False)]}), 'category_ids': fields.many2many('idea.category', string='Tags', readonly=True, states={'draft':[('readonly',False)]}),
'state': fields.selection([('draft', 'New'), 'state': fields.selection([('draft', 'New'),
('open', 'Accepted'), ('open', 'Accepted'),
('cancel', 'Refused'), ('cancel', 'Refused'),

View File

@ -72,11 +72,14 @@
<button name="idea_cancel" string="Refuse" states="open" class="oe_highlight"/> <button name="idea_cancel" string="Refuse" states="open" class="oe_highlight"/>
<field name="state" widget="statusbar" statusbar_visible="draft,open,close"/> <field name="state" widget="statusbar" statusbar_visible="draft,open,close"/>
</header> </header>
<sheet>
<label for="name" class="oe_edit_only"/> <label for="name" class="oe_edit_only"/>
<h1><field name="name"/></h1> <h1><field name="name"/></h1>
<label for="category_ids"/> <label for="category_ids" class="oe_edit_only"/>
<h2><field name="category_ids"/></h2> <field name="category_ids" widget="many2many_tags"/>
<label for="description"/><newline/>
<field name="description"/> <field name="description"/>
</sheet>
<footer> <footer>
<field name="message_ids" widget="mail_thread"/> <field name="message_ids" widget="mail_thread"/>
</footer> </footer>

View File

@ -134,8 +134,8 @@ class lunch_order(osv.osv):
'product': fields.many2one('lunch.product', 'Product', required=True, \ 'product': fields.many2one('lunch.product', 'Product', required=True, \
readonly=True, states={'draft':[('readonly', False)]}, change_default=True), readonly=True, states={'draft':[('readonly', False)]}, change_default=True),
'date': fields.date('Date', readonly=True, states={'draft':[('readonly', False)]}), 'date': fields.date('Date', readonly=True, states={'draft':[('readonly', False)]}),
'cashmove': fields.many2one('lunch.cashmove', 'CashMove' , readonly=True), 'cashmove': fields.many2one('lunch.cashmove', 'Cash Move' , readonly=True),
'descript': fields.char('Description Order', readonly=True, size=250, \ 'descript': fields.char('Comment', readonly=True, size=250, \
states = {'draft':[('readonly', False)]}), states = {'draft':[('readonly', False)]}),
'state': fields.selection([('draft', 'New'), ('confirmed', 'Confirmed'), ], \ 'state': fields.selection([('draft', 'New'), ('confirmed', 'Confirmed'), ], \
'Status', readonly=True, select=True), 'Status', readonly=True, select=True),

View File

@ -30,14 +30,18 @@
<field name="state" widget="statusbar" statusbar_visible="draft,confirmed"/> <field name="state" widget="statusbar" statusbar_visible="draft,confirmed"/>
</header> </header>
<sheet string="Order"> <sheet string="Order">
<group col="4"> <group>
<field name="user_id"/> <group>
<field name="date"/> <field name="product" on_change="onchange_product(product)"/>
<field name="product" on_change="onchange_product(product)"/> <field name="descript"/>
<field name="category"/> <field name="price"/>
<field name="descript"/> <field name="category"/>
<field name="price"/> </group>
<field name="cashmove"/> <group>
<field name="user_id"/>
<field name="cashmove"/>
<field name="date"/>
</group>
</group> </group>
</sheet> </sheet>
</form> </form>
@ -105,8 +109,10 @@
<field name="model">lunch.cashbox</field> <field name="model">lunch.cashbox</field>
<field name="arch" type="xml"> <field name="arch" type="xml">
<form string="Cashboxes" version="7.0"> <form string="Cashboxes" version="7.0">
<field name="name"/> <group colspan="4">
<field name="manager"/> <field name="name"/>
<field name="manager"/>
</group>
</form> </form>
</field> </field>
</record> </record>
@ -145,14 +151,16 @@
<field name="model">lunch.cashmove</field> <field name="model">lunch.cashmove</field>
<field name="arch" type="xml"> <field name="arch" type="xml">
<form string="CashMove" version="7.0"> <form string="CashMove" version="7.0">
<group col="4"> <sheet>
<field name="name"/> <group col="4">
<field name="user_cashmove"/> <field name="name"/>
<field name="amount"/> <field name="user_cashmove"/>
<field name="box"/> <field name="amount"/>
<field name="create_date"/> <field name="box"/>
<field name="active"/> <field name="create_date"/>
</group> <field name="active"/>
</group>
</sheet>
</form> </form>
</field> </field>
</record> </record>
@ -216,8 +224,9 @@
<field name="model">lunch.category</field> <field name="model">lunch.category</field>
<field name="arch" type="xml"> <field name="arch" type="xml">
<form string="Category" version="7.0"> <form string="Category" version="7.0">
<separator string="Category Related to Products" colspan="4"/> <group>
<field name="name"/> <field name="name"/>
</group>
</form> </form>
</field> </field>
</record> </record>
@ -250,18 +259,19 @@
<field name="model">lunch.product</field> <field name="model">lunch.product</field>
<field name="arch" type="xml"> <field name="arch" type="xml">
<form string="Products" version="7.0"> <form string="Products" version="7.0">
<group col="6"> <sheet>
<field name="name"/> <group>
<field name="category_id"/> <group>
<field name="price" /> <field name="name"/>
</group> <field name="category_id"/>
<notebook colspan="4"> <field name="price" />
<page string="General Information"> </group>
<field name="active"/> <group>
<separator string="Description" colspan="4" /> <field name="active"/>
<field name="description" nolabel="1" colspan="4" /> </group>
</page> <field name="description" placeholder="Add a description" nolabel="1" colspan="4"/>
</notebook> </group>
</sheet>
</form> </form>
</field> </field>
</record> </record>

View File

@ -541,7 +541,7 @@ openerp.mail = function(session) {
var self = this; var self = this;
this.reinit(); this.reinit();
if (! this.view.datarecord.id || if (! this.view.datarecord.id ||
instance.web.BufferedDataSet.virtual_id_regex.test(this.view.datarecord.id)) { session.web.BufferedDataSet.virtual_id_regex.test(this.view.datarecord.id)) {
this.$element.find('.oe_mail_thread').hide(); this.$element.find('.oe_mail_thread').hide();
return; return;
} }

View File

@ -1,20 +1,3 @@
.oe_module_survey{
font-size: 12px;
border-style:dotted;
border-radius: 15px;
text-align: left;
height:145px;
width:220px;
}
.oe_survey_title{
font-size: 15px;
height: auto;
font-size: 16px;
font-weight:bold;
width: 205px;
}
.oe_survey_responsible{ .oe_survey_responsible{
height: auto; height: auto;
width: 200px; width: 200px;
@ -26,12 +9,6 @@
width: 200px; width: 200px;
font-size: 14px; font-size: 14px;
} }
.oe_survey_fill{
align:right;
padding: 1px 165px;
}
.oe_survey_rate{ .oe_survey_rate{
font-size: 14px; font-size: 14px;
} }

View File

@ -68,6 +68,7 @@ class survey(osv.osv):
'users': fields.many2many('res.users', 'survey_users_rel', 'sid', 'uid', 'Users'), 'users': fields.many2many('res.users', 'survey_users_rel', 'sid', 'uid', 'Users'),
'send_response': fields.boolean('Email Notification on Answer'), 'send_response': fields.boolean('Email Notification on Answer'),
'type': fields.many2one('survey.type', 'Type'), 'type': fields.many2one('survey.type', 'Type'),
'color': fields.integer('Color Index'),
'invited_user_ids': fields.many2many('res.users', 'survey_invited_user_rel', 'sid', 'uid', 'Invited User'), 'invited_user_ids': fields.many2many('res.users', 'survey_invited_user_rel', 'sid', 'uid', 'Invited User'),
} }
_defaults = { _defaults = {
@ -177,7 +178,7 @@ class survey_page(osv.osv):
_columns = { _columns = {
'title': fields.char('Page Title', size=128, required=1), 'title': fields.char('Page Title', size=128, required=1),
'survey_id': fields.many2one('survey', 'Survey', ondelete='cascade'), 'survey_id': fields.many2one('survey', 'Survey', ondelete='cascade'),
'question_ids': fields.one2many('survey.question', 'page_id', 'Question'), 'question_ids': fields.one2many('survey.question', 'page_id', 'Questions'),
'sequence': fields.integer('Page Nr'), 'sequence': fields.integer('Page Nr'),
'note': fields.text('Description'), 'note': fields.text('Description'),
} }

View File

@ -26,189 +26,206 @@
<field name="state" widget="statusbar" statusbar_visible="open,close"/> <field name="state" widget="statusbar" statusbar_visible="open,close"/>
</header> </header>
<sheet> <sheet>
<group col="6" colspan="6"> <div class="oe_button_box oe_right">
<field name="title"/> <button name="%(action_view_survey_question_message)d" states="open,draft,close,cancel" string="Test Survey" type="action" icon="gtk-new" context="{'active':True,'survey_id': active_id}" attrs="{'invisible':[('id','=',0)]}"/>
<field name="responsible_id"/> <button name="%(action_view_survey_question_message)d" states="open,draft,close,cancel" string="Answer Survey" type="action" icon="gtk-execute" context="{'survey_id': active_id}" attrs="{'invisible':[('state','!=','open')]}"/>
<field name="id" invisible="1"/> </div>
<button name="%(action_view_survey_question_message)d" states="open,draft,close,cancel" <label for="title" class="oe_edit_only"/>
string="Test Survey" type="action" icon="gtk-new" <h1>
context="{'active':True,'survey_id': active_id}" attrs="{'invisible':[('id','=',0)]}"/> <field name="title" select="1" class="oe_inline"/>
<button name="%(action_view_survey_question_message)d" states="open,draft,close,cancel" <label string=", " attrs="{'invisible':[('type','=',False)]}" class="oe_inline"/>
string="Answer Survey" type="action" icon="gtk-execute" context="{'survey_id': active_id}" attrs="{'invisible':[('state','!=','open')]}"/> <field name="type" class="oe_inline"/>
<button name="%(action_view_survey_question_message)d" states="open,draft,close,cancel" </h1>
string="Edit Survey" type="action" icon="gtk-edit" context="{'active':True,'edit' : True,'survey_id': active_id}"/> <group>
</group> <group>
<notebook> <field name="id" invisible="1"/>
<page string="Survey"> <field name="responsible_id" class="oe_inline"/>
<field name="page_ids" colspan="4" nolabel="1" mode="tree"> <field name="send_response"/>
<form string="Survey Page"> </group>
<field name="title"/> <group>
<field name="sequence" groups="base.group_no_one"/> <field name="max_response_limit" attrs="{'readonly':[('state','in',('open','close'))]}"/>
<separator string="Description" colspan="4"/> <field name="response_user" attrs="{'readonly':[('state','in',('open','close'))]}"/>
<field name="note" colspan="4" nolabel="1"/> </group>
<field name="question_ids" height="200" width="200" colspan="4" nolabel="1"> </group>
<form string="Survey Question" > <notebook>
<group col="6" colspan="6" height="600" width="200"> <page string="Survey Details">
<field name="question" colspan="4"/> <field name="note" colspan="4" placeholder="Survey description..."/>
<field name="sequence"/> <label for="page_ids"/>
<field name="tot_resp"/> <field name="page_ids" colspan="4" mode="tree">
<field name="type" on_change="on_change_type(type)"/> <form string="Survey Page" version="7.0">
<field name="in_visible_rating_weight" invisible="1"/> <sheet>
<field name="in_visible_menu_choice" invisible="1"/> <label for="title" class="oe_edit_only"/>
<field name="in_visible_answer_type" invisible="1"/> <h1>
<notebook colspan="4"> <field name="title"/>
<page string="Options"> </h1>
<group attrs="{'invisible':[('type','!=','multiple_textboxes_diff_type'),('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','table')]}"> <group>
<separator string="Answer" colspan="4"/> <field name="note" placeholder="Description on the survey page..." nolabel="1"/>
<group colspan="4" attrs="{'invisible':[('type','=','table')]}"> </group>
<field name="answer_choice_ids" nolabel="1" colspan="4" context="{'in_visible_answer_type': in_visible_answer_type}"/> <newline/>
</group> <group>
<group colspan="4" attrs="{'invisible':[('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','table')]}"> <label for="question_ids"/>
<field name="column_heading_ids" colspan="4" nolabel="1" context="{'in_visible_rating_weight':in_visible_rating_weight,'in_visible_menu_choice':in_visible_menu_choice}"/> <newline/>
<group colspan="4" attrs="{'invisible':[('type','!=','table')]}"> <field name="question_ids" nolabel="1">
<field name="no_of_rows"/> <form string="Survey Question">
</group> <group>
</group> <group>
<field name="question"/>
<field name="type" on_change="on_change_type(type)"/>
</group> </group>
<newline/> </group>
<group attrs="{'invisible':[('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'), ('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale')]}"> <newline/>
<separator string="Comment Field" colspan="4"/> <group>
<group colspan="4"> <field name="in_visible_rating_weight" invisible="1"/>
<field name="is_comment_require"/> <field name="in_visible_menu_choice" invisible="1"/>
</group> <field name="in_visible_answer_type" invisible="1"/>
<group attrs="{'invisible':[('is_comment_require','=',False)]}"> <notebook colspan="4">
<group col="4" colspan="4"> <page string="Options">
<field name="comment_field_type" colspan="1"/> <group attrs="{'invisible':[('type','!=','multiple_textboxes_diff_type'),('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','table')]}" string="Answer">
<group colspan="2" attrs="{'invisible':[('comment_field_type','!=','char'),('comment_field_type','!=','text')]}"> <group colspan="4" attrs="{'invisible':[('type','=','table')]}">
<field colspan="2" name="comment_label" /> <field name="answer_choice_ids" nolabel="1" colspan="4" context="{'in_visible_answer_type': in_visible_answer_type}"/>
</group>
<group colspan="4" attrs="{'invisible':[('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','table')]}">
<field name="column_heading_ids" colspan="4" nolabel="1" context="{'in_visible_rating_weight':in_visible_rating_weight,'in_visible_menu_choice':in_visible_menu_choice}"/>
<group colspan="4" attrs="{'invisible':[('type','!=','table')]}">
<field name="no_of_rows"/>
</group> </group>
</group> </group>
<group col="6" colspan="4" attrs="{'invisible':[('comment_field_type','!=','char'),('comment_field_type','!=','text')]}">
<field name="comment_valid_type" colspan="2"/>
<group colspan="2" attrs="{'invisible':[('comment_valid_type','!=','must_be_specific_length'), ('comment_valid_type','!=','must_be_whole_number')]}">
<field name="comment_minimum_no" string="Between"/>
<field name="comment_maximum_no" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_decimal_number')]}">
<field name="comment_minimum_float" string="Between"/>
<field name="comment_maximum_float" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_date')]}">
<field name="comment_minimum_date" string="Between"/>
<field name="comment_maximum_date" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_specific_length'),('comment_valid_type','!=','must_be_decimal_number'),('comment_valid_type','!=','must_be_whole_number'),('comment_valid_type','!=','must_be_date'),('comment_valid_type','!=','must_be_email_address')]}">
<label string="When the comment is an invalid format, display this error message" colspan="4"/>
<field name="comment_valid_err_msg" nolabel="1" colspan="4"/>
</group>
</group>
</group> </group>
</group>
<newline/>
<group attrs="{'invisible':[('type','!=','matrix_of_choices_only_one_ans'),('type','!=','rating_scale')]}">
<field name="comment_column"/>
<group colspan="2" attrs="{'invisible':[('comment_column','!=',True)]}">
<field name="column_name" colspan="2"/>
</group>
</group>
<newline/>
<group attrs="{'invisible':[('type','!=','single_textbox'), ('type','!=','multiple_textboxes')]}">
<separator string="Validation" colspan="4"/>
<group colspan="4">
<field name="is_validation_require"/>
</group>
<group col="6" colspan="4" attrs="{'invisible':[('is_validation_require','=',False)]}">
<field name="validation_type" colspan="2"/>
<group colspan="2" attrs="{'invisible':[('validation_type','!=','must_be_specific_length'), ('validation_type','!=','must_be_whole_number')]}">
<field name="validation_minimum_no" string="Between"/>
<field name="validation_maximum_no" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_decimal_number')]}">
<field name="validation_minimum_float" string="Between"/>
<field name="validation_maximum_float" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_date')]}">
<field name="validation_minimum_date" string="Between"/>
<field name="validation_maximum_date" string="and"/>
</group>
</group>
<group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_specific_length'),('validation_type','!=','must_be_decimal_number'),('validation_type','!=','must_be_whole_number'),('validation_type','!=','must_be_date'),('validation_type','!=','must_be_email_address')]}">
<label string="When the comment is an invalid format, display this error message" colspan="4"/>
<field name="validation_valid_err_msg" nolabel="1" colspan="4"/>
</group>
</group>
<newline/>
<group attrs="{'invisible':[('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','single_textbox'),('type','!=','comment'),('type','!=','multiple_textboxes_diff_type')]}">
<separator string="Required Answer" colspan="4"/>
<newline/> <newline/>
<field name="is_require_answer"/> <group attrs="{'invisible':[('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'), ('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale')]}">
<group col="6" colspan="4" attrs="{'invisible':[('is_require_answer','=',False)]}"> <separator string="Comment Field" colspan="4"/>
<group colspan="4" attrs="{'invisible':[('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','multiple_textboxes_diff_type')]}"> <group colspan="4">
<field name="required_type"/> <field name="is_comment_require"/>
<group colspan="2" attrs="{'invisible':[('required_type','!=','at least'),('required_type','!=','at most'),('required_type','!=','exactly')]}">
<field name="req_ans" />
</group>
<group colspan="4" attrs="{'invisible':[('required_type','!=','a range')]}">
<field name="minimum_req_ans"/>
<field name="maximum_req_ans"/>
</group>
</group> </group>
<group colspan="4" attrs="{'invisible':[('required_type','!=','all'),('required_type','!=','at least'),('required_type','!=','at most'),('required_type','!=','exactly'),('required_type','!=','a range'),('is_require_answer','!=',True)]}"> <group attrs="{'invisible':[('is_comment_require','=',False)]}">
<label string="When the question is not answered, display this error message:"/> <group col="4" colspan="4">
<field name="req_error_msg" colspan="4" nolabel="1"/> <field name="comment_field_type" colspan="1"/>
</group> <group colspan="2" attrs="{'invisible':[('comment_field_type','!=','char'),('comment_field_type','!=','text')]}">
<group colspan="4" attrs="{'invisible':[('type','!=','numerical_textboxes')]}"> <field colspan="2" name="comment_label" />
<group colspan="2" > </group>
<field name="numeric_required_sum"/> </group>
<group col="6" colspan="4" attrs="{'invisible':[('comment_field_type','!=','char'),('comment_field_type','!=','text')]}">
<field name="comment_valid_type" colspan="2"/>
<group colspan="2" attrs="{'invisible':[('comment_valid_type','!=','must_be_specific_length'), ('comment_valid_type','!=','must_be_whole_number')]}">
<field name="comment_minimum_no" string="Between"/>
<field name="comment_maximum_no" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_decimal_number')]}">
<field name="comment_minimum_float" string="Between"/>
<field name="comment_maximum_float" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_date')]}">
<field name="comment_minimum_date" string="Between"/>
<field name="comment_maximum_date" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_specific_length'),('comment_valid_type','!=','must_be_decimal_number'),('comment_valid_type','!=','must_be_whole_number'),('comment_valid_type','!=','must_be_date'),('comment_valid_type','!=','must_be_email_address')]}">
<label string="When the comment is an invalid format, display this error message" colspan="4"/>
<field name="comment_valid_err_msg" nolabel="1" colspan="4"/>
</group>
</group> </group>
<newline/>
<label string="When the choices do not add up correctly, display this error message"/>
<field name="numeric_required_sum_err_msg" colspan="4" nolabel="1"/>
</group>
<group colspan="4" attrs="{'invisible':[('type','!=','rating_scale')]}">
<field name="rating_allow_one_column_require"/>
</group> </group>
</group> </group>
</group> <newline/>
<newline/> <group attrs="{'invisible':[('type','!=','matrix_of_choices_only_one_ans'),('type','!=','rating_scale')]}">
<group attrs="{'invisible':[('type','!=','descriptive_text')]}"> <field name="comment_column"/>
<separator string="Descriptive Text" colspan="4"/> <group colspan="2" attrs="{'invisible':[('comment_column','!=',True)]}">
<field name="descriptive_text" colspan="4" nolabel="1"/> <field name="column_name" colspan="2"/>
</group> </group>
</page> </group>
</notebook> <newline/>
</group> <group attrs="{'invisible':[('type','!=','single_textbox'), ('type','!=','multiple_textboxes')]}">
</form> <separator string="Validation" colspan="4"/>
<tree string="Survey Question"> <group colspan="4">
<field name="sequence" string="Seq"/> <field name="is_validation_require"/>
<field name="question" colspan="4"/> </group>
<field name="answer_choice_ids"/> <group col="6" colspan="4" attrs="{'invisible':[('is_validation_require','=',False)]}">
</tree> <field name="validation_type" colspan="2"/>
</field> <group colspan="2" attrs="{'invisible':[('validation_type','!=','must_be_specific_length'), ('validation_type','!=','must_be_whole_number')]}">
</form> <field name="validation_minimum_no" string="Between"/>
</field> <field name="validation_maximum_no" string="and"/>
</page> </group>
<page string="Other"> <group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_decimal_number')]}">
<group colspan="6" col='4'> <field name="validation_minimum_float" string="Between"/>
<field name="max_response_limit" <field name="validation_maximum_float" string="and"/>
attrs="{'readonly':[('state','in',('open','close'))]}"/> </group>
<field name="response_user" <group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_date')]}">
attrs="{'readonly':[('state','in',('open','close'))]}"/> <field name="validation_minimum_date" string="Between"/>
<field name="type"/> <field name="validation_maximum_date" string="and"/>
<field name="send_response"/> </group>
</group> </group>
<separator colspan="4" string="Survey Details"/> <group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_specific_length'),('validation_type','!=','must_be_decimal_number'),('validation_type','!=','must_be_whole_number'),('validation_type','!=','must_be_date'),('validation_type','!=','must_be_email_address')]}">
<field name="note" colspan="4" nolabel="1"/> <label string="When the comment is an invalid format, display this error message" colspan="4"/>
<field name="validation_valid_err_msg" nolabel="1" colspan="4"/>
</group>
</group>
<newline/>
<group attrs="{'invisible':[('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','single_textbox'),('type','!=','comment'),('type','!=','multiple_textboxes_diff_type')]}">
<separator string="Required Answer" colspan="4"/>
<newline/>
<field name="is_require_answer"/>
<group col="6" colspan="4" attrs="{'invisible':[('is_require_answer','=',False)]}">
<group colspan="4" attrs="{'invisible':[('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','multiple_textboxes_diff_type')]}">
<field name="required_type"/>
<group colspan="2" attrs="{'invisible':[('required_type','!=','at least'),('required_type','!=','at most'),('required_type','!=','exactly')]}">
<field name="req_ans" />
</group>
<group colspan="4" attrs="{'invisible':[('required_type','!=','a range')]}">
<field name="minimum_req_ans"/>
<field name="maximum_req_ans"/>
</group>
</group>
<group colspan="4" attrs="{'invisible':[('required_type','!=','all'),('required_type','!=','at least'),('required_type','!=','at most'),('required_type','!=','exactly'),('required_type','!=','a range'),('is_require_answer','!=',True)]}">
<label string="When the question is not answered, display this error message:"/>
<field name="req_error_msg" colspan="4" nolabel="1"/>
</group>
<group colspan="4" attrs="{'invisible':[('type','!=','numerical_textboxes')]}">
<group colspan="2" >
<field name="numeric_required_sum"/>
</group>
<newline/>
<label string="When the choices do not add up correctly, display this error message"/>
<field name="numeric_required_sum_err_msg" colspan="4" nolabel="1"/>
</group>
<group colspan="4" attrs="{'invisible':[('type','!=','rating_scale')]}">
<field name="rating_allow_one_column_require"/>
</group>
</group>
</group>
<newline/>
<group attrs="{'invisible':[('type','!=','descriptive_text')]}">
<separator string="Descriptive Text" colspan="4"/>
<field name="descriptive_text" colspan="4" nolabel="1"/>
</group>
</page>
</notebook>
</group>
</form>
<tree string="Survey Question">
<field name="sequence" string="Seq"/>
<field name="question"/>
<field name="answer_choice_ids"/>
</tree>
</field>
</group>
</sheet>
</form>
</field>
</page> </page>
<page string="Invited User"> <page string="Invited User">
<field name="invited_user_ids" nolabel="1" readonly="1"/> <field name="invited_user_ids" readonly="1"/>
</page> </page>
<page string="History"> <page string="History">
<field name="date_open"/> <group>
<field name="date_close"/> <group>
<field name="tot_start_survey"/> <field name="date_open"/>
<field name="tot_comp_survey"/> <field name="date_close"/>
<field name="history" colspan="4" nolabel="1"> </group>
<group>
<field name="tot_start_survey"/>
<field name="tot_comp_survey"/>
</group>
</group>
<field name="history" colspan="4">
<tree string="History"> <tree string="History">
<field name="date"/> <field name="date"/>
<field name="user_id"/> <field name="user_id"/>
@ -217,8 +234,8 @@
<field name="date"/> <field name="date"/>
<field name="user_id"/> <field name="user_id"/>
</form> </form>
</field> </field>
</page> </page>
</notebook> </notebook>
</sheet> </sheet>
</form> </form>
@ -286,32 +303,37 @@
<kanban> <kanban>
<field name="title"/> <field name="title"/>
<field name="date_open"/> <field name="date_open"/>
<field name="color"/>
<templates> <templates>
<t t-name="kanban-box"> <t t-name="kanban-box">
<div class="oe_module_survey"> <div t-attf-class="oe_kanban_color_#{kanban_getcolor(record.color.raw_value)} oe_kanban_card">
<a class="oe_module_icon"> <div class="oe_dropdown_toggle oe_dropdown_kanban">
<div class="oe_survey_title"><t t-esc="record.title.raw_value.toString()"/></div><br/> <span class="oe_e">i</span>
<div class="oe_survey_responsible"> <ul class="oe_dropdown_menu">
<t t-if="record.responsible_id.raw_value">By: <field name="responsible_id"/></t> <li><a type="edit">Edit...</a></li>
</div><br/> <li><a type="delete">Delete</a></li>
<div class="oe_survey_start_date"> <li><ul class="oe_kanban_colorpicker" data-field="color"/></li>
Open From: </ul>
<t t-if="record.date_open.raw_value"> </div>
<t t-esc="record.date_open.raw_value.getDate()"/> <div class="oe_kanban_content">
<t t-esc="record.date_open.raw_value.toString('MMM')"/>, <h3 class="oe_kanban_ellipsis"><t t-esc="record.title.raw_value.toString()"><field name="title"/></t></h3>
<t t-esc="record.date_open.raw_value.getFullYear()"/> <div class="oe_survey_responsible">
</t> <t t-if="record.responsible_id.raw_value">By: <field name="responsible_id"/></t>
</div><br/> </div><br/>
<div class="oe_survey_rate"> <div class="oe_survey_start_date">
Rate: <t t-if="record.date_open.raw_value">
<div class="oe_survey_fill" > Opened at
<button type="object" name="fill_survey" class=""> <t t-esc="record.date_open.raw_value.getDate()"/>
<span>Fill</span> <t t-esc="record.date_open.raw_value.toString('MMM')"/>,
</button> <t t-esc="record.date_open.raw_value.getFullYear()"/>
</div> </t>
</div> </div><br/>
</a> <div class="oe_survey_rate">
</div> Rate:
<a name="fill_survey" type="object">Fill</a>
</div>
</div>
</div>
</t> </t>
</templates> </templates>
</kanban> </kanban>
@ -344,149 +366,163 @@
<field name="arch" type="xml"> <field name="arch" type="xml">
<form string="Survey Page" version="7.0"> <form string="Survey Page" version="7.0">
<sheet> <sheet>
<field name="title" colspan="4"/> <label for="title" class="oe_edit_only"/>
<field name="survey_id"/> <h1>
<field name="sequence"/> <field name="title"/>
<separator string="Description" colspan="4"/> </h1>
<field name="note" colspan="4" nolabel="1"/> <group colspan="4">
<field name="question_ids" colspan="4" nolabel="1"> <field name="survey_id"/>
<form string="Survey Question">
<field name="question" colspan="4"/>
<field name="sequence"/> <field name="sequence"/>
<field name="tot_resp"/> </group>
<field name="type" on_change="on_change_type(type)"/> <group colspan="4">
<field name="in_visible_rating_weight" invisible="1"/> <field name="note" nolabel="1" placeholder="Description on the survey page..."/>
<field name="in_visible_menu_choice" invisible="1"/> </group>
<field name="in_visible_answer_type" invisible="1"/> <group col="4">
<notebook colspan="4"> <label for="question_ids"/>
<page string="Options"> <newline/>
<group attrs="{'invisible':[('type','!=','multiple_textboxes_diff_type'),('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','table')]}"> <field name="question_ids" nolabel="1">
<separator string="Answer" colspan="4"/> <form string="Survey Question">
<group colspan="4" attrs="{'invisible':[('type','=','table')]}"> <group>
<field name="answer_choice_ids" nolabel="1" colspan="4" context="{'in_visible_answer_type': in_visible_answer_type}"/> <group>
</group> <field name="question" select="1"/>
<group colspan="4" attrs="{'invisible':[('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','table')]}"> <field name="type" on_change="on_change_type(type)"/>
<field name="column_heading_ids" colspan="4" nolabel="1" context="{'in_visible_rating_weight':in_visible_rating_weight,'in_visible_menu_choice':in_visible_menu_choice}"/> </group>
<group colspan="4" attrs="{'invisible':[('type','!=','table')]}"> <group>
<field name="no_of_rows"/> <field name="sequence" invisible="1"/>
</group> <field name="tot_resp" invisible="1"/>
</group> <field name="in_visible_rating_weight" invisible="1"/>
<field name="in_visible_menu_choice" invisible="1"/>
<field name="in_visible_answer_type" invisible="1"/>
</group> </group>
<newline/> <newline/>
<group attrs="{'invisible':[('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'), ('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale')]}"> <notebook colspan="4">
<separator string="Comment Field" colspan="4"/> <page string="Options">
<group colspan="4"> <group attrs="{'invisible':[('type','!=','multiple_textboxes_diff_type'),('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','table')]}" string="Answer" col="4">
<field name="is_comment_require"/> <group attrs="{'invisible':[('type','=','table')]}">
</group> <field name="answer_choice_ids" nolabel="1" context="{'in_visible_answer_type': in_visible_answer_type}"/>
<group attrs="{'invisible':[('is_comment_require','=',False)]}"> </group>
<group col="4" colspan="4"> <group attrs="{'invisible':[('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','table')]}">
<field name="comment_field_type" colspan="1"/> <field name="column_heading_ids" nolabel="1" context="{'in_visible_rating_weight':in_visible_rating_weight,'in_visible_menu_choice':in_visible_menu_choice}"/>
<group colspan="2" attrs="{'invisible':[('comment_field_type','!=','char'),('comment_field_type','!=','text')]}"> <group attrs="{'invisible':[('type','!=','table')]}">
<field colspan="2" name="comment_label" /> <field name="no_of_rows"/>
</group>
</group>
</group>
<newline/>
<group attrs="{'invisible':[('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'), ('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale')]}" string="Comment Field" col="4">
<group>
<field name="is_comment_require"/>
</group>
<group attrs="{'invisible':[('is_comment_require','=',False)]}">
<group>
<field name="comment_field_type" colspan="1"/>
<group attrs="{'invisible':[('comment_field_type','!=','char'),('comment_field_type','!=','text')]}">
<field name="comment_label" />
</group>
</group>
<group col="6" colspan="4" attrs="{'invisible':[('comment_field_type','!=','char'),('comment_field_type','!=','text')]}">
<field name="comment_valid_type" colspan="2"/>
<group colspan="2" attrs="{'invisible':[('comment_valid_type','!=','must_be_specific_length'), ('comment_valid_type','!=','must_be_whole_number')]}">
<field name="comment_minimum_no" string="Between"/>
<field name="comment_maximum_no" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_decimal_number')]}">
<field name="comment_minimum_float" string="Between"/>
<field name="comment_maximum_float" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_date')]}">
<field name="comment_minimum_date" string="Between"/>
<field name="comment_maximum_date" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_specific_length'),('comment_valid_type','!=','must_be_decimal_number'),('comment_valid_type','!=','must_be_whole_number'),('comment_valid_type','!=','must_be_date'),('comment_valid_type','!=','must_be_email_address')]}">
<label string="When the comment is an invalid format, display this error message" colspan="4"/>
<field name="comment_valid_err_msg" nolabel="1" colspan="4"/>
</group>
</group>
</group> </group>
</group> </group>
<group col="6" colspan="4" attrs="{'invisible':[('comment_field_type','!=','char'),('comment_field_type','!=','text')]}"> <newline/>
<field name="comment_valid_type" colspan="2"/> <group attrs="{'invisible':[('type','!=','matrix_of_choices_only_one_ans'),('type','!=','rating_scale')]}">
<group colspan="2" attrs="{'invisible':[('comment_valid_type','!=','must_be_specific_length'), ('comment_valid_type','!=','must_be_whole_number')]}"> <field name="comment_column"/>
<field name="comment_minimum_no" string="Between"/> <group colspan="2" attrs="{'invisible':[('comment_column','!=',True)]}">
<field name="comment_maximum_no" string="and"/> <field name="column_name" colspan="2"/>
</group> </group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_decimal_number')]}"> </group>
<field name="comment_minimum_float" string="Between"/> <newline/>
<field name="comment_maximum_float" string="and"/> <group attrs="{'invisible':[('type','!=','single_textbox'), ('type','!=','multiple_textboxes')]}">
<separator string="Validation" colspan="4"/>
<group colspan="4">
<field name="is_validation_require"/>
</group> </group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_date')]}"> <group col="6" colspan="4" attrs="{'invisible':[('is_validation_require','=',False)]}">
<field name="comment_minimum_date" string="Between"/> <field name="validation_type" colspan="2"/>
<field name="comment_maximum_date" string="and"/> <group colspan="2" attrs="{'invisible':[('validation_type','!=','must_be_specific_length'), ('validation_type','!=','must_be_whole_number')]}">
<field name="validation_minimum_no" string="Between"/>
<field name="validation_maximum_no" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_decimal_number')]}">
<field name="validation_minimum_float" string="Between"/>
<field name="validation_maximum_float" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_date')]}">
<field name="validation_minimum_date" string="Between"/>
<field name="validation_maximum_date" string="and"/>
</group>
</group> </group>
<group colspan="4" attrs="{'invisible':[('comment_valid_type','!=','must_be_specific_length'),('comment_valid_type','!=','must_be_decimal_number'),('comment_valid_type','!=','must_be_whole_number'),('comment_valid_type','!=','must_be_date'),('comment_valid_type','!=','must_be_email_address')]}"> <group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_specific_length'),('validation_type','!=','must_be_decimal_number'),('validation_type','!=','must_be_whole_number'),('validation_type','!=','must_be_date'),('validation_type','!=','must_be_email_address')]}">
<label string="When the comment is an invalid format, display this error message" colspan="4"/> <label string="When the comment is an invalid format, display this error message" colspan="4"/>
<field name="comment_valid_err_msg" nolabel="1" colspan="4"/> <field name="validation_valid_err_msg" nolabel="1" colspan="4"/>
</group> </group>
</group> </group>
</group> <newline/>
</group> <group attrs="{'invisible':[('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','single_textbox'),('type','!=','comment'),('type','!=','multiple_textboxes_diff_type')]}">
<newline/> <separator string="Required Answer" colspan="4"/>
<group attrs="{'invisible':[('type','!=','matrix_of_choices_only_one_ans'),('type','!=','rating_scale')]}">
<field name="comment_column"/>
<group colspan="2" attrs="{'invisible':[('comment_column','!=',True)]}">
<field name="column_name" colspan="2"/>
</group>
</group>
<newline/>
<group attrs="{'invisible':[('type','!=','single_textbox'), ('type','!=','multiple_textboxes')]}">
<separator string="Validation" colspan="4"/>
<group colspan="4">
<field name="is_validation_require"/>
</group>
<group col="6" colspan="4" attrs="{'invisible':[('is_validation_require','=',False)]}">
<field name="validation_type" colspan="2"/>
<group colspan="2" attrs="{'invisible':[('validation_type','!=','must_be_specific_length'), ('validation_type','!=','must_be_whole_number')]}">
<field name="validation_minimum_no" string="Between"/>
<field name="validation_maximum_no" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_decimal_number')]}">
<field name="validation_minimum_float" string="Between"/>
<field name="validation_maximum_float" string="and"/>
</group>
<group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_date')]}">
<field name="validation_minimum_date" string="Between"/>
<field name="validation_maximum_date" string="and"/>
</group>
</group>
<group colspan="4" attrs="{'invisible':[('validation_type','!=','must_be_specific_length'),('validation_type','!=','must_be_decimal_number'),('validation_type','!=','must_be_whole_number'),('validation_type','!=','must_be_date'),('validation_type','!=','must_be_email_address')]}">
<label string="When the comment is an invalid format, display this error message" colspan="4"/>
<field name="validation_valid_err_msg" nolabel="1" colspan="4"/>
</group>
</group>
<newline/>
<group attrs="{'invisible':[('type','!=','multiple_choice_only_one_ans'), ('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','single_textbox'),('type','!=','comment'),('type','!=','multiple_textboxes_diff_type')]}">
<separator string="Required Answer" colspan="4"/>
<newline/>
<field name="is_require_answer"/>
<group col="6" colspan="4" attrs="{'invisible':[('is_require_answer','=',False)]}">
<group colspan="4" attrs="{'invisible':[('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','multiple_textboxes_diff_type')]}">
<field name="required_type"/>
<group colspan="2" attrs="{'invisible':[('required_type','!=','at least'),('required_type','!=','at most'),('required_type','!=','exactly')]}">
<field name="req_ans" />
</group>
<group colspan="4" attrs="{'invisible':[('required_type','!=','a range')]}">
<field name="minimum_req_ans"/>
<field name="maximum_req_ans"/>
</group>
</group>
<group colspan="4" attrs="{'invisible':[('required_type','!=','all'),('required_type','!=','at least'),('required_type','!=','at most'),('required_type','!=','exactly'),('required_type','!=','a range'),('is_require_answer','!=',True)]}">
<label string="When the question is not answered, display this error message:"/>
<field name="req_error_msg" colspan="4" nolabel="1"/>
</group>
<group colspan="4" attrs="{'invisible':[('type','!=','numerical_textboxes')]}">
<group colspan="2" >
<field name="numeric_required_sum"/>
</group>
<newline/> <newline/>
<label string="When the choices do not add up correctly, display this error message"/> <field name="is_require_answer"/>
<field name="numeric_required_sum_err_msg" colspan="4" nolabel="1"/> <group col="6" colspan="4" attrs="{'invisible':[('is_require_answer','=',False)]}">
<group colspan="4" attrs="{'invisible':[('type','!=','multiple_choice_multiple_ans'),('type','!=','matrix_of_choices_only_one_ans'),('type','!=','matrix_of_choices_only_multi_ans'),('type','!=','matrix_of_drop_down_menus'),('type','!=','rating_scale'),('type','!=','multiple_textboxes'),('type','!=','numerical_textboxes'),('type','!=','date'),('type','!=','date_and_time'),('type','!=','multiple_textboxes_diff_type')]}">
<field name="required_type"/>
<group colspan="2" attrs="{'invisible':[('required_type','!=','at least'),('required_type','!=','at most'),('required_type','!=','exactly')]}">
<field name="req_ans" />
</group>
<group colspan="4" attrs="{'invisible':[('required_type','!=','a range')]}">
<field name="minimum_req_ans"/>
<field name="maximum_req_ans"/>
</group>
</group>
<group colspan="4" attrs="{'invisible':[('required_type','!=','all'),('required_type','!=','at least'),('required_type','!=','at most'),('required_type','!=','exactly'),('required_type','!=','a range'),('is_require_answer','!=',True)]}">
<label string="When the question is not answered, display this error message:"/>
<field name="req_error_msg" colspan="4" nolabel="1"/>
</group>
<group colspan="4" attrs="{'invisible':[('type','!=','numerical_textboxes')]}">
<group colspan="2">
<field name="numeric_required_sum"/>
</group>
<newline/>
<label string="When the choices do not add up correctly, display this error message"/>
<field name="numeric_required_sum_err_msg" colspan="4" nolabel="1"/>
</group>
<group colspan="4" attrs="{'invisible':[('type','!=','rating_scale')]}">
<field name="rating_allow_one_column_require"/>
</group>
</group>
</group> </group>
<group colspan="4" attrs="{'invisible':[('type','!=','rating_scale')]}"> <newline/>
<field name="rating_allow_one_column_require"/> <group attrs="{'invisible':[('type','!=','descriptive_text')]}">
<separator string="Descriptive Text" colspan="4"/>
<field name="descriptive_text" colspan="4" nolabel="1"/>
</group> </group>
</group> </page>
</group> </notebook>
<newline/> </group>
<group attrs="{'invisible':[('type','!=','descriptive_text')]}"> </form>
<separator string="Descriptive Text" colspan="4"/> <tree string="Survey Question">
<field name="descriptive_text" colspan="4" nolabel="1"/> <field name="sequence" string="Seq"/>
</group> <field name="question"/>
</page> <field name="answer_choice_ids"/>
</notebook> </tree>
</field>
</form> </group>
<tree string="Survey Question">
<field name="sequence" string="Seq"/>
<field name="question" colspan="4"/>
<field name="answer_choice_ids"/>
</tree>
</field>
</sheet> </sheet>
</form> </form>
</field> </field>

View File

@ -18,7 +18,6 @@
<button string="Cancel" class="oe_link" special="cancel" /> <button string="Cancel" class="oe_link" special="cancel" />
</header> </header>
<group col="4"> <group col="4">
<separator colspan="4" string = "Select Survey and Related Answer"/>
<field name="survey_id"/> <field name="survey_id"/>
<field name="response_id" domain="[('survey_id','=', survey_id)]"/> <field name="response_id" domain="[('survey_id','=', survey_id)]"/>
</group> </group>

View File

@ -16,10 +16,10 @@
or or
<button string="Cancel" class="oe_link" special="cancel" /> <button string="Cancel" class="oe_link" special="cancel" />
</header> </header>
<group string="Select Survey"> <group>
<field name="survey_id" on_change="on_change_survey(survey_id)"/> <field name="survey_id" on_change="on_change_survey(survey_id)"/>
</group> </group>
<field name="note" attrs="{'readonly': [('survey_id','=',False)]}"/> <field name="note" placeholder="Add Description" attrs="{'readonly': [('survey_id','=',False)]}"/>
</form> </form>
</field> </field>
</record> </record>