In my Laravel-5.8 application, I am using jQuery-1.12.4 for my datepicker
I have Leave Commencement Date and Leave Resumption Date
<div class="col-sm-4">
<div class="form-group">
<label>Commencement Date:<span style="color:red;">*</span></label>
<input type="text" id="commencement_date" class="form-control" placeholder="dd/mm/yyyy" name="commencement_date" value="{{old('commencement_date')}}" >
</div>
</div>
<div class="col-sm-4">
<div class="form-group">
<label>Resumption Date:<span style="color:red;">*</span></label>
<input type="text" id="resumption_date" class="form-control" placeholder="dd/mm/yyyy" name="resumption_date" value="{{old('resumption_date')}}" >
</div>
</div>
<script type="text/javascript">
$(document).ready(function() {
$(function () {
$('#commencement_date').datepicker({
dateFormat: 'dd-mm-yy',
});
$('#resumption_date').datepicker({
dateFormat: 'dd-mm-yy',
});
});
});
</script>
How do I make:
Minimum Date in Commencement Date to be current day and Max. Date to be Last Day of the year
Minimum Date in Resumption Date to be current day + 1 (add a day to current day) and Max. Date to be Last Day of the year
Thanks