|
133 | 133 | readonly="is_editable == False"
|
134 | 134 | />
|
135 | 135 | <field name="description" readonly="is_editable == False" />
|
136 |
| - <field name="group_id" readonly="is_editable == False" /> |
| 136 | + <field |
| 137 | + name="group_id" |
| 138 | + readonly="is_editable == False" |
| 139 | + groups="base.group_no_one" |
| 140 | + /> |
137 | 141 | </group>
|
138 | 142 | <group>
|
139 | 143 | <field name="date_start" readonly="is_editable == False" />
|
140 | 144 | <field
|
141 | 145 | name="picking_type_id"
|
142 | 146 | readonly="is_editable == False"
|
143 | 147 | />
|
| 148 | + <field name="company_id" invisible="1" /> |
144 | 149 | <field
|
145 | 150 | name="company_id"
|
146 | 151 | groups="base.group_multi_company"
|
|
181 | 186 | <field name="date_required" />
|
182 | 187 | <field name="estimated_cost" widget="monetary" />
|
183 | 188 | <field name="currency_id" column_invisible="1" />
|
184 |
| - <field |
185 |
| - name="company_id" |
186 |
| - groups="base.group_multi_company" |
187 |
| - widget="selection" |
188 |
| - /> |
189 | 189 | <field name="cancelled" column_invisible="1" />
|
190 | 190 | <field name="is_editable" column_invisible="1" />
|
191 | 191 | <field name="purchased_qty" />
|
|
371 | 371 | </search>
|
372 | 372 | </field>
|
373 | 373 | </record>
|
| 374 | + <record id="view_purchase_request_kanban" model="ir.ui.view"> |
| 375 | + <field name="name">purchase.request.kanban</field> |
| 376 | + <field name="model">purchase.request</field> |
| 377 | + <field name="arch" type="xml"> |
| 378 | + <kanban class="o_kanban_mobile" quick_create="false"> |
| 379 | + <field name="name" /> |
| 380 | + <field name="requested_by" readonly="1" /> |
| 381 | + <field name="estimated_cost" /> |
| 382 | + <field name="state" /> |
| 383 | + <field name="date_start" /> |
| 384 | + <field name="currency_id" readonly="1" /> |
| 385 | + <field name="activity_state" /> |
| 386 | + <progressbar |
| 387 | + field="activity_state" |
| 388 | + colors="{"planned": "success", "today": "warning", "overdue": "danger"}" |
| 389 | + /> |
| 390 | + <templates> |
| 391 | + <t t-name="kanban-box"> |
| 392 | + <div t-attf-class="oe_kanban_card oe_kanban_global_click"> |
| 393 | + <div class="o_kanban_record_top mb16"> |
| 394 | + <div class="o_kanban_record_headings ms-1"> |
| 395 | + <strong class="o_kanban_record_title"><span><t |
| 396 | + t-esc="record.requested_by.value" |
| 397 | + /></span></strong> |
| 398 | + </div> |
| 399 | + <strong><field |
| 400 | + name="estimated_cost" |
| 401 | + widget="monetary" |
| 402 | + /></strong> |
| 403 | + </div> |
| 404 | + <div class="o_kanban_record_bottom"> |
| 405 | + <div class="oe_kanban_bottom_left"> |
| 406 | + <span><t t-esc="record.name.value" /> <t |
| 407 | + t-esc="record.date_start.value" |
| 408 | + /></span> |
| 409 | + <field |
| 410 | + name="activity_ids" |
| 411 | + widget="kanban_activity" |
| 412 | + /> |
| 413 | + </div> |
| 414 | + <div class="oe_kanban_bottom_right"> |
| 415 | + <field |
| 416 | + name="state" |
| 417 | + widget="label_selection" |
| 418 | + options="{'classes': {'draft': 'default', 'rejected': 'default', 'done': 'success', 'approved': 'warning'}}" |
| 419 | + /> |
| 420 | + </div> |
| 421 | + </div> |
| 422 | + </div> |
| 423 | + </t> |
| 424 | + </templates> |
| 425 | + </kanban> |
| 426 | + </field> |
| 427 | + </record> |
374 | 428 | <record model="ir.actions.act_window" id="purchase_request_form_action">
|
375 | 429 | <field name="name">Purchase Requests</field>
|
376 | 430 | <field name="type">ir.actions.act_window</field>
|
377 | 431 | <field name="res_model">purchase.request</field>
|
378 |
| - <field name="view_mode">tree,form</field> |
| 432 | + <field name="view_mode">tree,kanban,form</field> |
379 | 433 | <field name="context">{"search_default_requested_by":uid}</field>
|
380 | 434 | <field name="search_view_id" ref="view_purchase_request_search" />
|
381 | 435 | <field name="help" type="html">
|
|
0 commit comments