Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
gitlab-ce
Commits
09caa7c8
Commit
09caa7c8
authored
Jan 07, 2012
by
Valery Sizov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
More descriptive subject in notification message
parent
dae9cd2a
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
app/mailers/notify.rb
app/mailers/notify.rb
+6
-6
No files found.
app/mailers/notify.rb
View file @
09caa7c8
...
@@ -29,7 +29,7 @@ class Notify < ActionMailer::Base
...
@@ -29,7 +29,7 @@ class Notify < ActionMailer::Base
@project
=
note
.
project
@project
=
note
.
project
@commit
=
@project
.
repo
.
commits
(
note
.
noteable_id
).
first
@commit
=
@project
.
repo
.
commits
(
note
.
noteable_id
).
first
return
unless
(
note
.
notify
or
(
note
.
notify_author
and
@commit
.
author
.
email
==
@user
.
email
)
)
return
unless
(
note
.
notify
or
(
note
.
notify_author
and
@commit
.
author
.
email
==
@user
.
email
)
)
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
#{
@note
.
project
.
name
}
"
)
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
note for commit |
#{
@note
.
project
.
name
}
"
)
end
end
def
note_merge_request_email
(
user
,
note
)
def
note_merge_request_email
(
user
,
note
)
...
@@ -37,7 +37,7 @@ class Notify < ActionMailer::Base
...
@@ -37,7 +37,7 @@ class Notify < ActionMailer::Base
@note
=
note
@note
=
note
@project
=
note
.
project
@project
=
note
.
project
@merge_request
=
note
.
noteable
@merge_request
=
note
.
noteable
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
#{
@note
.
project
.
name
}
"
)
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
note for merge request |
#{
@note
.
project
.
name
}
"
)
end
end
def
note_issue_email
(
user
,
note
)
def
note_issue_email
(
user
,
note
)
...
@@ -45,14 +45,14 @@ class Notify < ActionMailer::Base
...
@@ -45,14 +45,14 @@ class Notify < ActionMailer::Base
@note
=
note
@note
=
note
@project
=
note
.
project
@project
=
note
.
project
@issue
=
note
.
noteable
@issue
=
note
.
noteable
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
#{
@note
.
project
.
name
}
"
)
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
note for issue
#{
@issue
.
id
}
|
#{
@note
.
project
.
name
}
"
)
end
end
def
new_merge_request_email
(
merge_request
)
def
new_merge_request_email
(
merge_request
)
@user
=
merge_request
.
assignee
@user
=
merge_request
.
assignee
@merge_request
=
merge_request
@merge_request
=
merge_request
@project
=
merge_request
.
project
@project
=
merge_request
.
project
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
#{
@merge_request
.
title
}
"
)
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
new merge request |
#{
@merge_request
.
title
}
"
)
end
end
def
changed_merge_request_email
(
user
,
merge_request
)
def
changed_merge_request_email
(
user
,
merge_request
)
...
@@ -60,7 +60,7 @@ class Notify < ActionMailer::Base
...
@@ -60,7 +60,7 @@ class Notify < ActionMailer::Base
@assignee_was
||=
User
.
find
(
merge_request
.
assignee_id_was
)
@assignee_was
||=
User
.
find
(
merge_request
.
assignee_id_was
)
@merge_request
=
merge_request
@merge_request
=
merge_request
@project
=
merge_request
.
project
@project
=
merge_request
.
project
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
#{
@merge_request
.
title
}
"
)
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
merge request changed |
#{
@merge_request
.
title
}
"
)
end
end
def
changed_issue_email
(
user
,
issue
)
def
changed_issue_email
(
user
,
issue
)
...
@@ -68,6 +68,6 @@ class Notify < ActionMailer::Base
...
@@ -68,6 +68,6 @@ class Notify < ActionMailer::Base
@assignee_was
||=
User
.
find
(
issue
.
assignee_id_was
)
@assignee_was
||=
User
.
find
(
issue
.
assignee_id_was
)
@issue
=
issue
@issue
=
issue
@project
=
issue
.
project
@project
=
issue
.
project
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
#{
@issue
.
title
}
"
)
mail
(
:to
=>
@user
.
email
,
:subject
=>
"gitlab |
changed issue |
#{
@issue
.
title
}
"
)
end
end
end
end
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment