Add auto_now attrs to date and time model fields (#1210)

Co-Authored-By: Ben Nace <ben2701@verizon.net>

Co-authored-by: Ben Nace <ben2701@verizon.net>
This commit is contained in:
Adam Johnson
2022-10-27 18:52:48 +01:00
committed by GitHub
parent f9fbeb0f9b
commit efebe22397

View File

@@ -456,6 +456,8 @@ class DateField(DateTimeCheckMixin, Field[_ST, _GT]):
_pyi_private_set_type: Union[str, date, Combinable]
_pyi_private_get_type: date
_pyi_lookup_exact_type: Union[str, date]
auto_now: bool
auto_now_add: bool
def __init__(
self,
verbose_name: Optional[_StrOrPromise] = ...,
@@ -484,6 +486,8 @@ class DateField(DateTimeCheckMixin, Field[_ST, _GT]):
class TimeField(DateTimeCheckMixin, Field[_ST, _GT]):
_pyi_private_set_type: Union[str, time, real_datetime, Combinable]
_pyi_private_get_type: time
auto_now: bool
auto_now_add: bool
def __init__(
self,
verbose_name: Optional[_StrOrPromise] = ...,