Menu : déplacement dans celui du module semantics
[OpenERP/todolist.git] / views / todolist.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <openerp>
3     <data>
4
5
6         <record model="ir.ui.view" id="todolist_form_view">
7             <field name="name">container.form</field>
8             <field name="model">todolist.container</field>
9             <field name="arch" type="xml">
10                 <form string="Todolist Form" version="7.0">
11                     <header>
12                         <button string="Start" type="object" name="action_start" states="draft" class="oe_highlight" />
13                         <button string="Stop" type="object" name="action_stop" states="pending" class="oe_highlight" />
14                         <button string="Restart" type="object" name="action_restart" states="pending,done" class="oe_highlight" />
15                         <field name="state" widget="statusbar" />
16                     </header>
17                     <sheet>
18                         <group colspan="4" col="3">
19                             <label for="name" colspan="1" />
20                             <field name="name" colspan="2" nolabel="1" />
21                             <label for="description" colspan="1" />
22                             <field name="description" colspan="2" nolabel="1" />
23                             <label for="number_tasks" colspan="1" />
24                             <field name="number_tasks" colspan="2" nolabel="1" />
25                             <label for="number_tasks_done" colspan="1" />
26                             <field name="number_tasks_done" colspan="2" nolabel="1" />
27                             <field name="progress_tasks" colspan="3" widget="progressbar" />
28                         </group>
29                         <notebook colspan="4">
30                             <page string="Dates">
31                                 <group colspan="4" col="1">
32                                     <label for="target" />
33                                     <field name="target" nolabel="1" />
34                                     <label for="milestone" />
35                                     <field name="milestone" nolabel="1" />
36                                     <label for="manday" />
37                                     <field name="manday" nolabel="1" />
38                                 </group>
39                             </page>
40                             <page string="Tasks">
41                                 <group colspan="4" col="1">
42                                     <field name="tasks" nolabel="1" mode="tree">
43                                         <tree string="Tasks" editable="1" colors="red:priority=='essential';
44                                                                                     #FF5800:priority=='necessary';
45                                                                                     black:priority=='useful'">
46                                             <field name="name"/>
47                                             <field name="description"/>
48                                             <field name="milestone"/>
49                                             <field name="planned"/>
50                                             <field name="manday"/>
51                                             <field name="priority"/>
52                                         </tree>
53                                     </field>
54                                 </group>
55                             </page>
56                             <page string="Topics">
57                                 <group colspan="4" col="1">
58                                     <field name="topics_id"/>
59                                 </group>
60                             </page>
61                         </notebook>
62                     </sheet>
63                     <div class="oe_chatter">
64                         <field name="message_follower_ids" widget="mail_followers"/>
65                         <field name="message_ids" widget="mail_thread" options="{'thread_level': 1}"/>
66                     </div>
67                 </form>
68             </field>
69         </record>
70
71
72         <record model="ir.ui.view" id="todolist_kanban_view">
73             <field name="name">container.kanban</field>
74             <field name="model">todolist.container</field>
75             <field name="arch" type="xml">
76                 <kanban>
77                     <templates>
78                         <t t-name="kanban-box">
79                             <div class="oe_kanban_card oe_semantic_html_override oe_kanban_global_click_edit">
80                                 <div class="oe_dropdown_kanban">
81
82                                     <div class="oe_dropdown_toggle">
83                                         <span class="oe_e">X</span>
84                                         <ul class="oe_dropdown_menu">
85                                             <li><a type="delete">Delete</a></li>
86                                            </ul>
87                                     </div>
88                                     <div class="oe_clear" />
89                                 </div>
90
91                                 <div t-attf-class="oe_kanban_content">
92                                     <h2><field name="name" /></h2>
93                                     <field name="description" />
94                                 </div>
95
96                             </div>
97                         </t>
98                     </templates>
99                 </kanban>
100             </field>
101         </record>
102
103
104         <record model="ir.ui.view" id="topic_form_view">
105             <field name="name">topic.form</field>
106             <field name="model">todolist.topic</field>
107             <field name="arch" type="xml">
108                 <form string="Topic Form" version="7.0">
109                     <sheet>
110                         <group colspan="4" col="4">
111                             <label for="name" colspan="3"/>
112                             <label for="activated" colspan="1"/>
113                             <field name="name" nolabel="1" colspan="3"/>
114                             <field name="activated" nolabel="1" colspan="1"/>
115                         </group>
116                         <group col="1">
117                             <label for="description"/>
118                             <field name="description" nolabel="1"/>
119                             <label for="nb_lists" />
120                             <field name="nb_lists" nolabel="1" />
121                             <field name="progress_tasks" colspan="3" widget="progressbar" />
122                         </group>
123                     </sheet>
124                     <div class="oe_chatter">
125                         <field name="message_follower_ids" widget="mail_followers"/>
126                         <field name="message_ids" widget="mail_thread" options="{'thread_level': 1}"/>
127                     </div>
128                 </form>
129             </field>
130         </record>
131
132
133         <record model="ir.ui.view" id="topic_kanban_view">
134             <field name="name">topic.kanban</field>
135             <field name="model">todolist.topic</field>
136             <field name="arch" type="xml">
137                 <kanban default_group_by="activated">
138                     <templates>
139                         <t t-name="kanban-box">
140                             <div class="oe_kanban_card oe_semantic_html_override oe_kanban_global_click_edit">
141                                 <div class="oe_dropdown_kanban">
142
143                                     <div class="oe_dropdown_toggle">
144                                         <span class="oe_e">X</span>
145                                         <ul class="oe_dropdown_menu">
146                                             <li><a type="delete">Delete</a></li>
147                                            </ul>
148                                     </div>
149                                     <div class="oe_clear" />
150                                 </div>
151                                 <div t-attf-class="oe_kanban_content">
152                                     <h1><field name="name" /></h1>
153                                     <field name="description" />
154                                 </div>
155                             </div>
156                         </t>
157                     </templates>
158                 </kanban>
159             </field>
160         </record>
161
162
163         <record model="ir.ui.view" id="task_form_view">
164             <field name="name">task.form</field>
165             <field name="model">todolist.task</field>
166             <field name="arch" type="xml">
167                 <form string="Task Form" version="7.0">
168                     <header>
169                         <button string="Reset" type="object" name="action_draft" states="proposal,approved,started" class="oe_highlight" />
170                         <button string="Propose" type="object" name="action_propose" states="draft,approved,started" class="oe_highlight" />
171                         <button string="Approve" type="object" name="action_approve" states="draft,proposal" class="oe_highlight" />
172                         <button string="Start" type="object" name="action_start" states="draft,approved" class="oe_highlight" />
173                         <button string="Stop" type="object" name="action_done" states="started" class="oe_highlight" />
174                         <field name="state" widget="statusbar" />
175                     </header>
176                     <sheet>
177                         <group>
178                             <field name="name"/>
179                             <field name="description" />
180                             <field name="milestone" />
181                             <field name="planned" />
182                             <field name="manday" />
183                             <field name="priority" />
184                             <field name="container_id" />
185                         </group>
186                     </sheet>
187                     <div class="oe_chatter">
188                         <field name="message_follower_ids" widget="mail_followers"/>
189                         <field name="message_ids" widget="mail_thread" options="{'thread_level': 1}"/>
190                     </div>
191                  </form>
192             </field>
193         </record>
194
195
196         <record model="ir.ui.view" id="task_kanban_view">
197             <field name="name">task.kanban</field>
198             <field name="model">todolist.task</field>
199             <field name="arch" type="xml">
200                 <kanban default_group_by="priority">
201                     <templates>
202                         <t t-name="kanban-box">
203                             <div class="oe_kanban_card oe_semantic_html_override oe_kanban_global_click_edit">
204                                 <div class="oe_dropdown_kanban">
205
206                                     <div class="oe_dropdown_toggle">
207                                         <span class="oe_e">X</span>
208                                         <ul class="oe_dropdown_menu">
209                                             <li><a type="delete">Delete</a></li>
210                                            </ul>
211                                     </div>
212                                     <div class="oe_clear" />
213                                 </div>
214
215                                 <div t-attf-class="oe_kanban_content">
216                                     <h4><field name="name" /></h4>
217                                     <p><field name="description" /></p>
218                                     <p>Planned on <field name="planned" /></p>
219                                 </div>
220
221                             </div>
222                         </t>
223                     </templates>
224                 </kanban>
225             </field>
226         </record>
227
228         <record model="ir.actions.act_window" id="todolist_list_action">
229             <field name="name">list of to do lists</field>
230             <field name="res_model">todolist.container</field>
231             <field name="view_mode">kanban,form</field>
232             <field name="help" type="html">
233                 <p class="oe_view_nocontent_create">Create your first to do list</p>
234             </field>
235         </record>
236
237
238         <record model="ir.actions.act_window" id="topic_list_action">
239             <field name="name">List of topics</field>
240             <field name="res_model">todolist.topic</field>
241             <field name="view_mode">kanban,form</field>
242             <field name="help" type="html">
243                 <p class="oe_view_nocontent_create">Créer your first topic</p>
244             </field>
245         </record>
246
247
248         <record model="ir.actions.act_window" id="task_list_action">
249             <field name="name">List of tasks</field>
250             <field name="res_model">todolist.task</field>
251             <field name="view_mode">kanban,form</field>
252             <field name="help" type="html">
253                 <p class="oe_view_nocontent_create">Create your first task</p>
254             </field>
255         </record>
256
257
258         <menuitem id="mt_todolist_menu" name="To do list" parent="semantics.main_semantics_menu" groups="group_todolist_user" />
259
260         <menuitem id="mt_todolist_container_menu" name="Lists" parent="mt_todolist_menu" action="todolist_list_action"/>
261
262         <menuitem id="mt_todolist_task_menu" name="Tasks" parent="mt_todolist_menu" action="task_list_action" />
263
264         <menuitem id="mt_settings_menu" name="Settings" parent="mt_todolist_menu" groups="group_todolist_manager" />
265
266         <menuitem id="mt_todolist_topic_menu" name="Topics" parent="mt_settings_menu" action="topic_list_action" />
267
268
269
270     </data>
271 </openerp>