def merch_month
      # TODO: This is very inefficient, but less complex than strategic guessing
      # maybe switch to a binary search or something
      merch_year = calendar.merch_year_from_date(date)
      @merch_month ||= (1..12).detect do |num|
        calendar.end_of_month(merch_year, num) >= date && date >= calendar.start_of_month(merch_year, num)
      end
    end
def merch_month
      # TODO: This is very inefficient, but less complex than strategic guessing
      # maybe switch to a binary search or something
      merch_year = calendar.merch_year_from_date(date)
      @merch_month ||= (1..12).detect do |num|
        calendar.end_of_month(merch_year, num) >= date && date >= calendar.start_of_month(merch_year, num)
      end
    end
This returns the "merch month" number for a date
 Month 1 is Feb for the retail calendar
 Month 1 is August for the fiscal calendar

 @return [Integer]