rosa-build/app/views/home/partials/_git_new_push_notification....

21 lines
1.2 KiB
Plaintext

-user= User.where(:email => user_email).first || User.new(:email => user_email) if defined?(user_email)
.top
.image= link_to(image_tag(avatar_url(user, :small), :alt => 'avatar'), user_path(user)) if user.try(:persisted?)
.text
%span
-_user_link = defined?(user_email) ? user_link(user, defined?(user_name) ? user_name : user_email) : nil
= raw t("notifications.bodies.#{change_type}_branch", {:branch_name => branch_name, :user_link => _user_link})
= raw t("notifications.bodies.project", :project_link => link_to("#{project_owner}/#{project_name}", project_path(project_owner, project_name)) )
.both
%span.date= activity_feed.created_at
.both
%span.subject
- last_commits.each do |commit|
= link_to shortest_hash_id(commit[0]), commit_path(project_owner, project_name, commit[0])
= commit[1]
%br
- if defined? other_commits
-pluralize = t('layout.commits.pluralize').map {|base, title| title.to_s}
%br
=link_to t('notifications.bodies.more_commits', :count => other_commits_count, :commits => Russian.p(other_commits_count, *pluralize)), diff_path(project_owner, project_name, :diff => other_commits)