[IMP] Combined the second message posts in one.
bzr revid: psa@tinyerp.com-20130214094724-vwxhd13erdhwmk3m
This commit is contained in:
parent
89d45ad9ec
commit
b581d65253
|
@ -163,6 +163,7 @@ class purchase_order(osv.osv):
|
|||
'state': {
|
||||
'purchase.mt_rfq_confirmed': lambda self, cr, uid, obj, ctx=None: obj['state'] == 'confirmed',
|
||||
'purchase.mt_rfq_approved': lambda self, cr, uid, obj, ctx=None: obj['state'] == 'approved',
|
||||
'purchase.mt_rfq_invoice_paid': lambda self, cr, uid, obj, ctx=None: obj['state'] == 'done',
|
||||
},
|
||||
}
|
||||
_columns = {
|
||||
|
@ -557,7 +558,7 @@ class purchase_order(osv.osv):
|
|||
|
||||
def invoice_done(self, cr, uid, ids, context=None):
|
||||
self.write(cr, uid, ids, {'state':'approved'}, context=context)
|
||||
self.message_post(cr, uid, ids, body=_("Invoice <b>Paid.</b>"), context=context)
|
||||
# self.message_post(cr, uid, ids, body=_("Invoice <b>Paid.</b>"), context=context)
|
||||
return True
|
||||
|
||||
def has_stockable_product(self, cr, uid, ids, *args):
|
||||
|
|
|
@ -60,6 +60,10 @@
|
|||
<field name="default" eval="False"/>
|
||||
<field name="res_model">purchase.order</field>
|
||||
</record>
|
||||
|
||||
<record id="mt_rfq_invoice_paid" model="mail.message.subtype">
|
||||
<field name="name">Invoice Paid</field>
|
||||
<field name="default" eval="False"/>
|
||||
<field name="res_model">purchase.order</field>
|
||||
</record>
|
||||
</data>
|
||||
</openerp>
|
||||
|
|
Loading…
Reference in New Issue