From a264e707a81693a78d69165a628a34f967ef06f8 Mon Sep 17 00:00:00 2001 From: Rick Barrette Date: Sat, 3 Sep 2016 09:15:37 -0400 Subject: [PATCH] Update issue_patch.rb --- lib/issue_patch.rb | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/issue_patch.rb b/lib/issue_patch.rb index df4b944..24f9e41 100644 --- a/lib/issue_patch.rb +++ b/lib/issue_patch.rb @@ -91,6 +91,12 @@ module IssuePatch end end + # Create a shareable link for a customer + def share_link + token = DownloadToken.create(:expires_at => Time.now + 24.hours, :issue_id => id) + link_to "#{tracker} ##{id}: #{subject}", view_path token.token + end + end # Add module to Issue