Skip to content

Commit

Permalink
feat: add support for relative recurring monthly
Browse files Browse the repository at this point in the history
  • Loading branch information
stakach committed Jun 30, 2023
1 parent e11d60d commit 0eed0df
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion shard.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: office365
version: 1.20.1
version: 1.21.0

crystal: ">= 0.36.1"

Expand Down
5 changes: 4 additions & 1 deletion src/models/recurrence_param.cr
Original file line number Diff line number Diff line change
@@ -1,12 +1,15 @@
require "./recurrence_pattern"

module Office365
class RecurrenceParam
property pattern : String
property range_end : Time
property interval : Int32?
property index : WeekIndex?
property days_of_week : Array(String)
property first_day_of_week : Office365::DayOfWeek?

def initialize(@pattern : String, @range_end : Time, @interval : Int32? = 1, @days_of_week : Array(String) = [] of String, first_day_of_week : String? = nil)
def initialize(@pattern : String, @range_end : Time, @interval : Int32? = 1, @days_of_week : Array(String) = [] of String, first_day_of_week : String? = nil, @index : WeekIndex? = nil)
@first_day_of_week = first_day_of_week ? Office365::DayOfWeek.parse(first_day_of_week) : Office365::DayOfWeek::Sunday
end
end
Expand Down

0 comments on commit 0eed0df

Please sign in to comment.