[ADD] added kanban view for survey module and also added the functionality in portal_customer module
bzr revid: bde@tinyerp.com-20120417055010-rtun8tblbubbs270
This commit is contained in:
parent
62c1606372
commit
e014e992a8
|
@ -22,7 +22,7 @@
|
|||
{
|
||||
'name' : "Portal Customer",
|
||||
'version' : "1.0",
|
||||
'depends' : ["sale","portal","event"],
|
||||
'depends' : ["sale","portal","event","survey"],
|
||||
'author' : "OpenERP SA",
|
||||
'category': 'Portal',
|
||||
'description': """
|
||||
|
|
|
@ -25,7 +25,7 @@
|
|||
<menuitem name="After Sales Services" id="customer_portal_after_sales" parent="customer_portal"/>
|
||||
<menuitem name="Issues" id="customer_portal_issues" parent="customer_portal_after_sales"/>
|
||||
<menuitem name="Claims" id="customer_portal_claims" parent="customer_portal_after_sales"/>
|
||||
<menuitem name="Feedback" id="customer_portal_feedback" parent="customer_portal_after_sales"/>
|
||||
<menuitem name="Feedback" id="customer_portal_feedback" parent="customer_portal_after_sales" action="survey.action_survey_form1"/>
|
||||
|
||||
<menuitem name="Contact Us" id="customer_portal_contact" parent="customer_portal"/>
|
||||
|
||||
|
|
|
@ -15,3 +15,14 @@ access_account_move_line,account.move.line,account.model_account_move_line,porta
|
|||
access_account_move_reconcile,account.move.reconcile,account.model_account_move_reconcile,portal_customer.group_sales_portal,1,0,0,0
|
||||
access_event_event,event.event,event.model_event_event,portal_customer.group_sales_portal,1,1,0,0
|
||||
access_event_registration,event.registration,event.model_event_registration,portal_customer.group_sales_portal,1,1,0,0
|
||||
access_event_event,event.event,event.model_event_event,portal_customer.group_sales_portal,1,1,0,0
|
||||
access_event_registration,event.registration,event.model_event_registration,portal_customer.group_sales_portal,1,1,0,0
|
||||
access_survey_survey,survey_survey,survey.model_survey,portal_customer.group_sales_portal,1,1,0,0
|
||||
access_survey_page,survey_page,survey.model_survey_page,portal_customer.group_sales_portal,1,1,0,0
|
||||
access_survey_question,survey_question,survey.model_survey_question,portal_customer.group_sales_portal,1,0,0,0
|
||||
access_survey_answer,survey_answer,survey.model_survey_answer,portal_customer.group_sales_portal,1,1,0,0
|
||||
access_survey_response,survey_response,survey.model_survey_response,portal_customer.group_sales_portal,1,1,1,0
|
||||
access_survey_history,survey_history,survey.model_survey_history,portal_customer.group_sales_portal,1,1,1,0
|
||||
access_survey_question_column_heading,survey_question_column_heading,survey.model_survey_question_column_heading,portal_customer.group_sales_portal,1,0,0,0
|
||||
access_survey_response_line,survey_response_line,survey.model_survey_response_line,portal_customer.group_sales_portal,1,1,1,0
|
||||
access_survey_response_answer,survey_response_answer,survey.model_survey_response_answer,portal_customer.group_sales_portal,1,1,1,0
|
|
|
@ -53,6 +53,7 @@ Partners are also sent mails with user name and password for the invitation of t
|
|||
'test/survey_question_type.yml',
|
||||
'test/survey_report.yml',
|
||||
],
|
||||
'css': ['static/src/css/survey.css'],
|
||||
'installable': True,
|
||||
'auto_install': False,
|
||||
'certificate' : '001131639736864143245',
|
||||
|
|
|
@ -0,0 +1,37 @@
|
|||
.oe_module_survey{
|
||||
font-size: 12px;
|
||||
border: 1px solid #ababab;
|
||||
text-align: left;
|
||||
height:135px;
|
||||
width:210px;
|
||||
}
|
||||
|
||||
.oe_survey_title{
|
||||
font-size: 15px;
|
||||
height: auto;
|
||||
color: #FFFFFF;
|
||||
-webkit-box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
|
||||
background-color: #8A89BA;
|
||||
width: 205px;
|
||||
}
|
||||
|
||||
.oe_survey_responsible{
|
||||
height: auto;
|
||||
width: 200px;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.oe_survey_start_date{
|
||||
height: auto;
|
||||
width: 200px;
|
||||
font-size: 14px;
|
||||
}
|
||||
|
||||
.oe_survey_fill{
|
||||
align:right;
|
||||
padding: 1px 165px;
|
||||
}
|
||||
|
||||
.oe_survey_rate{
|
||||
font-size: 14px;
|
||||
}
|
|
@ -142,6 +142,17 @@ class survey(osv.osv):
|
|||
'nodestroy':True,
|
||||
}
|
||||
return report
|
||||
|
||||
def fill_survey(self, cr, uid, ids, context=None):
|
||||
return {
|
||||
'view_type': 'form',
|
||||
'view_mode': 'form',
|
||||
'res_model': 'survey.question.wiz',
|
||||
'type': 'ir.actions.act_window',
|
||||
'target': 'new',
|
||||
'context': {'survey_id': ids[0]}
|
||||
}
|
||||
|
||||
survey()
|
||||
|
||||
class survey_history(osv.osv):
|
||||
|
|
|
@ -279,13 +279,52 @@
|
|||
</search>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.ui.view" id="view_survey_kanban">
|
||||
<field name="name">event.survey.kanban</field>
|
||||
<field name="model">survey</field>
|
||||
<field name="type">kanban</field>
|
||||
<field name="arch" type="xml">
|
||||
<kanban>
|
||||
<field name="title"/>
|
||||
<field name="date_open"/>
|
||||
<templates>
|
||||
<t t-name="kanban-box">
|
||||
<div class="oe_module_survey">
|
||||
<a class="oe_module_icon">
|
||||
<div class="oe_survey_title"><t t-esc="record.title.raw_value.toString()"/></div><br/>
|
||||
<div class="oe_survey_responsible">
|
||||
<t t-if="record.responsible_id.raw_value">By: <field name="responsible_id"/></t>
|
||||
</div><br/>
|
||||
<div class="oe_survey_start_date">
|
||||
<t t-if="record.date_open.raw_value">Open From:
|
||||
<t t-esc="record.date_open.raw_value.getDate()"/>
|
||||
<t t-esc="record.date_open.raw_value.toString('MMM')"/>,
|
||||
<t t-esc="record.date_open.raw_value.getFullYear()"/>
|
||||
</t>
|
||||
</div><br/>
|
||||
<div class="oe_survey_rate">
|
||||
Rate:
|
||||
</div>
|
||||
<div class="oe_survey_fill">
|
||||
<button type="object" name="fill_survey" class="">
|
||||
<span>Fill</span>
|
||||
</button>
|
||||
</div>
|
||||
</a>
|
||||
</div>
|
||||
</t>
|
||||
</templates>
|
||||
</kanban>
|
||||
</field>
|
||||
</record>
|
||||
|
||||
<record model="ir.actions.act_window" id="action_survey_form1">
|
||||
<field name="name">Surveys</field>
|
||||
<field name="res_model">survey</field>
|
||||
<field name="view_type">form</field>
|
||||
<field name="view_mode">tree,form</field>
|
||||
<field name="view_id" ref="survey_tree"></field>
|
||||
<field name="view_mode">kanban,tree,form</field>
|
||||
<field name="view_id" ref="view_survey_kanban"></field>
|
||||
<field name="search_view_id" ref="survey_search"/>
|
||||
<field name="help">You can create survey for different purposes: recruitment interviews, employee's periodical evaluations, marketing campaigns, etc. A survey is made of pages containing questions of several types: text, multiple choices, etc. You can edit survey manually or click on the 'Edit Survey' for a WYSIWYG interface.</field>
|
||||
</record>
|
||||
|
|
Loading…
Reference in New Issue