Pular para o conteúdo
Menu
Esta pergunta foi sinalizada
1 Responder
6426 Visualizações

I have a field type datetime.

date=fields.Datetime('Request date',default=fields.Date.today, required=True,readonly=True,copy=True)

When I duplicate, the field date copy the date of created not the current date when I duplicate.

I want to duplicate the field with current date. Can I duplicate the date with the current date?


Avatar
Cancelar
Melhor resposta

hello,

You may try like this(copy=False):

date=fields.Datetime('Request date',default=fields.Date.today, required=True,readonly=True,copy=False)

Hope this will help you.

Avatar
Cancelar
Autor

Hii Goood,very useful, thanks for your help

Publicações relacionadas Respostas Visualizações Atividade
1
jul. 16
5865
8
mai. 23
61562
4
fev. 23
71879
2
jul. 18
7093
2
fev. 18
6968