[IMP] procurement: Products reserverd from stock & added Manufucture Order in procurement.

bzr revid: tta@openerp.com-20121003094341-suosaw2sum3grn7k
This commit is contained in:
Tejas Tank
2012-10-03 15:13:41 +05:30
parent 0f534670ea
commit 9c2ca851e2
4 changed files with 4 additions and 5 deletions
+1
View File
@@ -954,6 +954,7 @@
<data>
<xpath expr="//field[@name='move_id']" position="before">
<field name="bom_id" domain="[('product_id','=',product_id),('bom_id','=',False)]"/>
<field name="production_id"/>
</xpath>
<xpath expr="//field[@name='close_move']" position="after">
<group colspan="4" groups="product.group_mrp_properties">
+1 -1
View File
@@ -362,7 +362,7 @@ class procurement_order(osv.osv):
""" Changes procurement state to Running and writes message.
@return: True
"""
message = _('From stock: products assigned.')
message = _('Products reserverd from stock.')
self.write(cr, uid, ids, {'state': 'running',
'message': message}, context=context)
self.message_post(cr, uid, ids, body=message, context=context)
+1 -2
View File
@@ -84,8 +84,7 @@ class procurement_order(osv.osv):
'project_id': project and project.id or False,
'company_id': procurement.company_id.id,
},context=context)
self.write(cr, uid, [procurement.id], {'task_id': task_id, 'state': 'running', 'message':'from project: task created.'}, context=context)
self.document_send_note(cr, uid, [procurement.id], body='%s %s:%s %s' % (_("Task"), procurement.origin or '', procurement.product_id.name, _("created")), context=context)
self.write(cr, uid, [procurement.id], {'task_id': task_id, 'state': 'running', 'message':'from project: task created.'}, context=context)
self.project_task_create_note(cr, uid, ids, context=context)
return task_id
+1 -2
View File
@@ -1082,8 +1082,7 @@ class procurement_order(osv.osv):
}
res[procurement.id] = self.create_procurement_purchase_order(cr, uid, procurement, po_vals, line_vals, context=new_context)
self.write(cr, uid, [procurement.id], {'state': 'running', 'purchase_id': res[procurement.id]})
self.document_send_note(cr, uid, [procurement.id], body='%s %s %s' % (_("Draft Purchase Order"), name or '', _("created")), context=context)
self.purchase_order_create_note(self, cr, uid, ids, context=context)
self.purchase_order_create_note(cr, uid, ids, context=context)
return res
def purchase_order_create_note(self, cr, uid, ids, context=None):