Skip to Content
Menu
This question has been flagged

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
Discard
Best Answer

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
Discard
Author

Hii Goood,very useful, thanks for your help

Related Posts Replies Views Activity
1
Jul 16
5868
8
May 23
61567
4
Feb 23
71882
2
Jul 18
7095
2
Feb 18
6971