Skip ke Konten
Menu
Pertanyaan ini telah diberikan tanda
1 Balas
4313 Tampilan

i've created a module named "appointement" that have as fields -start-datetime- finish-datetime ... 

but when i try to overide the function name_get i got this error "AttributeError: type object 'appointment' has no attribute 'id'"

@api.multi
def name_get(self):
result=[]
for rd in self:
name=rd.sujet+' faite par :'+rd.agent_id.name
result.append((appointment.id,name))
return result
Avatar
Buang
Jawaban Terbai

replace appointment.id with rd.id

Avatar
Buang
Post Terkait Replies Tampilan Aktivitas
0
Mar 15
5556
name_get Diselesaikan
2
Jul 24
11338
0
Mar 15
4968
1
Feb 25
3948
1
Jan 24
1739