You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

150 lines
7.1 KiB

<?xml version="1.0" encoding="UTF-8" ?>
<odoo>
<record id="view_crop_request_kanban" model="ir.ui.view">
<field name="name">crop.request.kanban</field>
<field name="model">crop.requests</field>
<field name="arch" type="xml">
<kanban default_group_by="state"
class="o_kanban_small_column o_kanban_project_tasks"
records_draggable="true" default_order="state"
examples="project"
js_class="project_task_kanban" sample="1">
<field name="ref"/>
<field name="farmer_id"/>
<field name="request_date"/>
<field name="seed_id"/>
<field name="tags_id" widget="many2many_tags"
options="{'color_field': 'color'}"/>
<progressbar field="state"
colors='{"draft": "warning","confirm": "info", "cancel": "danger", "ploughing": "muted", "harvest": "muted", "storage": "success", "manuring": "primary"}'/>
<templates>
<t t-name="kanban-box">
<div t-attf-class="oe_kanban_global_click">
<div class="oe_kanban_details">
<strong>
<field name="ref"/>
<br/>
<field name="farmer_id"/>
<br/>
<field name="request_date"/>
<br/>
<field name="seed_id"/>
<br/>
<field name="tags_id"
widget="many2many_tags"
options="{'color_field': 'color'}"/>
<br/>
</strong>
</div>
</div>
</t>
</templates>
</kanban>
</field>
</record>
<record id="view_crop_request_tree" model="ir.ui.view">
<field name="name">crop.request.tree</field>
<field name="model">crop.requests</field>
<field name="arch" type="xml">
<tree>
<field name="ref"/>
<field name="seed_id"/>
<field name="farmer_id"/>
<field name="location_id"/>
</tree>
</field>
</record>
<record id="view_crop_request_form" model="ir.ui.view">
<field name="name">crop.request.form</field>
<field name="model">crop.requests</field>
<field name="arch" type="xml">
<form>
<header>
<button id="button_draft" name="action_draft" string="Draft"
type="object" class="oe_highlight"
states="cancel"/>
<button id="button_confirm" name="action_confirm"
string="Submit" type="object" class="btn-primary"
states="draft"/>
<button id="button_ploughing" name="action_ploughing"
string="Ploughing"
class="btn-primary"
type="object" states="confirm"/>
<button id="button_sowing" name="action_sowing"
string="Sowing" class="btn-primary"
type="object" states="ploughing"/>
<button id="button_manuring" name="action_manuring"
string="Manure" class="btn-primary"
type="object" states="sowing"/>
<button id="button_irrigation" name="action_irrigation"
string="Irrigation" class="btn-primary"
type="object" states="manuring"/>
<button id="button_weeding" name="action_weeding"
string="Weeding" class="btn-primary"
type="object" states="irrigation"/>
<button id="button_harvest" name="action_harvest"
string="Harvest" class="btn-primary"
type="object" states="weeding"/>
<button id="button_storage" name="action_storage"
string="Storage" class="btn-primary"
type="object" states="harvest"/>
<button id="button_cancel" name="action_cancel"
string="Cancelled" class="btn-primary"
type="object"
states="ploughing,sowing,manuring,irrigation,weeding,harvest,storage"/>
<field name="state" widget="statusbar"
statusbar_visible="draft,confirm,ploughing,sowing,manuring,irrigation,weeding,harvest,storage,cancel"/>
</header>
<sheet>
<h1>
<field name="ref"/>
</h1>
<group>
<group>
<field name="farmer_id"/>
<field name="seed_id"/>
<field name="user_id"/>
</group>
<group>
<field name="request_date"/>
<field name="location_id"/>
<field name="tags_id" widget="many2many_tags"
options="{'color_field': 'color'}"/>
</group>
</group>
<notebook>
<page string="Machinery" name="used_machinery">
<field name="machinery_ids">
<tree editable="bottom">
<field name="vehicle_id"/>
<field name="qty"/>
</tree>
</field>
</page>
<page string="Animals" name="used_animals">
<field name="animal_ids">
<tree editable="bottom">
<field name="animal_id"/>
<field name="qty"/>
</tree>
</field>
</page>
<page string="Description" name="description">
<field name="note"
placeholder="Crop Description........"/>
</page>
</notebook>
</sheet>
<div class="oe_chatter">
<field name="message_follower_ids"/>
<field name="activity_ids"/>
<field name="message_ids"/>
</div>
</form>
</field>
</record>
</odoo>