Merge lp:~deryck/launchpad/remove-bugs-templates-in-lp-431916 into lp:launchpad

Proposed by Deryck Hodge
Status: Merged
Merged at revision: not available
Proposed branch: lp:~deryck/launchpad/remove-bugs-templates-in-lp-431916
Merge into: lp:launchpad
Diff against target: None lines
To merge this branch: bzr merge lp:~deryck/launchpad/remove-bugs-templates-in-lp-431916
Reviewer Review Type Date Requested Status
Celso Providelo (community) code Approve
Review via email: mp+11992@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Deryck Hodge (deryck) wrote :

= Summary =

This branch removes unused template bugbranch-delete.pt and updates
structural-subscriptions-manage.pt. These templates belong to the bugs
app but lived in lib/canonical/launchpad/templates.

See bug 431916.

No tests seem affected by the mechanical changes, but I'll run it
through it ec2test before submitting.

= Launchpad lint =

Checking for conflicts. and issues in doctests and templates.
Running jslint, xmllint, pyflakes, and pylint.
Using normal rules.

Linting changed files:
  lib/canonical/launchpad/pagetitles.py
  lib/canonical/launchpad/browser/structuralsubscription.py
  lib/canonical/launchpad/templates/structural-subscriptions-manage.pt

Revision history for this message
Celso Providelo (cprov) wrote :

Deryck,

The branch looks good, thanks for working on it.

We briefly discussed the current deficiencies on the default title using the reversed-nav-path and why we will be forced to override it almost every time. You pointed that this issue will be sorted after 3.0.

Other than that everything is great, r=me, thanks.

review: Approve (code)

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'lib/canonical/launchpad/browser/structuralsubscription.py'
2--- lib/canonical/launchpad/browser/structuralsubscription.py 2009-08-25 11:21:05 +0000
3+++ lib/canonical/launchpad/browser/structuralsubscription.py 2009-09-17 17:12:58 +0000
4@@ -34,6 +34,16 @@
5 custom_widget('subscriptions_team', LabeledMultiCheckBoxWidget)
6 custom_widget('remove_other_subscriptions', LabeledMultiCheckBoxWidget)
7
8+ override_title_breadcrumbs = True
9+
10+ @property
11+ def page_title(self):
12+ return 'Subscribe to Bugs in %s' % self.context.title
13+
14+ @property
15+ def label(self):
16+ return self.page_title
17+
18 def setUpFields(self):
19 """See LaunchpadFormView."""
20 LaunchpadFormView.setUpFields(self)
21
22=== modified file 'lib/canonical/launchpad/pagetitles.py'
23--- lib/canonical/launchpad/pagetitles.py 2009-09-17 12:31:13 +0000
24+++ lib/canonical/launchpad/pagetitles.py 2009-09-17 17:12:58 +0000
25@@ -363,9 +363,6 @@
26 distributionsourcepackage_publishinghistory = ContextTitle(
27 'Publishing history of %s')
28
29-structural_subscriptions_manage = ContextTitle(
30- 'Bug subscriptions for %s')
31-
32 distroarchseries_index = ContextTitle('%s in Launchpad')
33
34 distroarchseries_builds = ContextTitle('%s builds')
35
36=== removed file 'lib/canonical/launchpad/templates/bugbranch-delete.pt'
37--- lib/canonical/launchpad/templates/bugbranch-delete.pt 2009-07-17 17:59:07 +0000
38+++ lib/canonical/launchpad/templates/bugbranch-delete.pt 1970-01-01 00:00:00 +0000
39@@ -1,28 +0,0 @@
40-<html
41- xmlns="http://www.w3.org/1999/xhtml"
42- xml:lang="en"
43- lang="en"
44- metal:use-macro="context/@@main_template/master"
45- i18n:domain="launchpad">
46-
47-<body>
48-
49-<metal:leftportlets fill-slot="portlets">
50- <div tal:replace="structure context/branch/@@+portlet-details" />
51-</metal:leftportlets>
52-
53-<div metal:fill-slot="main">
54-
55- <h1>Delete bug branch link</h1>
56-
57- <div class="documentDescription">
58- Are you sure you want to remove the link between...
59- </div>
60-
61- <div metal:use-macro="context/@@launchpad_form/form">
62- </div>
63-
64-</div>
65-
66-</body>
67-</html>
68
69=== modified file 'lib/canonical/launchpad/templates/structural-subscriptions-manage.pt'
70--- lib/canonical/launchpad/templates/structural-subscriptions-manage.pt 2009-07-17 17:59:07 +0000
71+++ lib/canonical/launchpad/templates/structural-subscriptions-manage.pt 2009-09-17 17:12:58 +0000
72@@ -3,41 +3,28 @@
73 xmlns:tal="http://xml.zope.org/namespaces/tal"
74 xmlns:metal="http://xml.zope.org/namespaces/metal"
75 xmlns:i18n="http://xml.zope.org/namespaces/i18n"
76- xml:lang="en"
77- lang="en"
78- dir="ltr"
79- metal:use-macro="context/@@main_template/master"
80+ metal:use-macro="view/macro:page/main_side"
81 i18n:domain="launchpad"
82 >
83 <body>
84-
85-<metal:leftportlets fill-slot="portlets_one">
86- <div tal:replace="structure context/@@+portlet-malone-bugmail-filtering-faq"/>
87-</metal:leftportlets>
88-
89-<metal:rightportlets fill-slot="portlets_two">
90- <div tal:condition="view/show_details_portlet"
91- tal:replace="structure context/@@+portlet-details" />
92- <div tal:replace="structure context/@@+portlet-structural-subscribers" />
93-</metal:rightportlets>
94-
95-<metal:heading fill-slot="pageheading">
96- <h1>Change bug subscriptions</h1>
97-</metal:heading>
98-
99-<div metal:fill-slot="main">
100-
101- <p>
102- You can choose to receive an e-mail every time someone reports or
103- changes a public bug associated with
104- <span tal:replace="context/title">this item</span>.
105- </p>
106- <p>
107- <strong>Important:</strong> subscribing here may mean you receive a
108- great deal of e-mail. You can return here to unsubscribe at any
109- time.
110- </p>
111- <div metal:use-macro="context/@@launchpad_form/form" />
112-</div>
113+ <div metal:fill-slot="main">
114+ <p>
115+ You can choose to receive an e-mail every time someone reports or
116+ changes a public bug associated with
117+ <span tal:replace="context/title">this item</span>.
118+ </p>
119+ <p>
120+ <strong>Important:</strong> subscribing here may mean you receive a
121+ great deal of e-mail. You can return here to unsubscribe at any
122+ time.
123+ </p>
124+ <div metal:use-macro="context/@@launchpad_form/form" />
125+ </div>
126+ <div metal:fill-slot="side">
127+ <div tal:replace="structure context/@@+portlet-malone-bugmail-filtering-faq"/>
128+ <div tal:condition="view/show_details_portlet"
129+ tal:replace="structure context/@@+portlet-details" />
130+ <div tal:replace="structure context/@@+portlet-structural-subscribers" />
131+ </div>
132 </body>
133 </html>