Closed rahimramezanian closed 4 years ago
In https://github.com/dyonir/vue2-persian-datepicker/blob/44f38f2ed821db2c468045f167c61922063936da/src/components/PDatePicker.vue
part mounted
change the code below
if(this.inputCheck(this.value)){
this.inputChanged(this.value);
} else if(this.isToDayInRange()){
this.goToToday();
} else {
this.goToMonth(this.startAvailableDateV.year , this.startAvailableDateV.month - 1, this.startAvailableDateV.day);
}
to
if(this.inputCheck(this.value)){
this.inputChanged(this.value);
} else if(this.isToDayInRange()){
this.goToToday();
} else {
let ymd = this.availableDateEnd.split("/").map(x => parseInt(x));
this.goToMonth(ymd[0] , ymd[1]-1, ymd[2]);
}
If I set
availableDates="true"
when we open the dialog to chnage the map by default it shows first month of year 1300.