forked from OCA/project
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathproject_gtd_view.xml
138 lines (125 loc) · 6.37 KB
/
project_gtd_view.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
<?xml version="1.0" ?>
<openerp>
<data>
<record model="ir.ui.view" id="view_gtd_context_tree">
<field name="name">project.gtd.context.tree</field>
<field name="model">project.gtd.context</field>
<field name="arch" type="xml">
<tree string="Context">
<field name="sequence" invisible="1"/>
<field name="name"/>
</tree>
</field>
</record>
<record model="ir.ui.view" id="view_gtd_context_form">
<field name="name">project.gtd.context.form</field>
<field name="model">project.gtd.context</field>
<field name="arch" type="xml">
<form string="Context" version="7.0">
<group col="4">
<field name="name"/>
<field name="sequence"/>
</group>
</form>
</field>
</record>
<record model="ir.actions.act_window" id="open_gtd_context_tree">
<field name="name">Contexts</field>
<field name="res_model">project.gtd.context</field>
<field name="help">Contexts are defined in the "Getting Things Done" methodology. It allows you to categorize your tasks according to the context in which they have to be done: at the office, at home, when I take my car, etc.</field>
</record>
<menuitem name="Contexts" id="menu_open_gtd_time_contexts"
parent="project.menu_tasks_config" action="open_gtd_context_tree" groups="base.group_no_one"/>
<record model="ir.ui.view" id="view_gtd_timebox_tree">
<field name="name">project.gtd.timebox.tree</field>
<field name="model">project.gtd.timebox</field>
<field name="arch" type="xml">
<tree string="Timebox">
<field name="sequence" invisible="1"/>
<field name="name"/>
</tree>
</field>
</record>
<record model="ir.ui.view" id="view_gtd_timebox_form">
<field name="name">project.gtd.timebox.form</field>
<field name="model">project.gtd.timebox</field>
<field name="arch" type="xml">
<form string="Timeboxes" version="7.0">
<group col="4" string="Timebox Definition">
<field name="name"/>
<field name="sequence"/>
</group>
</form>
</field>
</record>
<record model="ir.actions.act_window" id="open_gtd_timebox_tree">
<field name="name">Timeboxes</field>
<field name="res_model">project.gtd.timebox</field>
<field name="view_type">form</field>
<field name="view_mode">tree,form</field>
<field name="view_id" ref="view_gtd_timebox_tree"/>
<field name="help">Timeboxes are defined in the "Getting Things Done" methodology. A timebox defines a period of time in order to categorize your tasks: today, this week, this month, long term.</field>
</record>
<menuitem name="Timeboxes" id="menu_open_gtd_time_timeboxes" parent="project.menu_tasks_config" action="open_gtd_timebox_tree" groups="base.group_no_one"/>
<record model="ir.ui.view" id="project_task_tree">
<field name="name">project.task.tree.timebox</field>
<field name="model">project.task</field>
<field name="inherit_id" ref="project.view_task_tree2" />
<field name="arch" type="xml">
<field name="remaining_hours" position="after">
<field string="Timeframe" name="timebox_id" invisible=" not context.get('gtd', False)"/>
<field name="context_id" invisible="not context.get('context_show', False)" widget="selection"/>
</field>
</field>
</record>
<record model="ir.ui.view" id="project_task">
<field name="name">project.task.form.timebox</field>
<field name="model">project.task</field>
<field name="inherit_id" ref="project.view_task_form2" />
<field name="arch" type="xml">
<field name="progress" position="after">
<field name="context_id" widget="selection" options='{"no_open": True}'/>
<field name="timebox_id" widget="selection" options='{"no_open": True}' string="Timeframe"/>
</field>
</field>
</record>
<record id="view_task_gtd_search" model="ir.ui.view">
<field name="name">project.task.search.inherit</field>
<field name="model">project.task</field>
<field name="inherit_id" ref="project.view_task_search_form"/>
<field name="arch" type="xml">
<filter name="message_unread" position="after">
<group string="Timebox">
<separator name="gtdsep"/>
</group>
</filter>
<filter string="Last Message" position="after">
<filter name="timebox_id" string="Timebox" domain="[]" context="{'group_by': 'timebox_id'}"/>
<filter name="context_id" string="Context" domain="[]" context="{'group_by': 'context_id'}"/>
</filter>
</field>
</record>
<record model="ir.actions.act_window" id="open_gtd_all_tasks">
<field name="name">Tasks (GTD)</field>
<field name="res_model">project.task</field>
<field name="search_view_id" ref="view_task_gtd_search"/>
<field name="context">{'set_visible': True, 'gtd': True, 'search_default_timebox_id': 1}</field>
<field name="domain">[('stage_id.sequence', '<', 20)]</field>
<field name="view_type">form</field>
<field name="view_mode">kanban,tree,form,calendar,gantt,graph</field>
</record>
<menuitem action="open_gtd_all_tasks" id="menu_open_gtd_timebox_all_tree"
parent="project.menu_project_management" sequence="10"/>
<record model="ir.actions.act_window" id="open_gtd_task">
<field name="name">My Tasks (GTD)</field>
<field name="res_model">project.task</field>
<field name="search_view_id" ref="view_task_gtd_search"/>
<field name="context">{'set_visible': True, 'gtd': True, 'user_invisible': True, 'search_default_timebox_id': 1}</field>
<field name="domain">[('user_id', '=', uid), ('stage_id.sequence', '<', 20)]</field>
<field name="view_type">form</field>
<field name="view_mode">kanban,tree,form,calendar,gantt,graph</field>
</record>
<menuitem action="open_gtd_task" id="menu_open_gtd_timebox_tree"
parent="project.menu_project_management" sequence="11"/>
</data>
</openerp>