Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorImre Farkas <ifarkas@gitlab.com>2018-05-31 17:01:04 +0300
committerDouwe Maan <douwe@gitlab.com>2018-05-31 17:01:04 +0300
commit20dfe25c151cc883ce0d38b67125b5ca41e6d422 (patch)
tree9a29f05a241713f3488e6bc2e5df03c07300ef45 /app/helpers/calendar_helper.rb
parent2fdd8982f8204340e6413a57f46e6c41d8ecb429 (diff)
Export assigned issues in iCalendar feed
Diffstat (limited to 'app/helpers/calendar_helper.rb')
-rw-r--r--app/helpers/calendar_helper.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/app/helpers/calendar_helper.rb b/app/helpers/calendar_helper.rb
new file mode 100644
index 00000000000..c54b91b0ce5
--- /dev/null
+++ b/app/helpers/calendar_helper.rb
@@ -0,0 +1,8 @@
+module CalendarHelper
+ def calendar_url_options
+ { format: :ics,
+ feed_token: current_user.try(:feed_token),
+ due_date: Issue::DueNextMonthAndPreviousTwoWeeks.name,
+ sort: 'closest_future_date' }
+ end
+end