I’m setting a default follow-up date two days from current date, which currently works:
const Notify = moment().add(2, 'days').toDate();
However, I would like to exclude weekends. So I installed moment WeekDay, but I can’t seem to get it to work with adding days to the current date. The documentation calls for:
But I can’t get that to work with adding in two days forward. Any ideas?
It should help you.
var momentBusinessDays = require("moment-business-days") momentBusinessDays('20-09-2018', 'DD-MM-YYYY').businessAdd(3)._d
Tue Sep 25 2018 00:00:00 GMT+0530 (IST)