Merge lp:~adiroiban/launchpad/bug-146178 into lp:launchpad/db-devel
- bug-146178
- Merge into db-devel
Status: | Merged |
---|---|
Merged at revision: | not available |
Proposed branch: | lp:~adiroiban/launchpad/bug-146178 |
Merge into: | lp:launchpad/db-devel |
Diff against target: |
469 lines (+204/-71) 5 files modified
lib/lp/registry/interfaces/distroseries.py (+12/-13) lib/lp/translations/browser/distroseries.py (+40/-4) lib/lp/translations/stories/distroseries/xx-distroseries-language-packs.txt (+87/-24) lib/lp/translations/templates/distroseries-language-packs.pt (+59/-22) lib/lp/translations/templates/distroseries-translations.pt (+6/-8) |
To merge this branch: | bzr merge lp:~adiroiban/launchpad/bug-146178 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Brad Crittenden (community) | code | Approve | |
Curtis Hovey (community) | ui | Approve | |
Eleanor Berger (community) | ui* | Approve | |
Abel Deuring (community) | code | Abstain | |
Review via email: mp+23760@code.launchpad.net |
Commit message
Add in the UI +latest-
Description of the change
= Bug 146178 =
With the move of language pack exports to production servers we added +latest-
We don't link to them from Launchpad so they are only available to people that knows about it.
We should add them to the +language-packs page.
== Proposed fix ==
Create translation navigation menu entries for distroseries and add them on distroseries@
== Pre-implementation notes ==
The links are of interest only for a few users and this is why they are added only on the +langauge-packs page.
Danilo hinted that when latest and current language packs are the same we should not show the latest language pack and rather use „no updates”
Danilo also mentioned that instead of „none yet” we can use „no updates” (or something similar) and that maybe we can find a better terminology for base / full / update / delta language packs.
== Implementation details ==
Screenshots:
distribution page: http://
language-packs page: http://
I have removed the inline css for "adminlabel" as portlet titles were not aligned.
I have changed the links to use sprites.
Regarding the terminology issue, I used "base" for the base language pack and "update" for the delta language pack that must be applied over the base pack.
I used "language pack" and not "language package" since they are just translation archive and not fully functional distribution packages.
When updating a delta language pack two notification messages were generated, once saying that the changes were applied and another that no changes were submitted. I have fix that issue in this bug and since this page is only used by Ubuntu developers/
== Tests ==
lp-tt distroseries-
== Demo and Q/A ==
Go to: https:/
You should see link to the "Base back" and "Update pack" if they are available, or "none yet" and "no update".
Languages packs can be changes from here:
https:/
On the language packs you should see links to both active, in testing, latest and unused languages packs.
Данило Шеган (danilo) wrote : | # |
Данило Шеган (danilo) wrote : | # |
And please, do not use tables on this page.
Abel Deuring (adeuring) wrote : | # |
This is my branch to fix from trivial issues while my brain is stuck in
first gear.
lp:~sinzui/launchpad/oil-and-pigment
Diff size: 489
Launchpad bug: https:/
https:/
https:/
https:/
Test command: ./bin/test -vv lp.registry.
./bin/test -t site-search -t xx-team-home -t xx-private-
-t person-karma
Pre-
Target release: 10.04
Fix from trivial issues while my brain is stuck in first gear
-------
Bug #436299 [Search results give wrong "Registered by" information]
The maintainer is listed as the registrant. This is wrong. The
problem is that distributions do not have a registrant.
Bug #568336 [Typo on profile workload page]
There is a double 'or'
Bug #130285 [Disregard deleted projects from Most active in]
Deactivated projects are listed in "Most active in" in the profile page
and the links are a 404.
Bug #557544 [Bad plural on team page ("1 active members")]
What: "1 active members" can appear on team page. This is incorrect use
of a plural.
Rules
-----
Bug #436299 [Search results give wrong "Registered by" information]
Verify there is a registrant using tales before appending the clause.
tal:
tal:
Bug #568336 [Typo on profile workload page]
Remove the second 'or'.
Bug #130285 [Disregard deleted projects from lists]
This issue in on the cusp of *not* trivial because a good understanding
of pillar name behaviour and karma testing is needed. The fix can be
easily placed into an existing doc test, but that is not the correct
location.
* pillar names (used by karma cache) have no concept of active/inactive.
The method must filter deactivate pillars /after/ the query to get the
names. The callsite must request more than is needed because of the
filtering.
* Generate the karma for a unit test of the method *and* the private
methods that were never directly tested.
* Test that deactivated pillars are not included.
* ADDENDUM: While I knew how to generate the karma, the reason why
the karma looks like it is inserted twice was not obvious from existing
tests. I took an extra hour learning this and adding comments for
future developers.
Bug #557544 [Bad plural on team page ("1 active members")]
* Use the plural-message macro to switch between member and members
QA
--
Bug #436299 [Search results give wrong "Registered by" information]
* Visit https:/
* Verify that Karianne Fog Heen is listed as the registrant
* Visit https:/
* Verify that no registrant is listed:
Registered on <date>
Bug #568336 [Typo on profile workload page]
* Visit https:/
* Verif...
Abel Deuring (adeuring) wrote : | # |
I am an idiot -- that was meant for another branch. Sorry for the noise...
Abel Deuring (adeuring) : | # |
Eleanor Berger (intellectronica) : | # |
Curtis Hovey (sinzui) wrote : | # |
The UI looks good to land.
Brad Crittenden (bac) wrote : | # |
Hi Adi,
Thanks for submitting this change. The work looks really good.
Please fix the small items below and then I'll (try) to land it for you, if ec2 will let me. :(
> === modified file 'lib/lp/
> --- lib/lp/
+++ lib/lp/
> @@ -250,33 +250,33 @@
> language_pack_base = Choice(
> title=_('Language pack base'), required=False,
> description=_('''
> - Language pack export with the export of all translations available
> - for this `IDistroSeries` when it was generated. Next delta exports
> - will be generated based on this one.
> + Language pack with the export of all translations
> + available for this distribution series when it was generated. The
> + subsequent update exports will be generated based on this one.
> '''), vocabulary=
>
> language_pack_delta = Choice(
> - title=_('Language pack delta'), required=False,
> + title=_('Language pack update'), required=False,
> description=_('''
> - Language pack export with the export of all translation updates
> - available for this `IDistroSeries` since language_pack_base was
> - generated.
> + Language pack with the export of all translation updates
> + available for this distribution series since the language pack
> + base was generated.
> '''), vocabulary=
>
> language_
> title=_('Proposed language pack update'), required=False,
> description=_('''
> - Base or delta language pack export that is being tested and
> - proposed to be used as the new language_pack_base or
> - language_pack_delta for this `IDistroSeries`.
> + Base or update language pack export that is being tested and
> + proposed to be used as the new language pack base or
> + language pack update for this distribution series.
> '''), vocabulary=
>
> language_
> title=_('Request a full language pack export'), required=True,
> description=_('''
> Whether next language pack generation will be a full export. This
> - is useful when delta packages are too big and want to merge all
> - those changes in the base package.
> + is useful when update packs are too big and want to merge all
> + those changes in the base pack.
s/This is/This information is/
> '''))
>
> last_full_
> === modified file 'lib/lp/
> --- lib/lp/
> +++ lib/lp/
> @@ -122,6 +122,28 @@
>
> return unused_
>
> + @property
> + def have_latest_full...
Brad Crittenden (bac) wrote : | # |
Also, I see this MP is targeted to db-devel not devel which seems to be in error.
Adi Roiban (adiroiban) wrote : | # |
Hi Brad and many thanks for your review.
I have create a new MP targeted to devel and added my diff there:
https:/
Preview Diff
1 | === modified file 'lib/lp/registry/interfaces/distroseries.py' | |||
2 | --- lib/lp/registry/interfaces/distroseries.py 2010-04-08 18:40:18 +0000 | |||
3 | +++ lib/lp/registry/interfaces/distroseries.py 2010-04-27 22:26:15 +0000 | |||
4 | @@ -53,7 +53,6 @@ | |||
5 | 53 | from lp.translations.interfaces.languagepack import ILanguagePack | 53 | from lp.translations.interfaces.languagepack import ILanguagePack |
6 | 54 | 54 | ||
7 | 55 | 55 | ||
8 | 56 | |||
9 | 57 | class DistroSeriesNameField(ContentNameField): | 56 | class DistroSeriesNameField(ContentNameField): |
10 | 58 | """A class to ensure `IDistroSeries` has unique names.""" | 57 | """A class to ensure `IDistroSeries` has unique names.""" |
11 | 59 | errormessage = _("%s is already in use by another series.") | 58 | errormessage = _("%s is already in use by another series.") |
12 | @@ -250,33 +249,33 @@ | |||
13 | 250 | language_pack_base = Choice( | 249 | language_pack_base = Choice( |
14 | 251 | title=_('Language pack base'), required=False, | 250 | title=_('Language pack base'), required=False, |
15 | 252 | description=_(''' | 251 | description=_(''' |
19 | 253 | Language pack export with the export of all translations available | 252 | Language pack with the export of all translations |
20 | 254 | for this `IDistroSeries` when it was generated. Next delta exports | 253 | available for this distribution series when it was generated. The |
21 | 255 | will be generated based on this one. | 254 | subsequent update exports will be generated based on this one. |
22 | 256 | '''), vocabulary='FilteredFullLanguagePack') | 255 | '''), vocabulary='FilteredFullLanguagePack') |
23 | 257 | 256 | ||
24 | 258 | language_pack_delta = Choice( | 257 | language_pack_delta = Choice( |
26 | 259 | title=_('Language pack delta'), required=False, | 258 | title=_('Language pack update'), required=False, |
27 | 260 | description=_(''' | 259 | description=_(''' |
31 | 261 | Language pack export with the export of all translation updates | 260 | Language pack with the export of all translation updates |
32 | 262 | available for this `IDistroSeries` since language_pack_base was | 261 | available for this distribution series since the language pack |
33 | 263 | generated. | 262 | base was generated. |
34 | 264 | '''), vocabulary='FilteredDeltaLanguagePack') | 263 | '''), vocabulary='FilteredDeltaLanguagePack') |
35 | 265 | 264 | ||
36 | 266 | language_pack_proposed = Choice( | 265 | language_pack_proposed = Choice( |
37 | 267 | title=_('Proposed language pack update'), required=False, | 266 | title=_('Proposed language pack update'), required=False, |
38 | 268 | description=_(''' | 267 | description=_(''' |
42 | 269 | Base or delta language pack export that is being tested and | 268 | Base or update language pack export that is being tested and |
43 | 270 | proposed to be used as the new language_pack_base or | 269 | proposed to be used as the new language pack base or |
44 | 271 | language_pack_delta for this `IDistroSeries`. | 270 | language pack update for this distribution series. |
45 | 272 | '''), vocabulary='FilteredLanguagePack') | 271 | '''), vocabulary='FilteredLanguagePack') |
46 | 273 | 272 | ||
47 | 274 | language_pack_full_export_requested = Bool( | 273 | language_pack_full_export_requested = Bool( |
48 | 275 | title=_('Request a full language pack export'), required=True, | 274 | title=_('Request a full language pack export'), required=True, |
49 | 276 | description=_(''' | 275 | description=_(''' |
50 | 277 | Whether next language pack generation will be a full export. This | 276 | Whether next language pack generation will be a full export. This |
53 | 278 | is useful when delta packages are too big and want to merge all | 277 | information is useful when update packs are too big and want to |
54 | 279 | those changes in the base package. | 278 | merge all those changes in the base pack. |
55 | 280 | ''')) | 279 | ''')) |
56 | 281 | 280 | ||
57 | 282 | last_full_language_pack_exported = Object( | 281 | last_full_language_pack_exported = Object( |
58 | 283 | 282 | ||
59 | === modified file 'lib/lp/translations/browser/distroseries.py' | |||
60 | --- lib/lp/translations/browser/distroseries.py 2010-02-24 18:33:18 +0000 | |||
61 | +++ lib/lp/translations/browser/distroseries.py 2010-04-27 22:26:15 +0000 | |||
62 | @@ -122,6 +122,34 @@ | |||
63 | 122 | 122 | ||
64 | 123 | return unused_language_packs | 123 | return unused_language_packs |
65 | 124 | 124 | ||
66 | 125 | @property | ||
67 | 126 | def have_latest_full_pack(self): | ||
68 | 127 | """Checks if this distribution series has a full language pack newer | ||
69 | 128 | than the current one.""" | ||
70 | 129 | |||
71 | 130 | current = self.context.language_pack_base | ||
72 | 131 | latest = self.context.last_full_language_pack_exported | ||
73 | 132 | if (current is None or | ||
74 | 133 | latest is None or | ||
75 | 134 | current.file.http_url == latest.file.http_url): | ||
76 | 135 | return False | ||
77 | 136 | else: | ||
78 | 137 | return True | ||
79 | 138 | |||
80 | 139 | @property | ||
81 | 140 | def have_latest_delta_pack(self): | ||
82 | 141 | """Checks if this distribution series has a delta language pack newer | ||
83 | 142 | than the current one.""" | ||
84 | 143 | |||
85 | 144 | current = self.context.language_pack_delta | ||
86 | 145 | latest = self.context.last_delta_language_pack_exported | ||
87 | 146 | if (current is None or | ||
88 | 147 | latest is None or | ||
89 | 148 | current.file.http_url == latest.file.http_url): | ||
90 | 149 | return False | ||
91 | 150 | else: | ||
92 | 151 | return True | ||
93 | 152 | |||
94 | 125 | def _request_full_export(self): | 153 | def _request_full_export(self): |
95 | 126 | if (self.old_request_value != | 154 | if (self.old_request_value != |
96 | 127 | self.context.language_pack_full_export_requested): | 155 | self.context.language_pack_full_export_requested): |
97 | @@ -135,9 +163,6 @@ | |||
98 | 135 | "Your request has been noted. Next language pack " | 163 | "Your request has been noted. Next language pack " |
99 | 136 | "export will be made relative to the current base " | 164 | "export will be made relative to the current base " |
100 | 137 | "language pack.") | 165 | "language pack.") |
101 | 138 | else: | ||
102 | 139 | self.request.response.addInfoNotification( | ||
103 | 140 | "You didn't change anything.") | ||
104 | 141 | 166 | ||
105 | 142 | @action("Change Settings", condition=is_translations_admin) | 167 | @action("Change Settings", condition=is_translations_admin) |
106 | 143 | def change_action(self, action, data): | 168 | def change_action(self, action, data): |
107 | @@ -232,7 +257,8 @@ | |||
108 | 232 | usedfor = IDistroSeries | 257 | usedfor = IDistroSeries |
109 | 233 | facet = 'translations' | 258 | facet = 'translations' |
110 | 234 | links = [ | 259 | links = [ |
112 | 235 | 'translations', 'templates', 'admin', 'language_packs', 'imports'] | 260 | 'translations', 'templates', 'admin', 'language_packs', |
113 | 261 | 'latest_full_language_pack', 'latest_delta_language_pack', 'imports'] | ||
114 | 236 | 262 | ||
115 | 237 | def translations(self): | 263 | def translations(self): |
116 | 238 | return Link('', 'Overview') | 264 | return Link('', 'Overview') |
117 | @@ -251,6 +277,16 @@ | |||
118 | 251 | def language_packs(self): | 277 | def language_packs(self): |
119 | 252 | return Link('+language-packs', 'Language packs') | 278 | return Link('+language-packs', 'Language packs') |
120 | 253 | 279 | ||
121 | 280 | def latest_full_language_pack(self): | ||
122 | 281 | return Link( | ||
123 | 282 | '+latest-full-language-pack', | ||
124 | 283 | 'Latest full language pack') | ||
125 | 284 | |||
126 | 285 | def latest_delta_language_pack(self): | ||
127 | 286 | return Link( | ||
128 | 287 | '+latest-delta-language-pack', | ||
129 | 288 | 'Latest delta language pack') | ||
130 | 289 | |||
131 | 254 | 290 | ||
132 | 255 | def check_distroseries_translations_viewable(distroseries): | 291 | def check_distroseries_translations_viewable(distroseries): |
133 | 256 | """Check that these distribution series translations are visible. | 292 | """Check that these distribution series translations are visible. |
134 | 257 | 293 | ||
135 | === modified file 'lib/lp/translations/stories/distroseries/xx-distroseries-language-packs.txt' | |||
136 | --- lib/lp/translations/stories/distroseries/xx-distroseries-language-packs.txt 2009-09-17 11:10:49 +0000 | |||
137 | +++ lib/lp/translations/stories/distroseries/xx-distroseries-language-packs.txt 2010-04-27 22:26:15 +0000 | |||
138 | @@ -1,4 +1,5 @@ | |||
140 | 1 | = Distribution series language packs admin = | 1 | Distribution series language packs admin |
141 | 2 | ======================================== | ||
142 | 2 | 3 | ||
143 | 3 | For each distribution series, we can select several special language packs: | 4 | For each distribution series, we can select several special language packs: |
144 | 4 | 5 | ||
145 | @@ -18,57 +19,83 @@ | |||
146 | 18 | ... 'http://translations.launchpad.dev/ubuntu/hoary') | 19 | ... 'http://translations.launchpad.dev/ubuntu/hoary') |
147 | 19 | >>> admin_browser.getLink('See all language packs').click() | 20 | >>> admin_browser.getLink('See all language packs').click() |
148 | 20 | 21 | ||
150 | 21 | Initially, there is no package selected. | 22 | Initially, there is no package selected and there are options for choosing a |
151 | 23 | base language pack. | ||
152 | 22 | 24 | ||
153 | 23 | >>> base = admin_browser.getControl('Language pack base') | 25 | >>> base = admin_browser.getControl('Language pack base') |
154 | 24 | >>> print base.displayValue | 26 | >>> print base.displayValue |
155 | 25 | ['(no value)'] | 27 | ['(no value)'] |
157 | 26 | >>> delta = admin_browser.getControl('Language pack delta') | 28 | >>> base.displayOptions |
158 | 29 | ['(no value)', '2007-09-10 19:16:01 UTC', '2007-09-10 19:14:26 UTC'] | ||
159 | 30 | >>> delta = admin_browser.getControl('Language pack update') | ||
160 | 27 | >>> print delta.displayValue | 31 | >>> print delta.displayValue |
161 | 28 | ['(no value)'] | 32 | ['(no value)'] |
162 | 29 | >>> proposed = admin_browser.getControl('Proposed language pack update') | 33 | >>> proposed = admin_browser.getControl('Proposed language pack update') |
163 | 30 | >>> print proposed.displayValue | 34 | >>> print proposed.displayValue |
164 | 31 | ['(no value)'] | 35 | ['(no value)'] |
165 | 32 | 36 | ||
166 | 33 | |||
167 | 34 | >>> base.displayOptions | ||
168 | 35 | ['(no value)', '2007-09-10 19:16:01 UTC', '2007-09-10 19:14:26 UTC'] | ||
169 | 36 | |||
170 | 37 | Let's select a base one: | 37 | Let's select a base one: |
171 | 38 | 38 | ||
173 | 39 | >>> base.displayValue = ['2007-09-10 19:16:01 UTC'] | 39 | >>> base.displayValue = ['2007-09-10 19:14:26 UTC'] |
174 | 40 | >>> admin_browser.getControl('Change').click() | 40 | >>> admin_browser.getControl('Change').click() |
175 | 41 | >>> print admin_browser.url | 41 | >>> print admin_browser.url |
176 | 42 | http://translations.launchpad.dev/ubuntu/hoary/+language-packs | 42 | http://translations.launchpad.dev/ubuntu/hoary/+language-packs |
177 | 43 | 43 | ||
179 | 44 | Now the admin page will show us that language pack selected. | 44 | Now the admin page will show us that language pack selected and a list of |
180 | 45 | available update packages. | ||
181 | 45 | 46 | ||
182 | 46 | >>> base = admin_browser.getControl('Language pack base') | 47 | >>> base = admin_browser.getControl('Language pack base') |
183 | 47 | >>> print base.displayValue | 48 | >>> print base.displayValue |
187 | 48 | ['2007-09-10 19:16:01 UTC'] | 49 | ['2007-09-10 19:14:26 UTC'] |
188 | 49 | 50 | ||
189 | 50 | Also, that change is shown in the public language pack listing web page: | 51 | >>> update = admin_browser.getControl('Language pack update') |
190 | 52 | >>> print update.displayValue | ||
191 | 53 | ['(no value)'] | ||
192 | 54 | >>> update.displayOptions | ||
193 | 55 | ['(no value)', '2007-09-10 19:15:19 UTC', '2007-09-10 19:15:01 UTC'] | ||
194 | 56 | |||
195 | 57 | Those changes are shown in the public language pack listing web page: | ||
196 | 51 | 58 | ||
197 | 52 | >>> browser.open('http://translations.launchpad.dev/ubuntu/hoary') | 59 | >>> browser.open('http://translations.launchpad.dev/ubuntu/hoary') |
198 | 53 | >>> browser.getLink('See all language packs').click() | 60 | >>> browser.getLink('See all language packs').click() |
199 | 54 | >>> print extract_text(find_tag_by_id(browser.contents, "language_packs")) | 61 | >>> print extract_text(find_tag_by_id(browser.contents, "language_packs")) |
200 | 55 | A language pack... | 62 | A language pack... |
201 | 56 | Active language packs | 63 | Active language packs |
207 | 57 | Base pack: 2007-09-10 19:16:01 UTC | 64 | Base pack: 2007-09-10 19:14:26 UTC |
208 | 58 | A complete set of translations for the OS. | 65 | Archive containing a complete set of translations |
209 | 59 | Delta pack: | 66 | for this operating system. |
210 | 60 | none yet | 67 | Update pack: |
211 | 61 | Translation updates, applied on top of the base pack. | 68 | no update |
212 | 69 | Archive containing translation updates, applied on top of the base pack. | ||
213 | 70 | Latest language packs | ||
214 | 71 | Base pack: | ||
215 | 72 | 2007-09-10 19:16:01 UTC | ||
216 | 73 | Latest archive containing a complete set of translations | ||
217 | 74 | for this operating system. | ||
218 | 75 | Update pack: | ||
219 | 76 | no update | ||
220 | 77 | Latest archive containing translation updates, | ||
221 | 78 | applied on top of the base pack. | ||
222 | 62 | Language pack being tested | 79 | Language pack being tested |
223 | 63 | No pack is being tested right now. | 80 | No pack is being tested right now. |
224 | 64 | Currently unused language packs | 81 | Currently unused language packs |
225 | 82 | Full language pack: 2007-09-10 19:16:01 UTC | ||
226 | 65 | Delta language pack: 2007-09-10 19:15:19 UTC | 83 | Delta language pack: 2007-09-10 19:15:19 UTC |
227 | 66 | Delta language pack: 2007-09-10 19:15:01 UTC | 84 | Delta language pack: 2007-09-10 19:15:01 UTC |
233 | 67 | Full language pack: 2007-09-10 19:14:26 UTC | 85 | |
234 | 68 | 86 | The active base language pack URL is linking to an archive, while the latest | |
235 | 69 | There is also an option to set/unset whether next language pack generation is | 87 | URL uses '+latest-full-language-pack'. |
236 | 70 | a full export: | 88 | |
237 | 71 | 89 | >>> print browser.getLink('2007-09-10 19:14:26 UTC').url | |
238 | 90 | http.../71/ubuntu-hoary-translations.tar.gz | ||
239 | 91 | >>> print browser.getLink('2007-09-10 19:16:01 UTC').url | ||
240 | 92 | http://translations.launchpad.dev/ubuntu/hoary/+latest-full-language-pack | ||
241 | 93 | |||
242 | 94 | An administrator can choose the current update pack and there is also an | ||
243 | 95 | option to set/unset whether next language pack generation is a full export: | ||
244 | 96 | |||
245 | 97 | >>> update = admin_browser.getControl('Language pack update') | ||
246 | 98 | >>> update.displayValue = ['2007-09-10 19:15:01 UTC'] | ||
247 | 72 | >>> admin_browser.getControl( | 99 | >>> admin_browser.getControl( |
248 | 73 | ... 'Request a full language pack export').selected | 100 | ... 'Request a full language pack export').selected |
249 | 74 | False | 101 | False |
250 | @@ -88,6 +115,42 @@ | |||
251 | 88 | True | 115 | True |
252 | 89 | 116 | ||
253 | 90 | There are no visible user interface changes once this flag is changed. It | 117 | There are no visible user interface changes once this flag is changed. It |
256 | 91 | just changes the behaviour of the language pack export, which is executed by cron, | 118 | just changes the behaviour of the language pack export, which is executed by |
257 | 92 | it will do a full export of translations for this distro series. | 119 | cron, it will do a full export of translations for this distro series. |
258 | 120 | |||
259 | 121 | The language pack changes are visible on the public language pack page: | ||
260 | 122 | |||
261 | 123 | >>> browser.open( | ||
262 | 124 | ... 'http://translations.launchpad.dev/ubuntu/hoary/+language-packs') | ||
263 | 125 | >>> print extract_text(find_tag_by_id(browser.contents, "language_packs")) | ||
264 | 126 | A language pack... | ||
265 | 127 | Active language packs | ||
266 | 128 | Base pack: 2007-09-10 19:14:26 UTC | ||
267 | 129 | Archive containing a complete set of translations | ||
268 | 130 | for this operating system. | ||
269 | 131 | Update pack: | ||
270 | 132 | 2007-09-10 19:15:01 UTC | ||
271 | 133 | Archive containing translation updates, applied on top of the base pack. | ||
272 | 134 | Latest language packs | ||
273 | 135 | Base pack: | ||
274 | 136 | 2007-09-10 19:16:01 UTC | ||
275 | 137 | Latest archive containing a complete set of translations | ||
276 | 138 | for this operating system. | ||
277 | 139 | Update pack: | ||
278 | 140 | 2007-09-10 19:15:19 UTC | ||
279 | 141 | Latest archive containing translation updates, | ||
280 | 142 | applied on top of the base pack. | ||
281 | 143 | Language pack being tested | ||
282 | 144 | No pack is being tested right now. | ||
283 | 145 | Currently unused language packs | ||
284 | 146 | Full language pack: 2007-09-10 19:16:01 UTC | ||
285 | 147 | Delta language pack: 2007-09-10 19:15:19 UTC | ||
286 | 148 | |||
287 | 149 | The active update language pack URL is linking to an archive, while the latest | ||
288 | 150 | URL uses '+latest-full-language-pack'. | ||
289 | 151 | |||
290 | 152 | >>> print browser.getLink('2007-09-10 19:15:01 UTC').url | ||
291 | 153 | http.../72/ubuntu-hoary-translations-update.tar.gz | ||
292 | 154 | >>> print browser.getLink('2007-09-10 19:15:19 UTC').url | ||
293 | 155 | http://translations.launchpad.dev/ubuntu/hoary/+latest-delta-language-pack | ||
294 | 93 | 156 | ||
295 | 94 | 157 | ||
296 | === modified file 'lib/lp/translations/templates/distroseries-language-packs.pt' | |||
297 | --- lib/lp/translations/templates/distroseries-language-packs.pt 2009-09-17 11:10:49 +0000 | |||
298 | +++ lib/lp/translations/templates/distroseries-language-packs.pt 2010-04-27 22:26:15 +0000 | |||
299 | @@ -6,14 +6,6 @@ | |||
300 | 6 | metal:use-macro="view/macro:page/main_only" | 6 | metal:use-macro="view/macro:page/main_only" |
301 | 7 | i18n:domain="launchpad" > | 7 | i18n:domain="launchpad" > |
302 | 8 | <body> | 8 | <body> |
303 | 9 | <div metal:fill-slot="head_epilogue"> | ||
304 | 10 | <style type="text/css"> | ||
305 | 11 | h2.adminlabel { | ||
306 | 12 | margin: 1.5em 0 0 0; | ||
307 | 13 | } | ||
308 | 14 | </style> | ||
309 | 15 | </div> | ||
310 | 16 | |||
311 | 17 | <div metal:fill-slot="main"> | 9 | <div metal:fill-slot="main"> |
312 | 18 | <div id="language_packs"> | 10 | <div id="language_packs"> |
313 | 19 | 11 | ||
314 | @@ -39,41 +31,86 @@ | |||
315 | 39 | </p> | 31 | </p> |
316 | 40 | </div> | 32 | </div> |
317 | 41 | <div class="yui-g"> | 33 | <div class="yui-g"> |
319 | 42 | <div class="yui-u first portlet"> | 34 | <div class="yui-u first portlet" id="active-language-packs"> |
320 | 43 | <h2>Active language packs</h2> | 35 | <h2>Active language packs</h2> |
321 | 44 | <dl> | 36 | <dl> |
322 | 45 | <dt> | 37 | <dt> |
323 | 46 | Base pack: | 38 | Base pack: |
325 | 47 | <a tal:condition="context/language_pack_base" | 39 | <a class="sprite download" |
326 | 40 | tal:condition="context/language_pack_base" | ||
327 | 48 | tal:attributes="href context/language_pack_base/file/http_url"> | 41 | tal:attributes="href context/language_pack_base/file/http_url"> |
328 | 49 | <tal:export-date | 42 | <tal:export-date |
329 | 50 | replace="context/language_pack_base/date_exported/fmt:datetime" /> | 43 | replace="context/language_pack_base/date_exported/fmt:datetime" /> |
330 | 51 | <img tal:condition="context/language_pack_base" | ||
331 | 52 | alt="download icon" src="/@@/download" /> | ||
332 | 53 | </a> | 44 | </a> |
333 | 54 | <tal:not-export-date condition="not: context/language_pack_base"> | 45 | <tal:not-export-date condition="not: context/language_pack_base"> |
334 | 55 | none yet | 46 | none yet |
335 | 56 | </tal:not-export-date> | 47 | </tal:not-export-date> |
336 | 57 | </dt> | 48 | </dt> |
338 | 58 | <dd>A complete set of translations for the OS.</dd> | 49 | <dd> |
339 | 50 | Archive containing a complete set of translations for this | ||
340 | 51 | operating system. | ||
341 | 52 | </dd> | ||
342 | 59 | <dt> | 53 | <dt> |
345 | 60 | Delta pack: | 54 | Update pack: |
346 | 61 | <a tal:condition="context/language_pack_delta" | 55 | <a class="sprite download" |
347 | 56 | tal:condition="context/language_pack_delta" | ||
348 | 62 | tal:attributes="href context/language_pack_delta/file/http_url"> | 57 | tal:attributes="href context/language_pack_delta/file/http_url"> |
349 | 63 | <tal:export-date | 58 | <tal:export-date |
350 | 64 | replace="context/language_pack_delta/date_exported/fmt:datetime" /> | 59 | replace="context/language_pack_delta/date_exported/fmt:datetime" /> |
351 | 65 | <img tal:condition="context/language_pack_delta" | ||
352 | 66 | alt="download icon" src="/@@/download" /> | ||
353 | 67 | </a> | 60 | </a> |
354 | 68 | <tal:not-export-date condition="not: context/language_pack_delta"> | 61 | <tal:not-export-date condition="not: context/language_pack_delta"> |
356 | 69 | none yet | 62 | no update |
357 | 70 | </tal:not-export-date> | 63 | </tal:not-export-date> |
358 | 71 | </dt> | 64 | </dt> |
360 | 72 | <dd>Translation updates, applied on top of the base pack.</dd> | 65 | <dd> |
361 | 66 | Archive containing translation updates, applied on top of the | ||
362 | 67 | base pack. | ||
363 | 68 | </dd> | ||
364 | 73 | </dl> | 69 | </dl> |
365 | 74 | </div> | 70 | </div> |
366 | 71 | |||
367 | 75 | <div class="yui-u"> | 72 | <div class="yui-u"> |
369 | 76 | <div class="portlet"> | 73 | <div> |
370 | 74 | <div id="latest-language-packs" class="portlet"> | ||
371 | 75 | <h2>Latest language packs</h2> | ||
372 | 76 | <dl> | ||
373 | 77 | <dt> | ||
374 | 78 | Base pack: | ||
375 | 79 | <a class="sprite download" | ||
376 | 80 | tal:condition="view/have_latest_full_pack" | ||
377 | 81 | tal:attributes="href context/menu:navigation/latest_full_language_pack/url"> | ||
378 | 82 | <tal:export-date | ||
379 | 83 | replace="context/last_full_language_pack_exported/date_exported/fmt:datetime" /> | ||
380 | 84 | </a> | ||
381 | 85 | <tal:not-export-date | ||
382 | 86 | condition="not: view/have_latest_full_pack"> | ||
383 | 87 | none yet | ||
384 | 88 | </tal:not-export-date> | ||
385 | 89 | </dt> | ||
386 | 90 | <dd> | ||
387 | 91 | Latest archive containing a complete set of translations for | ||
388 | 92 | this operating system. | ||
389 | 93 | </dd> | ||
390 | 94 | <dt> | ||
391 | 95 | Update pack: | ||
392 | 96 | <a class="sprite download" | ||
393 | 97 | tal:condition="view/have_latest_delta_pack" | ||
394 | 98 | tal:attributes="href context/menu:navigation/latest_delta_language_pack/url"> | ||
395 | 99 | <tal:export-date | ||
396 | 100 | replace="context/last_delta_language_pack_exported/date_exported/fmt:datetime" /> | ||
397 | 101 | </a> | ||
398 | 102 | <tal:not-export-date | ||
399 | 103 | condition="not: view/have_latest_delta_pack"> | ||
400 | 104 | no update | ||
401 | 105 | </tal:not-export-date> | ||
402 | 106 | </dt> | ||
403 | 107 | <dd> | ||
404 | 108 | Latest archive containing translation updates, applied on top | ||
405 | 109 | of the base pack. | ||
406 | 110 | </dd> | ||
407 | 111 | </dl> | ||
408 | 112 | </div> | ||
409 | 113 | <div id="testing-language-packs"> | ||
410 | 77 | <h2>Language pack being tested</h2> | 114 | <h2>Language pack being tested</h2> |
411 | 78 | <dl tal:condition="context/language_pack_proposed"> | 115 | <dl tal:condition="context/language_pack_proposed"> |
412 | 79 | <dt> | 116 | <dt> |
413 | @@ -96,14 +133,14 @@ | |||
414 | 96 | <p tal:condition="not:context/language_pack_proposed"> | 133 | <p tal:condition="not:context/language_pack_proposed"> |
415 | 97 | No pack is being tested right now. | 134 | No pack is being tested right now. |
416 | 98 | </p> | 135 | </p> |
417 | 136 | </div> | ||
418 | 99 | </div> | 137 | </div> |
419 | 100 | </div> | 138 | </div> |
420 | 101 | </div> | 139 | </div> |
421 | 102 | 140 | ||
422 | 103 | <div class="yui-g"> | 141 | <div class="yui-g"> |
423 | 104 | <div class="yui-u first portlet" tal:condition="view/is_admin"> | 142 | <div class="yui-u first portlet" tal:condition="view/is_admin"> |
426 | 105 | <h2 class="adminlabel" | 143 | <h2 tal:content="view/adminlabel">Language pack settings</h2> |
425 | 106 | tal:content="view/adminlabel">Language pack settings</h2> | ||
427 | 107 | <div metal:use-macro="context/@@launchpad_form/form"> </div> | 144 | <div metal:use-macro="context/@@launchpad_form/form"> </div> |
428 | 108 | </div> | 145 | </div> |
429 | 109 | <div class="yui-u" tal:condition="view/unused_language_packs"> | 146 | <div class="yui-u" tal:condition="view/unused_language_packs"> |
430 | 110 | 147 | ||
431 | === modified file 'lib/lp/translations/templates/distroseries-translations.pt' | |||
432 | --- lib/lp/translations/templates/distroseries-translations.pt 2009-12-16 15:21:36 +0000 | |||
433 | +++ lib/lp/translations/templates/distroseries-translations.pt 2010-04-27 22:26:15 +0000 | |||
434 | @@ -99,13 +99,12 @@ | |||
435 | 99 | context/distribution/@@+language-pack-admin-info" /> | 99 | context/distribution/@@+language-pack-admin-info" /> |
436 | 100 | 100 | ||
437 | 101 | <div> | 101 | <div> |
440 | 102 | <strong>Current base pack:</strong> | 102 | <strong>Base pack:</strong> |
441 | 103 | <a tal:condition="context/language_pack_base" | 103 | <a class="sprite download" |
442 | 104 | tal:condition="context/language_pack_base" | ||
443 | 104 | tal:attributes="href context/language_pack_base/file/http_url"> | 105 | tal:attributes="href context/language_pack_base/file/http_url"> |
444 | 105 | <tal:export-date | 106 | <tal:export-date |
445 | 106 | replace="context/language_pack_base/date_exported/fmt:datetime" /> | 107 | replace="context/language_pack_base/date_exported/fmt:datetime" /> |
446 | 107 | <img tal:condition="context/language_pack_base" | ||
447 | 108 | alt="download icon" src="/@@/download" /> | ||
448 | 109 | </a> | 108 | </a> |
449 | 110 | <tal:not-export-date condition="not: context/language_pack_base"> | 109 | <tal:not-export-date condition="not: context/language_pack_base"> |
450 | 111 | none yet | 110 | none yet |
451 | @@ -113,15 +112,14 @@ | |||
452 | 113 | </div> | 112 | </div> |
453 | 114 | <div> | 113 | <div> |
454 | 115 | <strong>Update pack:</strong> | 114 | <strong>Update pack:</strong> |
456 | 116 | <a tal:condition="context/language_pack_delta" | 115 | <a class="sprite download" |
457 | 116 | tal:condition="context/language_pack_delta" | ||
458 | 117 | tal:attributes="href context/language_pack_delta/file/http_url"> | 117 | tal:attributes="href context/language_pack_delta/file/http_url"> |
459 | 118 | <tal:export-date | 118 | <tal:export-date |
460 | 119 | replace="context/language_pack_delta/date_exported/fmt:datetime" /> | 119 | replace="context/language_pack_delta/date_exported/fmt:datetime" /> |
461 | 120 | <img tal:condition="context/language_pack_delta" | ||
462 | 121 | alt="download icon" src="/@@/download" /> | ||
463 | 122 | </a> | 120 | </a> |
464 | 123 | <tal:not-export-date condition="not: context/language_pack_delta"> | 121 | <tal:not-export-date condition="not: context/language_pack_delta"> |
466 | 124 | none yet | 122 | no update |
467 | 125 | </tal:not-export-date> | 123 | </tal:not-export-date> |
468 | 126 | </div> | 124 | </div> |
469 | 127 | <p> | 125 | <p> |
Looking at the screenshots: any reason to still add 'Current' to the titles on distroseries: +translations page? And don't forget to decapitalize "Base" in "Current Base" on the +language-packs page (not to mention that it'd be nice to find better terminology for these, but I am letting you take care of that with the UI reviewer)