重新点击时不应显示所选日期,我想再次点击此日期选择
<span class="RegistrationDate">Registration Date</span>
<div class=" col-sm-8 col-md-4 col-lg-4 input-group date" id="dateofRegistration" style="padding-top: 10px;">
<input placeholder="DD/MM/YYYY" type="text" class="form-control" id="datepicker1">
<div class="input-group-addon" for="datepicker">
<i class="fa fa-calendar"></i>
</div>
</div>
<script>
var date = new Date();
var today = new Date(date.getFullYear(), date.getMonth(), date.getDate());
var end = new Date(date.getFullYear(), date.getMonth(), date.getDate());
$('#dateofRegistration').datepicker({
format: "dd-MM-yyyy", //"dd-MM-yyyy",
todayHighlight: true,
minDate: 0,
autoclose: true,
endDate: '+0d'
});
$('#dateofRegistration').datepicker('setDate', today);
</script>