Merge lp:~openerp-dev/openobject-addons/trunk-widget-tooltip-mba into lp:openobject-addons
- trunk-widget-tooltip-mba
- Merge into trunk
Proposed by
Mahendra Barad(OpenERP)
Status: | Needs review |
---|---|
Proposed branch: | lp:~openerp-dev/openobject-addons/trunk-widget-tooltip-mba |
Merge into: | lp:openobject-addons |
Diff against target: |
2018 lines (+574/-252) 34 files modified
crm/crm.py (+30/-5) crm/crm_lead.py (+1/-15) crm/crm_lead_data.xml (+24/-0) crm/crm_lead_demo.xml (+15/-15) crm/crm_lead_view.xml (+14/-7) crm/crm_phonecall.py (+2/-2) crm/crm_phonecall_demo.xml (+5/-5) crm/crm_phonecall_view.xml (+1/-1) crm/crm_view.xml (+49/-1) crm/report/crm_phonecall_report.py (+1/-1) crm_claim/crm_claim.py (+2/-2) crm_claim/crm_claim_demo.xml (+6/-6) crm_claim/crm_claim_view.xml (+1/-1) crm_claim/report/crm_claim_report.py (+3/-5) crm_helpdesk/crm_helpdesk.py (+2/-2) crm_helpdesk/crm_helpdesk_demo.xml (+3/-3) crm_helpdesk/crm_helpdesk_view.xml (+1/-1) hr_recruitment/hr_recruitment.py (+30/-20) hr_recruitment/hr_recruitment_data.xml (+24/-0) hr_recruitment/hr_recruitment_demo.xml (+1/-1) hr_recruitment/hr_recruitment_view.xml (+58/-17) project/project.py (+62/-29) project/project_data.xml (+33/-0) project/project_demo.xml (+7/-4) project/project_view.xml (+91/-31) project/report/project_report.py (+1/-1) project/static/src/css/project.css (+4/-0) project/static/src/js/project.js (+10/-0) project_issue/project_issue.py (+26/-27) project_issue/project_issue_data.xml (+6/-0) project_issue/project_issue_demo.xml (+13/-10) project_issue/project_issue_view.xml (+46/-38) project_issue/report/project_issue_report.py (+1/-1) project_timesheet/project_timesheet_view.xml (+1/-1) |
To merge this branch: | bzr merge lp:~openerp-dev/openobject-addons/trunk-widget-tooltip-mba |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Richard Mathot (Odoo, formerly OpenERP) | Pending | ||
Review via email: mp+217431@code.launchpad.net |
This proposal supersedes a proposal from 2014-04-14.
Commit message
Description of the change
Hello ,
I have removed .THIS file.
Thanks
To post a comment you must log in.
Revision history for this message
Richard Mathot (Odoo, formerly OpenERP) (rim-openerp) wrote : Posted in a previous version of this proposal | # |
review:
Needs Fixing
- 9074. By Mahendra Barad(OpenERP)
-
[Merge]with trunk
- 9075. By Mahendra Barad(OpenERP)
-
[IMP]improve resolved conflict code
- 9076. By Mahendra Barad(OpenERP)
-
[Merge]with trunk
Unmerged revisions
- 9076. By Mahendra Barad(OpenERP)
-
[Merge]with trunk
- 9075. By Mahendra Barad(OpenERP)
-
[IMP]improve resolved conflict code
- 9074. By Mahendra Barad(OpenERP)
-
[Merge]with trunk
- 9073. By Mahendra Barad(OpenERP)
-
[IMP]remove .THIS file
- 9072. By Mahendra Barad(OpenERP)
-
[IMP]improve the tooltip
- 9071. By Mahendra Barad(OpenERP)
-
[Merge]with trunk
- 9070. By Mahendra Barad(OpenERP)
-
[Merge]with trunk
- 9069. By Mahendra Barad(OpenERP)
-
[IMP]currency symbol in kanban
- 9068. By Mahendra Barad(OpenERP)
-
[IMP]demo data
- 9067. By Mahendra Barad(OpenERP)
-
[Add]data for legends
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file 'crm/crm.py' | |||
2 | --- crm/crm.py 2014-02-11 11:09:36 +0000 | |||
3 | +++ crm/crm.py 2014-05-07 10:11:23 +0000 | |||
4 | @@ -28,11 +28,11 @@ | |||
5 | 28 | from openerp.osv import osv | 28 | from openerp.osv import osv |
6 | 29 | 29 | ||
7 | 30 | AVAILABLE_PRIORITIES = [ | 30 | AVAILABLE_PRIORITIES = [ |
13 | 31 | ('1', 'Highest'), | 31 | ('0', 'Very Low'), |
14 | 32 | ('2', 'High'), | 32 | ('1', 'Low'), |
15 | 33 | ('3', 'Normal'), | 33 | ('2', 'Normal'), |
16 | 34 | ('4', 'Low'), | 34 | ('3', 'High'), |
17 | 35 | ('5', 'Lowest'), | 35 | ('4', 'Very High'), |
18 | 36 | ] | 36 | ] |
19 | 37 | 37 | ||
20 | 38 | class crm_case_channel(osv.osv): | 38 | class crm_case_channel(osv.osv): |
21 | @@ -57,6 +57,26 @@ | |||
22 | 57 | _description = "Stage of case" | 57 | _description = "Stage of case" |
23 | 58 | _rec_name = 'name' | 58 | _rec_name = 'name' |
24 | 59 | _order = "sequence" | 59 | _order = "sequence" |
25 | 60 | |||
26 | 61 | def _get_tooltips(self, cr, uid, ids, field, args, context=None): | ||
27 | 62 | res = {} | ||
28 | 63 | for rec in self.read(cr, uid, ids, ['legend_star1','legend_star2','legend_star3','legend_star4','requirements'], context=context): | ||
29 | 64 | value = "" | ||
30 | 65 | img = "<img src='/web/static/src/img/icons/star-on.png'/>" | ||
31 | 66 | if rec['legend_star1']: | ||
32 | 67 | value += img +' '+ rec['legend_star1'] + "<br/>" | ||
33 | 68 | if rec['legend_star2']: | ||
34 | 69 | value += img + img +' '+ rec['legend_star2'] + "<br/>" | ||
35 | 70 | if rec['legend_star3']: | ||
36 | 71 | value += img + img + img +' '+ rec['legend_star3'] + "<br/>" | ||
37 | 72 | if rec['legend_star4']: | ||
38 | 73 | value += img + img + img + img +' '+ rec['legend_star4'] + "<br/>" | ||
39 | 74 | if rec['requirements']: | ||
40 | 75 | value += rec['requirements'] | ||
41 | 76 | tooltip = {'tooltip': value} | ||
42 | 77 | tooltip.update(rec) | ||
43 | 78 | res[rec['id']] = tooltip | ||
44 | 79 | return res | ||
45 | 60 | 80 | ||
46 | 61 | _columns = { | 81 | _columns = { |
47 | 62 | 'name': fields.char('Stage Name', size=64, required=True, translate=True), | 82 | 'name': fields.char('Stage Name', size=64, required=True, translate=True), |
48 | @@ -64,6 +84,7 @@ | |||
49 | 64 | 'probability': fields.float('Probability (%)', required=True, help="This percentage depicts the default/average probability of the Case for this stage to be a success"), | 84 | 'probability': fields.float('Probability (%)', required=True, help="This percentage depicts the default/average probability of the Case for this stage to be a success"), |
50 | 65 | 'on_change': fields.boolean('Change Probability Automatically', help="Setting this stage will change the probability automatically on the opportunity."), | 85 | 'on_change': fields.boolean('Change Probability Automatically', help="Setting this stage will change the probability automatically on the opportunity."), |
51 | 66 | 'requirements': fields.text('Requirements'), | 86 | 'requirements': fields.text('Requirements'), |
52 | 87 | 'kanban_column_tooltip': fields.function(_get_tooltips, string='Tooltips', type="char", help="This tooltips will display on kanban stage header" ), | ||
53 | 67 | 'section_ids': fields.many2many('crm.case.section', 'section_stage_rel', 'stage_id', 'section_id', string='Sections', | 88 | 'section_ids': fields.many2many('crm.case.section', 'section_stage_rel', 'stage_id', 'section_id', string='Sections', |
54 | 68 | help="Link between stages and sales teams. When set, this limitate the current stage to the selected sales teams."), | 89 | help="Link between stages and sales teams. When set, this limitate the current stage to the selected sales teams."), |
55 | 69 | 'case_default': fields.boolean('Default to New Sales Team', | 90 | 'case_default': fields.boolean('Default to New Sales Team', |
56 | @@ -76,6 +97,10 @@ | |||
57 | 76 | ('both', 'Both')], | 97 | ('both', 'Both')], |
58 | 77 | string='Type', size=16, required=True, | 98 | string='Type', size=16, required=True, |
59 | 78 | help="This field is used to distinguish stages related to Leads from stages related to Opportunities, or to specify stages available for both types."), | 99 | help="This field is used to distinguish stages related to Leads from stages related to Opportunities, or to specify stages available for both types."), |
60 | 100 | 'legend_star1':fields.char('Legend Star', help='This tooltip will appear on kanban view column header.'), | ||
61 | 101 | 'legend_star2':fields.char('Legend Star2', help='This tooltip will appear on kanban view column header.'), | ||
62 | 102 | 'legend_star3':fields.char('Legend Star3', help='This tooltip will appear on kanban view column header.'), | ||
63 | 103 | 'legend_star4':fields.char('Legend Star4', help='This tooltip will appear on kanban view column header.'), | ||
64 | 79 | } | 104 | } |
65 | 80 | 105 | ||
66 | 81 | _defaults = { | 106 | _defaults = { |
67 | 82 | 107 | ||
68 | === modified file 'crm/crm_lead.py' | |||
69 | --- crm/crm_lead.py 2014-05-02 13:07:53 +0000 | |||
70 | +++ crm/crm_lead.py 2014-05-07 10:11:23 +0000 | |||
71 | @@ -278,6 +278,7 @@ | |||
72 | 278 | 'partner_address_name': fields.related('partner_id', 'name', type='char', string='Partner Contact Name', readonly=True), | 278 | 'partner_address_name': fields.related('partner_id', 'name', type='char', string='Partner Contact Name', readonly=True), |
73 | 279 | 'partner_address_email': fields.related('partner_id', 'email', type='char', string='Partner Contact Email', readonly=True), | 279 | 'partner_address_email': fields.related('partner_id', 'email', type='char', string='Partner Contact Email', readonly=True), |
74 | 280 | 'company_currency': fields.related('company_id', 'currency_id', type='many2one', string='Currency', readonly=True, relation="res.currency"), | 280 | 'company_currency': fields.related('company_id', 'currency_id', type='many2one', string='Currency', readonly=True, relation="res.currency"), |
75 | 281 | 'company_currency_symbol': fields.related('company_id', 'currency_id', 'symbol', type='char', string='Symbol', readonly=True, relation="res.currency"), | ||
76 | 281 | 'user_email': fields.related('user_id', 'email', type='char', string='User Email', readonly=True), | 282 | 'user_email': fields.related('user_id', 'email', type='char', string='User Email', readonly=True), |
77 | 282 | 'user_login': fields.related('user_id', 'login', type='char', string='User Login', readonly=True), | 283 | 'user_login': fields.related('user_id', 'login', type='char', string='User Login', readonly=True), |
78 | 283 | 284 | ||
79 | @@ -458,21 +459,6 @@ | |||
80 | 458 | self.write(cr, uid, [case.id], data, context=context) | 459 | self.write(cr, uid, [case.id], data, context=context) |
81 | 459 | return True | 460 | return True |
82 | 460 | 461 | ||
83 | 461 | def set_priority(self, cr, uid, ids, priority, context=None): | ||
84 | 462 | """ Set lead priority | ||
85 | 463 | """ | ||
86 | 464 | return self.write(cr, uid, ids, {'priority': priority}, context=context) | ||
87 | 465 | |||
88 | 466 | def set_high_priority(self, cr, uid, ids, context=None): | ||
89 | 467 | """ Set lead priority to high | ||
90 | 468 | """ | ||
91 | 469 | return self.set_priority(cr, uid, ids, '1', context=context) | ||
92 | 470 | |||
93 | 471 | def set_normal_priority(self, cr, uid, ids, context=None): | ||
94 | 472 | """ Set lead priority to normal | ||
95 | 473 | """ | ||
96 | 474 | return self.set_priority(cr, uid, ids, '3', context=context) | ||
97 | 475 | |||
98 | 476 | def _merge_get_result_type(self, cr, uid, opps, context=None): | 462 | def _merge_get_result_type(self, cr, uid, opps, context=None): |
99 | 477 | """ | 463 | """ |
100 | 478 | Define the type of the result of the merge. If at least one of the | 464 | Define the type of the result of the merge. If at least one of the |
101 | 479 | 465 | ||
102 | === modified file 'crm/crm_lead_data.xml' | |||
103 | --- crm/crm_lead_data.xml 2014-02-21 11:29:15 +0000 | |||
104 | +++ crm/crm_lead_data.xml 2014-05-07 10:11:23 +0000 | |||
105 | @@ -10,6 +10,10 @@ | |||
106 | 10 | <field name="on_change">1</field> | 10 | <field name="on_change">1</field> |
107 | 11 | <field name="sequence">1</field> | 11 | <field name="sequence">1</field> |
108 | 12 | <field name="type">both</field> | 12 | <field name="type">both</field> |
109 | 13 | <field name="legend_star1">Low priority</field> | ||
110 | 14 | <field name="legend_star2">Normal priority</field> | ||
111 | 15 | <field name="legend_star3">High priority</field> | ||
112 | 16 | <field name="legend_star4">Highest priority</field> | ||
113 | 13 | </record> | 17 | </record> |
114 | 14 | <record model="crm.case.stage" id="stage_lead2"> | 18 | <record model="crm.case.stage" id="stage_lead2"> |
115 | 15 | <field name="name">Dead</field> | 19 | <field name="name">Dead</field> |
116 | @@ -26,6 +30,10 @@ | |||
117 | 26 | <field name="on_change">1</field> | 30 | <field name="on_change">1</field> |
118 | 27 | <field name="sequence">40</field> | 31 | <field name="sequence">40</field> |
119 | 28 | <field name="type">opportunity</field> | 32 | <field name="type">opportunity</field> |
120 | 33 | <field name="legend_star1">Low priority</field> | ||
121 | 34 | <field name="legend_star2">Normal priority</field> | ||
122 | 35 | <field name="legend_star3">High priority</field> | ||
123 | 36 | <field name="legend_star4">Highest priority</field> | ||
124 | 29 | </record> | 37 | </record> |
125 | 30 | <record model="crm.case.stage" id="stage_lead4"> | 38 | <record model="crm.case.stage" id="stage_lead4"> |
126 | 31 | <field name="name">Proposition</field> | 39 | <field name="name">Proposition</field> |
127 | @@ -33,6 +41,10 @@ | |||
128 | 33 | <field name="probability">40</field> | 41 | <field name="probability">40</field> |
129 | 34 | <field name="sequence">50</field> | 42 | <field name="sequence">50</field> |
130 | 35 | <field name="type">opportunity</field> | 43 | <field name="type">opportunity</field> |
131 | 44 | <field name="legend_star1">Low priority</field> | ||
132 | 45 | <field name="legend_star2">Normal priority</field> | ||
133 | 46 | <field name="legend_star3">High priority</field> | ||
134 | 47 | <field name="legend_star4">Highest priority</field> | ||
135 | 36 | </record> | 48 | </record> |
136 | 37 | <record model="crm.case.stage" id="stage_lead5"> | 49 | <record model="crm.case.stage" id="stage_lead5"> |
137 | 38 | <field name="name">Negotiation</field> | 50 | <field name="name">Negotiation</field> |
138 | @@ -40,6 +52,10 @@ | |||
139 | 40 | <field name="probability">60</field> | 52 | <field name="probability">60</field> |
140 | 41 | <field name="sequence">60</field> | 53 | <field name="sequence">60</field> |
141 | 42 | <field name="type">opportunity</field> | 54 | <field name="type">opportunity</field> |
142 | 55 | <field name="legend_star1">Low priority</field> | ||
143 | 56 | <field name="legend_star2">Normal priority</field> | ||
144 | 57 | <field name="legend_star3">High priority</field> | ||
145 | 58 | <field name="legend_star4">Highest priority</field> | ||
146 | 43 | </record> | 59 | </record> |
147 | 44 | <record model="crm.case.stage" id="stage_lead6"> | 60 | <record model="crm.case.stage" id="stage_lead6"> |
148 | 45 | <field name="name">Won</field> | 61 | <field name="name">Won</field> |
149 | @@ -49,6 +65,10 @@ | |||
150 | 49 | <field name="on_change">1</field> | 65 | <field name="on_change">1</field> |
151 | 50 | <field name="sequence">70</field> | 66 | <field name="sequence">70</field> |
152 | 51 | <field name="type">opportunity</field> | 67 | <field name="type">opportunity</field> |
153 | 68 | <field name="legend_star1">Low priority</field> | ||
154 | 69 | <field name="legend_star2">Normal priority</field> | ||
155 | 70 | <field name="legend_star3">High priority</field> | ||
156 | 71 | <field name="legend_star4">Highest priority</field> | ||
157 | 52 | </record> | 72 | </record> |
158 | 53 | <record model="crm.case.stage" id="stage_lead7"> | 73 | <record model="crm.case.stage" id="stage_lead7"> |
159 | 54 | <field name="name">Lost</field> | 74 | <field name="name">Lost</field> |
160 | @@ -58,6 +78,10 @@ | |||
161 | 58 | <field name="on_change">1</field> | 78 | <field name="on_change">1</field> |
162 | 59 | <field name="sequence">80</field> | 79 | <field name="sequence">80</field> |
163 | 60 | <field name="type">opportunity</field> | 80 | <field name="type">opportunity</field> |
164 | 81 | <field name="legend_star1">Low priority</field> | ||
165 | 82 | <field name="legend_star2">Normal priority</field> | ||
166 | 83 | <field name="legend_star3">High priority</field> | ||
167 | 84 | <field name="legend_star4">Highest priority</field> | ||
168 | 61 | </record> | 85 | </record> |
169 | 62 | 86 | ||
170 | 63 | <record model="crm.case.section" id="section_sales_department"> | 87 | <record model="crm.case.section" id="section_sales_department"> |
171 | 64 | 88 | ||
172 | === modified file 'crm/crm_lead_demo.xml' | |||
173 | --- crm/crm_lead_demo.xml 2013-10-27 12:31:04 +0000 | |||
174 | +++ crm/crm_lead_demo.xml 2014-05-07 10:11:23 +0000 | |||
175 | @@ -54,7 +54,7 @@ | |||
176 | 54 | <field name="type_id" ref="type_lead7"/> | 54 | <field name="type_id" ref="type_lead7"/> |
177 | 55 | <field name="categ_ids" eval="[(6, 0, [categ_oppor2])]"/> | 55 | <field name="categ_ids" eval="[(6, 0, [categ_oppor2])]"/> |
178 | 56 | <field name="channel_id" ref="crm_case_channel_website"/> | 56 | <field name="channel_id" ref="crm_case_channel_website"/> |
180 | 57 | <field name="priority">4</field> | 57 | <field name="priority">1</field> |
181 | 58 | <field name="section_id" ref="section_sales_department"/> | 58 | <field name="section_id" ref="section_sales_department"/> |
182 | 59 | <field name="user_id" ref="base.user_root"/> | 59 | <field name="user_id" ref="base.user_root"/> |
183 | 60 | <field name="stage_id" ref="stage_lead1"/> | 60 | <field name="stage_id" ref="stage_lead1"/> |
184 | @@ -104,7 +104,7 @@ | |||
185 | 104 | <field name="type_id" ref="type_lead8"/> | 104 | <field name="type_id" ref="type_lead8"/> |
186 | 105 | <field name="categ_ids" eval="[(6, 0, [categ_oppor5])]"/> | 105 | <field name="categ_ids" eval="[(6, 0, [categ_oppor5])]"/> |
187 | 106 | <field name="channel_id" ref=""/> | 106 | <field name="channel_id" ref=""/> |
189 | 107 | <field name="priority">3</field> | 107 | <field name="priority">2</field> |
190 | 108 | <field name="section_id" ref="crm_case_section_2"/> | 108 | <field name="section_id" ref="crm_case_section_2"/> |
191 | 109 | <field name="user_id" ref="base.user_demo"/> | 109 | <field name="user_id" ref="base.user_demo"/> |
192 | 110 | <field name="stage_id" ref="stage_lead6"/> | 110 | <field name="stage_id" ref="stage_lead6"/> |
193 | @@ -129,7 +129,7 @@ | |||
194 | 129 | <field name="type_id" ref="type_lead3"/> | 129 | <field name="type_id" ref="type_lead3"/> |
195 | 130 | <field name="categ_ids" eval="[(6, 0, [categ_oppor1])]"/> | 130 | <field name="categ_ids" eval="[(6, 0, [categ_oppor1])]"/> |
196 | 131 | <field name="channel_id" ref="crm_case_channel_website"/> | 131 | <field name="channel_id" ref="crm_case_channel_website"/> |
198 | 132 | <field name="priority">3</field> | 132 | <field name="priority">2</field> |
199 | 133 | <field name="section_id" ref="crm_case_section_1"/> | 133 | <field name="section_id" ref="crm_case_section_1"/> |
200 | 134 | <field name="user_id" ref=""/> | 134 | <field name="user_id" ref=""/> |
201 | 135 | <field name="stage_id" ref="stage_lead1"/> | 135 | <field name="stage_id" ref="stage_lead1"/> |
202 | @@ -156,7 +156,7 @@ | |||
203 | 156 | <field name="type_id" ref="type_lead3"/> | 156 | <field name="type_id" ref="type_lead3"/> |
204 | 157 | <field name="categ_ids" eval="[(6, 0, [categ_oppor3,categ_oppor4])]"/> | 157 | <field name="categ_ids" eval="[(6, 0, [categ_oppor3,categ_oppor4])]"/> |
205 | 158 | <field name="channel_id" ref=""/> | 158 | <field name="channel_id" ref=""/> |
207 | 159 | <field name="priority">3</field> | 159 | <field name="priority">2</field> |
208 | 160 | <field name="section_id" ref="crm_case_section_2"/> | 160 | <field name="section_id" ref="crm_case_section_2"/> |
209 | 161 | <field name="user_id" ref=""/> | 161 | <field name="user_id" ref=""/> |
210 | 162 | <field name="stage_id" ref="stage_lead1"/> | 162 | <field name="stage_id" ref="stage_lead1"/> |
211 | @@ -174,7 +174,7 @@ | |||
212 | 174 | <field name="type_id" ref="type_lead8"/> | 174 | <field name="type_id" ref="type_lead8"/> |
213 | 175 | <field name="categ_ids" eval="[(6, 0, [categ_oppor4])]"/> | 175 | <field name="categ_ids" eval="[(6, 0, [categ_oppor4])]"/> |
214 | 176 | <field name="channel_id" ref=""/> | 176 | <field name="channel_id" ref=""/> |
216 | 177 | <field name="priority">5</field> | 177 | <field name="priority">0</field> |
217 | 178 | <field name="section_id" ref="crm_case_section_2"/> | 178 | <field name="section_id" ref="crm_case_section_2"/> |
218 | 179 | <field name="user_id" ref="base.user_root"/> | 179 | <field name="user_id" ref="base.user_root"/> |
219 | 180 | <field name="stage_id" ref="stage_lead1"/> | 180 | <field name="stage_id" ref="stage_lead1"/> |
220 | @@ -193,7 +193,7 @@ | |||
221 | 193 | <field name="type_id" ref="type_lead5"/> | 193 | <field name="type_id" ref="type_lead5"/> |
222 | 194 | <field name="categ_ids" eval="[(6, 0, [categ_oppor6,categ_oppor8])]"/> | 194 | <field name="categ_ids" eval="[(6, 0, [categ_oppor6,categ_oppor8])]"/> |
223 | 195 | <field name="channel_id" ref=""/> | 195 | <field name="channel_id" ref=""/> |
225 | 196 | <field name="priority">4</field> | 196 | <field name="priority">1</field> |
226 | 197 | <field name="section_id" ref="section_sales_department"/> | 197 | <field name="section_id" ref="section_sales_department"/> |
227 | 198 | <field name="user_id" ref="base.user_root"/> | 198 | <field name="user_id" ref="base.user_root"/> |
228 | 199 | <field name="stage_id" ref="stage_lead1"/> | 199 | <field name="stage_id" ref="stage_lead1"/> |
229 | @@ -253,7 +253,7 @@ | |||
230 | 253 | <field name="type_id" ref="type_lead3"/> | 253 | <field name="type_id" ref="type_lead3"/> |
231 | 254 | <field name="categ_ids" eval="[(6, 0, [categ_oppor7])]"/> | 254 | <field name="categ_ids" eval="[(6, 0, [categ_oppor7])]"/> |
232 | 255 | <field name="channel_id" ref="crm_case_channel_direct"/> | 255 | <field name="channel_id" ref="crm_case_channel_direct"/> |
234 | 256 | <field name="priority">3</field> | 256 | <field name="priority">2</field> |
235 | 257 | <field name="section_id" ref="crm_case_section_1"/> | 257 | <field name="section_id" ref="crm_case_section_1"/> |
236 | 258 | <field name="user_id" ref=""/> | 258 | <field name="user_id" ref=""/> |
237 | 259 | <field name="stage_id" ref="stage_lead1"/> | 259 | <field name="stage_id" ref="stage_lead1"/> |
238 | @@ -331,7 +331,7 @@ | |||
239 | 331 | <field name="type_id" ref="type_lead3"/> | 331 | <field name="type_id" ref="type_lead3"/> |
240 | 332 | <field name="categ_ids" eval="[(6, 0, [categ_oppor2])]"/> | 332 | <field name="categ_ids" eval="[(6, 0, [categ_oppor2])]"/> |
241 | 333 | <field name="channel_id" ref="crm_case_channel_website"/> | 333 | <field name="channel_id" ref="crm_case_channel_website"/> |
243 | 334 | <field name="priority">3</field> | 334 | <field name="priority">2</field> |
244 | 335 | <field eval="time.strftime('%Y-%m-23')" name="date_deadline"/> | 335 | <field eval="time.strftime('%Y-%m-23')" name="date_deadline"/> |
245 | 336 | <field eval="time.strftime('%Y-%m-10')" name="date_action"/> | 336 | <field eval="time.strftime('%Y-%m-10')" name="date_action"/> |
246 | 337 | <field name="title_action">Send Catalogue by Email</field> | 337 | <field name="title_action">Send Catalogue by Email</field> |
247 | @@ -404,7 +404,7 @@ | |||
248 | 404 | <field name="type_id" ref="type_lead3"/> | 404 | <field name="type_id" ref="type_lead3"/> |
249 | 405 | <field name="categ_ids" eval="[(6, 0, [categ_oppor3,categ_oppor4])]"/> | 405 | <field name="categ_ids" eval="[(6, 0, [categ_oppor3,categ_oppor4])]"/> |
250 | 406 | <field name="channel_id" ref="crm_case_channel_website"/> | 406 | <field name="channel_id" ref="crm_case_channel_website"/> |
252 | 407 | <field name="priority">4</field> | 407 | <field name="priority">1</field> |
253 | 408 | <field eval="time.strftime('%Y-%m-8')" name="date_deadline"/> | 408 | <field eval="time.strftime('%Y-%m-8')" name="date_deadline"/> |
254 | 409 | <field eval="time.strftime('%Y-%m-3')" name="date_action"/> | 409 | <field eval="time.strftime('%Y-%m-3')" name="date_action"/> |
255 | 410 | <field name="title_action">Send price list regarding our interventions</field> | 410 | <field name="title_action">Send price list regarding our interventions</field> |
256 | @@ -431,7 +431,7 @@ | |||
257 | 431 | <field name="partner_id" ref="base.res_partner_4"/> | 431 | <field name="partner_id" ref="base.res_partner_4"/> |
258 | 432 | <field name="type_id" ref="type_lead8"/> | 432 | <field name="type_id" ref="type_lead8"/> |
259 | 433 | <field name="categ_ids" eval="[(6, 0, [categ_oppor4,categ_oppor6])]"/> | 433 | <field name="categ_ids" eval="[(6, 0, [categ_oppor4,categ_oppor6])]"/> |
261 | 434 | <field name="priority">4</field> | 434 | <field name="priority">1</field> |
262 | 435 | <field eval="time.strftime('%Y-%m-13')" name="date_deadline"/> | 435 | <field eval="time.strftime('%Y-%m-13')" name="date_deadline"/> |
263 | 436 | <field eval="time.strftime('%Y-%m-4')" name="date_action"/> | 436 | <field eval="time.strftime('%Y-%m-4')" name="date_action"/> |
264 | 437 | <field name="title_action">Call to define real needs about training</field> | 437 | <field name="title_action">Call to define real needs about training</field> |
265 | @@ -492,7 +492,7 @@ | |||
266 | 492 | <field name="type_id" ref="type_lead2"/> | 492 | <field name="type_id" ref="type_lead2"/> |
267 | 493 | <field name="categ_ids" eval="[(6, 0, [categ_oppor7])]"/> | 493 | <field name="categ_ids" eval="[(6, 0, [categ_oppor7])]"/> |
268 | 494 | <field name="channel_id" ref="crm_case_channel_phone"/> | 494 | <field name="channel_id" ref="crm_case_channel_phone"/> |
270 | 495 | <field name="priority">3</field> | 495 | <field name="priority">2</field> |
271 | 496 | <field name="section_id" ref="crm_case_section_2"/> | 496 | <field name="section_id" ref="crm_case_section_2"/> |
272 | 497 | <field name="user_id" ref="base.user_root"/> | 497 | <field name="user_id" ref="base.user_root"/> |
273 | 498 | <field name="stage_id" ref="crm.stage_lead4"/> | 498 | <field name="stage_id" ref="crm.stage_lead4"/> |
274 | @@ -510,7 +510,7 @@ | |||
275 | 510 | <field name="type_id" ref="type_lead7"/> | 510 | <field name="type_id" ref="type_lead7"/> |
276 | 511 | <field name="categ_ids" eval="[(6, 0, [categ_oppor3])]"/> | 511 | <field name="categ_ids" eval="[(6, 0, [categ_oppor3])]"/> |
277 | 512 | <field name="channel_id" ref="crm_case_channel_email"/> | 512 | <field name="channel_id" ref="crm_case_channel_email"/> |
279 | 513 | <field name="priority">3</field> | 513 | <field name="priority">1</field> |
280 | 514 | <field name="section_id" ref="crm_case_section_2"/> | 514 | <field name="section_id" ref="crm_case_section_2"/> |
281 | 515 | <field name="user_id" ref="base.user_root"/> | 515 | <field name="user_id" ref="base.user_root"/> |
282 | 516 | <field name="stage_id" ref="crm.stage_lead5"/> | 516 | <field name="stage_id" ref="crm.stage_lead5"/> |
283 | @@ -525,7 +525,7 @@ | |||
284 | 525 | <field name="type_id" ref="type_lead5"/> | 525 | <field name="type_id" ref="type_lead5"/> |
285 | 526 | <field name="categ_ids" eval="[(6, 0, [categ_oppor3])]"/> | 526 | <field name="categ_ids" eval="[(6, 0, [categ_oppor3])]"/> |
286 | 527 | <field name="channel_id" ref="crm_case_channel_direct"/> | 527 | <field name="channel_id" ref="crm_case_channel_direct"/> |
288 | 528 | <field name="priority">5</field> | 528 | <field name="priority">0</field> |
289 | 529 | <field name="section_id" ref="section_sales_department"/> | 529 | <field name="section_id" ref="section_sales_department"/> |
290 | 530 | <field name="user_id" ref="base.user_demo"/> | 530 | <field name="user_id" ref="base.user_demo"/> |
291 | 531 | <field name="stage_id" ref="crm.stage_lead5"/> | 531 | <field name="stage_id" ref="crm.stage_lead5"/> |
292 | @@ -543,7 +543,7 @@ | |||
293 | 543 | <field name="type_id" ref="type_lead8"/> | 543 | <field name="type_id" ref="type_lead8"/> |
294 | 544 | <field name="categ_ids" eval="[(6, 0, [categ_oppor7])]"/> | 544 | <field name="categ_ids" eval="[(6, 0, [categ_oppor7])]"/> |
295 | 545 | <field name="channel_id" ref="crm_case_channel_website"/> | 545 | <field name="channel_id" ref="crm_case_channel_website"/> |
297 | 546 | <field name="priority">5</field> | 546 | <field name="priority">0</field> |
298 | 547 | <field eval="time.strftime('%Y-%m-6')" name="date_deadline"/> | 547 | <field eval="time.strftime('%Y-%m-6')" name="date_deadline"/> |
299 | 548 | <field name="section_id" ref="section_sales_department"/> | 548 | <field name="section_id" ref="section_sales_department"/> |
300 | 549 | <field name="user_id" ref="base.user_root"/> | 549 | <field name="user_id" ref="base.user_root"/> |
301 | @@ -588,7 +588,7 @@ | |||
302 | 588 | <field name="type_id" ref="type_lead3"/> | 588 | <field name="type_id" ref="type_lead3"/> |
303 | 589 | <field name="categ_ids" eval="[(6, 0, [categ_oppor2])]"/> | 589 | <field name="categ_ids" eval="[(6, 0, [categ_oppor2])]"/> |
304 | 590 | <field name="channel_id" ref="crm_case_channel_website"/> | 590 | <field name="channel_id" ref="crm_case_channel_website"/> |
306 | 591 | <field name="priority">3</field> | 591 | <field name="priority">2</field> |
307 | 592 | <field eval="time.strftime('%Y-%m-23')" name="date_deadline"/> | 592 | <field eval="time.strftime('%Y-%m-23')" name="date_deadline"/> |
308 | 593 | <field eval="time.strftime('%Y-%m-10')" name="date_action"/> | 593 | <field eval="time.strftime('%Y-%m-10')" name="date_action"/> |
309 | 594 | <field name="title_action">Send Catalogue by Email</field> | 594 | <field name="title_action">Send Catalogue by Email</field> |
310 | 595 | 595 | ||
311 | === modified file 'crm/crm_lead_view.xml' | |||
312 | --- crm/crm_lead_view.xml 2014-05-02 13:22:58 +0000 | |||
313 | +++ crm/crm_lead_view.xml 2014-05-07 10:11:23 +0000 | |||
314 | @@ -158,7 +158,7 @@ | |||
315 | 158 | <field name="type" invisible="1"/> | 158 | <field name="type" invisible="1"/> |
316 | 159 | </group> | 159 | </group> |
317 | 160 | <group> | 160 | <group> |
319 | 161 | <field name="priority"/> | 161 | <field name="priority" widget="priority"/> |
320 | 162 | <field name="categ_ids" | 162 | <field name="categ_ids" |
321 | 163 | widget="many2many_tags" | 163 | widget="many2many_tags" |
322 | 164 | domain="[('object_id.model','=','crm.lead')]" | 164 | domain="[('object_id.model','=','crm.lead')]" |
323 | @@ -261,7 +261,7 @@ | |||
324 | 261 | <field name="model">crm.lead</field> | 261 | <field name="model">crm.lead</field> |
325 | 262 | <field name="arch" type="xml"> | 262 | <field name="arch" type="xml"> |
326 | 263 | <kanban default_group_by="stage_id"> | 263 | <kanban default_group_by="stage_id"> |
328 | 264 | <field name="stage_id"/> | 264 | <field name="stage_id" options='{"tooltip_on_group_by": "kanban_column_tooltip"}'/> |
329 | 265 | <field name="color"/> | 265 | <field name="color"/> |
330 | 266 | <field name="priority"/> | 266 | <field name="priority"/> |
331 | 267 | <field name="planned_revenue" sum="Expected Revenues"/> | 267 | <field name="planned_revenue" sum="Expected Revenues"/> |
332 | @@ -290,7 +290,7 @@ | |||
333 | 290 | <b><field name="name"/></b> | 290 | <b><field name="name"/></b> |
334 | 291 | <t t-if="record.planned_revenue.raw_value"> | 291 | <t t-if="record.planned_revenue.raw_value"> |
335 | 292 | - <b><t t-esc="record.planned_revenue.value"/> | 292 | - <b><t t-esc="record.planned_revenue.value"/> |
337 | 293 | <field name="company_currency"/></b> | 293 | <field name="company_currency_symbol"/></b> |
338 | 294 | </t> | 294 | </t> |
339 | 295 | </div> | 295 | </div> |
340 | 296 | <div> | 296 | <div> |
341 | @@ -303,9 +303,16 @@ | |||
342 | 303 | <field name="title_action"/> | 303 | <field name="title_action"/> |
343 | 304 | </div> | 304 | </div> |
344 | 305 | <div class="oe_kanban_bottom_right"> | 305 | <div class="oe_kanban_bottom_right"> |
348 | 306 | <a t-if="record.priority.raw_value == 1" type="object" name="set_normal_priority" class="oe_e oe_star_on">7</a> | 306 | <table> |
349 | 307 | <a t-if="record.priority.raw_value != 1" type="object" name="set_high_priority" class="oe_e oe_star_off">7</a> | 307 | <tr> |
350 | 308 | <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar" t-if="record.user_id.value"/> | 308 | <td groups="base.group_user"> |
351 | 309 | <field name="priority" widget="priority"/> | ||
352 | 310 | </td> | ||
353 | 311 | <td> | ||
354 | 312 | <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar"/> | ||
355 | 313 | </td> | ||
356 | 314 | </tr> | ||
357 | 315 | </table> | ||
358 | 309 | </div> | 316 | </div> |
359 | 310 | <div class="oe_kanban_footer_left"> | 317 | <div class="oe_kanban_footer_left"> |
360 | 311 | <t t-raw="record.message_summary.raw_value"/> | 318 | <t t-raw="record.message_summary.raw_value"/> |
361 | @@ -430,7 +437,7 @@ | |||
362 | 430 | <field name="title_action" class="oe_inline" nolabel="1" placeholder="e.g. Call for proposal"/> | 437 | <field name="title_action" class="oe_inline" nolabel="1" placeholder="e.g. Call for proposal"/> |
363 | 431 | </div> | 438 | </div> |
364 | 432 | <field name="date_deadline"/> | 439 | <field name="date_deadline"/> |
366 | 433 | <field name="priority"/> | 440 | <field name="priority" widget="priority"/> |
367 | 434 | </group> | 441 | </group> |
368 | 435 | 442 | ||
369 | 436 | <group> | 443 | <group> |
370 | 437 | 444 | ||
371 | === modified file 'crm/crm_phonecall.py' | |||
372 | --- crm/crm_phonecall.py 2014-03-24 13:56:21 +0000 | |||
373 | +++ crm/crm_phonecall.py 2014-05-07 10:11:23 +0000 | |||
374 | @@ -70,7 +70,7 @@ | |||
375 | 70 | ('object_id.model', '=', 'crm.phonecall')]"), | 70 | ('object_id.model', '=', 'crm.phonecall')]"), |
376 | 71 | 'partner_phone': fields.char('Phone', size=32), | 71 | 'partner_phone': fields.char('Phone', size=32), |
377 | 72 | 'partner_mobile': fields.char('Mobile', size=32), | 72 | 'partner_mobile': fields.char('Mobile', size=32), |
379 | 73 | 'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority'), | 73 | 'priority': fields.selection([('0','Low'), ('1','Normal'), ('2','High')], 'Priority'), |
380 | 74 | 'date_closed': fields.datetime('Closed', readonly=True), | 74 | 'date_closed': fields.datetime('Closed', readonly=True), |
381 | 75 | 'date': fields.datetime('Date'), | 75 | 'date': fields.datetime('Date'), |
382 | 76 | 'opportunity_id': fields.many2one ('crm.lead', 'Lead/Opportunity'), | 76 | 'opportunity_id': fields.many2one ('crm.lead', 'Lead/Opportunity'), |
383 | @@ -85,7 +85,7 @@ | |||
384 | 85 | 85 | ||
385 | 86 | _defaults = { | 86 | _defaults = { |
386 | 87 | 'date': fields.datetime.now, | 87 | 'date': fields.datetime.now, |
388 | 88 | 'priority': crm.AVAILABLE_PRIORITIES[2][0], | 88 | 'priority': '1', |
389 | 89 | 'state': _get_default_state, | 89 | 'state': _get_default_state, |
390 | 90 | 'user_id': lambda self, cr, uid, ctx: uid, | 90 | 'user_id': lambda self, cr, uid, ctx: uid, |
391 | 91 | 'active': 1 | 91 | 'active': 1 |
392 | 92 | 92 | ||
393 | === modified file 'crm/crm_phonecall_demo.xml' | |||
394 | --- crm/crm_phonecall_demo.xml 2013-10-27 12:31:04 +0000 | |||
395 | +++ crm/crm_phonecall_demo.xml 2014-05-07 10:11:23 +0000 | |||
396 | @@ -6,7 +6,7 @@ | |||
397 | 6 | <record id="crm_phonecall_1" model="crm.phonecall"> | 6 | <record id="crm_phonecall_1" model="crm.phonecall"> |
398 | 7 | <field eval="time.strftime('%Y-%m-04 10:45:36')" name="date"/> | 7 | <field eval="time.strftime('%Y-%m-04 10:45:36')" name="date"/> |
399 | 8 | <field name="partner_id" ref="base.res_partner_11"/> | 8 | <field name="partner_id" ref="base.res_partner_11"/> |
401 | 9 | <field eval="'3'" name="priority"/> | 9 | <field eval="'1'" name="priority"/> |
402 | 10 | <field name="user_id" ref="base.user_root"/> | 10 | <field name="user_id" ref="base.user_root"/> |
403 | 11 | <field name="name">Left the message</field> | 11 | <field name="name">Left the message</field> |
404 | 12 | <field name="state">done</field> | 12 | <field name="state">done</field> |
405 | @@ -19,7 +19,7 @@ | |||
406 | 19 | <record id="crm_phonecall_2" model="crm.phonecall"> | 19 | <record id="crm_phonecall_2" model="crm.phonecall"> |
407 | 20 | <field eval="time.strftime('%Y-%m-11 11:19:25')" name="date"/> | 20 | <field eval="time.strftime('%Y-%m-11 11:19:25')" name="date"/> |
408 | 21 | <field name="partner_id" ref="base.res_partner_7"/> | 21 | <field name="partner_id" ref="base.res_partner_7"/> |
410 | 22 | <field eval="'4'" name="priority"/> | 22 | <field eval="'0'" name="priority"/> |
411 | 23 | <field name="user_id" ref="base.user_root"/> | 23 | <field name="user_id" ref="base.user_root"/> |
412 | 24 | <field name="name">Need more information on the proposed deal</field> | 24 | <field name="name">Need more information on the proposed deal</field> |
413 | 25 | <field name="state">done</field> | 25 | <field name="state">done</field> |
414 | @@ -44,7 +44,7 @@ | |||
415 | 44 | </record> | 44 | </record> |
416 | 45 | <record id="crm_phonecall_4" model="crm.phonecall"> | 45 | <record id="crm_phonecall_4" model="crm.phonecall"> |
417 | 46 | <field eval="time.strftime('%Y-%m-21 14:10:23')" name="date"/> | 46 | <field eval="time.strftime('%Y-%m-21 14:10:23')" name="date"/> |
419 | 47 | <field eval="'3'" name="priority"/> | 47 | <field eval="'1'" name="priority"/> |
420 | 48 | <field name="user_id" ref="base.user_root"/> | 48 | <field name="user_id" ref="base.user_root"/> |
421 | 49 | <field name="name">Wanted information about pricing of laptops</field> | 49 | <field name="name">Wanted information about pricing of laptops</field> |
422 | 50 | <field name="state">done</field> | 50 | <field name="state">done</field> |
423 | @@ -58,7 +58,7 @@ | |||
424 | 58 | <record id="crm_phonecall_5" model="crm.phonecall"> | 58 | <record id="crm_phonecall_5" model="crm.phonecall"> |
425 | 59 | <field eval="time.strftime('%Y-%m-28 16:20:43')" name="date"/> | 59 | <field eval="time.strftime('%Y-%m-28 16:20:43')" name="date"/> |
426 | 60 | <field name="partner_id" ref="base.res_partner_5"/> | 60 | <field name="partner_id" ref="base.res_partner_5"/> |
428 | 61 | <field eval="'3'" name="priority"/> | 61 | <field eval="'1'" name="priority"/> |
429 | 62 | <field name="user_id" ref="base.user_root"/> | 62 | <field name="user_id" ref="base.user_root"/> |
430 | 63 | <field name="name">More information on the proposed deal</field> | 63 | <field name="name">More information on the proposed deal</field> |
431 | 64 | <field name="state">pending</field> | 64 | <field name="state">pending</field> |
432 | @@ -69,7 +69,7 @@ | |||
433 | 69 | <field eval="2.08" name="duration"/> | 69 | <field eval="2.08" name="duration"/> |
434 | 70 | </record> | 70 | </record> |
435 | 71 | <record id="crm_phonecall_6" model="crm.phonecall"> | 71 | <record id="crm_phonecall_6" model="crm.phonecall"> |
437 | 72 | <field eval="'3'" name="priority"/> | 72 | <field eval="'1'" name="priority"/> |
438 | 73 | <field name="user_id" ref="base.user_root"/> | 73 | <field name="user_id" ref="base.user_root"/> |
439 | 74 | <field name="name">Proposal for discount offer</field> | 74 | <field name="name">Proposal for discount offer</field> |
440 | 75 | <field name="state">open</field> | 75 | <field name="state">open</field> |
441 | 76 | 76 | ||
442 | === modified file 'crm/crm_phonecall_view.xml' | |||
443 | --- crm/crm_phonecall_view.xml 2014-05-02 13:07:53 +0000 | |||
444 | +++ crm/crm_phonecall_view.xml 2014-05-07 10:11:23 +0000 | |||
445 | @@ -103,7 +103,7 @@ | |||
446 | 103 | <field name="categ_id" widget="selection" | 103 | <field name="categ_id" widget="selection" |
447 | 104 | domain="[('object_id.model', '=', 'crm.phonecall')]"/> | 104 | domain="[('object_id.model', '=', 'crm.phonecall')]"/> |
448 | 105 | <field name="partner_mobile"/> | 105 | <field name="partner_mobile"/> |
450 | 106 | <field name="priority"/> | 106 | <field name="priority" widget="priority"/> |
451 | 107 | <field name="opportunity_id" on_change="on_change_opportunity(opportunity_id)"/> | 107 | <field name="opportunity_id" on_change="on_change_opportunity(opportunity_id)"/> |
452 | 108 | </group> | 108 | </group> |
453 | 109 | <field name="description" placeholder="Description..."/> | 109 | <field name="description" placeholder="Description..."/> |
454 | 110 | 110 | ||
455 | === modified file 'crm/crm_view.xml' | |||
456 | --- crm/crm_view.xml 2013-12-10 09:33:07 +0000 | |||
457 | +++ crm/crm_view.xml 2014-05-07 10:11:23 +0000 | |||
458 | @@ -107,9 +107,57 @@ | |||
459 | 107 | </group> | 107 | </group> |
460 | 108 | 108 | ||
461 | 109 | </group> | 109 | </group> |
462 | 110 | <div attrs="{'invisible':[('type','=', 'lead')]}"> | ||
463 | 111 | <separator string="Legend"/> | ||
464 | 112 | <p>The legend will appear as tooltip of each column of the opportunities pipe.</p> | ||
465 | 113 | <div> | ||
466 | 114 | <group col="3"> | ||
467 | 115 | <div width="57"> | ||
468 | 116 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">7</span> | ||
469 | 117 | </div> | ||
470 | 118 | <div width="400"> | ||
471 | 119 | <field name="legend_star1"/> | ||
472 | 120 | </div> | ||
473 | 121 | <div></div> | ||
474 | 122 | </group> | ||
475 | 123 | </div> | ||
476 | 124 | <div> | ||
477 | 125 | <group col="3"> | ||
478 | 126 | <div width="57"> | ||
479 | 127 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">77</span> | ||
480 | 128 | </div> | ||
481 | 129 | <div width="400"> | ||
482 | 130 | <field name="legend_star2"/> | ||
483 | 131 | </div> | ||
484 | 132 | <div></div> | ||
485 | 133 | </group> | ||
486 | 134 | </div> | ||
487 | 135 | <div> | ||
488 | 136 | <group col="3"> | ||
489 | 137 | <div width="57"> | ||
490 | 138 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">777</span> | ||
491 | 139 | </div> | ||
492 | 140 | <div width="400"> | ||
493 | 141 | <field name="legend_star3"/> | ||
494 | 142 | </div> | ||
495 | 143 | <div></div> | ||
496 | 144 | </group> | ||
497 | 145 | </div> | ||
498 | 146 | <div> | ||
499 | 147 | <group col="3"> | ||
500 | 148 | <div width="57"> | ||
501 | 149 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">7777</span> | ||
502 | 150 | </div> | ||
503 | 151 | <div width="400"> | ||
504 | 152 | <field name="legend_star4"/> | ||
505 | 153 | </div> | ||
506 | 154 | <div></div> | ||
507 | 155 | </group> | ||
508 | 156 | </div> | ||
509 | 157 | </div> | ||
510 | 158 | <field name="section_ids" invisible="1"/> | ||
511 | 110 | <separator string="Requirements"/> | 159 | <separator string="Requirements"/> |
512 | 111 | <field name="requirements" nolabel="1"/> | 160 | <field name="requirements" nolabel="1"/> |
513 | 112 | <field name="section_ids" invisible="1"/> | ||
514 | 113 | </form> | 161 | </form> |
515 | 114 | </field> | 162 | </field> |
516 | 115 | </record> | 163 | </record> |
517 | 116 | 164 | ||
518 | === modified file 'crm/report/crm_phonecall_report.py' | |||
519 | --- crm/report/crm_phonecall_report.py 2014-01-29 09:56:55 +0000 | |||
520 | +++ crm/report/crm_phonecall_report.py 2014-05-07 10:11:23 +0000 | |||
521 | @@ -42,7 +42,7 @@ | |||
522 | 42 | _columns = { | 42 | _columns = { |
523 | 43 | 'user_id':fields.many2one('res.users', 'User', readonly=True), | 43 | 'user_id':fields.many2one('res.users', 'User', readonly=True), |
524 | 44 | 'section_id':fields.many2one('crm.case.section', 'Section', readonly=True), | 44 | 'section_id':fields.many2one('crm.case.section', 'Section', readonly=True), |
526 | 45 | 'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority'), | 45 | 'priority': fields.selection([('0','Low'), ('1','Normal'), ('2','High')], 'Priority'), |
527 | 46 | 'nbr': fields.integer('# of Cases', readonly=True), | 46 | 'nbr': fields.integer('# of Cases', readonly=True), |
528 | 47 | 'state': fields.selection(AVAILABLE_STATES, 'Status', size=16, readonly=True), | 47 | 'state': fields.selection(AVAILABLE_STATES, 'Status', size=16, readonly=True), |
529 | 48 | 'create_date': fields.datetime('Create Date', readonly=True, select=True), | 48 | 'create_date': fields.datetime('Create Date', readonly=True, select=True), |
530 | 49 | 49 | ||
531 | === modified file 'crm_claim/crm_claim.py' | |||
532 | --- crm_claim/crm_claim.py 2014-03-24 05:09:21 +0000 | |||
533 | +++ crm_claim/crm_claim.py 2014-05-07 10:11:23 +0000 | |||
534 | @@ -88,7 +88,7 @@ | |||
535 | 88 | 'categ_id': fields.many2one('crm.case.categ', 'Category', \ | 88 | 'categ_id': fields.many2one('crm.case.categ', 'Category', \ |
536 | 89 | domain="[('section_id','=',section_id),\ | 89 | domain="[('section_id','=',section_id),\ |
537 | 90 | ('object_id.model', '=', 'crm.claim')]"), | 90 | ('object_id.model', '=', 'crm.claim')]"), |
539 | 91 | 'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority'), | 91 | 'priority': fields.selection([('0','Low'), ('1','Normal'), ('2','High')], 'Priority'), |
540 | 92 | 'type_action': fields.selection([('correction','Corrective Action'),('prevention','Preventive Action')], 'Action Type'), | 92 | 'type_action': fields.selection([('correction','Corrective Action'),('prevention','Preventive Action')], 'Action Type'), |
541 | 93 | 'user_id': fields.many2one('res.users', 'Responsible'), | 93 | 'user_id': fields.many2one('res.users', 'Responsible'), |
542 | 94 | 'user_fault': fields.char('Trouble Responsible', size=64), | 94 | 'user_fault': fields.char('Trouble Responsible', size=64), |
543 | @@ -111,7 +111,7 @@ | |||
544 | 111 | 'section_id': lambda s, cr, uid, c: s._get_default_section_id(cr, uid, c), | 111 | 'section_id': lambda s, cr, uid, c: s._get_default_section_id(cr, uid, c), |
545 | 112 | 'date': fields.datetime.now, | 112 | 'date': fields.datetime.now, |
546 | 113 | 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.case', context=c), | 113 | 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.case', context=c), |
548 | 114 | 'priority': lambda *a: crm.AVAILABLE_PRIORITIES[2][0], | 114 | 'priority': '1', |
549 | 115 | 'active': lambda *a: 1, | 115 | 'active': lambda *a: 1, |
550 | 116 | 'stage_id': lambda s, cr, uid, c: s._get_default_stage_id(cr, uid, c) | 116 | 'stage_id': lambda s, cr, uid, c: s._get_default_stage_id(cr, uid, c) |
551 | 117 | } | 117 | } |
552 | 118 | 118 | ||
553 | === modified file 'crm_claim/crm_claim_demo.xml' | |||
554 | --- crm_claim/crm_claim_demo.xml 2012-11-29 22:26:45 +0000 | |||
555 | +++ crm_claim/crm_claim_demo.xml 2014-05-07 10:11:23 +0000 | |||
556 | @@ -9,7 +9,7 @@ | |||
557 | 9 | <record id="crm_claim_1" model="crm.claim"> | 9 | <record id="crm_claim_1" model="crm.claim"> |
558 | 10 | <field eval="time.strftime('%Y-%m-04 10:45:36')" name="date"/> | 10 | <field eval="time.strftime('%Y-%m-04 10:45:36')" name="date"/> |
559 | 11 | <field name="partner_id" ref="base.res_partner_11"/> | 11 | <field name="partner_id" ref="base.res_partner_11"/> |
561 | 12 | <field eval=""3"" name="priority"/> | 12 | <field eval=""1"" name="priority"/> |
562 | 13 | <field name="user_id" ref="base.user_root"/> | 13 | <field name="user_id" ref="base.user_root"/> |
563 | 14 | <field eval=""Problem with the delivery of goods"" name="name"/> | 14 | <field eval=""Problem with the delivery of goods"" name="name"/> |
564 | 15 | <field name="section_id" ref="crm.section_sales_department"/> | 15 | <field name="section_id" ref="crm.section_sales_department"/> |
565 | @@ -21,7 +21,7 @@ | |||
566 | 21 | <record id="crm_claim_2" model="crm.claim"> | 21 | <record id="crm_claim_2" model="crm.claim"> |
567 | 22 | <field eval="time.strftime('%Y-%m-11 11:19:25')" name="date"/> | 22 | <field eval="time.strftime('%Y-%m-11 11:19:25')" name="date"/> |
568 | 23 | <field name="partner_id" ref="base.res_partner_6"/> | 23 | <field name="partner_id" ref="base.res_partner_6"/> |
570 | 24 | <field eval=""4"" name="priority"/> | 24 | <field eval=""0"" name="priority"/> |
571 | 25 | <field name="user_id" ref="base.user_root"/> | 25 | <field name="user_id" ref="base.user_root"/> |
572 | 26 | <field eval=""Damaged Products"" name="name"/> | 26 | <field eval=""Damaged Products"" name="name"/> |
573 | 27 | <field name="section_id" ref="crm.section_sales_department"/> | 27 | <field name="section_id" ref="crm.section_sales_department"/> |
574 | @@ -46,7 +46,7 @@ | |||
575 | 46 | <record id="crm_claim_4" model="crm.claim"> | 46 | <record id="crm_claim_4" model="crm.claim"> |
576 | 47 | <field eval="time.strftime('%Y-%m-21 14:10:23')" name="date"/> | 47 | <field eval="time.strftime('%Y-%m-21 14:10:23')" name="date"/> |
577 | 48 | <field name="partner_id" ref="base.res_partner_18"/> | 48 | <field name="partner_id" ref="base.res_partner_18"/> |
579 | 49 | <field eval=""3"" name="priority"/> | 49 | <field eval=""1"" name="priority"/> |
580 | 50 | <field name="user_id" ref="base.user_root"/> | 50 | <field name="user_id" ref="base.user_root"/> |
581 | 51 | <field eval=""Product quality not maintained"" name="name"/> | 51 | <field eval=""Product quality not maintained"" name="name"/> |
582 | 52 | <field name="section_id" ref="crm.section_sales_department"/> | 52 | <field name="section_id" ref="crm.section_sales_department"/> |
583 | @@ -58,7 +58,7 @@ | |||
584 | 58 | <record id="crm_claim_5" model="crm.claim"> | 58 | <record id="crm_claim_5" model="crm.claim"> |
585 | 59 | <field eval="time.strftime('%Y-%m-28 16:20:43')" name="date"/> | 59 | <field eval="time.strftime('%Y-%m-28 16:20:43')" name="date"/> |
586 | 60 | <field name="partner_id" ref="base.res_partner_5"/> | 60 | <field name="partner_id" ref="base.res_partner_5"/> |
588 | 61 | <field eval=""3"" name="priority"/> | 61 | <field eval=""1"" name="priority"/> |
589 | 62 | <field name="user_id" ref="base.user_root"/> | 62 | <field name="user_id" ref="base.user_root"/> |
590 | 63 | <field eval=""Some products missing"" name="name"/> | 63 | <field eval=""Some products missing"" name="name"/> |
591 | 64 | <field name="section_id" ref="crm.section_sales_department"/> | 64 | <field name="section_id" ref="crm.section_sales_department"/> |
592 | @@ -69,7 +69,7 @@ | |||
593 | 69 | 69 | ||
594 | 70 | <record id="crm_claim_6" model="crm.claim"> | 70 | <record id="crm_claim_6" model="crm.claim"> |
595 | 71 | <field name="partner_id" ref="base.res_partner_9"/> | 71 | <field name="partner_id" ref="base.res_partner_9"/> |
597 | 72 | <field eval=""3"" name="priority"/> | 72 | <field eval=""1"" name="priority"/> |
598 | 73 | <field name="user_id" ref="base.user_root"/> | 73 | <field name="user_id" ref="base.user_root"/> |
599 | 74 | <field eval=""Problem with the delivery of assignments"" name="name"/> | 74 | <field eval=""Problem with the delivery of assignments"" name="name"/> |
600 | 75 | <field name="section_id" ref="crm.section_sales_department"/> | 75 | <field name="section_id" ref="crm.section_sales_department"/> |
601 | @@ -82,7 +82,7 @@ | |||
602 | 82 | 82 | ||
603 | 83 | <record id="crm_claim_7" model="crm.claim"> | 83 | <record id="crm_claim_7" model="crm.claim"> |
604 | 84 | <field name="partner_id" ref="base.res_partner_19"/> | 84 | <field name="partner_id" ref="base.res_partner_19"/> |
606 | 85 | <field eval=""3"" name="priority"/> | 85 | <field eval=""1"" name="priority"/> |
607 | 86 | <field name="user_id" ref="base.user_root"/> | 86 | <field name="user_id" ref="base.user_root"/> |
608 | 87 | <field eval=""Documents unclear"" name="name"/> | 87 | <field eval=""Documents unclear"" name="name"/> |
609 | 88 | <field name="section_id" ref="crm.section_sales_department"/> | 88 | <field name="section_id" ref="crm.section_sales_department"/> |
610 | 89 | 89 | ||
611 | === modified file 'crm_claim/crm_claim_view.xml' | |||
612 | --- crm_claim/crm_claim_view.xml 2013-10-27 12:31:04 +0000 | |||
613 | +++ crm_claim/crm_claim_view.xml 2014-05-07 10:11:23 +0000 | |||
614 | @@ -107,7 +107,7 @@ | |||
615 | 107 | </group> | 107 | </group> |
616 | 108 | <group colspan="4" col="4" groups="base.group_user"> | 108 | <group colspan="4" col="4" groups="base.group_user"> |
617 | 109 | <field name="user_id" context="{'default_groups_ref': ['base.group_user', 'base.group_partner_manager', 'base.group_sale_salesman_all_leads']}"/> | 109 | <field name="user_id" context="{'default_groups_ref': ['base.group_user', 'base.group_partner_manager', 'base.group_sale_salesman_all_leads']}"/> |
619 | 110 | <field name="priority"/> | 110 | <field name="priority" widget="priority"/> |
620 | 111 | <field name="section_id" groups="base.group_multi_salesteams"/> | 111 | <field name="section_id" groups="base.group_multi_salesteams"/> |
621 | 112 | <field name="date_deadline"/> | 112 | <field name="date_deadline"/> |
622 | 113 | </group> | 113 | </group> |
623 | 114 | 114 | ||
624 | === modified file 'crm_claim/report/crm_claim_report.py' | |||
625 | --- crm_claim/report/crm_claim_report.py 2013-10-27 12:31:04 +0000 | |||
626 | +++ crm_claim/report/crm_claim_report.py 2014-05-07 10:11:23 +0000 | |||
627 | @@ -23,11 +23,9 @@ | |||
628 | 23 | from openerp import tools | 23 | from openerp import tools |
629 | 24 | 24 | ||
630 | 25 | AVAILABLE_PRIORITIES = [ | 25 | AVAILABLE_PRIORITIES = [ |
636 | 26 | ('5', 'Lowest'), | 26 | ('0', 'Low'), |
637 | 27 | ('4', 'Low'), | 27 | ('1', 'Normal'), |
638 | 28 | ('3', 'Normal'), | 28 | ('2', 'High') |
634 | 29 | ('2', 'High'), | ||
635 | 30 | ('1', 'Highest') | ||
639 | 31 | ] | 29 | ] |
640 | 32 | 30 | ||
641 | 33 | 31 | ||
642 | 34 | 32 | ||
643 | === modified file 'crm_helpdesk/crm_helpdesk.py' | |||
644 | --- crm_helpdesk/crm_helpdesk.py 2013-11-27 15:32:57 +0000 | |||
645 | +++ crm_helpdesk/crm_helpdesk.py 2014-05-07 10:11:23 +0000 | |||
646 | @@ -59,7 +59,7 @@ | |||
647 | 59 | 'channel_id': fields.many2one('crm.case.channel', 'Channel', help="Communication channel."), | 59 | 'channel_id': fields.many2one('crm.case.channel', 'Channel', help="Communication channel."), |
648 | 60 | 'planned_revenue': fields.float('Planned Revenue'), | 60 | 'planned_revenue': fields.float('Planned Revenue'), |
649 | 61 | 'planned_cost': fields.float('Planned Costs'), | 61 | 'planned_cost': fields.float('Planned Costs'), |
651 | 62 | 'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority'), | 62 | 'priority': fields.selection([('0','Low'), ('1','Normal'), ('2','High')], 'Priority'), |
652 | 63 | 'probability': fields.float('Probability (%)'), | 63 | 'probability': fields.float('Probability (%)'), |
653 | 64 | 'categ_id': fields.many2one('crm.case.categ', 'Category', \ | 64 | 'categ_id': fields.many2one('crm.case.categ', 'Category', \ |
654 | 65 | domain="['|',('section_id','=',False),('section_id','=',section_id),\ | 65 | domain="['|',('section_id','=',False),('section_id','=',section_id),\ |
655 | @@ -83,7 +83,7 @@ | |||
656 | 83 | 'state': lambda *a: 'draft', | 83 | 'state': lambda *a: 'draft', |
657 | 84 | 'date': fields.datetime.now, | 84 | 'date': fields.datetime.now, |
658 | 85 | 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.helpdesk', context=c), | 85 | 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.helpdesk', context=c), |
660 | 86 | 'priority': lambda *a: crm.AVAILABLE_PRIORITIES[2][0], | 86 | 'priority': '1', |
661 | 87 | } | 87 | } |
662 | 88 | 88 | ||
663 | 89 | def on_change_partner_id(self, cr, uid, ids, partner_id, context=None): | 89 | def on_change_partner_id(self, cr, uid, ids, partner_id, context=None): |
664 | 90 | 90 | ||
665 | === modified file 'crm_helpdesk/crm_helpdesk_demo.xml' | |||
666 | --- crm_helpdesk/crm_helpdesk_demo.xml 2012-11-29 22:26:45 +0000 | |||
667 | +++ crm_helpdesk/crm_helpdesk_demo.xml 2014-05-07 10:11:23 +0000 | |||
668 | @@ -5,7 +5,7 @@ | |||
669 | 5 | <field eval="1" name="active"/> | 5 | <field eval="1" name="active"/> |
670 | 6 | <field name="user_id" ref="base.user_root"/> | 6 | <field name="user_id" ref="base.user_root"/> |
671 | 7 | <field name="company_id" ref="base.main_company"/> | 7 | <field name="company_id" ref="base.main_company"/> |
673 | 8 | <field name="priority">3</field> | 8 | <field name="priority">1</field> |
674 | 9 | <field name="state">draft</field> | 9 | <field name="state">draft</field> |
675 | 10 | <field name="section_id" ref="crm.section_sales_department"/> | 10 | <field name="section_id" ref="crm.section_sales_department"/> |
676 | 11 | <field name="date" eval="time.strftime('%Y-%m-04 11:10:36')"/> | 11 | <field name="date" eval="time.strftime('%Y-%m-04 11:10:36')"/> |
677 | @@ -17,7 +17,7 @@ | |||
678 | 17 | <field eval="1" name="active"/> | 17 | <field eval="1" name="active"/> |
679 | 18 | <field name="user_id" ref="base.user_demo"/> | 18 | <field name="user_id" ref="base.user_demo"/> |
680 | 19 | <field name="company_id" ref="base.main_company"/> | 19 | <field name="company_id" ref="base.main_company"/> |
682 | 20 | <field name="priority">3</field> | 20 | <field name="priority">1</field> |
683 | 21 | <field name="state">draft</field> | 21 | <field name="state">draft</field> |
684 | 22 | <field name="section_id" ref="crm.section_sales_department"/> | 22 | <field name="section_id" ref="crm.section_sales_department"/> |
685 | 23 | <field name="date" eval="time.strftime('%Y-%m-12 11:12:09')"/> | 23 | <field name="date" eval="time.strftime('%Y-%m-12 11:12:09')"/> |
686 | @@ -42,7 +42,7 @@ | |||
687 | 42 | <field name="partner_id" ref="base.res_partner_2"/> | 42 | <field name="partner_id" ref="base.res_partner_2"/> |
688 | 43 | <field name="user_id" ref="base.user_root"/> | 43 | <field name="user_id" ref="base.user_root"/> |
689 | 44 | <field name="company_id" ref="base.main_company"/> | 44 | <field name="company_id" ref="base.main_company"/> |
691 | 45 | <field name="priority">3</field> | 45 | <field name="priority">1</field> |
692 | 46 | <field name="state">draft</field> | 46 | <field name="state">draft</field> |
693 | 47 | <field name="date" eval="time.strftime('%Y-%m-12 11:15:17')"/> | 47 | <field name="date" eval="time.strftime('%Y-%m-12 11:15:17')"/> |
694 | 48 | <field name="name">How to create a new module</field> | 48 | <field name="name">How to create a new module</field> |
695 | 49 | 49 | ||
696 | === modified file 'crm_helpdesk/crm_helpdesk_view.xml' | |||
697 | --- crm_helpdesk/crm_helpdesk_view.xml 2014-04-17 11:26:55 +0000 | |||
698 | +++ crm_helpdesk/crm_helpdesk_view.xml 2014-05-07 10:11:23 +0000 | |||
699 | @@ -51,7 +51,7 @@ | |||
700 | 51 | <field name="email_from"/> | 51 | <field name="email_from"/> |
701 | 52 | </group> | 52 | </group> |
702 | 53 | <group string="Categorization"> | 53 | <group string="Categorization"> |
704 | 54 | <field name="priority"/> | 54 | <field name="priority" widget="priority"/> |
705 | 55 | <field name="categ_id" domain="[('object_id.model', '=', 'crm.helpdesk')]" context="{'object_name': 'crm.helpdesk'}"/> | 55 | <field name="categ_id" domain="[('object_id.model', '=', 'crm.helpdesk')]" context="{'object_name': 'crm.helpdesk'}"/> |
706 | 56 | <field name="channel_id"/> | 56 | <field name="channel_id"/> |
707 | 57 | </group> | 57 | </group> |
708 | 58 | 58 | ||
709 | === modified file 'hr_recruitment/hr_recruitment.py' | |||
710 | --- hr_recruitment/hr_recruitment.py 2014-04-17 06:53:56 +0000 | |||
711 | +++ hr_recruitment/hr_recruitment.py 2014-05-07 10:11:23 +0000 | |||
712 | @@ -25,12 +25,11 @@ | |||
713 | 25 | 25 | ||
714 | 26 | 26 | ||
715 | 27 | AVAILABLE_PRIORITIES = [ | 27 | AVAILABLE_PRIORITIES = [ |
719 | 28 | ('', ''), | 28 | ('0', 'Bad'), |
720 | 29 | ('5', 'Not Good'), | 29 | ('1', 'Below Average'), |
721 | 30 | ('4', 'On Average'), | 30 | ('2', 'Average'), |
722 | 31 | ('3', 'Good'), | 31 | ('3', 'Good'), |
725 | 32 | ('2', 'Very Good'), | 32 | ('4', 'Excellent') |
724 | 33 | ('1', 'Excellent') | ||
726 | 34 | ] | 33 | ] |
727 | 35 | 34 | ||
728 | 36 | class hr_recruitment_source(osv.osv): | 35 | class hr_recruitment_source(osv.osv): |
729 | @@ -46,6 +45,27 @@ | |||
730 | 46 | _name = "hr.recruitment.stage" | 45 | _name = "hr.recruitment.stage" |
731 | 47 | _description = "Stage of Recruitment" | 46 | _description = "Stage of Recruitment" |
732 | 48 | _order = 'sequence' | 47 | _order = 'sequence' |
733 | 48 | |||
734 | 49 | def _get_tooltips(self, cr, uid, ids, field, args, context=None): | ||
735 | 50 | res = {} | ||
736 | 51 | for rec in self.read(cr, uid, ids, ['legend_star1','legend_star2','legend_star3','legend_star4','requirements'], context=context): | ||
737 | 52 | value = "" | ||
738 | 53 | img = "<img src='/web/static/src/img/icons/star-on.png'/>" | ||
739 | 54 | if rec['legend_star1']: | ||
740 | 55 | value += img +' '+ rec['legend_star1'] + "<br/>" | ||
741 | 56 | if rec['legend_star2']: | ||
742 | 57 | value += img + img +' '+ rec['legend_star2'] + "<br/>" | ||
743 | 58 | if rec['legend_star3']: | ||
744 | 59 | value += img + img + img +' '+ rec['legend_star3'] + "<br/>" | ||
745 | 60 | if rec['legend_star4']: | ||
746 | 61 | value += img + img + img + img +' '+ rec['legend_star4'] + "<br/>" | ||
747 | 62 | if rec['requirements']: | ||
748 | 63 | value += rec['requirements'] | ||
749 | 64 | tooltip = {'tooltip': value} | ||
750 | 65 | tooltip.update(rec) | ||
751 | 66 | res[rec['id']] = tooltip | ||
752 | 67 | return res | ||
753 | 68 | |||
754 | 49 | _columns = { | 69 | _columns = { |
755 | 50 | 'name': fields.char('Name', size=64, required=True, translate=True), | 70 | 'name': fields.char('Name', size=64, required=True, translate=True), |
756 | 51 | 'sequence': fields.integer('Sequence', help="Gives the sequence order when displaying a list of stages."), | 71 | 'sequence': fields.integer('Sequence', help="Gives the sequence order when displaying a list of stages."), |
757 | @@ -55,6 +75,11 @@ | |||
758 | 55 | 'fold': fields.boolean('Folded in Kanban View', | 75 | 'fold': fields.boolean('Folded in Kanban View', |
759 | 56 | help='This stage is folded in the kanban view when' | 76 | help='This stage is folded in the kanban view when' |
760 | 57 | 'there are no records in that stage to display.'), | 77 | 'there are no records in that stage to display.'), |
761 | 78 | 'kanban_column_tooltip': fields.function(_get_tooltips, string='Tooltips', type="char", help="This tooltips will display on kanban stage header" ), | ||
762 | 79 | 'legend_star1':fields.char('Legend Star', help='This tooltip will appear on kanban view column header.'), | ||
763 | 80 | 'legend_star2':fields.char('Legend Star2', help='This tooltip will appear on kanban view column header.'), | ||
764 | 81 | 'legend_star3':fields.char('Legend Star3', help='This tooltip will appear on kanban view column header.'), | ||
765 | 82 | 'legend_star4':fields.char('Legend Star4', help='This tooltip will appear on kanban view column header.'), | ||
766 | 58 | } | 83 | } |
767 | 59 | _defaults = { | 84 | _defaults = { |
768 | 60 | 'sequence': 1, | 85 | 'sequence': 1, |
769 | @@ -489,21 +514,6 @@ | |||
770 | 489 | dict_act_window['view_mode'] = 'form,tree' | 514 | dict_act_window['view_mode'] = 'form,tree' |
771 | 490 | return dict_act_window | 515 | return dict_act_window |
772 | 491 | 516 | ||
773 | 492 | def set_priority(self, cr, uid, ids, priority, *args): | ||
774 | 493 | """Set applicant priority | ||
775 | 494 | """ | ||
776 | 495 | return self.write(cr, uid, ids, {'priority': priority}) | ||
777 | 496 | |||
778 | 497 | def set_high_priority(self, cr, uid, ids, *args): | ||
779 | 498 | """Set applicant priority to high | ||
780 | 499 | """ | ||
781 | 500 | return self.set_priority(cr, uid, ids, '1') | ||
782 | 501 | |||
783 | 502 | def set_normal_priority(self, cr, uid, ids, *args): | ||
784 | 503 | """Set applicant priority to normal | ||
785 | 504 | """ | ||
786 | 505 | return self.set_priority(cr, uid, ids, '3') | ||
787 | 506 | |||
788 | 507 | def get_empty_list_help(self, cr, uid, help, context=None): | 517 | def get_empty_list_help(self, cr, uid, help, context=None): |
789 | 508 | context['empty_list_help_model'] = 'hr.job' | 518 | context['empty_list_help_model'] = 'hr.job' |
790 | 509 | context['empty_list_help_id'] = context.get('default_job_id', None) | 519 | context['empty_list_help_id'] = context.get('default_job_id', None) |
791 | 510 | 520 | ||
792 | === modified file 'hr_recruitment/hr_recruitment_data.xml' | |||
793 | --- hr_recruitment/hr_recruitment_data.xml 2014-02-12 09:56:06 +0000 | |||
794 | +++ hr_recruitment/hr_recruitment_data.xml 2014-05-07 10:11:23 +0000 | |||
795 | @@ -92,30 +92,54 @@ | |||
796 | 92 | <record model="hr.recruitment.stage" id="stage_job1"> | 92 | <record model="hr.recruitment.stage" id="stage_job1"> |
797 | 93 | <field name="name">Initial Qualification</field> | 93 | <field name="name">Initial Qualification</field> |
798 | 94 | <field name="sequence">1</field> | 94 | <field name="sequence">1</field> |
799 | 95 | <field name="legend_star1">Average</field> | ||
800 | 96 | <field name="legend_star2">Correspond to the job requirements</field> | ||
801 | 97 | <field name="legend_star3">Nice to have skills</field> | ||
802 | 98 | <field name="legend_star4">Excellent</field> | ||
803 | 95 | </record> | 99 | </record> |
804 | 96 | <record model="hr.recruitment.stage" id="stage_job2"> | 100 | <record model="hr.recruitment.stage" id="stage_job2"> |
805 | 97 | <field name="name">First Interview</field> | 101 | <field name="name">First Interview</field> |
806 | 98 | <field name="template_id" ref="applicant_interest"/> | 102 | <field name="template_id" ref="applicant_interest"/> |
807 | 99 | <field name="sequence">2</field> | 103 | <field name="sequence">2</field> |
808 | 104 | <field name="legend_star1">Average</field> | ||
809 | 105 | <field name="legend_star2">Good</field> | ||
810 | 106 | <field name="legend_star3">Very Good</field> | ||
811 | 107 | <field name="legend_star4">Excellent</field> | ||
812 | 100 | </record> | 108 | </record> |
813 | 101 | <record model="hr.recruitment.stage" id="stage_job3"> | 109 | <record model="hr.recruitment.stage" id="stage_job3"> |
814 | 102 | <field name="name">Second Interview</field> | 110 | <field name="name">Second Interview</field> |
815 | 103 | <field name="sequence">3</field> | 111 | <field name="sequence">3</field> |
816 | 112 | <field name="legend_star1">Average</field> | ||
817 | 113 | <field name="legend_star2">Good at required skills</field> | ||
818 | 114 | <field name="legend_star3">Expert in required skills</field> | ||
819 | 115 | <field name="legend_star4">Excellent in all the skills</field> | ||
820 | 104 | </record> | 116 | </record> |
821 | 105 | <record model="hr.recruitment.stage" id="stage_job4"> | 117 | <record model="hr.recruitment.stage" id="stage_job4"> |
822 | 106 | <field name="name">Contract Proposed</field> | 118 | <field name="name">Contract Proposed</field> |
823 | 107 | <field name="sequence">4</field> | 119 | <field name="sequence">4</field> |
824 | 120 | <field name="legend_star1">Average</field> | ||
825 | 121 | <field name="legend_star2">Good</field> | ||
826 | 122 | <field name="legend_star3">Very Good</field> | ||
827 | 123 | <field name="legend_star4">Excellent</field> | ||
828 | 108 | </record> | 124 | </record> |
829 | 109 | <record model="hr.recruitment.stage" id="stage_job5"> | 125 | <record model="hr.recruitment.stage" id="stage_job5"> |
830 | 110 | <field name="name">Contract Signed</field> | 126 | <field name="name">Contract Signed</field> |
831 | 111 | <field name="sequence">5</field> | 127 | <field name="sequence">5</field> |
832 | 112 | <field name="fold" eval="True"/> | 128 | <field name="fold" eval="True"/> |
833 | 129 | <field name="legend_star1">Average</field> | ||
834 | 130 | <field name="legend_star2">Good</field> | ||
835 | 131 | <field name="legend_star3">Very Good</field> | ||
836 | 132 | <field name="legend_star4">Excellent</field> | ||
837 | 113 | </record> | 133 | </record> |
838 | 114 | <record model="hr.recruitment.stage" id="stage_job6"> | 134 | <record model="hr.recruitment.stage" id="stage_job6"> |
839 | 115 | <field name="name">Refused</field> | 135 | <field name="name">Refused</field> |
840 | 116 | <field name="sequence">6</field> | 136 | <field name="sequence">6</field> |
841 | 117 | <field name="template_id" ref="applicant_refuse"/> | 137 | <field name="template_id" ref="applicant_refuse"/> |
842 | 118 | <field name="fold" eval="True"/> | 138 | <field name="fold" eval="True"/> |
843 | 139 | <field name="legend_star1">Average</field> | ||
844 | 140 | <field name="legend_star2">Good</field> | ||
845 | 141 | <field name="legend_star3">Very Good</field> | ||
846 | 142 | <field name="legend_star4">Excellent</field> | ||
847 | 119 | </record> | 143 | </record> |
848 | 120 | 144 | ||
849 | 121 | <record id="mail_alias_jobs" model="mail.alias"> | 145 | <record id="mail_alias_jobs" model="mail.alias"> |
850 | 122 | 146 | ||
851 | === modified file 'hr_recruitment/hr_recruitment_demo.xml' | |||
852 | --- hr_recruitment/hr_recruitment_demo.xml 2014-02-12 09:56:06 +0000 | |||
853 | +++ hr_recruitment/hr_recruitment_demo.xml 2014-05-07 10:11:23 +0000 | |||
854 | @@ -75,7 +75,7 @@ | |||
855 | 75 | <field name="type_id" ref="degree_licenced"/> | 75 | <field name="type_id" ref="degree_licenced"/> |
856 | 76 | <field name="categ_ids" eval="[(6,0,[ref('tag_applicant_reserve')])]"/> | 76 | <field name="categ_ids" eval="[(6,0,[ref('tag_applicant_reserve')])]"/> |
857 | 77 | <field name="user_id" ref="base.user_root"/> | 77 | <field name="user_id" ref="base.user_root"/> |
859 | 78 | <field name="priority">4</field> | 78 | <field name="priority">2</field> |
860 | 79 | <field name="partner_name">David Armstrong</field> | 79 | <field name="partner_name">David Armstrong</field> |
861 | 80 | <field name="stage_id" ref="stage_job2"/> | 80 | <field name="stage_id" ref="stage_job2"/> |
862 | 81 | <field name="partner_phone">33968745</field> | 81 | <field name="partner_phone">33968745</field> |
863 | 82 | 82 | ||
864 | === modified file 'hr_recruitment/hr_recruitment_view.xml' | |||
865 | --- hr_recruitment/hr_recruitment_view.xml 2014-04-15 15:01:46 +0000 | |||
866 | +++ hr_recruitment/hr_recruitment_view.xml 2014-05-07 10:11:23 +0000 | |||
867 | @@ -130,7 +130,7 @@ | |||
868 | 130 | <field name="date_action"/> | 130 | <field name="date_action"/> |
869 | 131 | <field name="title_action" class="oe_inline" placeholder="e.g. Call for interview"/> | 131 | <field name="title_action" class="oe_inline" placeholder="e.g. Call for interview"/> |
870 | 132 | </div> | 132 | </div> |
872 | 133 | <field name="priority"/> | 133 | <field name="priority" widget="priority"/> |
873 | 134 | <field name="source_id"/> | 134 | <field name="source_id"/> |
874 | 135 | <field name="reference"/> | 135 | <field name="reference"/> |
875 | 136 | </group> | 136 | </group> |
876 | @@ -246,7 +246,7 @@ | |||
877 | 246 | <field name="model">hr.applicant</field> | 246 | <field name="model">hr.applicant</field> |
878 | 247 | <field name="arch" type="xml"> | 247 | <field name="arch" type="xml"> |
879 | 248 | <kanban default_group_by="stage_id"> | 248 | <kanban default_group_by="stage_id"> |
881 | 249 | <field name="stage_id"/> | 249 | <field name="stage_id" options='{"tooltip_on_group_by": "kanban_column_tooltip"}'/> |
882 | 250 | <field name="color"/> | 250 | <field name="color"/> |
883 | 251 | <field name="priority"/> | 251 | <field name="priority"/> |
884 | 252 | <field name="survey"/> | 252 | <field name="survey"/> |
885 | @@ -294,21 +294,16 @@ | |||
886 | 294 | </div> | 294 | </div> |
887 | 295 | <div style="width:240px"><field name="categ_ids"/></div> | 295 | <div style="width:240px"><field name="categ_ids"/></div> |
888 | 296 | <div class="oe_kanban_right"> | 296 | <div class="oe_kanban_right"> |
904 | 297 | <t t-set="priority" t-value="record.priority.raw_value || 5"/> | 297 | <table> |
905 | 298 | <a type="object" name="set_priority" args="['3']" t-if="priority gt 3"> | 298 | <tr> |
906 | 299 | <img src="/web/static/src/img/icons/star-off.png" width="16" height="16" title="Good"/> | 299 | <td groups="base.group_user"> |
907 | 300 | </a> | 300 | <field name="priority" widget="priority"/> |
908 | 301 | <a type="object" name="set_priority" args="['5']" t-if="priority lte 3"> | 301 | </td> |
909 | 302 | <img t-attf-src="/web/static/src/img/icons/star-#{priority lte 3 ? 'on' : 'off'}.png" width="16" height="16" title="Good"/> | 302 | <td> |
910 | 303 | </a> | 303 | <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar"/> |
911 | 304 | <a type="object" name="set_priority" args="['2']"> | 304 | </td> |
912 | 305 | <img t-attf-src="/web/static/src/img/icons/star-#{priority lte 2 ? 'on' : 'off'}.png" width="16" height="16" title="Very Good"/> | 305 | </tr> |
913 | 306 | </a> | 306 | </table> |
899 | 307 | <a type="object" name="set_priority" args="['1']"> | ||
900 | 308 | <img t-attf-src="/web/static/src/img/icons/star-#{priority == 1 ? 'on' : 'off'}.png" width="16" height="16" title="Excellent"/> | ||
901 | 309 | </a> | ||
902 | 310 | <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar"/> | ||
903 | 311 | |||
914 | 312 | </div> | 307 | </div> |
915 | 313 | <div class="oe_kanban_footer_left" style="margin-top:5px;"> | 308 | <div class="oe_kanban_footer_left" style="margin-top:5px;"> |
916 | 314 | <t t-raw="record.message_summary.raw_value"/> | 309 | <t t-raw="record.message_summary.raw_value"/> |
917 | @@ -553,6 +548,52 @@ | |||
918 | 553 | <field name="template_id" domain= "[('model_id.model', '=', 'hr.applicant')]"/> | 548 | <field name="template_id" domain= "[('model_id.model', '=', 'hr.applicant')]"/> |
919 | 554 | </group> | 549 | </group> |
920 | 555 | </group> | 550 | </group> |
921 | 551 | <separator string="Legend"/> | ||
922 | 552 | <p>The legend will appear as tooltip of each column of the opportunities pipe.</p> | ||
923 | 553 | <div> | ||
924 | 554 | <group col="3"> | ||
925 | 555 | <div width="57"> | ||
926 | 556 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">7</span> | ||
927 | 557 | </div> | ||
928 | 558 | <div width="400"> | ||
929 | 559 | <field name="legend_star1"/> | ||
930 | 560 | </div> | ||
931 | 561 | <div></div> | ||
932 | 562 | </group> | ||
933 | 563 | </div> | ||
934 | 564 | <div> | ||
935 | 565 | <group col="3"> | ||
936 | 566 | <div width="57"> | ||
937 | 567 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">77</span> | ||
938 | 568 | </div> | ||
939 | 569 | <div width="400"> | ||
940 | 570 | <field name="legend_star2"/> | ||
941 | 571 | </div> | ||
942 | 572 | <div></div> | ||
943 | 573 | </group> | ||
944 | 574 | </div> | ||
945 | 575 | <div> | ||
946 | 576 | <group col="3"> | ||
947 | 577 | <div width="57"> | ||
948 | 578 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">777</span> | ||
949 | 579 | </div> | ||
950 | 580 | <div width="400"> | ||
951 | 581 | <field name="legend_star3"/> | ||
952 | 582 | </div> | ||
953 | 583 | <div></div> | ||
954 | 584 | </group> | ||
955 | 585 | </div> | ||
956 | 586 | <div> | ||
957 | 587 | <group col="3"> | ||
958 | 588 | <div width="57"> | ||
959 | 589 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">7777</span> | ||
960 | 590 | </div> | ||
961 | 591 | <div width="400"> | ||
962 | 592 | <field name="legend_star4"/> | ||
963 | 593 | </div> | ||
964 | 594 | <div></div> | ||
965 | 595 | </group> | ||
966 | 596 | </div> | ||
967 | 556 | <separator string="Requirements"/> | 597 | <separator string="Requirements"/> |
968 | 557 | <field name="requirements"/> | 598 | <field name="requirements"/> |
969 | 558 | </sheet> | 599 | </sheet> |
970 | 559 | 600 | ||
971 | === modified file 'project/project.py' | |||
972 | --- project/project.py 2014-04-10 14:51:31 +0000 | |||
973 | +++ project/project.py 2014-05-07 10:11:23 +0000 | |||
974 | @@ -34,6 +34,29 @@ | |||
975 | 34 | _name = 'project.task.type' | 34 | _name = 'project.task.type' |
976 | 35 | _description = 'Task Stage' | 35 | _description = 'Task Stage' |
977 | 36 | _order = 'sequence' | 36 | _order = 'sequence' |
978 | 37 | |||
979 | 38 | def _get_tooltips(self, cr, uid, ids, field, args, context=None): | ||
980 | 39 | res = {} | ||
981 | 40 | for rec in self.read(cr, uid, ids, ['legend_blocked', 'legend_done', 'legend_star1','legend_star2','description'],context=context): | ||
982 | 41 | value = "" | ||
983 | 42 | star = "<img src='/web/static/src/img/icons/star-on.png'/>" | ||
984 | 43 | if rec['legend_blocked']: | ||
985 | 44 | img = "<img src='/web/static/src/img/icons/gtk-no.png'/>" | ||
986 | 45 | value += img +' '+ rec['legend_blocked'] + "<br/>" | ||
987 | 46 | if rec['legend_done']: | ||
988 | 47 | img = "<img src='/web/static/src/img/icons/gtk-yes.png'/> " | ||
989 | 48 | value += img +' '+ rec['legend_done'] + "<br/>" | ||
990 | 49 | if rec['legend_star1']: | ||
991 | 50 | value += star +' '+ rec['legend_star1'] + "<br/>" | ||
992 | 51 | if rec['legend_star2']: | ||
993 | 52 | value += star + star +' '+ rec['legend_star2'] + "<br/>" | ||
994 | 53 | if rec['description']: | ||
995 | 54 | value += rec['description'] | ||
996 | 55 | tooltip = {'tooltip': value} | ||
997 | 56 | tooltip.update(rec) | ||
998 | 57 | res[rec['id']] = tooltip | ||
999 | 58 | return res | ||
1000 | 59 | |||
1001 | 37 | _columns = { | 60 | _columns = { |
1002 | 38 | 'name': fields.char('Stage Name', required=True, size=64, translate=True), | 61 | 'name': fields.char('Stage Name', required=True, size=64, translate=True), |
1003 | 39 | 'description': fields.text('Description'), | 62 | 'description': fields.text('Description'), |
1004 | @@ -41,6 +64,16 @@ | |||
1005 | 41 | 'case_default': fields.boolean('Default for New Projects', | 64 | 'case_default': fields.boolean('Default for New Projects', |
1006 | 42 | help="If you check this field, this stage will be proposed by default on each new project. It will not assign this stage to existing projects."), | 65 | help="If you check this field, this stage will be proposed by default on each new project. It will not assign this stage to existing projects."), |
1007 | 43 | 'project_ids': fields.many2many('project.project', 'project_task_type_rel', 'type_id', 'project_id', 'Projects'), | 66 | 'project_ids': fields.many2many('project.project', 'project_task_type_rel', 'type_id', 'project_id', 'Projects'), |
1008 | 67 | 'kanban_column_tooltip': fields.function(_get_tooltips, string='Tooltips', type="char", help="This tooltips will display on kanban stage header"), | ||
1009 | 68 | 'legend_blocked': fields.char('Legend Red', help='This tooltip will appear on kanban view column header.'), | ||
1010 | 69 | 'legend_done':fields.char('Legend Green', help='This tooltip will appear on kanban view column header.'), | ||
1011 | 70 | 'legend_star1':fields.char('Legend Star', help='This tooltip will appear on kanban view column header.'), | ||
1012 | 71 | 'legend_star2':fields.char('Legend Star2', help='This tooltip will appear on kanban view column header.'), | ||
1013 | 72 | 'type': fields.selection([('task', 'Task'), | ||
1014 | 73 | ('issue', 'Issue'), | ||
1015 | 74 | ('both', 'Both')], | ||
1016 | 75 | string='Type', size=16, required=True, | ||
1017 | 76 | help="This field is used to distinguish stages related to Issues and Tasks, or to specify stages available for both types."), | ||
1018 | 44 | 'fold': fields.boolean('Folded in Kanban View', | 77 | 'fold': fields.boolean('Folded in Kanban View', |
1019 | 45 | help='This stage is folded in the kanban view when' | 78 | help='This stage is folded in the kanban view when' |
1020 | 46 | 'there are no records in that stage to display.'), | 79 | 'there are no records in that stage to display.'), |
1021 | @@ -54,6 +87,9 @@ | |||
1022 | 54 | 87 | ||
1023 | 55 | _defaults = { | 88 | _defaults = { |
1024 | 56 | 'sequence': 1, | 89 | 'sequence': 1, |
1025 | 90 | 'fold': False, | ||
1026 | 91 | 'case_default': True, | ||
1027 | 92 | 'type': 'both', | ||
1028 | 57 | 'project_ids': _get_default_project_ids, | 93 | 'project_ids': _get_default_project_ids, |
1029 | 58 | } | 94 | } |
1030 | 59 | _order = 'sequence' | 95 | _order = 'sequence' |
1031 | @@ -543,9 +579,19 @@ | |||
1032 | 543 | # if alias_model has been changed, update alias_model_id accordingly | 579 | # if alias_model has been changed, update alias_model_id accordingly |
1033 | 544 | if vals.get('alias_model'): | 580 | if vals.get('alias_model'): |
1034 | 545 | model_ids = self.pool.get('ir.model').search(cr, uid, [('model', '=', vals.get('alias_model', 'project.task'))]) | 581 | model_ids = self.pool.get('ir.model').search(cr, uid, [('model', '=', vals.get('alias_model', 'project.task'))]) |
1036 | 546 | vals.update(alias_model_id=model_ids[0]) | 582 | if model_ids and len(model_ids): |
1037 | 583 | vals.update(alias_model_id=model_ids[0]) | ||
1038 | 547 | return super(project, self).write(cr, uid, ids, vals, context=context) | 584 | return super(project, self).write(cr, uid, ids, vals, context=context) |
1039 | 548 | 585 | ||
1040 | 586 | def project_tasks_action(self, cr, uid, ids, context=None): | ||
1041 | 587 | data_obj = self.pool.get('ir.model.data') | ||
1042 | 588 | action_obj =self.pool.get('ir.actions.act_window') | ||
1043 | 589 | |||
1044 | 590 | action_id = data_obj.get_object_reference(cr, uid, 'project', 'act_project_project_2_project_task_all')[1] | ||
1045 | 591 | action = action_obj.read(cr, uid, action_id, [], context) | ||
1046 | 592 | res = self.read(cr, uid, ids, ['task_label'], context)[0] | ||
1047 | 593 | action['name'] = res['task_label'] | ||
1048 | 594 | return action | ||
1049 | 549 | 595 | ||
1050 | 550 | class task(osv.osv): | 596 | class task(osv.osv): |
1051 | 551 | _name = "project.task" | 597 | _name = "project.task" |
1052 | @@ -565,6 +611,7 @@ | |||
1053 | 565 | }, | 611 | }, |
1054 | 566 | 'kanban_state': { | 612 | 'kanban_state': { |
1055 | 567 | 'project.mt_task_blocked': lambda self, cr, uid, obj, ctx=None: obj.kanban_state == 'blocked', | 613 | 'project.mt_task_blocked': lambda self, cr, uid, obj, ctx=None: obj.kanban_state == 'blocked', |
1056 | 614 | 'project.mt_task_done': lambda self, cr, uid, obj, ctx=None: obj.kanban_state == 'done', | ||
1057 | 568 | }, | 615 | }, |
1058 | 569 | } | 616 | } |
1059 | 570 | 617 | ||
1060 | @@ -583,7 +630,7 @@ | |||
1061 | 583 | def _get_default_stage_id(self, cr, uid, context=None): | 630 | def _get_default_stage_id(self, cr, uid, context=None): |
1062 | 584 | """ Gives default stage_id """ | 631 | """ Gives default stage_id """ |
1063 | 585 | project_id = self._get_default_project_id(cr, uid, context=context) | 632 | project_id = self._get_default_project_id(cr, uid, context=context) |
1065 | 586 | return self.stage_find(cr, uid, [], project_id, [('fold', '=', False)], context=context) | 633 | return self.stage_find(cr, uid, [], project_id, [('sequence', '=', 1),('type', 'in',['task','both'])], context=context) |
1066 | 587 | 634 | ||
1067 | 588 | def _resolve_project_id_from_context(self, cr, uid, context=None): | 635 | def _resolve_project_id_from_context(self, cr, uid, context=None): |
1068 | 589 | """ Returns ID of project based on the value of 'default_project_id' | 636 | """ Returns ID of project based on the value of 'default_project_id' |
1069 | @@ -611,7 +658,9 @@ | |||
1070 | 611 | project_id = self._resolve_project_id_from_context(cr, uid, context=context) | 658 | project_id = self._resolve_project_id_from_context(cr, uid, context=context) |
1071 | 612 | if project_id: | 659 | if project_id: |
1072 | 613 | search_domain += ['|', ('project_ids', '=', project_id)] | 660 | search_domain += ['|', ('project_ids', '=', project_id)] |
1074 | 614 | search_domain += [('id', 'in', ids)] | 661 | search_domain += [('id', 'in', ids),('type', 'in', ['task', 'both'])] |
1075 | 662 | else: | ||
1076 | 663 | search_domain += [('id', 'in', ids)] | ||
1077 | 615 | stage_ids = stage_obj._search(cr, uid, search_domain, order=order, access_rights_uid=access_rights_uid, context=context) | 664 | stage_ids = stage_obj._search(cr, uid, search_domain, order=order, access_rights_uid=access_rights_uid, context=context) |
1078 | 616 | result = stage_obj.name_get(cr, access_rights_uid, stage_ids, context=context) | 665 | result = stage_obj.name_get(cr, access_rights_uid, stage_ids, context=context) |
1079 | 617 | # restore order of the search | 666 | # restore order of the search |
1080 | @@ -740,18 +789,18 @@ | |||
1081 | 740 | 'active': fields.function(_is_template, store=True, string='Not a Template Task', type='boolean', help="This field is computed automatically and have the same behavior than the boolean 'active' field: if the task is linked to a template or unactivated project, it will be hidden unless specifically asked."), | 789 | 'active': fields.function(_is_template, store=True, string='Not a Template Task', type='boolean', help="This field is computed automatically and have the same behavior than the boolean 'active' field: if the task is linked to a template or unactivated project, it will be hidden unless specifically asked."), |
1082 | 741 | 'name': fields.char('Task Summary', track_visibility='onchange', size=128, required=True, select=True), | 790 | 'name': fields.char('Task Summary', track_visibility='onchange', size=128, required=True, select=True), |
1083 | 742 | 'description': fields.text('Description'), | 791 | 'description': fields.text('Description'), |
1085 | 743 | 'priority': fields.selection([('4','Very Low'), ('3','Low'), ('2','Medium'), ('1','Important'), ('0','Very important')], 'Priority', select=True), | 792 | 'priority': fields.selection([('0','Low'), ('1','Normal'), ('2','High')], 'Priority', select=True), |
1086 | 744 | 'sequence': fields.integer('Sequence', select=True, help="Gives the sequence order when displaying a list of tasks."), | 793 | 'sequence': fields.integer('Sequence', select=True, help="Gives the sequence order when displaying a list of tasks."), |
1087 | 745 | 'stage_id': fields.many2one('project.task.type', 'Stage', track_visibility='onchange', select=True, | 794 | 'stage_id': fields.many2one('project.task.type', 'Stage', track_visibility='onchange', select=True, |
1089 | 746 | domain="[('project_ids', '=', project_id)]"), | 795 | domain="[('project_ids', '=', project_id), ('type', 'in', ['task','both'])]"), |
1090 | 747 | 'categ_ids': fields.many2many('project.category', string='Tags'), | 796 | 'categ_ids': fields.many2many('project.category', string='Tags'), |
1092 | 748 | 'kanban_state': fields.selection([('normal', 'Normal'),('blocked', 'Blocked'),('done', 'Ready for next stage')], 'Kanban State', | 797 | 'kanban_state': fields.selection([('normal', 'In Progress'),('blocked', 'Blocked'),('done', 'Ready')], 'Kanban State', |
1093 | 749 | track_visibility='onchange', | 798 | track_visibility='onchange', |
1094 | 750 | help="A task's kanban state indicates special situations affecting it:\n" | 799 | help="A task's kanban state indicates special situations affecting it:\n" |
1095 | 751 | " * Normal is the default situation\n" | 800 | " * Normal is the default situation\n" |
1096 | 752 | " * Blocked indicates something is preventing the progress of this task\n" | 801 | " * Blocked indicates something is preventing the progress of this task\n" |
1097 | 753 | " * Ready for next stage indicates the task is ready to be pulled to the next stage", | 802 | " * Ready for next stage indicates the task is ready to be pulled to the next stage", |
1099 | 754 | readonly=True, required=False), | 803 | required=False), |
1100 | 755 | 'create_date': fields.datetime('Create Date', readonly=True, select=True), | 804 | 'create_date': fields.datetime('Create Date', readonly=True, select=True), |
1101 | 756 | 'write_date': fields.datetime('Last Modification Date', readonly=True, select=True), #not displayed in the view but it might be useful with base_action_rule module (and it needs to be defined first for that) | 805 | 'write_date': fields.datetime('Last Modification Date', readonly=True, select=True), #not displayed in the view but it might be useful with base_action_rule module (and it needs to be defined first for that) |
1102 | 757 | 'date_start': fields.datetime('Starting Date',select=True), | 806 | 'date_start': fields.datetime('Starting Date',select=True), |
1103 | @@ -799,7 +848,7 @@ | |||
1104 | 799 | 'project_id': _get_default_project_id, | 848 | 'project_id': _get_default_project_id, |
1105 | 800 | 'date_last_stage_update': fields.datetime.now, | 849 | 'date_last_stage_update': fields.datetime.now, |
1106 | 801 | 'kanban_state': 'normal', | 850 | 'kanban_state': 'normal', |
1108 | 802 | 'priority': '2', | 851 | 'priority': '1', |
1109 | 803 | 'progress': 0, | 852 | 'progress': 0, |
1110 | 804 | 'sequence': 10, | 853 | 'sequence': 10, |
1111 | 805 | 'active': True, | 854 | 'active': True, |
1112 | @@ -808,17 +857,7 @@ | |||
1113 | 808 | 'partner_id': lambda self, cr, uid, ctx=None: self._get_default_partner(cr, uid, context=ctx), | 857 | 'partner_id': lambda self, cr, uid, ctx=None: self._get_default_partner(cr, uid, context=ctx), |
1114 | 809 | } | 858 | } |
1115 | 810 | _order = "priority, sequence, date_start, name, id" | 859 | _order = "priority, sequence, date_start, name, id" |
1127 | 811 | 860 | ||
1117 | 812 | def set_high_priority(self, cr, uid, ids, *args): | ||
1118 | 813 | """Set task priority to high | ||
1119 | 814 | """ | ||
1120 | 815 | return self.write(cr, uid, ids, {'priority' : '0'}) | ||
1121 | 816 | |||
1122 | 817 | def set_normal_priority(self, cr, uid, ids, *args): | ||
1123 | 818 | """Set task priority to normal | ||
1124 | 819 | """ | ||
1125 | 820 | return self.write(cr, uid, ids, {'priority' : '2'}) | ||
1126 | 821 | |||
1128 | 822 | def _check_recursion(self, cr, uid, ids, context=None): | 861 | def _check_recursion(self, cr, uid, ids, context=None): |
1129 | 823 | for id in ids: | 862 | for id in ids: |
1130 | 824 | visited_branch = set() | 863 | visited_branch = set() |
1131 | @@ -1003,16 +1042,6 @@ | |||
1132 | 1003 | def set_remaining_time_10(self, cr, uid, ids, context=None): | 1042 | def set_remaining_time_10(self, cr, uid, ids, context=None): |
1133 | 1004 | return self.set_remaining_time(cr, uid, ids, 10.0, context) | 1043 | return self.set_remaining_time(cr, uid, ids, 10.0, context) |
1134 | 1005 | 1044 | ||
1135 | 1006 | def set_kanban_state_blocked(self, cr, uid, ids, context=None): | ||
1136 | 1007 | return self.write(cr, uid, ids, {'kanban_state': 'blocked'}, context=context) | ||
1137 | 1008 | |||
1138 | 1009 | def set_kanban_state_normal(self, cr, uid, ids, context=None): | ||
1139 | 1010 | return self.write(cr, uid, ids, {'kanban_state': 'normal'}, context=context) | ||
1140 | 1011 | |||
1141 | 1012 | def set_kanban_state_done(self, cr, uid, ids, context=None): | ||
1142 | 1013 | self.write(cr, uid, ids, {'kanban_state': 'done'}, context=context) | ||
1143 | 1014 | return False | ||
1144 | 1015 | |||
1145 | 1016 | def _store_history(self, cr, uid, ids, context=None): | 1045 | def _store_history(self, cr, uid, ids, context=None): |
1146 | 1017 | for task in self.browse(cr, uid, ids, context=context): | 1046 | for task in self.browse(cr, uid, ids, context=context): |
1147 | 1018 | self.pool.get('project.task.history').create(cr, uid, { | 1047 | self.pool.get('project.task.history').create(cr, uid, { |
1148 | @@ -1193,7 +1222,11 @@ | |||
1149 | 1193 | _columns = { | 1222 | _columns = { |
1150 | 1194 | 'use_tasks': fields.boolean('Tasks',help="If checked, this contract will be available in the project menu and you will be able to manage tasks or track issues"), | 1223 | 'use_tasks': fields.boolean('Tasks',help="If checked, this contract will be available in the project menu and you will be able to manage tasks or track issues"), |
1151 | 1195 | 'company_uom_id': fields.related('company_id', 'project_time_mode_id', type='many2one', relation='product.uom'), | 1224 | 'company_uom_id': fields.related('company_id', 'project_time_mode_id', type='many2one', relation='product.uom'), |
1152 | 1225 | 'task_label': fields.char('Use Task as', size=128, help="Gives label to tasks on project's kanaban view.", required=True) | ||
1153 | 1196 | } | 1226 | } |
1154 | 1227 | _defaults = { | ||
1155 | 1228 | 'task_label': 'Tasks' | ||
1156 | 1229 | } | ||
1157 | 1197 | 1230 | ||
1158 | 1198 | def on_change_template(self, cr, uid, ids, template_id, date_start=False, context=None): | 1231 | def on_change_template(self, cr, uid, ids, template_id, date_start=False, context=None): |
1159 | 1199 | res = super(account_analytic_account, self).on_change_template(cr, uid, ids, template_id, date_start=date_start, context=context) | 1232 | res = super(account_analytic_account, self).on_change_template(cr, uid, ids, template_id, date_start=date_start, context=context) |
1160 | 1200 | 1233 | ||
1161 | === modified file 'project/project_data.xml' | |||
1162 | --- project/project_data.xml 2014-02-21 11:27:04 +0000 | |||
1163 | +++ project/project_data.xml 2014-05-07 10:11:23 +0000 | |||
1164 | @@ -31,32 +31,56 @@ | |||
1165 | 31 | <field name="sequence">1</field> | 31 | <field name="sequence">1</field> |
1166 | 32 | <field name="name">Analysis</field> | 32 | <field name="name">Analysis</field> |
1167 | 33 | <field name="case_default" eval="True"/> | 33 | <field name="case_default" eval="True"/> |
1168 | 34 | <field name="legend_blocked">There is a problem in analysis.</field> | ||
1169 | 35 | <field name="legend_done">Ready for the next stage.</field> | ||
1170 | 36 | <field name="legend_star1">High priority for the analysis.</field> | ||
1171 | 37 | <field name="legend_star2">Highest priority for the analysis.</field> | ||
1172 | 34 | </record> | 38 | </record> |
1173 | 35 | <record id="project_tt_specification" model="project.task.type"> | 39 | <record id="project_tt_specification" model="project.task.type"> |
1174 | 36 | <field name="sequence">10</field> | 40 | <field name="sequence">10</field> |
1175 | 37 | <field name="name">Specification</field> | 41 | <field name="name">Specification</field> |
1176 | 38 | <field name="case_default" eval="True"/> | 42 | <field name="case_default" eval="True"/> |
1177 | 43 | <field name="legend_blocked">Need more info about customer’s needs.</field> | ||
1178 | 44 | <field name="legend_done">Ready for the next stage.</field> | ||
1179 | 45 | <field name="legend_star1">High priority for the specification.</field> | ||
1180 | 46 | <field name="legend_star2">Highest priority for the specification.</field> | ||
1181 | 39 | </record> | 47 | </record> |
1182 | 40 | <record id="project_tt_design" model="project.task.type"> | 48 | <record id="project_tt_design" model="project.task.type"> |
1183 | 41 | <field name="sequence">11</field> | 49 | <field name="sequence">11</field> |
1184 | 42 | <field name="name">Design</field> | 50 | <field name="name">Design</field> |
1185 | 43 | <field name="case_default" eval="True"/> | 51 | <field name="case_default" eval="True"/> |
1186 | 52 | <field name="legend_blocked">Design is not valid.</field> | ||
1187 | 53 | <field name="legend_done">Ready for the next stage.</field> | ||
1188 | 54 | <field name="legend_star1">High priority for the design.</field> | ||
1189 | 55 | <field name="legend_star2">Highest priority for the design.</field> | ||
1190 | 44 | </record> | 56 | </record> |
1191 | 45 | <record id="project_tt_development" model="project.task.type"> | 57 | <record id="project_tt_development" model="project.task.type"> |
1192 | 46 | <field name="sequence">12</field> | 58 | <field name="sequence">12</field> |
1193 | 47 | <field name="name">Development</field> | 59 | <field name="name">Development</field> |
1194 | 48 | <field name="case_default" eval="True"/> | 60 | <field name="case_default" eval="True"/> |
1195 | 61 | <field name="legend_blocked">Need help from the specification team.</field> | ||
1196 | 62 | <field name="legend_done">Ready for the next stage.</field> | ||
1197 | 63 | <field name="legend_star1">High priority for the development.</field> | ||
1198 | 64 | <field name="legend_star2">Highest priority for the development.</field> | ||
1199 | 49 | </record> | 65 | </record> |
1200 | 50 | <record id="project_tt_testing" model="project.task.type"> | 66 | <record id="project_tt_testing" model="project.task.type"> |
1201 | 51 | <field name="sequence">13</field> | 67 | <field name="sequence">13</field> |
1202 | 52 | <field name="name">Testing</field> | 68 | <field name="name">Testing</field> |
1203 | 53 | <field name="case_default" eval="True"/> | 69 | <field name="case_default" eval="True"/> |
1204 | 70 | <field name="legend_blocked">Test is failed.</field> | ||
1205 | 71 | <field name="legend_done">Test result is achieved.</field> | ||
1206 | 72 | <field name="legend_star1">High priority for the testing.</field> | ||
1207 | 73 | <field name="legend_star2">Highest priority for the testing.</field> | ||
1208 | 54 | </record> | 74 | </record> |
1209 | 55 | <record id="project_tt_merge" model="project.task.type"> | 75 | <record id="project_tt_merge" model="project.task.type"> |
1210 | 56 | <field name="sequence">14</field> | 76 | <field name="sequence">14</field> |
1211 | 57 | <field name="name">Merge</field> | 77 | <field name="name">Merge</field> |
1212 | 58 | <field name="case_default" eval="False"/> | 78 | <field name="case_default" eval="False"/> |
1213 | 59 | <field name="fold" eval="True"/> | 79 | <field name="fold" eval="True"/> |
1214 | 80 | <field name="legend_blocked">TConflict in any file.</field> | ||
1215 | 81 | <field name="legend_done">Ready for the next stage.</field> | ||
1216 | 82 | <field name="legend_star1">High priority for the merging.</field> | ||
1217 | 83 | <field name="legend_star2">Highest priority for the merging.</field> | ||
1218 | 60 | </record> | 84 | </record> |
1219 | 61 | <record id="project_tt_deployment" model="project.task.type"> | 85 | <record id="project_tt_deployment" model="project.task.type"> |
1220 | 62 | <field name="sequence">20</field> | 86 | <field name="sequence">20</field> |
1221 | @@ -69,6 +93,9 @@ | |||
1222 | 69 | <field name="name">Cancelled</field> | 93 | <field name="name">Cancelled</field> |
1223 | 70 | <field name="case_default" eval="True"/> | 94 | <field name="case_default" eval="True"/> |
1224 | 71 | <field name="fold" eval="True"/> | 95 | <field name="fold" eval="True"/> |
1225 | 96 | <field name="legend_done">Ready to reopen.</field> | ||
1226 | 97 | <field name="legend_star1">High priority for the reopen.</field> | ||
1227 | 98 | <field name="legend_star2">Highest priority for the reopen.</field> | ||
1228 | 72 | </record> | 99 | </record> |
1229 | 73 | </data> | 100 | </data> |
1230 | 74 | 101 | ||
1231 | @@ -93,6 +120,12 @@ | |||
1232 | 93 | <field name="default" eval="False"/> | 120 | <field name="default" eval="False"/> |
1233 | 94 | <field name="description">Task blocked</field> | 121 | <field name="description">Task blocked</field> |
1234 | 95 | </record> | 122 | </record> |
1235 | 123 | <record id="mt_project_task_done" model="mail.message.subtype"> | ||
1236 | 124 | <field name="name">Task Done</field> | ||
1237 | 125 | <field name="res_model">project.task</field> | ||
1238 | 126 | <field name="default" eval="False"/> | ||
1239 | 127 | <field name="description">Task Done</field> | ||
1240 | 128 | </record> | ||
1241 | 96 | <record id="mt_task_stage" model="mail.message.subtype"> | 129 | <record id="mt_task_stage" model="mail.message.subtype"> |
1242 | 97 | <field name="name">Stage Changed</field> | 130 | <field name="name">Stage Changed</field> |
1243 | 98 | <field name="res_model">project.task</field> | 131 | <field name="res_model">project.task</field> |
1244 | 99 | 132 | ||
1245 | === modified file 'project/project_demo.xml' | |||
1246 | --- project/project_demo.xml 2013-11-27 15:32:57 +0000 | |||
1247 | +++ project/project_demo.xml 2014-05-07 10:11:23 +0000 | |||
1248 | @@ -67,6 +67,7 @@ | |||
1249 | 67 | <field name="alias_model">project.task</field> | 67 | <field name="alias_model">project.task</field> |
1250 | 68 | <field name="privacy_visibility">employees</field> | 68 | <field name="privacy_visibility">employees</field> |
1251 | 69 | <field name="members" eval="[(4, ref('base.user_root')), (4, ref('base.user_demo'))]"/> | 69 | <field name="members" eval="[(4, ref('base.user_root')), (4, ref('base.user_demo'))]"/> |
1252 | 70 | <field name="task_label">Trainings</field> | ||
1253 | 70 | </record> | 71 | </record> |
1254 | 71 | 72 | ||
1255 | 72 | <record id="project_project_3" model="project.project"> | 73 | <record id="project_project_3" model="project.project"> |
1256 | @@ -82,6 +83,7 @@ | |||
1257 | 82 | <field name="alias_model">project.task</field> | 83 | <field name="alias_model">project.task</field> |
1258 | 83 | <field name="privacy_visibility">employees</field> | 84 | <field name="privacy_visibility">employees</field> |
1259 | 84 | <field name="members" eval="[(4, ref('base.user_root')), (4,ref('base.user_demo'))]"/> | 85 | <field name="members" eval="[(4, ref('base.user_root')), (4,ref('base.user_demo'))]"/> |
1260 | 86 | <field name="task_label">Designs</field> | ||
1261 | 85 | </record> | 87 | </record> |
1262 | 86 | 88 | ||
1263 | 87 | <record id="project_project_4" model="project.project"> | 89 | <record id="project_project_4" model="project.project"> |
1264 | @@ -98,6 +100,7 @@ | |||
1265 | 98 | <field name="members" eval="[(6, 0, [ | 100 | <field name="members" eval="[(6, 0, [ |
1266 | 99 | ref('base.user_root'), | 101 | ref('base.user_root'), |
1267 | 100 | ref('base.user_demo')])]"/> | 102 | ref('base.user_demo')])]"/> |
1268 | 103 | <field name="task_label">Databases</field> | ||
1269 | 101 | </record> | 104 | </record> |
1270 | 102 | 105 | ||
1271 | 103 | <record id="project_project_5" model="project.project"> | 106 | <record id="project_project_5" model="project.project"> |
1272 | @@ -110,7 +113,7 @@ | |||
1273 | 110 | <field name="planned_hours" eval="40.0"/> | 113 | <field name="planned_hours" eval="40.0"/> |
1274 | 111 | <field name="remaining_hours" eval="40.0"/> | 114 | <field name="remaining_hours" eval="40.0"/> |
1275 | 112 | <field name="user_id" ref="base.user_demo"/> | 115 | <field name="user_id" ref="base.user_demo"/> |
1277 | 113 | <field name="priority">4</field> | 116 | <field name="priority">0</field> |
1278 | 114 | <field name="project_id" ref="project.project_project_1"/> | 117 | <field name="project_id" ref="project.project_project_1"/> |
1279 | 115 | <field name="name">Prepare Requirements Document</field> | 118 | <field name="name">Prepare Requirements Document</field> |
1280 | 116 | <field name="stage_id" ref="project_tt_analysis"/> | 119 | <field name="stage_id" ref="project_tt_analysis"/> |
1281 | @@ -120,7 +123,7 @@ | |||
1282 | 120 | <field name="planned_hours" eval="32.0"/> | 123 | <field name="planned_hours" eval="32.0"/> |
1283 | 121 | <field name="remaining_hours" eval="32.0"/> | 124 | <field name="remaining_hours" eval="32.0"/> |
1284 | 122 | <field name="user_id" ref="base.user_demo"/> | 125 | <field name="user_id" ref="base.user_demo"/> |
1286 | 123 | <field name="priority">4</field> | 126 | <field name="priority">0</field> |
1287 | 124 | <field name="project_id" ref="project.project_project_1"/> | 127 | <field name="project_id" ref="project.project_project_1"/> |
1288 | 125 | <field name="name">Make SRS</field> | 128 | <field name="name">Make SRS</field> |
1289 | 126 | <field name="stage_id" ref="project_tt_specification"/> | 129 | <field name="stage_id" ref="project_tt_specification"/> |
1290 | @@ -129,7 +132,7 @@ | |||
1291 | 129 | <field name="planned_hours" eval="10.0"/> | 132 | <field name="planned_hours" eval="10.0"/> |
1292 | 130 | <field name="remaining_hours" eval="10.0"/> | 133 | <field name="remaining_hours" eval="10.0"/> |
1293 | 131 | <field name="user_id" ref="base.user_root"/> | 134 | <field name="user_id" ref="base.user_root"/> |
1295 | 132 | <field name="priority">4</field> | 135 | <field name="priority">0</field> |
1296 | 133 | <field name="project_id" ref="project.project_project_1"/> | 136 | <field name="project_id" ref="project.project_project_1"/> |
1297 | 134 | <field name="name">Budget Planning</field> | 137 | <field name="name">Budget Planning</field> |
1298 | 135 | <field name="date_deadline" eval="time.strftime('%Y-%m-24')"/> | 138 | <field name="date_deadline" eval="time.strftime('%Y-%m-24')"/> |
1299 | @@ -140,7 +143,7 @@ | |||
1300 | 140 | <field name="planned_hours" eval="60.0"/> | 143 | <field name="planned_hours" eval="60.0"/> |
1301 | 141 | <field name="remaining_hours" eval="60.0"/> | 144 | <field name="remaining_hours" eval="60.0"/> |
1302 | 142 | <field name="user_id" ref="base.user_demo"/> | 145 | <field name="user_id" ref="base.user_demo"/> |
1304 | 143 | <field name="priority">4</field> | 146 | <field name="priority">0</field> |
1305 | 144 | <field name="project_id" ref="project.project_project_1"/> | 147 | <field name="project_id" ref="project.project_project_1"/> |
1306 | 145 | <field name="name">Develop module for Sale Management</field> | 148 | <field name="name">Develop module for Sale Management</field> |
1307 | 146 | <field name="description">Use the account_budget module</field> | 149 | <field name="description">Use the account_budget module</field> |
1308 | 147 | 150 | ||
1309 | === modified file 'project/project_view.xml' | |||
1310 | --- project/project_view.xml 2014-04-15 12:14:04 +0000 | |||
1311 | +++ project/project_view.xml 2014-05-07 10:11:23 +0000 | |||
1312 | @@ -87,14 +87,14 @@ | |||
1313 | 87 | <h1> | 87 | <h1> |
1314 | 88 | <field name="name" string="Project Name"/> | 88 | <field name="name" string="Project Name"/> |
1315 | 89 | </h1> | 89 | </h1> |
1319 | 90 | <div name="options_active"> | 90 | <div name="options_active" class="oe_inline oe_left"> |
1320 | 91 | <field name="use_tasks" class="oe_inline"/> | 91 | <field name="use_tasks" class="oe_from_boolean_align"/> |
1321 | 92 | <label for="use_tasks"/> | 92 | <label for="task_label" class="oe_edit_only"/> |
1322 | 93 | <b><field name="task_label" class="oe_inline"/></b> | ||
1323 | 93 | </div> | 94 | </div> |
1324 | 94 | </div> | 95 | </div> |
1325 | 95 | <div class="oe_right oe_button_box" name="buttons" groups="base.group_user"> | 96 | <div class="oe_right oe_button_box" name="buttons" groups="base.group_user"> |
1328 | 96 | <button class="oe_inline oe_stat_button" type="action" attrs="{'invisible':[('use_tasks','=', 0)]}" | 97 | <button class="oe_inline oe_stat_button" type="object" attrs="{'invisible':[('use_tasks','=', 0)]}" name="project_tasks_action" icon="fa-tasks"> |
1327 | 97 | name="%(act_project_project_2_project_task_all)d" icon="fa-tasks"> | ||
1329 | 98 | <field string="Tasks" name="task_count" widget="statinfo"/> | 98 | <field string="Tasks" name="task_count" widget="statinfo"/> |
1330 | 99 | </button> | 99 | </button> |
1331 | 100 | <button class="oe_inline oe_stat_button" name="attachment_tree_view" type="object" icon="fa-files-o"> | 100 | <button class="oe_inline oe_stat_button" name="attachment_tree_view" type="object" icon="fa-files-o"> |
1332 | @@ -125,9 +125,8 @@ | |||
1333 | 125 | </div> | 125 | </div> |
1334 | 126 | <label for="alias_model" string="Incoming Emails create"/> | 126 | <label for="alias_model" string="Incoming Emails create"/> |
1335 | 127 | <field name="alias_model" class="oe_inline" nolabel="1"/> | 127 | <field name="alias_model" class="oe_inline" nolabel="1"/> |
1339 | 128 | <field name="alias_contact" class="oe_inline" | 128 | <field name="alias_contact" class="oe_inline" string="Accept Emails From"/> |
1340 | 129 | string="Accept Emails From"/> | 129 | </group> |
1338 | 130 | </group> | ||
1341 | 131 | </group> | 130 | </group> |
1342 | 132 | <notebook> | 131 | <notebook> |
1343 | 133 | <page string="Team" name="team"> | 132 | <page string="Team" name="team"> |
1344 | @@ -170,7 +169,13 @@ | |||
1345 | 170 | </group> | 169 | </group> |
1346 | 171 | </page> | 170 | </page> |
1347 | 172 | <page string="Project Stages" attrs="{'invisible': [('use_tasks', '=', False)]}" name="project_stages"> | 171 | <page string="Project Stages" attrs="{'invisible': [('use_tasks', '=', False)]}" name="project_stages"> |
1349 | 173 | <field name="type_ids"/> | 172 | <field name="type_ids"> |
1350 | 173 | <tree> | ||
1351 | 174 | <field name="sequence" widget="handle"/> | ||
1352 | 175 | <field name="name"/> | ||
1353 | 176 | <field name="kanban_column_tooltip" widget="tooltiphtml"/> | ||
1354 | 177 | </tree> | ||
1355 | 178 | </field> | ||
1356 | 174 | </page> | 179 | </page> |
1357 | 175 | </notebook> | 180 | </notebook> |
1358 | 176 | </sheet> | 181 | </sheet> |
1359 | @@ -264,9 +269,9 @@ | |||
1360 | 264 | <span class="oe_e oe_e_alias">%%</span><small><field name="alias_id"/></small> | 269 | <span class="oe_e oe_e_alias">%%</span><small><field name="alias_id"/></small> |
1361 | 265 | </div> | 270 | </div> |
1362 | 266 | <div class="oe_kanban_project_list"> | 271 | <div class="oe_kanban_project_list"> |
1366 | 267 | <a t-if="record.use_tasks.raw_value" name="%(act_project_project_2_project_task_all)d" type="action" style="margin-right: 10px"> | 272 | <a t-if="record.use_tasks.raw_value" name="project_tasks_action" type="object" style="margin-right: 10px"> |
1367 | 268 | <t t-raw="record.task_ids.raw_value.length"/> Tasks | 273 | <span><field name="task_count"/> <field name="task_label"/></span> |
1368 | 269 | </a> | 274 | </a> |
1369 | 270 | </div> | 275 | </div> |
1370 | 271 | <div class="oe_kanban_project_list"> | 276 | <div class="oe_kanban_project_list"> |
1371 | 272 | <a t-if="record.doc_count.raw_value" name="attachment_tree_view" type="object" style="margin-right: 10px"> <field name="doc_count"/> Documents</a> | 277 | <a t-if="record.doc_count.raw_value" name="attachment_tree_view" type="object" style="margin-right: 10px"> <field name="doc_count"/> Documents</a> |
1372 | @@ -379,11 +384,10 @@ | |||
1373 | 379 | <sheet string="Task"> | 384 | <sheet string="Task"> |
1374 | 380 | <h1> | 385 | <h1> |
1375 | 381 | <field name="name" placeholder="Task summary..." class="oe_inline"/> | 386 | <field name="name" placeholder="Task summary..." class="oe_inline"/> |
1376 | 382 | <field name="kanban_state" invisible='1'/> | ||
1377 | 383 | <button name="set_kanban_state_done" help="In Progress" attrs="{'invisible': [('kanban_state', 'in', ['done','blocked'])]}" type="object" icon="gtk-normal" class="oe_link oe_right"/> | ||
1378 | 384 | <button name="set_kanban_state_blocked" help="Ready for Next Stage" attrs="{'invisible': [('kanban_state', 'in', ['normal','blocked'])]}" type="object" icon="gtk-yes" class="oe_link oe_right"/> | ||
1379 | 385 | <button name="set_kanban_state_normal" help="Blocked" attrs="{'invisible': [('kanban_state', 'in', ['done','normal'])]}" type="object" icon="gtk-no" class="oe_link oe_right"/> | ||
1380 | 386 | </h1> | 387 | </h1> |
1381 | 388 | <div class="oe_right"> | ||
1382 | 389 | <field name="kanban_state" class="oe_inline" widget="dropdown_selection"/> | ||
1383 | 390 | </div> | ||
1384 | 387 | <group> | 391 | <group> |
1385 | 388 | <group> | 392 | <group> |
1386 | 389 | <field name="project_id" domain="[('state', '!=', 'close')]" on_change="onchange_project(project_id)" context="{'default_use_tasks':1}"/> | 393 | <field name="project_id" domain="[('state', '!=', 'close')]" on_change="onchange_project(project_id)" context="{'default_use_tasks':1}"/> |
1387 | @@ -444,7 +448,7 @@ | |||
1388 | 444 | </page> | 448 | </page> |
1389 | 445 | <page string="Extra Info"> | 449 | <page string="Extra Info"> |
1390 | 446 | <group col="4"> | 450 | <group col="4"> |
1392 | 447 | <field name="priority" groups="base.group_user"/> | 451 | <field name="priority" groups="base.group_user" widget="priority"/> |
1393 | 448 | <field name="sequence"/> | 452 | <field name="sequence"/> |
1394 | 449 | <field name="partner_id"/> | 453 | <field name="partner_id"/> |
1395 | 450 | <field name="company_id" groups="base.group_multi_company" widget="selection"/> | 454 | <field name="company_id" groups="base.group_multi_company" widget="selection"/> |
1396 | @@ -477,7 +481,7 @@ | |||
1397 | 477 | <kanban default_group_by="stage_id" > | 481 | <kanban default_group_by="stage_id" > |
1398 | 478 | <field name="color"/> | 482 | <field name="color"/> |
1399 | 479 | <field name="priority"/> | 483 | <field name="priority"/> |
1401 | 480 | <field name="stage_id"/> | 484 | <field name="stage_id" options='{"tooltip_on_group_by": "kanban_column_tooltip"}'/> |
1402 | 481 | <field name="user_id"/> | 485 | <field name="user_id"/> |
1403 | 482 | <field name="user_email"/> | 486 | <field name="user_email"/> |
1404 | 483 | <field name="description"/> | 487 | <field name="description"/> |
1405 | @@ -515,16 +519,6 @@ | |||
1406 | 515 | <t t-if="record.date_deadline.raw_value and record.date_deadline.raw_value lt (new Date())" t-set="red">oe_kanban_text_red</t> | 519 | <t t-if="record.date_deadline.raw_value and record.date_deadline.raw_value lt (new Date())" t-set="red">oe_kanban_text_red</t> |
1407 | 516 | <span t-attf-class="#{red || ''}"><i><field name="date_deadline"/></i></span> | 520 | <span t-attf-class="#{red || ''}"><i><field name="date_deadline"/></i></span> |
1408 | 517 | </div> | 521 | </div> |
1409 | 518 | <div class="oe_kanban_bottom_right"> | ||
1410 | 519 | <t groups="base.group_user"> | ||
1411 | 520 | <a t-if="record.kanban_state.raw_value === 'normal'" type="object" string="In Progress" name="set_kanban_state_done" class="oe_kanban_status"> </a> | ||
1412 | 521 | <a t-if="record.kanban_state.raw_value === 'done'" type="object" string="Ready for next stage" name="set_kanban_state_blocked" class="oe_kanban_status oe_kanban_status_green"> </a> | ||
1413 | 522 | <a t-if="record.kanban_state.raw_value === 'blocked'" type="object" string="Blocked" name="set_kanban_state_normal" class="oe_kanban_status oe_kanban_status_red"> </a> | ||
1414 | 523 | <a t-if="record.priority.raw_value > 0" type="object" string="Normal" name="set_high_priority" class="oe_e oe_star_off">7</a> | ||
1415 | 524 | <a t-if="record.priority.raw_value == 0" type="object" string="Very Important" name="set_normal_priority" class="oe_e oe_star_on">7</a> | ||
1416 | 525 | </t> | ||
1417 | 526 | <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar"/> | ||
1418 | 527 | </div> | ||
1419 | 528 | <div class="oe_kanban_footer_left"> | 522 | <div class="oe_kanban_footer_left"> |
1420 | 529 | <span groups="project.group_time_work_estimation_tasks" title="Remaining hours"> | 523 | <span groups="project.group_time_work_estimation_tasks" title="Remaining hours"> |
1421 | 530 | <span class="oe_e">N</span> | 524 | <span class="oe_e">N</span> |
1422 | @@ -535,6 +529,21 @@ | |||
1423 | 535 | <t t-raw="record.message_summary.raw_value"/> | 529 | <t t-raw="record.message_summary.raw_value"/> |
1424 | 536 | <field name="categ_ids"/> | 530 | <field name="categ_ids"/> |
1425 | 537 | </div> | 531 | </div> |
1426 | 532 | <div class="oe_kanban_bottom_right"> | ||
1427 | 533 | <table> | ||
1428 | 534 | <tr> | ||
1429 | 535 | <td groups="base.group_user"> | ||
1430 | 536 | <field name="kanban_state" widget="dropdown_selection"/> | ||
1431 | 537 | </td> | ||
1432 | 538 | <td groups="base.group_user"> | ||
1433 | 539 | <field name="priority" widget="priority"/> | ||
1434 | 540 | </td> | ||
1435 | 541 | <td> | ||
1436 | 542 | <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar"/> | ||
1437 | 543 | </td> | ||
1438 | 544 | </tr> | ||
1439 | 545 | </table> | ||
1440 | 546 | </div> | ||
1441 | 538 | </div> | 547 | </div> |
1442 | 539 | <div class="oe_clear"></div> | 548 | <div class="oe_clear"></div> |
1443 | 540 | </div> | 549 | </div> |
1444 | @@ -609,8 +618,11 @@ | |||
1445 | 609 | <field eval="18" name="priority"/> | 618 | <field eval="18" name="priority"/> |
1446 | 610 | <field name="arch" type="xml"> | 619 | <field name="arch" type="xml"> |
1447 | 611 | <xpath expr='//div[@name="project"]' position='inside'> | 620 | <xpath expr='//div[@name="project"]' position='inside'> |
1450 | 612 | <field name="use_tasks"/> | 621 | <div name="options_active" class="oe_inline oe_left"> |
1451 | 613 | <label for="use_tasks"/> | 622 | <field name="use_tasks" class="oe_from_boolean_align"/> |
1452 | 623 | <label for="task_label" class="oe_edit_only"/> | ||
1453 | 624 | <b><field name="task_label" class="oe_inline"/></b> | ||
1454 | 625 | </div> | ||
1455 | 614 | </xpath> | 626 | </xpath> |
1456 | 615 | </field> | 627 | </field> |
1457 | 616 | </record> | 628 | </record> |
1458 | @@ -688,6 +700,7 @@ | |||
1459 | 688 | <group> | 700 | <group> |
1460 | 689 | <group> | 701 | <group> |
1461 | 690 | <field name="name"/> | 702 | <field name="name"/> |
1462 | 703 | <field name="type" invisible="1"/> | ||
1463 | 691 | <field name="sequence"/> | 704 | <field name="sequence"/> |
1464 | 692 | </group> | 705 | </group> |
1465 | 693 | <group> | 706 | <group> |
1466 | @@ -695,6 +708,53 @@ | |||
1467 | 695 | <field name="fold"/> | 708 | <field name="fold"/> |
1468 | 696 | </group> | 709 | </group> |
1469 | 697 | </group> | 710 | </group> |
1470 | 711 | <separator string="Legends"/> | ||
1471 | 712 | <p>The legend will appear as tooltip of each column of the tasks/issues pipe.</p> | ||
1472 | 713 | <div> | ||
1473 | 714 | <group col="3"> | ||
1474 | 715 | <div width="35"> | ||
1475 | 716 | <span class='status error' title="This tooltip will appear on kanban view column header."/> | ||
1476 | 717 | </div> | ||
1477 | 718 | <div width="400"> | ||
1478 | 719 | <field name="legend_blocked" title="This tooltip will appear on kanban view column header."/> | ||
1479 | 720 | </div> | ||
1480 | 721 | <div></div> | ||
1481 | 722 | </group> | ||
1482 | 723 | </div> | ||
1483 | 724 | <div> | ||
1484 | 725 | <group col="3"> | ||
1485 | 726 | <div width="35"> | ||
1486 | 727 | <span class='status ok'/> | ||
1487 | 728 | </div> | ||
1488 | 729 | <div width="400"> | ||
1489 | 730 | <field name="legend_done"/> | ||
1490 | 731 | </div> | ||
1491 | 732 | <div></div> | ||
1492 | 733 | </group> | ||
1493 | 734 | </div> | ||
1494 | 735 | <div> | ||
1495 | 736 | <group col="3"> | ||
1496 | 737 | <div width="35"> | ||
1497 | 738 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">7</span> | ||
1498 | 739 | </div> | ||
1499 | 740 | <div width="400"> | ||
1500 | 741 | <field name="legend_star1"/> | ||
1501 | 742 | </div> | ||
1502 | 743 | <div></div> | ||
1503 | 744 | </group> | ||
1504 | 745 | </div> | ||
1505 | 746 | <div attrs="{'invisible':[('type','=', 'task')]}"> | ||
1506 | 747 | <group col="3"> | ||
1507 | 748 | <div width="35"> | ||
1508 | 749 | <span class="oe_e oe_star_on" title="This tooltip will appear on kanban view column header.">77</span> | ||
1509 | 750 | </div> | ||
1510 | 751 | <div width="400"> | ||
1511 | 752 | <field name="legend_star2"/> | ||
1512 | 753 | </div> | ||
1513 | 754 | <div></div> | ||
1514 | 755 | </group> | ||
1515 | 756 | </div> | ||
1516 | 757 | <separator string="Description"/> | ||
1517 | 698 | <field name="description" placeholder="Add a description..."/> | 758 | <field name="description" placeholder="Add a description..."/> |
1518 | 699 | </form> | 759 | </form> |
1519 | 700 | </field> | 760 | </field> |
1520 | @@ -733,7 +793,7 @@ | |||
1521 | 733 | 793 | ||
1522 | 734 | <menuitem id="base.menu_project_config_project" name="Stages" parent="base.menu_definitions" sequence="1" groups="base.group_no_one"/> | 794 | <menuitem id="base.menu_project_config_project" name="Stages" parent="base.menu_definitions" sequence="1" groups="base.group_no_one"/> |
1523 | 735 | 795 | ||
1525 | 736 | <menuitem action="open_task_type_form" name="Task Stages" id="menu_task_types_view" parent="base.menu_project_config_project" sequence="2"/> | 796 | <menuitem action="open_task_type_form" name="Project Stages" id="menu_task_types_view" parent="base.menu_project_config_project" sequence="2"/> |
1526 | 737 | <menuitem action="open_view_project_all" id="menu_projects" name="Projects" parent="menu_project_management" sequence="1"/> | 797 | <menuitem action="open_view_project_all" id="menu_projects" name="Projects" parent="menu_project_management" sequence="1"/> |
1527 | 738 | 798 | ||
1528 | 739 | 799 | ||
1529 | 740 | 800 | ||
1530 | === modified file 'project/report/project_report.py' | |||
1531 | --- project/report/project_report.py 2014-01-29 15:24:40 +0000 | |||
1532 | +++ project/report/project_report.py 2014-05-07 10:11:23 +0000 | |||
1533 | @@ -48,7 +48,7 @@ | |||
1534 | 48 | help="Number of Days to Open the task"), | 48 | help="Number of Days to Open the task"), |
1535 | 49 | 'delay_endings_days': fields.float('Overpassed Deadline', digits=(16,2), readonly=True), | 49 | 'delay_endings_days': fields.float('Overpassed Deadline', digits=(16,2), readonly=True), |
1536 | 50 | 'nbr': fields.integer('# of tasks', readonly=True), | 50 | 'nbr': fields.integer('# of tasks', readonly=True), |
1538 | 51 | 'priority': fields.selection([('4', 'Very Low'), ('3', 'Low'), ('2', 'Medium'), ('1', 'Urgent'), ('0', 'Very urgent')], | 51 | 'priority': fields.selection([('0','Low'), ('1','Normal'), ('2','High')], |
1539 | 52 | string='Priority', readonly=True), | 52 | string='Priority', readonly=True), |
1540 | 53 | 'state': fields.selection([('draft', 'Draft'), ('open', 'In Progress'), ('pending', 'Pending'), ('cancelled', 'Cancelled'), ('done', 'Done')],'Status', readonly=True), | 53 | 'state': fields.selection([('draft', 'Draft'), ('open', 'In Progress'), ('pending', 'Pending'), ('cancelled', 'Cancelled'), ('done', 'Done')],'Status', readonly=True), |
1541 | 54 | 'company_id': fields.many2one('res.company', 'Company', readonly=True), | 54 | 'company_id': fields.many2one('res.company', 'Company', readonly=True), |
1542 | 55 | 55 | ||
1543 | === modified file 'project/static/src/css/project.css' | |||
1544 | --- project/static/src/css/project.css 2013-10-27 12:31:04 +0000 | |||
1545 | +++ project/static/src/css/project.css 2014-05-07 10:11:23 +0000 | |||
1546 | @@ -62,4 +62,8 @@ | |||
1547 | 62 | -box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); | 62 | -box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); |
1548 | 63 | } | 63 | } |
1549 | 64 | 64 | ||
1550 | 65 | .openerp .oe_form .oe_from_boolean_align{ | ||
1551 | 66 | vertical-align: middle; | ||
1552 | 67 | margin-top: 2px; | ||
1553 | 68 | } | ||
1554 | 65 | 69 | ||
1555 | 66 | 70 | ||
1556 | === modified file 'project/static/src/js/project.js' | |||
1557 | --- project/static/src/js/project.js 2014-04-17 09:05:15 +0000 | |||
1558 | +++ project/static/src/js/project.js 2014-05-07 10:11:23 +0000 | |||
1559 | @@ -42,4 +42,14 @@ | |||
1560 | 42 | } | 42 | } |
1561 | 43 | }, | 43 | }, |
1562 | 44 | }); | 44 | }); |
1563 | 45 | |||
1564 | 46 | openerp.web.list.TooltipHtml = openerp.web.list.Column.extend({ | ||
1565 | 47 | format: function (row_data, options) { | ||
1566 | 48 | if (row_data.kanban_column_tooltip !== undefined){ | ||
1567 | 49 | return row_data.kanban_column_tooltip.value.tooltip | ||
1568 | 50 | } | ||
1569 | 51 | } | ||
1570 | 52 | }); | ||
1571 | 53 | |||
1572 | 54 | openerp.web.list.columns.add('field.tooltiphtml', 'openerp.web.list.TooltipHtml'); | ||
1573 | 45 | }; | 55 | }; |
1574 | 46 | 56 | ||
1575 | === modified file 'project_issue/project_issue.py' | |||
1576 | --- project_issue/project_issue.py 2014-04-10 14:51:31 +0000 | |||
1577 | +++ project_issue/project_issue.py 2014-05-07 10:11:23 +0000 | |||
1578 | @@ -57,6 +57,7 @@ | |||
1579 | 57 | }, | 57 | }, |
1580 | 58 | 'kanban_state': { | 58 | 'kanban_state': { |
1581 | 59 | 'project_issue.mt_issue_blocked': lambda self, cr, uid, obj, ctx=None: obj.kanban_state == 'blocked', | 59 | 'project_issue.mt_issue_blocked': lambda self, cr, uid, obj, ctx=None: obj.kanban_state == 'blocked', |
1582 | 60 | 'project_issue.mt_issue_done': lambda self, cr, uid, obj, ctx=None: obj.kanban_state == 'done', | ||
1583 | 60 | }, | 61 | }, |
1584 | 61 | } | 62 | } |
1585 | 62 | 63 | ||
1586 | @@ -75,7 +76,7 @@ | |||
1587 | 75 | def _get_default_stage_id(self, cr, uid, context=None): | 76 | def _get_default_stage_id(self, cr, uid, context=None): |
1588 | 76 | """ Gives default stage_id """ | 77 | """ Gives default stage_id """ |
1589 | 77 | project_id = self._get_default_project_id(cr, uid, context=context) | 78 | project_id = self._get_default_project_id(cr, uid, context=context) |
1591 | 78 | return self.stage_find(cr, uid, [], project_id, [('fold', '=', False)], context=context) | 79 | return self.stage_find(cr, uid, [], project_id, [('sequence','=',1),('type','in',['issue','both'])], context=context) |
1592 | 79 | 80 | ||
1593 | 80 | def _resolve_project_id_from_context(self, cr, uid, context=None): | 81 | def _resolve_project_id_from_context(self, cr, uid, context=None): |
1594 | 81 | """ Returns ID of project based on the value of 'default_project_id' | 82 | """ Returns ID of project based on the value of 'default_project_id' |
1595 | @@ -108,7 +109,9 @@ | |||
1596 | 108 | project_id = self._resolve_project_id_from_context(cr, uid, context=context) | 109 | project_id = self._resolve_project_id_from_context(cr, uid, context=context) |
1597 | 109 | if project_id: | 110 | if project_id: |
1598 | 110 | search_domain += ['|', ('project_ids', '=', project_id)] | 111 | search_domain += ['|', ('project_ids', '=', project_id)] |
1600 | 111 | search_domain += [('id', 'in', ids)] | 112 | search_domain += [('id', 'in', ids),('type', 'in', ['issue','both'])] |
1601 | 113 | else: | ||
1602 | 114 | search_domain += [('id', 'in', ids)] | ||
1603 | 112 | # perform search | 115 | # perform search |
1604 | 113 | stage_ids = stage_obj._search(cr, uid, search_domain, order=order, access_rights_uid=access_rights_uid, context=context) | 116 | stage_ids = stage_obj._search(cr, uid, search_domain, order=order, access_rights_uid=access_rights_uid, context=context) |
1605 | 114 | result = stage_obj.name_get(cr, access_rights_uid, stage_ids, context=context) | 117 | result = stage_obj.name_get(cr, access_rights_uid, stage_ids, context=context) |
1606 | @@ -250,7 +253,7 @@ | |||
1607 | 250 | " * Normal is the default situation\n" | 253 | " * Normal is the default situation\n" |
1608 | 251 | " * Blocked indicates something is preventing the progress of this issue\n" | 254 | " * Blocked indicates something is preventing the progress of this issue\n" |
1609 | 252 | " * Ready for next stage indicates the issue is ready to be pulled to the next stage", | 255 | " * Ready for next stage indicates the issue is ready to be pulled to the next stage", |
1611 | 253 | readonly=True, required=False), | 256 | required=False), |
1612 | 254 | 'email_from': fields.char('Email', size=128, help="These people will receive email.", select=1), | 257 | 'email_from': fields.char('Email', size=128, help="These people will receive email.", select=1), |
1613 | 255 | 'email_cc': fields.char('Watchers Emails', size=256, help="These email addresses will be added to the CC field of all inbound and outbound emails for this record before being sent. Separate multiple email addresses with a comma"), | 258 | 'email_cc': fields.char('Watchers Emails', size=256, help="These email addresses will be added to the CC field of all inbound and outbound emails for this record before being sent. Separate multiple email addresses with a comma"), |
1614 | 256 | 'date_open': fields.datetime('Opened', readonly=True,select=True), | 259 | 'date_open': fields.datetime('Opened', readonly=True,select=True), |
1615 | @@ -260,11 +263,11 @@ | |||
1616 | 260 | 'date_last_stage_update': fields.datetime('Last Stage Update', select=True), | 263 | 'date_last_stage_update': fields.datetime('Last Stage Update', select=True), |
1617 | 261 | 'channel_id': fields.many2one('crm.case.channel', 'Channel', help="Communication channel."), | 264 | 'channel_id': fields.many2one('crm.case.channel', 'Channel', help="Communication channel."), |
1618 | 262 | 'categ_ids': fields.many2many('project.category', string='Tags'), | 265 | 'categ_ids': fields.many2many('project.category', string='Tags'), |
1620 | 263 | 'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority', select=True), | 266 | 'priority': fields.selection([('0','Low'), ('1','Normal'), ('2','High')], 'Priority', select=True), |
1621 | 264 | 'version_id': fields.many2one('project.issue.version', 'Version'), | 267 | 'version_id': fields.many2one('project.issue.version', 'Version'), |
1622 | 265 | 'stage_id': fields.many2one ('project.task.type', 'Stage', | 268 | 'stage_id': fields.many2one ('project.task.type', 'Stage', |
1623 | 266 | track_visibility='onchange', select=True, | 269 | track_visibility='onchange', select=True, |
1625 | 267 | domain="[('project_ids', '=', project_id)]"), | 270 | domain="[('project_ids', '=', project_id),('type','in',['issue','both'])]"), |
1626 | 268 | 'project_id': fields.many2one('project.project', 'Project', track_visibility='onchange', select=True), | 271 | 'project_id': fields.many2one('project.project', 'Project', track_visibility='onchange', select=True), |
1627 | 269 | 'duration': fields.float('Duration'), | 272 | 'duration': fields.float('Duration'), |
1628 | 270 | 'task_id': fields.many2one('project.task', 'Task', domain="[('project_id','=',project_id)]"), | 273 | 'task_id': fields.many2one('project.task', 'Task', domain="[('project_id','=',project_id)]"), |
1629 | @@ -295,7 +298,7 @@ | |||
1630 | 295 | 'active': 1, | 298 | 'active': 1, |
1631 | 296 | 'stage_id': lambda s, cr, uid, c: s._get_default_stage_id(cr, uid, c), | 299 | 'stage_id': lambda s, cr, uid, c: s._get_default_stage_id(cr, uid, c), |
1632 | 297 | 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.helpdesk', context=c), | 300 | 'company_id': lambda s, cr, uid, c: s.pool.get('res.company')._company_default_get(cr, uid, 'crm.helpdesk', context=c), |
1634 | 298 | 'priority': crm.AVAILABLE_PRIORITIES[2][0], | 301 | 'priority': '1', |
1635 | 299 | 'kanban_state': 'normal', | 302 | 'kanban_state': 'normal', |
1636 | 300 | 'date_last_stage_update': fields.datetime.now, | 303 | 'date_last_stage_update': fields.datetime.now, |
1637 | 301 | 'user_id': lambda obj, cr, uid, context: uid, | 304 | 'user_id': lambda obj, cr, uid, context: uid, |
1638 | @@ -306,17 +309,9 @@ | |||
1639 | 306 | } | 309 | } |
1640 | 307 | 310 | ||
1641 | 308 | def set_priority(self, cr, uid, ids, priority, *args): | 311 | def set_priority(self, cr, uid, ids, priority, *args): |
1653 | 309 | return self.write(cr, uid, ids, {'priority' : priority}) | 312 | """Set lead priority |
1654 | 310 | 313 | """ | |
1655 | 311 | def set_high_priority(self, cr, uid, ids, *args): | 314 | return self.write(cr, uid, ids, {'priority' : str(priority)}) |
1645 | 312 | """Set lead priority to high | ||
1646 | 313 | """ | ||
1647 | 314 | return self.set_priority(cr, uid, ids, '1') | ||
1648 | 315 | |||
1649 | 316 | def set_normal_priority(self, cr, uid, ids, *args): | ||
1650 | 317 | """Set lead priority to normal | ||
1651 | 318 | """ | ||
1652 | 319 | return self.set_priority(cr, uid, ids, '3') | ||
1656 | 320 | 315 | ||
1657 | 321 | def copy(self, cr, uid, id, default=None, context=None): | 316 | def copy(self, cr, uid, id, default=None, context=None): |
1658 | 322 | issue = self.read(cr, uid, id, ['name'], context=context) | 317 | issue = self.read(cr, uid, id, ['name'], context=context) |
1659 | @@ -375,15 +370,6 @@ | |||
1660 | 375 | # Stage management | 370 | # Stage management |
1661 | 376 | # ------------------------------------------------------- | 371 | # ------------------------------------------------------- |
1662 | 377 | 372 | ||
1663 | 378 | def set_kanban_state_blocked(self, cr, uid, ids, context=None): | ||
1664 | 379 | return self.write(cr, uid, ids, {'kanban_state': 'blocked'}, context=context) | ||
1665 | 380 | |||
1666 | 381 | def set_kanban_state_normal(self, cr, uid, ids, context=None): | ||
1667 | 382 | return self.write(cr, uid, ids, {'kanban_state': 'normal'}, context=context) | ||
1668 | 383 | |||
1669 | 384 | def set_kanban_state_done(self, cr, uid, ids, context=None): | ||
1670 | 385 | return self.write(cr, uid, ids, {'kanban_state': 'done'}, context=context) | ||
1671 | 386 | |||
1672 | 387 | def stage_find(self, cr, uid, cases, section_id, domain=[], order='sequence', context=None): | 373 | def stage_find(self, cr, uid, cases, section_id, domain=[], order='sequence', context=None): |
1673 | 388 | """ Override of the base.stage method | 374 | """ Override of the base.stage method |
1674 | 389 | Parameter of the stage search taken from the issue: | 375 | Parameter of the stage search taken from the issue: |
1675 | @@ -403,7 +389,7 @@ | |||
1676 | 403 | # OR all section_ids and OR with case_default | 389 | # OR all section_ids and OR with case_default |
1677 | 404 | search_domain = [] | 390 | search_domain = [] |
1678 | 405 | if section_ids: | 391 | if section_ids: |
1680 | 406 | search_domain += [('|')] * (len(section_ids)-1) | 392 | search_domain = [('|')] * (len(section_ids)-1) |
1681 | 407 | for section_id in section_ids: | 393 | for section_id in section_ids: |
1682 | 408 | search_domain.append(('project_ids', '=', section_id)) | 394 | search_domain.append(('project_ids', '=', section_id)) |
1683 | 409 | search_domain += list(domain) | 395 | search_domain += list(domain) |
1684 | @@ -514,6 +500,15 @@ | |||
1685 | 514 | (_check_escalation, 'Error! You cannot assign escalation to the same project!', ['project_escalation_id']) | 500 | (_check_escalation, 'Error! You cannot assign escalation to the same project!', ['project_escalation_id']) |
1686 | 515 | ] | 501 | ] |
1687 | 516 | 502 | ||
1688 | 503 | def project_issues_action(self, cr, uid, ids, context=None): | ||
1689 | 504 | data_obj = self.pool.get('ir.model.data') | ||
1690 | 505 | action_obj =self.pool.get('ir.actions.act_window') | ||
1691 | 506 | |||
1692 | 507 | action_id = data_obj.get_object_reference(cr, uid, 'project_issue', 'act_project_project_2_project_issue_all')[1] | ||
1693 | 508 | action = action_obj.read(cr, uid, action_id, [], context) | ||
1694 | 509 | res = self.read(cr, uid, ids, ['issue_label'], context)[0] | ||
1695 | 510 | action['name'] = res['issue_label'] | ||
1696 | 511 | return action | ||
1697 | 517 | 512 | ||
1698 | 518 | class account_analytic_account(osv.Model): | 513 | class account_analytic_account(osv.Model): |
1699 | 519 | _inherit = 'account.analytic.account' | 514 | _inherit = 'account.analytic.account' |
1700 | @@ -521,6 +516,10 @@ | |||
1701 | 521 | 516 | ||
1702 | 522 | _columns = { | 517 | _columns = { |
1703 | 523 | 'use_issues': fields.boolean('Issues', help="Check this field if this project manages issues"), | 518 | 'use_issues': fields.boolean('Issues', help="Check this field if this project manages issues"), |
1704 | 519 | 'issue_label': fields.char('Use Issues as', size=128, help="Gives label to issues on project's kanaban view.", required=True), | ||
1705 | 520 | } | ||
1706 | 521 | _defaults = { | ||
1707 | 522 | 'issue_label': 'Issues', | ||
1708 | 524 | } | 523 | } |
1709 | 525 | 524 | ||
1710 | 526 | def on_change_template(self, cr, uid, ids, template_id, date_start=False, context=None): | 525 | def on_change_template(self, cr, uid, ids, template_id, date_start=False, context=None): |
1711 | 527 | 526 | ||
1712 | === modified file 'project_issue/project_issue_data.xml' | |||
1713 | --- project_issue/project_issue_data.xml 2014-02-21 11:27:04 +0000 | |||
1714 | +++ project_issue/project_issue_data.xml 2014-05-07 10:11:23 +0000 | |||
1715 | @@ -48,6 +48,12 @@ | |||
1716 | 48 | <field name="default" eval="False"/> | 48 | <field name="default" eval="False"/> |
1717 | 49 | <field name="description">Issue blocked</field> | 49 | <field name="description">Issue blocked</field> |
1718 | 50 | </record> | 50 | </record> |
1719 | 51 | <record id="mt_issue_done" model="mail.message.subtype"> | ||
1720 | 52 | <field name="name">Issue Done</field> | ||
1721 | 53 | <field name="res_model">project.issue</field> | ||
1722 | 54 | <field name="default" eval="False"/> | ||
1723 | 55 | <field name="description">Issue Done</field> | ||
1724 | 56 | </record> | ||
1725 | 51 | <record id="mt_issue_stage" model="mail.message.subtype"> | 57 | <record id="mt_issue_stage" model="mail.message.subtype"> |
1726 | 52 | <field name="name">Stage Changed</field> | 58 | <field name="name">Stage Changed</field> |
1727 | 53 | <field name="res_model">project.issue</field> | 59 | <field name="res_model">project.issue</field> |
1728 | 54 | 60 | ||
1729 | === modified file 'project_issue/project_issue_demo.xml' | |||
1730 | --- project_issue/project_issue_demo.xml 2012-11-29 22:26:45 +0000 | |||
1731 | +++ project_issue/project_issue_demo.xml 2014-05-07 10:11:23 +0000 | |||
1732 | @@ -6,12 +6,15 @@ | |||
1733 | 6 | <field name="use_issues" eval="True"/> | 6 | <field name="use_issues" eval="True"/> |
1734 | 7 | </record> | 7 | </record> |
1735 | 8 | <record id="project.project_project_2" model="project.project"> | 8 | <record id="project.project_project_2" model="project.project"> |
1736 | 9 | <field name="issue_label">Bugs</field> | ||
1737 | 9 | <field name="use_issues" eval="True"/> | 10 | <field name="use_issues" eval="True"/> |
1738 | 10 | </record> | 11 | </record> |
1739 | 11 | <record id="project.project_project_3" model="project.project"> | 12 | <record id="project.project_project_3" model="project.project"> |
1740 | 13 | <field name="issue_label">Feedbacks</field> | ||
1741 | 12 | <field name="use_issues" eval="True"/> | 14 | <field name="use_issues" eval="True"/> |
1742 | 13 | </record> | 15 | </record> |
1743 | 14 | <record id="project.project_project_4" model="project.project"> | 16 | <record id="project.project_project_4" model="project.project"> |
1744 | 17 | <field name="issue_label">Bugs</field> | ||
1745 | 15 | <field name="use_issues" eval="True"/> | 18 | <field name="use_issues" eval="True"/> |
1746 | 16 | </record> | 19 | </record> |
1747 | 17 | <record id="project.project_project_5" model="project.project"> | 20 | <record id="project.project_project_5" model="project.project"> |
1748 | @@ -35,7 +38,7 @@ | |||
1749 | 35 | <!-- Issues --> | 38 | <!-- Issues --> |
1750 | 36 | <record id="crm_case_buginaccountsmodule0" model="project.issue"> | 39 | <record id="crm_case_buginaccountsmodule0" model="project.issue"> |
1751 | 37 | <field eval="time.strftime('%Y-%m-08 10:15:00')" name="date"/> | 40 | <field eval="time.strftime('%Y-%m-08 10:15:00')" name="date"/> |
1753 | 38 | <field name="priority">5</field> | 41 | <field name="priority">0</field> |
1754 | 39 | <field name="user_id" ref="base.user_root"/> | 42 | <field name="user_id" ref="base.user_root"/> |
1755 | 40 | <field name="partner_id" ref="base.res_partner_2"/> | 43 | <field name="partner_id" ref="base.res_partner_2"/> |
1756 | 41 | <field name="section_id" ref="crm.section_sales_department"/> | 44 | <field name="section_id" ref="crm.section_sales_department"/> |
1757 | @@ -51,7 +54,7 @@ | |||
1758 | 51 | 54 | ||
1759 | 52 | <record id="crm_case_programnotgivingproperoutput0" model="project.issue"> | 55 | <record id="crm_case_programnotgivingproperoutput0" model="project.issue"> |
1760 | 53 | <field eval="time.strftime('%Y-%m-15 12:50:00')" name="date"/> | 56 | <field eval="time.strftime('%Y-%m-15 12:50:00')" name="date"/> |
1762 | 54 | <field name="priority">3</field> | 57 | <field name="priority">1</field> |
1763 | 55 | <field name="user_id" ref="base.user_root"/> | 58 | <field name="user_id" ref="base.user_root"/> |
1764 | 56 | <field name="partner_id" ref="base.res_partner_1"/> | 59 | <field name="partner_id" ref="base.res_partner_1"/> |
1765 | 57 | <field name="section_id" ref="crm.section_sales_department"/> | 60 | <field name="section_id" ref="crm.section_sales_department"/> |
1766 | @@ -64,7 +67,7 @@ | |||
1767 | 64 | 67 | ||
1768 | 65 | <record id="crm_case_outputincorrect0" model="project.issue"> | 68 | <record id="crm_case_outputincorrect0" model="project.issue"> |
1769 | 66 | <field eval="time.strftime('%Y-%m-18 14:30:00')" name="date"/> | 69 | <field eval="time.strftime('%Y-%m-18 14:30:00')" name="date"/> |
1771 | 67 | <field name="priority">4</field> | 70 | <field name="priority">0</field> |
1772 | 68 | <field name="user_id" ref="base.user_demo"/> | 71 | <field name="user_id" ref="base.user_demo"/> |
1773 | 69 | <field name="section_id" ref="crm.section_sales_department"/> | 72 | <field name="section_id" ref="crm.section_sales_department"/> |
1774 | 70 | <field eval="1" name="active"/> | 73 | <field eval="1" name="active"/> |
1775 | @@ -79,7 +82,7 @@ | |||
1776 | 79 | 82 | ||
1777 | 80 | <record id="crm_case_problemloadingpage0" model="project.issue"> | 83 | <record id="crm_case_problemloadingpage0" model="project.issue"> |
1778 | 81 | <field eval="time.strftime('%Y-%m-20 15:25:05')" name="date"/> | 84 | <field eval="time.strftime('%Y-%m-20 15:25:05')" name="date"/> |
1780 | 82 | <field name="priority">3</field> | 85 | <field name="priority">1</field> |
1781 | 83 | <field name="user_id" ref="base.user_root"/> | 86 | <field name="user_id" ref="base.user_root"/> |
1782 | 84 | <field name="partner_id" ref="base.res_partner_14"/> | 87 | <field name="partner_id" ref="base.res_partner_14"/> |
1783 | 85 | <field name="section_id" ref="crm.section_sales_department"/> | 88 | <field name="section_id" ref="crm.section_sales_department"/> |
1784 | @@ -92,7 +95,7 @@ | |||
1785 | 92 | 95 | ||
1786 | 93 | <record id="crm_case_pagenotfound0" model="project.issue"> | 96 | <record id="crm_case_pagenotfound0" model="project.issue"> |
1787 | 94 | <field eval="time.strftime('%Y-%m-22 18:15:00')" name="date"/> | 97 | <field eval="time.strftime('%Y-%m-22 18:15:00')" name="date"/> |
1789 | 95 | <field name="priority">3</field> | 98 | <field name="priority">1</field> |
1790 | 96 | <field name="user_id" ref="base.user_root"/> | 99 | <field name="user_id" ref="base.user_root"/> |
1791 | 97 | <field name="partner_id" ref="base.res_partner_13"/> | 100 | <field name="partner_id" ref="base.res_partner_13"/> |
1792 | 98 | <field name="section_id" ref="crm.section_sales_department"/> | 101 | <field name="section_id" ref="crm.section_sales_department"/> |
1793 | @@ -105,7 +108,7 @@ | |||
1794 | 105 | 108 | ||
1795 | 106 | <record id="crm_case_programmingerror0" model="project.issue"> | 109 | <record id="crm_case_programmingerror0" model="project.issue"> |
1796 | 107 | <field eval="time.strftime('%Y-%m-24 09:45:00')" name="date"/> | 110 | <field eval="time.strftime('%Y-%m-24 09:45:00')" name="date"/> |
1798 | 108 | <field name="priority">3</field> | 111 | <field name="priority">1</field> |
1799 | 109 | <field name="user_id" ref="base.user_root"/> | 112 | <field name="user_id" ref="base.user_root"/> |
1800 | 110 | <field name="partner_id" ref="base.res_partner_5"/> | 113 | <field name="partner_id" ref="base.res_partner_5"/> |
1801 | 111 | <field name="section_id" ref="crm.section_sales_department"/> | 114 | <field name="section_id" ref="crm.section_sales_department"/> |
1802 | @@ -172,7 +175,7 @@ | |||
1803 | 172 | 175 | ||
1804 | 173 | <record id="crm_case_newfeaturestobeadded0" model="project.issue"> | 176 | <record id="crm_case_newfeaturestobeadded0" model="project.issue"> |
1805 | 174 | <field eval="time.strftime('%Y-%m-01 12:15:10')" name="date"/> | 177 | <field eval="time.strftime('%Y-%m-01 12:15:10')" name="date"/> |
1807 | 175 | <field name="priority">4</field> | 178 | <field name="priority">0</field> |
1808 | 176 | <field name="user_id" ref="base.user_root"/> | 179 | <field name="user_id" ref="base.user_root"/> |
1809 | 177 | <field name="partner_id" ref="base.res_partner_8"/> | 180 | <field name="partner_id" ref="base.res_partner_8"/> |
1810 | 178 | <field name="section_id" ref="crm.section_sales_department"/> | 181 | <field name="section_id" ref="crm.section_sales_department"/> |
1811 | @@ -199,7 +202,7 @@ | |||
1812 | 199 | 202 | ||
1813 | 200 | <record id="crm_case_includeattendancesheetinproject0" model="project.issue"> | 203 | <record id="crm_case_includeattendancesheetinproject0" model="project.issue"> |
1814 | 201 | <field eval="time.strftime('%Y-%m-10 17:05:30')" name="date"/> | 204 | <field eval="time.strftime('%Y-%m-10 17:05:30')" name="date"/> |
1816 | 202 | <field name="priority">3</field> | 205 | <field name="priority">1</field> |
1817 | 203 | <field name="user_id" ref="base.user_root"/> | 206 | <field name="user_id" ref="base.user_root"/> |
1818 | 204 | <field name="partner_id" ref="base.res_partner_10"/> | 207 | <field name="partner_id" ref="base.res_partner_10"/> |
1819 | 205 | <field name="section_id" ref="crm.section_sales_department"/> | 208 | <field name="section_id" ref="crm.section_sales_department"/> |
1820 | @@ -213,7 +216,7 @@ | |||
1821 | 213 | 216 | ||
1822 | 214 | <record id="crm_case_createnewobject0" model="project.issue"> | 217 | <record id="crm_case_createnewobject0" model="project.issue"> |
1823 | 215 | <field eval="time.strftime('%Y-%m-15 10:35:15')" name="date"/> | 218 | <field eval="time.strftime('%Y-%m-15 10:35:15')" name="date"/> |
1825 | 216 | <field name="priority">3</field> | 219 | <field name="priority">1</field> |
1826 | 217 | <field name="user_id" ref="base.user_root"/> | 220 | <field name="user_id" ref="base.user_root"/> |
1827 | 218 | <field name="partner_id" ref="base.res_partner_6"/> | 221 | <field name="partner_id" ref="base.res_partner_6"/> |
1828 | 219 | <field name="section_id" ref="crm.section_sales_department"/> | 222 | <field name="section_id" ref="crm.section_sales_department"/> |
1829 | @@ -226,7 +229,7 @@ | |||
1830 | 226 | 229 | ||
1831 | 227 | <record id="crm_case_improvereportsinhrms0" model="project.issue"> | 230 | <record id="crm_case_improvereportsinhrms0" model="project.issue"> |
1832 | 228 | <field eval="time.strftime('%Y-%m-19 12:15:00')" name="date"/> | 231 | <field eval="time.strftime('%Y-%m-19 12:15:00')" name="date"/> |
1834 | 229 | <field name="priority">4</field> | 232 | <field name="priority">0</field> |
1835 | 230 | <field name="user_id" ref="base.user_root"/> | 233 | <field name="user_id" ref="base.user_root"/> |
1836 | 231 | <field name="partner_id" ref="base.res_partner_11"/> | 234 | <field name="partner_id" ref="base.res_partner_11"/> |
1837 | 232 | <field name="section_id" ref="crm.section_sales_department"/> | 235 | <field name="section_id" ref="crm.section_sales_department"/> |
1838 | 233 | 236 | ||
1839 | === modified file 'project_issue/project_issue_view.xml' | |||
1840 | --- project_issue/project_issue_view.xml 2014-05-02 13:07:53 +0000 | |||
1841 | +++ project_issue/project_issue_view.xml 2014-05-07 10:11:23 +0000 | |||
1842 | @@ -55,11 +55,10 @@ | |||
1843 | 55 | <label for="name" class="oe_edit_only"/> | 55 | <label for="name" class="oe_edit_only"/> |
1844 | 56 | <h1> | 56 | <h1> |
1845 | 57 | <field name="name" class="oe_inline"/> | 57 | <field name="name" class="oe_inline"/> |
1846 | 58 | <field name="kanban_state" invisible='1'/> | ||
1847 | 59 | <button name="set_kanban_state_done" help="In Progress" attrs="{'invisible': [('kanban_state', 'in', ['done','blocked'])]}" type="object" icon="gtk-normal" class="oe_link oe_right"/> | ||
1848 | 60 | <button name="set_kanban_state_blocked" help="Ready for Next Stage" attrs="{'invisible': [('kanban_state', 'in', ['normal','blocked'])]}" type="object" icon="gtk-yes" class="oe_link oe_right"/> | ||
1849 | 61 | <button name="set_kanban_state_normal" help="Blocked" attrs="{'invisible': [('kanban_state', 'in', ['done','normal'])]}" type="object" icon="gtk-no" class="oe_link oe_right"/> | ||
1850 | 62 | </h1> | 58 | </h1> |
1851 | 59 | <div class="oe_right"> | ||
1852 | 60 | <field name="kanban_state" class="oe_inline" widget="dropdown_selection"/> | ||
1853 | 61 | </div> | ||
1854 | 63 | <label for="categ_ids" class="oe_edit_only"/> | 62 | <label for="categ_ids" class="oe_edit_only"/> |
1855 | 64 | <field name="categ_ids" widget="many2many_tags"/> | 63 | <field name="categ_ids" widget="many2many_tags"/> |
1856 | 65 | <group> | 64 | <group> |
1857 | @@ -78,7 +77,7 @@ | |||
1858 | 78 | <group> | 77 | <group> |
1859 | 79 | <field name="id"/> | 78 | <field name="id"/> |
1860 | 80 | <field name="version_id" groups="base.group_user"/> | 79 | <field name="version_id" groups="base.group_user"/> |
1862 | 81 | <field name="priority" groups="base.group_user"/> | 80 | <field name="priority" groups="base.group_user" widget="priority"/> |
1863 | 82 | <label for="task_id" groups="base.group_user"/> | 81 | <label for="task_id" groups="base.group_user"/> |
1864 | 83 | <div groups="base.group_user"> | 82 | <div groups="base.group_user"> |
1865 | 84 | <field name="task_id" on_change="onchange_task_id(task_id)" class="oe_inline" context="{'default_project_id':project_id}"/> | 83 | <field name="task_id" on_change="onchange_task_id(task_id)" class="oe_inline" context="{'default_project_id':project_id}"/> |
1866 | @@ -186,7 +185,7 @@ | |||
1867 | 186 | <field name="model">project.issue</field> | 185 | <field name="model">project.issue</field> |
1868 | 187 | <field name="arch" type="xml"> | 186 | <field name="arch" type="xml"> |
1869 | 188 | <kanban default_group_by="stage_id"> | 187 | <kanban default_group_by="stage_id"> |
1871 | 189 | <field name="stage_id"/> | 188 | <field name="stage_id" options='{"tooltip_on_group_by": "kanban_column_tooltip"}'/> |
1872 | 190 | <field name="color"/> | 189 | <field name="color"/> |
1873 | 191 | <field name="priority"/> | 190 | <field name="priority"/> |
1874 | 192 | <field name="user_email"/> | 191 | <field name="user_email"/> |
1875 | @@ -220,28 +219,19 @@ | |||
1876 | 220 | <div class="oe_kanban_footer_left"> | 219 | <div class="oe_kanban_footer_left"> |
1877 | 221 | <field name="categ_ids"/> | 220 | <field name="categ_ids"/> |
1878 | 222 | <div class="oe_right"> | 221 | <div class="oe_right"> |
1901 | 223 | <span class="oe_kanban_highlight" groups="base.group_user"> | 222 | <table> |
1902 | 224 | <a t-if="record.kanban_state.raw_value === 'normal'" type="object" string="In Progress" name="set_kanban_state_done" class="oe_kanban_status"> </a> | 223 | <tr> |
1903 | 225 | <a t-if="record.kanban_state.raw_value === 'done'" type="object" string="Ready for next stage" name="set_kanban_state_blocked" class="oe_kanban_status oe_kanban_status_green"> </a> | 224 | <td groups="base.group_user"> |
1904 | 226 | <a t-if="record.kanban_state.raw_value === 'blocked'" type="object" string="Blocked" name="set_kanban_state_normal" class="oe_kanban_status oe_kanban_status_red"> </a> | 225 | <field name="kanban_state" widget="dropdown_selection"/> |
1905 | 227 | <t t-set="priority" t-value="record.priority.raw_value || 5"/> | 226 | </td> |
1906 | 228 | <a type="object" name="set_priority" args="['3']" t-if="priority gt 3" title="Normal Priority"> | 227 | <td groups="base.group_user"> |
1907 | 229 | <img src="/web/static/src/img/icons/star-off.png" width="16" height="16"/> | 228 | <field name="priority" widget="priority"/> |
1908 | 230 | </a> | 229 | </td> |
1909 | 231 | <a type="object" name="set_priority" args="['5']" t-if="priority lte 3" title="Normal Priority"> | 230 | <td> |
1910 | 232 | <img t-attf-src="/web/static/src/img/icons/star-#{priority lte 3 ? 'on' : 'off'}.png" width="16" height="16"/> | 231 | <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar"/> |
1911 | 233 | </a> | 232 | </td> |
1912 | 234 | <a type="object" name="set_priority" args="['2']" title="High Priority"> | 233 | </tr> |
1913 | 235 | <img t-attf-src="/web/static/src/img/icons/star-#{priority lte 2 ? 'on' : 'off'}.png" width="16" height="16"/> | 234 | </table> |
1892 | 236 | </a> | ||
1893 | 237 | <a type="object" name="set_priority" args="['1']" title="Highest Priority"> | ||
1894 | 238 | <img t-attf-src="/web/static/src/img/icons/star-#{priority == 1 ? 'on' : 'off'}.png" width="16" height="16"/> | ||
1895 | 239 | </a> | ||
1896 | 240 | </span> | ||
1897 | 241 | <t t-if="record.date_deadline.raw_value and record.date_deadline.raw_value lt (new Date())"> | ||
1898 | 242 | <span t-attf-class="oe_kanban_status oe_kaban_status_red"> </span> | ||
1899 | 243 | </t> | ||
1900 | 244 | <img t-att-src="kanban_image('res.users', 'image_small', record.user_id.raw_value)" t-att-title="record.user_id.value" width="24" height="24" class="oe_kanban_avatar"/> | ||
1914 | 245 | </div> | 235 | </div> |
1915 | 246 | </div> | 236 | </div> |
1916 | 247 | <div class="oe_kanban_footer_left"> | 237 | <div class="oe_kanban_footer_left"> |
1917 | @@ -301,13 +291,16 @@ | |||
1918 | 301 | <field name="inherit_id" ref="project.edit_project"/> | 291 | <field name="inherit_id" ref="project.edit_project"/> |
1919 | 302 | <field name="arch" type="xml"> | 292 | <field name="arch" type="xml"> |
1920 | 303 | <xpath expr='//div[@name="options_active"]' position='inside'> | 293 | <xpath expr='//div[@name="options_active"]' position='inside'> |
1922 | 304 | <field name="use_issues" class="oe_inline" | 294 | <div> |
1923 | 295 | <field name="use_issues" class="oe_inline oe_from_boolean_align" | ||
1924 | 305 | on_change="on_change_use_tasks_or_issues(use_tasks, use_issues)"/> | 296 | on_change="on_change_use_tasks_or_issues(use_tasks, use_issues)"/> |
1926 | 306 | <label for="use_issues"/> | 297 | <label for="issue_label" class="oe_edit_only"/> |
1927 | 298 | <b><field name="issue_label" class="oe_inline"/></b> | ||
1928 | 299 | </div> | ||
1929 | 307 | </xpath> | 300 | </xpath> |
1930 | 308 | <xpath expr='//div[@name="buttons"]' position='inside'> | 301 | <xpath expr='//div[@name="buttons"]' position='inside'> |
1933 | 309 | <button class="oe_inline oe_stat_button" type="action" attrs="{'invisible':[('use_issues','=', 0)]}" | 302 | <button class="oe_inline oe_stat_button" type="object" attrs="{'invisible':[('use_issues','=', 0)]}" |
1934 | 310 | name="%(act_project_project_2_project_issue_all)d" icon="fa-bug"> | 303 | name="project_issues_action" icon="fa-bug"> |
1935 | 311 | <field string="Issues" name="issue_count" widget="statinfo"/> | 304 | <field string="Issues" name="issue_count" widget="statinfo"/> |
1936 | 312 | </button> | 305 | </button> |
1937 | 313 | </xpath> | 306 | </xpath> |
1938 | @@ -320,6 +313,9 @@ | |||
1939 | 320 | <field name="sequence" position="before"> | 313 | <field name="sequence" position="before"> |
1940 | 321 | <field name="project_escalation_id"/> | 314 | <field name="project_escalation_id"/> |
1941 | 322 | </field> | 315 | </field> |
1942 | 316 | <xpath expr='//page[@name="project_stages"]' position="attributes"> | ||
1943 | 317 | <attribute name="attrs">{'invisible': [('use_issues', '=', False), ('use_tasks', '=', False)]}</attribute> | ||
1944 | 318 | </xpath> | ||
1945 | 323 | </field> | 319 | </field> |
1946 | 324 | </record> | 320 | </record> |
1947 | 325 | 321 | ||
1948 | @@ -334,10 +330,8 @@ | |||
1949 | 334 | </field> | 330 | </field> |
1950 | 335 | <xpath expr="//div[contains(@class, 'oe_kanban_project_list')]" position="inside"> | 331 | <xpath expr="//div[contains(@class, 'oe_kanban_project_list')]" position="inside"> |
1951 | 336 | <a t-if="record.use_issues.raw_value" style="margin-right: 10px" | 332 | <a t-if="record.use_issues.raw_value" style="margin-right: 10px" |
1956 | 337 | name="%(act_project_project_2_project_issue_all)d" type="action"> | 333 | name="project_issues_action" type="object"> |
1957 | 338 | <t t-raw="record.issue_ids.raw_value.length"/> | 334 | <span><field name="issue_count"/> <field name="issue_label"/></span> |
1954 | 339 | <span t-if="record.issue_ids.raw_value.length == 1">Issue</span> | ||
1955 | 340 | <span t-if="record.issue_ids.raw_value.length > 1">Issues</span> | ||
1958 | 341 | </a> | 335 | </a> |
1959 | 342 | </xpath> | 336 | </xpath> |
1960 | 343 | </field> | 337 | </field> |
1961 | @@ -350,8 +344,11 @@ | |||
1962 | 350 | <field eval="18" name="priority"/> | 344 | <field eval="18" name="priority"/> |
1963 | 351 | <field name="arch" type="xml"> | 345 | <field name="arch" type="xml"> |
1964 | 352 | <xpath expr='//div[@name="project"]' position='inside'> | 346 | <xpath expr='//div[@name="project"]' position='inside'> |
1967 | 353 | <field name="use_issues"/> | 347 | <div class="oe_left"> |
1968 | 354 | <label for="use_issues"/> | 348 | <field name="use_issues" class="oe_from_boolean_align"/> |
1969 | 349 | <label for="issue_label" class="oe_edit_only"/> | ||
1970 | 350 | <b><field name="issue_label" class="oe_inline"/></b> | ||
1971 | 351 | </div> | ||
1972 | 355 | </xpath> | 352 | </xpath> |
1973 | 356 | </field> | 353 | </field> |
1974 | 357 | </record> | 354 | </record> |
1975 | @@ -370,6 +367,17 @@ | |||
1976 | 370 | </field> | 367 | </field> |
1977 | 371 | </record> | 368 | </record> |
1978 | 372 | 369 | ||
1979 | 370 | <record id="view_project_task_type_form_inherited" model="ir.ui.view"> | ||
1980 | 371 | <field name="name">project.task.type.form.inherited</field> | ||
1981 | 372 | <field name="model">project.task.type</field> | ||
1982 | 373 | <field name="inherit_id" ref="project.task_type_edit"/> | ||
1983 | 374 | <field name="arch" type="xml"> | ||
1984 | 375 | <xpath expr='//field[@name="type"]' position="attributes"> | ||
1985 | 376 | <attribute name="invisible">0</attribute> | ||
1986 | 377 | </xpath> | ||
1987 | 378 | </field> | ||
1988 | 379 | </record> | ||
1989 | 380 | |||
1990 | 373 | <!-- res.partner --> | 381 | <!-- res.partner --> |
1991 | 374 | <record model="ir.ui.view" id="res_partner_issues_button_view"> | 382 | <record model="ir.ui.view" id="res_partner_issues_button_view"> |
1992 | 375 | <field name="name">res.partner.issues.button.view</field> | 383 | <field name="name">res.partner.issues.button.view</field> |
1993 | 376 | 384 | ||
1994 | === modified file 'project_issue/report/project_issue_report.py' | |||
1995 | --- project_issue/report/project_issue_report.py 2013-10-27 12:31:04 +0000 | |||
1996 | +++ project_issue/report/project_issue_report.py 2014-05-07 10:11:23 +0000 | |||
1997 | @@ -47,7 +47,7 @@ | |||
1998 | 47 | 'delay_close': fields.float('Avg. Delay to Close', digits=(16,2), readonly=True, group_operator="avg", | 47 | 'delay_close': fields.float('Avg. Delay to Close', digits=(16,2), readonly=True, group_operator="avg", |
1999 | 48 | help="Number of Days to close the project issue"), | 48 | help="Number of Days to close the project issue"), |
2000 | 49 | 'company_id' : fields.many2one('res.company', 'Company'), | 49 | 'company_id' : fields.many2one('res.company', 'Company'), |
2002 | 50 | 'priority': fields.selection(crm.AVAILABLE_PRIORITIES, 'Priority'), | 50 | 'priority': fields.selection([('0','Low'), ('1','Normal'), ('2','High')], 'Priority'), |
2003 | 51 | 'project_id':fields.many2one('project.project', 'Project',readonly=True), | 51 | 'project_id':fields.many2one('project.project', 'Project',readonly=True), |
2004 | 52 | 'version_id': fields.many2one('project.issue.version', 'Version'), | 52 | 'version_id': fields.many2one('project.issue.version', 'Version'), |
2005 | 53 | 'user_id' : fields.many2one('res.users', 'Assigned to',readonly=True), | 53 | 'user_id' : fields.many2one('res.users', 'Assigned to',readonly=True), |
2006 | 54 | 54 | ||
2007 | === modified file 'project_timesheet/project_timesheet_view.xml' | |||
2008 | --- project_timesheet/project_timesheet_view.xml 2014-04-15 12:57:15 +0000 | |||
2009 | +++ project_timesheet/project_timesheet_view.xml 2014-05-07 10:11:23 +0000 | |||
2010 | @@ -25,7 +25,7 @@ | |||
2011 | 25 | <field name="model">project.project</field> | 25 | <field name="model">project.project</field> |
2012 | 26 | <field name="inherit_id" ref="project.edit_project"/> | 26 | <field name="inherit_id" ref="project.edit_project"/> |
2013 | 27 | <field name="arch" type="xml"> | 27 | <field name="arch" type="xml"> |
2015 | 28 | <xpath expr='//div[@name="options_active"]' position='inside'> | 28 | <xpath expr='//div[@name="options_active"]' position='before'> |
2016 | 29 | <field name="use_timesheets" class="oe_inline"/> | 29 | <field name="use_timesheets" class="oe_inline"/> |
2017 | 30 | <label for="use_timesheets"/> | 30 | <label for="use_timesheets"/> |
2018 | 31 | </xpath> | 31 | </xpath> |
A .THIS file has been left in the code... please remove it
(we will review the code later)