@wiki_content_url = url_for(:controller => 'wiki', :action => 'show',
:project_id => wiki_content.project,
:id => wiki_content.page.title)
- mail :to => user,
- :subject => "[#{wiki_content.project.name}] #{l(:mail_subject_wiki_content_added, :id => wiki_content.page.pretty_title)}"
+ mail(
+ :to => user,
+ :subject =>
+ "[#{wiki_content.project.name}] #{l(:mail_subject_wiki_content_added, :id => wiki_content.page.pretty_title)}"
+ )
end
# Notifies users about a new wiki content (wiki page added).
message_id wiki_content
@wiki_content = wiki_content
@user = user
- @wiki_content_url = url_for(:controller => 'wiki', :action => 'show',
- :project_id => wiki_content.project,
- :id => wiki_content.page.title)
- @wiki_diff_url = url_for(:controller => 'wiki', :action => 'diff',
- :project_id => wiki_content.project, :id => wiki_content.page.title,
- :version => wiki_content.version)
- mail :to => user,
- :subject => "[#{wiki_content.project.name}] #{l(:mail_subject_wiki_content_updated, :id => wiki_content.page.pretty_title)}"
+ @wiki_content_url =
+ url_for(:controller => 'wiki', :action => 'show',
+ :project_id => wiki_content.project,
+ :id => wiki_content.page.title)
+ @wiki_diff_url =
+ url_for(:controller => 'wiki', :action => 'diff',
+ :project_id => wiki_content.project, :id => wiki_content.page.title,
+ :version => wiki_content.version)
+ mail(
+ :to => user,
+ :subject =>
+ "[#{wiki_content.project.name}] #{l(:mail_subject_wiki_content_updated, :id => wiki_content.page.pretty_title)}"
+ )
end
# Notifies users about the update of the specified wiki content
user_ids = options[:users]
- scope = Issue.open.where("#{Issue.table_name}.assigned_to_id IS NOT NULL" +
- " AND #{Project.table_name}.status = #{Project::STATUS_ACTIVE}" +
- " AND #{Issue.table_name}.due_date <= ?", days.day.from_now.to_date
- )
+ scope =
+ Issue.open.where(
+ "#{Issue.table_name}.assigned_to_id IS NOT NULL" \
+ " AND #{Project.table_name}.status = #{Project::STATUS_ACTIVE}" \
+ " AND #{Issue.table_name}.due_date <= ?", days.day.from_now.to_date
+ )
scope = scope.where(:assigned_to_id => user_ids) if user_ids.present?
scope = scope.where(:project_id => project.id) if project
scope = scope.where(:fixed_version_id => target_version_id) if target_version_id.present?