在瞬间重复使用多个规则无法正常工作
我正在使用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 }
我怎样才能使它工作? 还有其他方法可以处理多个规则吗?
谢谢!
- 使用JavaScript API将jsonix JSON模式转换为ElasticSearchtypes映射
- Night-watch.js安装错误?
- 添加Java脚本库作为npm依赖关系还是简单地将它们包含在HTML中有什么区别?
- 'session'是未定义的 – Este JS / Express / Redis会话存储
- 从JSON中读取数据,操作并将其写回到NodeJs中
- 当mysql查询asynchronous瀑布不按顺序
- 通过键名获取值mongodb node.js驱动程序
- 如何使用express js创build一个简单的html服务器
- Node.js – 在pipe道响应之前检查stream是否有错误