在我的BsDaterange选择器中,我希望禁用将来的日期,
虽然我这样做是正确的,但当我单击当前日期时,它会跳转到未来的月份,这不是一个好的做法。
重构:-请点击今天的current Date,它不应该跳到未来的一个月,
<input type="text"
placeholder="Daterangepicker"
class="form-control"
bsDaterangepicker
[bsConfig]="{ showPreviousMonth: true }"
[maxDate]="maxDate"
>.ts
maxDate = new Date();工作演示-- Stackblitz
https://stackblitz.com/edit/angular-cxy5xw?file=app%2Fshow-previous-month.html
发布于 2021-04-07 22:51:43
我认为,您想要的功能很快就可以通过this PR提供
https://stackoverflow.com/questions/66009870
复制相似问题