Files
tryton/move.xml
T
Cédric Krier b534d12db1 - Reduce move columns to have only one columns that link to packing in/out
- Add some constraints on move
- simplify creation of inventory move for packing in and simplify overriding
  that will add field on move
2008-05-07 18:04:25 +02:00

191 lines
8.8 KiB
XML

<?xml version="1.0"?>
<tryton>
<data>
<record model="ir.ui.view" id="move_view_form">
<field name="model">stock.move</field>
<field name="type">form</field>
<field name="arch" type="xml">
<![CDATA[
<form string="Move" col="6">
<label name="product"/>
<field name="product"/>
<label name="quantity"/>
<field name="quantity"/>
<label name="uom"/>
<field name="uom"/>
<label name="from_location"/>
<field name="from_location"/>
<label name="to_location"/>
<field name="to_location"/>
<newline/>
<label name="planned_date"/>
<field name="planned_date"/>
<label name="effective_date"/>
<field name="effective_date"/>
<newline/>
<label name="state"/>
<field name="state"/>
<group col="4" colspan="4">
<button string="Set Waiting"
name="set_state_waiting"
type="object"
states="{'invisible': '''state in
('done','cancel','waiting',) '''}"/>
<button string="set Done"
name="set_state_done"
type="object"
states="{'invisible': '''state in
('cancel','done',) '''}"/>
<button string="set Draft"
name="set_state_draft"
type="object"
states="{'invisible': '''state in
('waiting','done', 'draft') '''}"/>
<button string="Cancel"
name="set_state_cancel"
type="object"
states="{'invisible': '''state in
('draft', 'cancel') '''}"/>
</group>
</form>
]]>
</field>
</record>
<record model="ir.ui.view" id="move_view_tree">
<field name="model">stock.move</field>
<field name="type">tree</field>
<field name="arch" type="xml">
<![CDATA[
<tree string="Moves">
<field name="product" select="1"/>
<field name="from_location" select="1"/>
<field name="to_location" select="1"/>
<field name="quantity" select="2"/>
<field name="uom" select="2"/>
<field name="state" select="2"/>
</tree>
]]>
</field>
</record>
<record model="ir.action.act_window" id="act_move_form">
<field name="name">Moves</field>
<field name="res_model">stock.move</field>
<field name="view_type">form</field>
</record>
<record model="ir.action.act_window.view" id="act_move_form_view1">
<field name="sequence" eval="1"/>
<field name="view" ref="move_view_tree"/>
<field name="act_window" ref="act_move_form"/>
</record>
<record model="ir.action.act_window.view" id="act_move_form_view2">
<field name="sequence" eval="2"/>
<field name="view" ref="move_view_form"/>
<field name="act_window" ref="act_move_form"/>
</record>
<menuitem parent="menu_stock" sequence="3"
action="act_move_form" id="menu_move_form"/>
<record model="ir.action.act_window" id="act_move_form_supp">
<field name="name">Moves from suppliers</field>
<field name="res_model">stock.move</field>
<field name="view_type">form</field>
<field name="domain">[('from_location.type', '=', 'supplier')]</field>
</record>
<record model="ir.action.act_window.view" id="act_move_form_supp_view1">
<field name="sequence" eval="1"/>
<field name="view" ref="move_view_tree"/>
<field name="act_window" ref="act_move_form_supp"/>
</record>
<record model="ir.action.act_window.view"
id="act_move_form_supp_view2">
<field name="sequence" eval="2"/>
<field name="view" ref="move_view_form"/>
<field name="act_window" ref="act_move_form_supp"/>
</record>
<menuitem parent="menu_move_form" sequence="1"
action="act_move_form_supp" id="menu_move_form_supp"/>
<record model="ir.action.act_window" id="act_move_form_supp_proceed">
<field name="name">Moves from suppliers to proceed</field>
<field name="res_model">stock.move</field>
<field name="view_type">form</field>
<field name="domain">[('from_location.type', '=', 'supplier'), ('state','in',['draft','waiting']), ('_packing_in','=',False)]</field>
</record>
<record model="ir.action.act_window.view"
id="act_move_form_supp_proceed_view1">
<field name="sequence" eval="1"/>
<field name="view" ref="move_view_tree"/>
<field name="act_window" ref="act_move_form_supp_proceed"/>
</record>
<record model="ir.action.act_window.view"
id="act_move_form_supp_proceed_view2">
<field name="sequence" eval="2"/>
<field name="view" ref="move_view_form"/>
<field name="act_window" ref="act_move_form_supp_proceed"/>
</record>
<menuitem parent="menu_move_form" sequence="2"
action="act_move_form_supp_proceed"
id="menu_move_form_supp_proceed"/>
<record model="ir.action.act_window" id="act_move_form_cust">
<field name="name">Moves to customers</field>
<field name="res_model">stock.move</field>
<field name="view_type">form</field>
<field name="domain">
[('to_location.type', '=', 'customer')]</field>
</record>
<record model="ir.action.act_window.view"
id="act_move_form_cust_view1">
<field name="sequence" eval="1"/>
<field name="view" ref="move_view_tree"/>
<field name="act_window" ref="act_move_form_cust"/>
</record>
<record model="ir.action.act_window.view"
id="act_move_form_cust_view2">
<field name="sequence" eval="2"/>
<field name="view" ref="move_view_form"/>
<field name="act_window" ref="act_move_form_cust"/>
</record>
<menuitem parent="menu_move_form" sequence="3"
action="act_move_form_cust" id="menu_move_form_cust"/>
<record model="ir.action.act_window" id="act_move_form_cust_proceed">
<field name="name">Moves to customers to proceed</field>
<field name="res_model">stock.move</field>
<field name="view_type">form</field>
<field name="domain">[('to_location.type', '=', 'customer'),
('state','in',['draft','waiting'])]</field>
</record>
<record model="ir.action.act_window.view"
id="act_move_form_cust_proceed_view1">
<field name="sequence" eval="1"/>
<field name="view" ref="move_view_tree"/>
<field name="act_window" ref="act_move_form_cust_proceed"/>
</record>
<record model="ir.action.act_window.view"
id="act_move_form_cust_proceed_view2">
<field name="sequence" eval="2"/>
<field name="view" ref="move_view_form"/>
<field name="act_window" ref="act_move_form_cust_proceed"/>
</record>
<menuitem parent="menu_move_form" sequence="4"
action="act_move_form_cust_proceed"
id="menu_move_form_cust_proceed"/>
<record model="ir.action.wizard" id="act_create_packing">
<field name="name">Create Packing</field>
<field name="wiz_name">stock.move.create_packing</field>
</record>
<record model="ir.action.keyword" id="act_create_packing_keyword">
<field name="keyword">form_action</field>
<field name="model">stock.move,0</field>
<field name="action" ref="act_create_packing"/>
</record>
</data>
</tryton>