I'm working on a django project, where the user need to pick the dates for applying leaves. So, I have included the below code in my base.html. I have no basic knowledge in javascript but some how i came up how to disable weekends.
<script>
    $(document).ready(function() {
        $('.datepicker').datepicker(
          {
            minDate : 0,
            beforeShowDay : $.datepicker.noWeekends
          }
        );
    });
    </script>
I have list of custom dates in db which are declared as holidays and I want them to be disabled in the datepicker, provided with weekends as disabled too.