do u have an example
for instance:
addr_obj = self.pool.get('res.partner.address').browse(cr, uid, contact_id)
(this is from wiki to get partner contact name)
how do i call this from my module (at the moment i want to get the receivable
account number and display it through message box (by raising error).
gen_invoice will be called from the button in the xml file.
class umbrella_geninvoice(osv.osv):
_name = 'umbrella.geninvoice'
_columns = {
'sdate': fields.date('Start Date'),
'edate': fields.date('End Date'),
}
def gen_invoice(self, cr, uid, ids, context=None):
partner_obj = self.pool.get('res.partner').browse(cr, uid,
partner_id)
recv_acc = partner_obj.??
raise osv.except_osv('Receivable Account', recv_acc)
thanks
khalid
-------------------- m2f --------------------
--
http://www.openobject.com/forum/viewtopic.php?p=49855#49855
-------------------- m2f --------------------
_______________________________________________
Tinyerp-users mailing list
http://tiny.be/mailman2/listinfo/tinyerp-users