just want to correct myself
after comparing a printable with not printable line I believe it's not data dependant.
the lines with fixed text from the following statement are printable the others not.
def _partner_name(self, cr, uid, ids, field_name, arg, context={}):
result = {}
for partner in self.browse(cr, uid, ids, context): #pname=''
pname = None
if partner.partner_id and not (partner.sale_line_id or partner.purchase_line_id) : pname = partner.partner_id.name
if partner.sale_line_id: pname = partner.sale_line_id.order_id.partner_id.name
if partner.purchase_line_id: pname = partner.purchase_line_id.order_id.partner_id.name
if not pname and partner.location_id.usage == 'internal':
if partner.location_dest_id.usage == 'production': pname = ' Used for Production'
if partner.location_dest_id.usage == 'inventory': pname = ' Inventory'
if partner.location_dest_id.usage == 'internal': pname = ' Internal'
if not pname and (partner.location_id.usage == 'production' and partner.location_dest_id.usage == 'internal' ): pname = ' Production'
just want to correct myself
after comparing a printable with not printable line I believe it's not data dependant.
the lines with fixed text from the following statement are printable the others not.
def _partner_name(self, cr, uid, ids, field_name, arg, context={}):
# pname=' ' sale_line_ id or partner. purchase_ line_id) :
pname = partner. partner_ id.name sale_line_ id:
pname = partner. sale_line_ id.order_ id.partner_ id.name purchase_ line_id:
pname = partner. purchase_ line_id. order_id. partner_ id.name location_ id.usage == 'internal': location_ dest_id. usage == 'production':
pname = ' Used for Production' location_ dest_id. usage == 'inventory':
pname = ' Inventory' location_ dest_id. usage == 'internal':
pname = ' Internal' location_ id.usage == 'production' and partner. location_ dest_id. usage == 'internal' ):
pname = ' Production'
result = {}
for partner in self.browse(cr, uid, ids, context):
pname = None
if partner.partner_id and not (partner.
if partner.
if partner.
if not pname and partner.
if partner.
if partner.
if partner.
if not pname and (partner.
return result
....
'partner_ name' : fields. function( _partner_ name, method=True, string= "Partner" ,type=' char', size=132,store=True ),