Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
2948 Zobrazení

class modelA(models.Model):

_name='model.a'

code = fields.Char('Description: ')

subject =   fields.Char('Subject: ')

def action_button(self):

data = {

'ids': self.ids,
'model': 'stock.move',
'form': self.read(['start_date', 'end_date', 'route', 'salesman'])[0]

}

#code to pass data

return ?


class modelB(models.Model):

_name='model.b'

def print_data(self,code,subject):

x = (code,subject)

return x


How can i pass the  field values from class A to B? Thank u in advance for the help :)


Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
3
lis 24
30835
1
pro 21
3157
0
pro 21
2731
0
dub 15
5048
2
bře 15
10792