Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
1 Odpowiedz
1153 Widoki
Model patient:
def open_form(self):
return{
'type': 'ir.actions.act_window',
'res_model': 'model.appoint',
'view_mode': 'form',
'context':{'default_patient_name': self.id
}
}

model model.appoint:

patient_name =field.many2one("patient")


Awatar
Odrzuć
Autor

@Niyas Raphy
i try to add 'target': 'new'
but srill not work

Najlepsza odpowiedź

HI,
Written code seems to by fine, can you ensure that service has been restarted after adding the context.

Can you add                 'target': 'new' in the return dict and see if that makes any difference.


Thanks

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
0
lip 22
2271
3
wrz 20
2945
2
gru 15
4588
0
mar 15
3270
2
mar 15
6400