slashmili / django-jalali

Jalali DateField support for Django model
http://pypi.python.org/pypi/django_jalali
BSD 3-Clause "New" or "Revised" License
254 stars 53 forks source link

Problem is in 31-day months #193

Closed mshzsh closed 1 year ago

mshzsh commented 2 years ago

serilizers.py :

from django_jalali.serializers.serializerfield
import JDateTimeField
rsd = JDateTimeField(required=False)

models.py :

rsd = jmodels.jDateTimeField(null=True)

input data : 1401-6-31 00:00

error : Enter a valid date/time in YYYY-MM-DD HH:MM[:ss[.uuuuuu]] format.

But it works correctly with date 1401-6-30 00:00

hramezani commented 1 year ago

Thanks @mshzsh for reporting!

I've created https://github.com/slashmili/django-jalali/pull/201 to fix the problem. Please take a look and test it if you have time.

mshzsh commented 1 year ago

Yes, I tested the changes of this commit and the problem was solved, thank you @hramezani . Due to the problems that have arisen in some of our projects, we are impatiently waiting for the new force update.

slashmili commented 1 year ago

Thanks @hramezani

The changes are pushed https://pypi.org/project/django-jalali/6.0.1/