Se rendre au contenu
Menu
Cette question a été signalée
1 Répondre
4201 Vues

Hello,

I have a class "task" with one field "taskname".

_columns={
    'taskname':fields.char('Task',size= 32 ,required=True),
}

I have also a relation to the task.

_columns={
    'task_id':fields.many2one('gestion.tasks', 'Task', readonly=False, relate=True),
}

But in the view I have "model,id" and not the task name.

How can I show the taskname and not the ID in my view?

Thanks.

Avatar
Ignorer
Meilleure réponse

You have 2 possibilities:

1- Rename the taskname field by name

2- Add the _rec_name attribute to your class like this: _rec_name: "taskname"

Avatar
Ignorer
Publications associées Réponses Vues Activité
0
oct. 23
1249
3
avr. 20
3443
1
févr. 20
2176
4
mars 15
7547
1
juil. 25
293