在瞬间重复使用多个规则无法正常工作
我正在使用moment-recur
包,我试图创build一个根据一些规则发生的所有date的数组。 为此,我正在使用recurrence.all("L")
。
使用下一个对象调用此方法将返回一个空数组:
{ start: moment.utc("2018-01-04T22:00:00.000+00:00"), end: moment.utc("2019-01-04T22:00:00.000+00:00"), rules: [ { measure: 'daysOfWeek', units: { '0': true, '1': true, '5': true}}, { measure: 'weeks', units:{ '2': true } } ], exceptions: [], units: null, measure: null, from: null }
我怎样才能使它工作? 还有其他方法可以处理多个规则吗?
谢谢!