[IMP] mrp, procurement: procurement workflow documented
bzr revid: qdp-launchpad@openerp.com-20121217103104-vrlm8z02ha6cpa13
This commit is contained in:
parent
f97ff9210e
commit
4dd9751d5e
|
@ -35,6 +35,7 @@ class procurement_order(osv.osv):
|
|||
}
|
||||
|
||||
def check_produce_product(self, cr, uid, procurement, context=None):
|
||||
''' Depict the capacity of the procurement workflow to produce products (not services)'''
|
||||
return True
|
||||
|
||||
def check_bom_exists(self, cr, uid, ids, context=None):
|
||||
|
|
|
@ -234,12 +234,14 @@ class procurement_order(osv.osv):
|
|||
return False
|
||||
|
||||
def check_produce_service(self, cr, uid, procurement, context=None):
|
||||
""" Depicts the capacity of the procurement workflow to deal with production of services.
|
||||
By default, it's False. Overwritten by project_mrp module.
|
||||
"""
|
||||
return False
|
||||
|
||||
def check_produce_product(self, cr, uid, procurement, context=None):
|
||||
""" Finds BoM of a product if not found writes exception message.
|
||||
@param procurement: Current procurement.
|
||||
@return: True or False.
|
||||
""" Depicts the capacity of the procurement workflow to deal with production of products.
|
||||
By default, it's False. Overwritten by mrp module.
|
||||
"""
|
||||
return False
|
||||
|
||||
|
@ -274,7 +276,8 @@ class procurement_order(osv.osv):
|
|||
return True
|
||||
|
||||
def check_buy(self, cr, uid, ids):
|
||||
"""ability of the workflow to manage the supply_method == 'buy'.
|
||||
""" Depicts the capacity of the procurement workflow to manage the supply_method == 'buy'.
|
||||
By default, it's False. Overwritten by purchase module.
|
||||
"""
|
||||
return False
|
||||
|
||||
|
|
|
@ -159,6 +159,11 @@
|
|||
</record>
|
||||
|
||||
<record id="trans_confirm_mto_make_done" model="workflow.transition">
|
||||
<!-- This transition is there to unblock products that would be in MTO with a supply method that would be
|
||||
produce or buy without MRP or purchase module installed. These modules overwrite the check_produce()
|
||||
and check_buy() methods -so that it invalidates their part of this 'bypass transition'-, and define
|
||||
their own workflow paths.
|
||||
-->
|
||||
<field name="act_from" ref="act_confirm_mto"/>
|
||||
<field name="act_to" ref="act_make_done"/>
|
||||
<field name="condition">not check_produce() and not check_buy()</field>
|
||||
|
|
Loading…
Reference in New Issue