After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 728049 - Add "Join team" option to teams page
Add "Join team" option to teams page
Status: RESOLVED OBSOLETE
Product: damned-lies
Classification: Infrastructure
Component: general
unspecified
Other Linux
: High enhancement
: ---
Assigned To: gregoire
damned-lies Maintainer(s)
Depends on:
Blocks:
 
 
Reported: 2014-04-11 17:27 UTC by Tom Tryfonidis
Modified: 2018-05-22 12:18 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Join option in teams list page (4.06 KB, image/png)
2014-04-11 17:28 UTC, Tom Tryfonidis
  Details
Join option in a team page (18.62 KB, image/png)
2014-04-11 17:30 UTC, Tom Tryfonidis
  Details
Add join/leave buttons to teams page (9.19 KB, patch)
2015-08-12 10:47 UTC, gregoire
none Details | Review
> Testing URL resolution does not bring much value IMHO. This is Django's job (23.65 KB, patch)
2015-08-13 13:34 UTC, gregoire
none Details | Review

Description Tom Tryfonidis 2014-04-11 17:27:32 UTC
At the moment this page https://l10n.gnome.org/teams/ displays a list with the translation teams of GNOME along with the coordinator.It would be nice to add an option to join a team.

Also this can be done to the teams pages,somewhere next to the title you could add this option with some information about the role of a user.
Comment 1 Tom Tryfonidis 2014-04-11 17:28:46 UTC
Created attachment 274122 [details]
Join option in teams list page
Comment 2 Tom Tryfonidis 2014-04-11 17:30:07 UTC
Created attachment 274123 [details]
Join option in a team page
Comment 3 Claude Paroz 2014-04-13 19:14:09 UTC
I'm not fond of the first proposal, but the second one could be nice.
Comment 4 Alexandre Franke 2015-06-05 13:21:32 UTC
Tom, did you actually work on a patch or are these images just mockups?
Comment 5 Tom Tryfonidis 2015-06-06 17:07:14 UTC
(In reply to Alexandre Franke from comment #4)
> Tom, did you actually work on a patch or are these images just mockups?

Alexandre they are mockups.
Comment 6 Alexandre Franke 2015-06-06 17:47:59 UTC
Thanks, I'll try to come up with a patch.
Comment 7 gregoire 2015-08-12 10:47:14 UTC
Created attachment 309137 [details] [review]
Add join/leave buttons to teams page

With corresponding views and associated tests.

I created new test files because I like to use test_foo when working on
module foo but I can put them in test.py if you prefer.
Comment 8 Claude Paroz 2015-08-12 15:37:42 UTC
Review of attachment 309137 [details] [review]:

::: teams/test_urls.py
@@ +13,3 @@
+    def test_team_leave_url(self):
+        self.assertEqual("/teams/fr/leave/",
+                reverse('team_leave', args = ['fr'], current_app='teams'))

Testing URL resolution does not bring much value IMHO. This is Django's job and I trust it :-) I would simply remove this file.
Instead I would use the reverse in test_views.py (self.url = reverse('team_join', args = ['gl']), the less hardcoded urls the better, even in tests.

::: teams/urls.py
@@ +25,1 @@
 )

There are already team_join/team_leave urls and views in the people app. If you really think they are better placed here, then delete the others. Otherwise, these are simply duplicates.
Comment 9 gregoire 2015-08-13 13:34:51 UTC
Created attachment 309207 [details] [review]
> Testing URL resolution does not bring much value IMHO. This is Django's job

> and I trust it :-) I would simply remove this file.

I respectfully disagree :-)
While I do trust django, I don't trust me and I think the url tests have
some value, especially if using reverse in the view tests:
- checking that I did't screw-up the regex and the order of url definitions
- checking that the url doesn't change. If you use reverse everywhere this
  wouldn't break any internal links but it might break links from outside.
  (it might not be relevant in this particular case though as those views
  are crsf protected).
But I changed the tests to use resolve instead of reverse.

> Instead I would use the reverse in test_views.py (self.url =
> reverse('team_join', args = ['gl']), the less hardcoded urls the better, even
> in tests.

Fixed.

> There are already team_join/team_leave urls and views in the people app. If
> you really think they are better placed here, then delete the others.
> Otherwise, these are simply duplicates.

Oups, I didn't see those.
I have now merged them together but left them in teams.views: I thought that
they could be seen as create/delete views for Role objects and Role is defined
in teams.models.
Comment 10 Mingye Wang 2015-11-08 17:35:23 UTC
The second proposal can be nice.
Comment 11 GNOME Infrastructure Team 2018-05-22 12:18:03 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/damned-lies/issues/54.