[IMP] Change views for routing

bzr revid: jco@openerp.com-20130703203622-jxg5s2l52tud4afe
This commit is contained in:
Josse Colpaert
2013-07-03 22:36:22 +02:00
parent ef8b995e2a
commit 7c9de07720
2 changed files with 7 additions and 66 deletions
+4 -3
View File
@@ -171,14 +171,15 @@ class product_removal_strategy(osv.osv):
class product_product(osv.osv):
_inherit = 'product.product'
_columns = {
'route_ids': fields.many2many('stock.location.path', 'Routes'),
'route_ids': fields.many2many('stock.location.route', 'stock_location_route_product', 'product_id', 'route_id', 'Routes'),
}
class product_category(osv.osv):
_inherit = 'product.category'
_columns = {
'removal_strategy_ids': fields.one2many('product.removal', 'product_categ_id', 'Removal Strategies'),
'putaway_strategy_ids': fields.one2many('product.putaway', 'product_categ_id', 'Put Away Strategies'),
'route_ids': fields.many2many('stock.location.route', 'stock_location_route_categ', 'categ_id', 'route_id', 'Routes'),
#'removal_strategy_ids': fields.one2many('product.removal', 'product_categ_id', 'Removal Strategies'),
#'putaway_strategy_ids': fields.one2many('product.putaway', 'product_categ_id', 'Put Away Strategies'),
}
+3 -63
View File
@@ -39,57 +39,8 @@
<field name="inherit_id" ref="product.product_normal_form_view"/>
<field name="arch" type="xml">
<group name="inventory" position="after">
<group string="Pull Flow">
<field name="flow_pull_ids" colspan="4" nolabel="1">
<tree string="Pulled flows">
<field name="name"/>
<field name="location_id" attrs="{'required': [('type_proc', '=', 'move')]}"/>
<field name="type_proc"/>
<field name="company_id" groups="base.group_multi_company"/>
</tree>
<form string="Pulled Paths">
<group>
<group string="Conditions">
<field name="name" placeholder="Fulfill needs on location X from location Y "/>
<field name="location_id"/>
</group>
<group string="Action Type">
<field name="type_proc"/>
<field name="company_id"/>
</group>
</group>
<group attrs="{'invisible':[('type_proc','!=','move')]}">
<field name="location_src_id" attrs="{'required': [('type_proc', '=', 'move')]}"/>
<field name="picking_type"/>
<field name="partner_address_id"/>
<field name="procure_method"/>
<field name="cancel_cascade"/>
<field name="invoice_state"/>
</group>
</form>
</field>
</group>
<group string="Push Flow">
<field name="path_ids" nolabel="1">
<tree string="Pushed flows">
<field name="location_from_id"/>
<field name="location_dest_id"/>
<field name="auto"/>
<field name="name"/>
<field name="invoice_state"/>
<field name="company_id" groups="base.group_multi_company"/>
</tree>
<form string="Pushed flows">
<field name="name" placeholder="When receiving at location X, move to location Y"/>
<field name="location_from_id"/>
<field name="location_dest_id"/>
<field name="auto"/>
<field name="delay"/>
<field name="picking_type"/>
<field name="invoice_state"/>
<field name="company_id" groups="base.group_multi_company"/>
</form>
</field>
<group string="Routes">
<field name = "route_ids"/>
</group>
</group>
</field>
@@ -104,18 +55,7 @@
<group name="parent" position="after">
<separator name="Strategy"/>
<group name="Strategies">
<field name = "putaway_strategy_ids">
<tree string="Put Away strategies" editable="top">
<field name="location_id"/>
<field name="method"/>
</tree>
</field>
<field name = "removal_strategy_ids" >
<tree string="Removal strategies" editable="top">
<field name="location_id"/>
<field name="method"/>
</tree>
</field>
<field name="route_ids"/>
</group>
</group>
</field>