launchpad-reviewers team mailing list archive
-
launchpad-reviewers team
-
Mailing list archive
-
Message #00618
[Merge] lp:~sinzui/launchpad/contact-via-web-reason-0 into lp:launchpad/devel
Curtis Hovey has proposed merging lp:~sinzui/launchpad/contact-via-web-reason-0 into lp:launchpad/devel.
Requested reviews:
Launchpad code reviewers (launchpad-reviewers)
Related bugs:
#598051 'contact this user' mails do not clearly state they were sent from the profile page
https://bugs.launchpad.net/bugs/598051
This is my branch to clarify the contact-via-web context.
lp:~sinzui/launchpad/contact-via-web-reason-0
Diff size: 88
Launchpad bug:
https://bugs.launchpad.net/bugs/598051
Test command: ./bin/test -vv -t user-to-user-views
Pre-implementation: lifeless
Target release: 10.09
Clarify the contact-via-web context
----------------------------------
The contact-via-web emails (contact this user, contact this team, contact
this team admin) to not clearly state where the user used the think to
contact the recipient. The team display name or "you profile page" does makes
the recipient wonder where the page really is.
Rules
-----
* Add the url of the origin page to the email footer.
QA
--
* Use the contact-via-web link from your profile page.
* Verify the url of your page is in the footer
Lint
----
Linting changed files:
lib/lp/registry/browser/person.py
lib/lp/registry/browser/tests/user-to-user-views.txt
Test
----
* lib/lp/registry/browser/tests/user-to-user-views.txt
* Updated the tests to verify the url in the email footer.
* Updated the test to verify the fixed link name.
Implementation
--------------
* lib/lp/registry/browser/person.py
* Added the URL of the origin page to the recipient reason that is
shown in the email footer.
* Fixed the "Contact this teams' owner" link name in the reason.
--
https://code.launchpad.net/~sinzui/launchpad/contact-via-web-reason-0/+merge/32767
Your team Launchpad code reviewers is requested to review the proposed merge of lp:~sinzui/launchpad/contact-via-web-reason-0 into lp:launchpad/devel.
=== modified file 'lib/lp/registry/browser/person.py'
--- lib/lp/registry/browser/person.py 2010-08-13 07:48:54 +0000
+++ lib/lp/registry/browser/person.py 2010-08-16 14:21:02 +0000
@@ -5639,20 +5639,25 @@
header = 'ContactViaWeb user'
elif self._primary_reason is self.TO_OWNER:
reason = (
- 'the "Contact this team" owner link on the '
- '%s team page' % person_or_team.displayname)
+ 'the "Contact this team\'s owner" link on the '
+ '%s team page\n(%s)' % (
+ person_or_team.displayname,
+ canonical_url(person_or_team)))
header = 'ContactViaWeb owner (%s team)' % person_or_team.name
elif self._primary_reason is self.TO_TEAM:
reason = (
'the "Contact this team" link on the '
- '%s team page' % person_or_team.displayname)
+ '%s team page\n(%s)' % (
+ person_or_team.displayname,
+ canonical_url(person_or_team)))
header = 'ContactViaWeb member (%s team)' % person_or_team.name
else:
# self._primary_reason is self.TO_MEMBERS.
reason = (
'the "Contact this team" link on the %s\n'
- 'team page to each member directly' %
- person_or_team.displayname)
+ 'team page to each member directly\n(%s)' % (
+ person_or_team.displayname,
+ canonical_url(person_or_team)))
header = 'ContactViaWeb member (%s team)' % person_or_team.name
return (reason, header)
=== modified file 'lib/lp/registry/browser/tests/user-to-user-views.txt'
--- lib/lp/registry/browser/tests/user-to-user-views.txt 2010-07-14 16:27:33 +0000
+++ lib/lp/registry/browser/tests/user-to-user-views.txt 2010-08-16 14:21:02 +0000
@@ -306,7 +306,8 @@
--
This message was sent from Launchpad by the user
Bart (http://launchpad.dev/~bart)
- using the "Contact this team" owner link on the GuadaMen team page.
+ using the "Contact this team's owner" link on the GuadaMen team page
+ (http://launchpad.dev/~guadamen).
For more information see
https://help.launchpad.net/YourAccount/ContactingPeople
# of Messages: 1
@@ -347,7 +348,7 @@
This message was sent from Launchpad by the user
Foo Bar (http://launchpad.dev/~name16)
using the "Contact this team" link on the GuadaMen
- team page to each member directly.
+ team page to each member directly (http://launchpad.dev/~guadamen).
For more information see
https://help.launchpad.net/YourAccount/ContactingPeople
# of Messages: 10
@@ -400,7 +401,8 @@
This message was sent from Launchpad by the user
Foo Bar (http://launchpad.dev/~name16)
using the "Contact this team" link on the GuadaMen
- team page to each member directly.
+ team page to each member directly
+ (http://launchpad.dev/~guadamen).
For more information see
https://help.launchpad.net/YourAccount/ContactingPeople
# of Messages: 10
@@ -461,7 +463,8 @@
--
This message was sent from Launchpad by the user
Foo Bar (http://launchpad.dev/~name16)
- using the "Contact this team" link on the GuadaMen team page.
+ using the "Contact this team" link on the GuadaMen team page
+ (http://launchpad.dev/~guadamen).
For more information see
https://help.launchpad.net/YourAccount/ContactingPeople
@@ -576,7 +579,8 @@
^This message was sent from Launchpad by the user$
^Sample Person (http://launchpad.dev/~name12)$
^using the "Contact this team" link on the Landscape Developers$
- ^team page to each member directly.$
+ ^team page to each member directly$
+ ^(http://launchpad.dev/~landscape-developers).$
^For more information see$
^https://help.launchpad.net/YourAccount/ContactingPeople$