Closed sherafatian closed 6 years ago
Your functions are wrong. You passed shamsi parsed arguments to DateTime constrcutor
>>> \Morilog\Jalali\jDateTime::toJalali(2018, 5, 20);
=> [
1397,
2,
30,
]
>>> \Morilog\Jalali\jDateTime::toGregorian(1397, 2, 30);
=> [
2018,
5,
20,
]
this package convert 1397/02/30 to 2018-05-20 that it's correct but convert 2018-05-20 to 1397/03/02 that means wrong. See my functions that do this:
And