##// END OF EJS Templates
emails: optimize some labels, and made few i18n fixes....
marcink -
r532:7cb56fd9 default
parent child Browse files
Show More
@@ -1,11 +1,25 b''
1 ## -*- coding: utf-8 -*-
1 ## -*- coding: utf-8 -*-
2 <%inherit file="base.mako"/>
2 <%inherit file="base.mako"/>
3
3
4
4 <%def name="subject()" filter="n,trim">
5 <%def name="subject()" filter="n,trim">
5 ${_('[mention]') if mention else ''} ${_('%(user)s commented on a commit of %(repo_name)s') % {
6 <%
6 'user': h.person(user),
7 data = {
7 'repo_name': repo_name
8 'user': h.person(user),
8 } }
9 'comment_file': comment_file,
10 'comment_line': comment_line,
11 'repo_name': repo_name,
12 'commit_id': h.show_id(commit),
13 }
14 %>
15 ${_('[mention]') if mention else ''} \
16
17 % if comment_file:
18 ${_('%(user)s commented on commit `%(commit_id)s` (file: `%(comment_file)s`)') % data} ${_('in the %(repo_name)s repository') % data}
19 % else:
20 ${_('%(user)s commented on commit `%(commit_id)s`') % data |n} ${_('in the %(repo_name)s repository') % data}
21 % endif
22
9 </%def>
23 </%def>
10
24
11 <%def name="body_plaintext()" filter="n,trim">
25 <%def name="body_plaintext()" filter="n,trim">
@@ -31,18 +45,30 b''
31 ${self.plaintext_footer()}
45 ${self.plaintext_footer()}
32 </%def>
46 </%def>
33
47
48
49 <%
50 data = {
51 'user': h.person(user),
52 'comment_file': comment_file,
53 'comment_line': comment_line,
54 'repo': commit_target_repo,
55 'repo_name': repo_name,
56 'commit_id': h.show_id(commit),
57 }
58 %>
34 <table style="text-align:left;vertical-align:middle;">
59 <table style="text-align:left;vertical-align:middle;">
35 <tr><td colspan="2" style="width:100%;padding-bottom:15px;border-bottom:1px solid #dbd9da;"><h4><a href="${commit_comment_url}" style="color:#427cc9;text-decoration:none;cursor:pointer">
60 <tr><td colspan="2" style="width:100%;padding-bottom:15px;border-bottom:1px solid #dbd9da;">
36 % if comment_file:
61 % if comment_file:
37 ${_('%(user)s commented on %(comment_file)s on line %(comment_line)s</a> in the %(repo)s repository') % {'user': h.person(user), 'comment_file': comment_file, 'comment_line': comment_line, 'repo': commit_target_repo} |n}</h4>
62 <h4><a href="${commit_comment_url}" style="color:#427cc9;text-decoration:none;cursor:pointer">${_('%(user)s commented on commit `%(commit_id)s` (file:`%(comment_file)s`)') % data}</a> ${_('in the %(repo)s repository') % data |n}</h4>
38 % else:
63 % else:
39 ${_('%(user)s commented on a commit</a> in the %(repo)s repository') % {'user': h.person(user), 'repo': commit_target_repo} |n}
64 <h4><a href="${commit_comment_url}" style="color:#427cc9;text-decoration:none;cursor:pointer">${_('%(user)s commented on commit `%(commit_id)s`') % data |n}</a> ${_('in the %(repo)s repository') % data |n}</h4>
40 % endif
65 % endif
41 </h4></td></tr>
66 </td></tr>
42 <tr><td style="padding-right:20px;padding-top:15px;">${_('Commit')}</td><td style="padding-top:15px;"><a href="${commit_comment_url}" style="color:#427cc9;text-decoration:none;cursor:pointer">${h.show_id(commit)}</a></td></tr>
67 <tr><td style="padding-right:20px;padding-top:15px;">${_('Commit')}</td><td style="padding-top:15px;"><a href="${commit_comment_url}" style="color:#427cc9;text-decoration:none;cursor:pointer">${h.show_id(commit)}</a></td></tr>
43 <tr><td style="padding-right:20px;">${_('Description')}</td><td>${h.urlify_commit_message(commit.message, repo_name)}</td></tr>
68 <tr><td style="padding-right:20px;">${_('Description')}</td><td>${h.urlify_commit_message(commit.message, repo_name)}</td></tr>
44 %if status_change:
69
45 <tr><td style="padding-right:20px;">${_('Status')}<td/>${_('The commit status was changed to')} ${status_change}.</td></tr>
70 % if status_change:
46 %endif
71 <tr><td style="padding-right:20px;">${_('Status')}</td><td>${_('The commit status was changed to')}: ${status_change}.</td></tr>
47 <tr><td style="padding-right:20px;">${_('Comment')}</td><td style="line-height:1.2em;">${h.render(comment_body, renderer=renderer_type, mentions=True)}</td></tr>
72 % endif
48 </table> No newline at end of file
73 <tr><td style="padding-right:20px;">${(_('Comment on line: %(comment_line)s') if comment_file else _('Comment')) % data}</td><td style="line-height:1.2em;">${h.render(comment_body, renderer=renderer_type, mentions=True)}</td></tr>
74 </table>
@@ -27,5 +27,5 b' There was a request to reset your passwo'
27 <br/>
27 <br/>
28 <strong>If you did not request a password reset, please contact your RhodeCode administrator.</strong>
28 <strong>If you did not request a password reset, please contact your RhodeCode administrator.</strong>
29 </p><p>
29 </p><p>
30 ${_('<a href="%(url)s">Generate new password here</a>.') % {'url': password_reset_url} |n}
30 <a href="${password_reset_url}">${_('Generate new password here')}.</a>
31 </p> No newline at end of file
31 </p>
@@ -27,4 +27,4 b' Below is your new access password for Rh'
27 <br/>
27 <br/>
28 <strong>If you didn't request a new password, please contact your RhodeCode administrator.</strong>
28 <strong>If you didn't request a new password, please contact your RhodeCode administrator.</strong>
29 </p>
29 </p>
30 <p>password: <input value='${new_password}'></pre></p> No newline at end of file
30 <p>password: <input value='${new_password}'/></p>
@@ -1,15 +1,44 b''
1 ## -*- coding: utf-8 -*-
1 ## -*- coding: utf-8 -*-
2 <%inherit file="base.mako"/>
2 <%inherit file="base.mako"/>
3
3
4
4 <%def name="subject()" filter="n,trim">
5 <%def name="subject()" filter="n,trim">
5 ${_('[mention]') if mention else ''} ${_('%(user)s commented on pull request #%(pr_id)s: "%(pr_title)s"') % {
6 <%
6 'user': h.person(user),
7 data = {
7 'pr_title': pull_request.title,
8 'user': h.person(user),
8 'pr_id': pull_request.pull_request_id
9 'pr_title': pull_request.title,
9 } |n}
10 'pr_id': pull_request.pull_request_id,
11 'status': status_change,
12 'comment_file': comment_file,
13 'comment_line': comment_line,
14 }
15 %>
16
17 ${_('[mention]') if mention else ''} \
18
19 % if comment_file:
20 ${_('%(user)s commented on pull request #%(pr_id)s "%(pr_title)s" (file: `%(comment_file)s`)') % data |n}
21 % else:
22 % if status_change:
23 ${_('%(user)s commented on pull request #%(pr_id)s "%(pr_title)s" (status: %(status)s)') % data |n}
24 % else:
25 ${_('%(user)s commented on pull request #%(pr_id)s "%(pr_title)s"') % data |n}
26 % endif
27
28 % endif
10 </%def>
29 </%def>
11
30
12 <%def name="body_plaintext()" filter="n,trim">
31 <%def name="body_plaintext()" filter="n,trim">
32 <%
33 data = {
34 'user': h.person(user),
35 'pr_title': pull_request.title,
36 'pr_id': pull_request.pull_request_id,
37 'status': status_change,
38 'comment_file': comment_file,
39 'comment_line': comment_line,
40 }
41 %>
13 ${self.subject()}
42 ${self.subject()}
14
43
15 * ${_('Comment link')}: ${pr_comment_url}
44 * ${_('Comment link')}: ${pr_comment_url}
@@ -22,39 +51,46 b''
22
51
23 ---
52 ---
24
53
54 %if status_change and not closing_pr:
55 ${_('%(user)s submitted pull request #%(pr_id)s status: *%(status)s*') % data}
56 %elif status_change and closing_pr:
57 ${_('%(user)s submitted pull request #%(pr_id)s status: *%(status)s and closed*') % data}
58 %endif
59
25 ${comment_body|n}
60 ${comment_body|n}
26
61
27
62
28 %if status_change and not closing_pr:
29 ${_('Pull request status was changed to')}: *${status_change}*
30 %elif status_change and closing_pr:
31 ${_('Pull request was closed with status')}: *${status_change}*
32 %endif
33
34 ${self.plaintext_footer()}
63 ${self.plaintext_footer()}
35 </%def>
64 </%def>
36
65
66
67 <%
68 data = {
69 'user': h.person(user),
70 'pr_title': pull_request.title,
71 'pr_id': pull_request.pull_request_id,
72 'status': status_change,
73 'comment_file': comment_file,
74 'comment_line': comment_line,
75 }
76 %>
37 <table style="text-align:left;vertical-align:middle;">
77 <table style="text-align:left;vertical-align:middle;">
38 <tr><td colspan="2" style="width:100%;padding-bottom:15px;border-bottom:1px solid #dbd9da;"><h4><a href="${pr_comment_url}" style="color:#427cc9;text-decoration:none;cursor:pointer">
78 <tr><td colspan="2" style="width:100%;padding-bottom:15px;border-bottom:1px solid #dbd9da;">
39 % if comment_file:
79 <h4><a href="${pr_comment_url}" style="color:#427cc9;text-decoration:none;cursor:pointer">
40 ${_('%(user)s commented on %(comment_file)s on pull request #%(pr_id)s: "%(pr_title)s".') % {'user': h.person(user), 'comment_file': comment_file, 'pr_title': pull_request.title, 'pr_id': pull_request.pull_request_id} |n}
80
41 % elif status_change and not closing_pr:
81 % if comment_file:
42 ${_('%(user)s changed the status of pull request #%(pr_id)s "%(pr_title)s" to %(status)s.') % {'user': h.person(user),'pr_title': pull_request.title,'pr_id': pull_request.pull_request_id, 'status': status_change} |n}
82 ${_('%(user)s commented on pull request #%(pr_id)s "%(pr_title)s" (file:`%(comment_file)s`)') % data |n}
43 %elif status_change and closing_pr:
83 % else:
44 ${_('%(user)s closed pull request #%(pr_id)s "%(pr_title)s" with status %(status)s.') % {'user': h.person(user),'pr_title': pull_request.title,'pr_id': pull_request.pull_request_id, 'status': status_change} |n}
84 ${_('%(user)s commented on pull request #%(pr_id)s "%(pr_title)s"') % data |n}
45 %else:
85 % endif
46 ${_('%(user)s commented in pull request #%(pr_id)s "%(pr_title)s".') % {'user': h.person(user),'pr_title': pull_request.title,'pr_id': pull_request.pull_request_id} |n}
86 </a>
47 % endif
87 %if status_change and not closing_pr:
48 </a></h4></td></tr>
88 , ${_('submitted pull request status: %(status)s') % data}
89 %elif status_change and closing_pr:
90 , ${_('submitted pull request status: %(status)s and closed') % data}
91 %endif
92 </h4>
93 </td></tr>
49 <tr><td style="padding-right:20px;padding-top:15px;">${_('Source')}</td><td style="padding-top:15px;"><a style="color:#427cc9;text-decoration:none;cursor:pointer" href="${pr_source_repo_url}">${pr_source_repo.repo_name}</a></td></tr>
94 <tr><td style="padding-right:20px;padding-top:15px;">${_('Source')}</td><td style="padding-top:15px;"><a style="color:#427cc9;text-decoration:none;cursor:pointer" href="${pr_source_repo_url}">${pr_source_repo.repo_name}</a></td></tr>
50 % if comment_file:
95 <tr><td style="padding-right:20px;">${(_('Comment on line: %(comment_line)s') if comment_file else _('Comment')) % data}</td><td style="line-height:1.2em;">${h.render(comment_body, renderer=renderer_type, mentions=True)}</td></tr>
51 <tr><td style="padding-right:20px;">${_('File')}</td><td>${_('%(comment_file)s on line %(comment_line)s') % {'comment_file': comment_file, 'comment_line': comment_line}}</td></tr>
52 %endif
53 %if status_change and not closing_pr:
54 <tr><td style="padding-right:20px;">${_('Status')}</td><td>${_('The commit status was changed to')} ${status_change}</td></tr>
55 %elif status_change and closing_pr:
56 <tr><td style="padding-right:20px;">${_('Status')}</td><td>${_('Pull request was closed with status')}: ${status_change}</td></tr>
57 %endif
58 <tr><td style="padding-right:20px;">${_('Comment')}</td><td style="line-height:1.2em;">${h.render(comment_body, renderer=renderer_type, mentions=True)}</td></tr>
59 </table>
96 </table>
60
@@ -57,7 +57,7 b''
57 %endif
57 %endif
58
58
59 ${h.submit('send', _('Send password reset email'), class_="btn sign-in")}
59 ${h.submit('send', _('Send password reset email'), class_="btn sign-in")}
60 <div class="activation_msg">${_('Password reset link will be send to matching email address')}</div>
60 <div class="activation_msg">${_('Password reset link will be sent to matching email address')}</div>
61
61
62 ${h.end_form()}
62 ${h.end_form()}
63 </div>
63 </div>
General Comments 0
You need to be logged in to leave comments. Login now