theroozbeh / vue2-persian-datepicker

A vue component that provides datepicker for persian developers
MIT License
100 stars 18 forks source link

Date formatting not work properly #28

Closed MINASHIJ closed 5 years ago

MINASHIJ commented 5 years ago

hi and thanks for your greate library. I change the Date formatting, in input i see the Date formatting that i used, but the value is not the same , and is in 'yyyy/M/d' format. for example i use this:

but "this.followdate" value is in 'yyyy/M/d' format for more information , i select date and it shows : ۱۳۹۷/۰۴/۰۲ but the input value is: ۱۳۹۷/۴/۲ please help me, i need to solve this problem.

theroozbeh commented 5 years ago

Hi take a look at this fiddle. according to this, formatting is working properly. If this fiddle wouldn't solve your problem please provide more of your code, so I could figure what is wrong.

MINASHIJ commented 5 years ago

may i type in farsi?

MINASHIJ commented 5 years ago

please see this page : https://dyonir.github.io/vue2-persian-datepicker/ تاریخ انتخاب شده is always in " yyyy/M/d " format. but i need to be in "yyyy/MM/dd" format.

theroozbeh commented 5 years ago

Yeap sure, type in Persian

On Mon, Jul 9, 2018, 8:01 PM MINASHIJ notifications@github.com wrote:

please see this page : https://dyonir.github.io/vue2-persian-datepicker/ تاریخ انتخاب شده is always in " yyyy/M/d " format. but i need to be in "yyyy/MM/dd" format.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/dyonir/vue2-persian-datepicker/issues/28#issuecomment-403520181, or mute the thread https://github.com/notifications/unsubscribe-auth/AGZ_EcHjPnvj9hHwPDQdo5xLeu_iBQcRks5uE3c4gaJpZM4VHsBn .

theroozbeh commented 5 years ago

Ok! I understand now... Unfortunately, currently, formatting only applies to user input of the component. I'll fix this in the next release