Commit c6a9f4a51a5199121387ca705b97a485f1f92b20
1 parent
a09de0d8
Exists in
master
and in
1 other branch
add helper to generate urls at a single point
Showing
1 changed file
with
5 additions
and
1 deletions
Show diff stats
app/models/notification_service.rb
... | ... | @@ -8,7 +8,7 @@ class NotificationService |
8 | 8 | field :api_token, :type => String |
9 | 9 | field :subdomain, :type => String |
10 | 10 | field :sender_name, :type => String |
11 | - | |
11 | + | |
12 | 12 | embedded_in :app, :inverse_of => :notification_service |
13 | 13 | |
14 | 14 | validate :check_params |
... | ... | @@ -34,4 +34,8 @@ class NotificationService |
34 | 34 | def configured? |
35 | 35 | api_token.present? |
36 | 36 | end |
37 | + | |
38 | + def problem_url(problem) | |
39 | + "http://#{Errbit::Config.host}/apps/#{problem.app.id}/problems/#{problem.id}" | |
40 | + end | |
37 | 41 | end | ... | ... |