| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Add a series list view - as opposed to the default view which shows patches, this new view shows a list of all series. This is a much easier way to navigate and manage large repositories with 100+ patches (Some series alone contain more than 20-30 patches in a single series). This view will allow simple management of patch series. This version is MVP - and contains the basic view needed to navigate around.
|
As a user who missed the series view that presumably was in our ancient/horrible fork, this is great. Can you make the list show the number of patches in the series somewhere? |
Sorry, something went wrong.
Thanks, yes I'll work on it |
Sorry, something went wrong.
|
I've held of doing this because I wanted to add support for boolean Series states first, i.e. a series is either open/closed depending on the status of the state field of each associated Patch. I think this is still the priority, because without this the series page grows without end. This is also an issues with the /series APIs, fwiw. I wonder if you'd be interested in working on that first? I suspect we can derive the value of an e.g. Series.is_open or Series.resolved field by inspecting the value of Patch.series.action_required. If action_required is False, the patch can be consider "closed". If all patches are "closed", then Series.is_open can be set to False. This can be done both in an initial migration and at runtime whenever we change the state of a patch (via the save method). There are some other minor issues with the patch, which I'll leave comments for shortly, but I'd rather focus on closing the above first before we consider merging this. |
Sorry, something went wrong.
| </td> | ||
| </tr> | ||
| </table> | ||
| {% endif %} |
There was a problem hiding this comment.
This code is for bundles and doesn't do anything here. It can be removed.
Sorry, something went wrong.
| e.preventDefault(); | ||
| }); | ||
| }); | ||
| </script> |
There was a problem hiding this comment.
Are we doing anything with the checkboxes? Given we don't have any widgets for updating a series, I'd assume not? If so, do we need this?
Sorry, something went wrong.
| @@ -0,0 +1,154 @@ | |||
| {% load person %} | |||
There was a problem hiding this comment.
This doesn't need to be a partial. The only reason we have a patch-list partial is because we re-use that partial for both the patch list view and the bundle view (bundles are just lists of patches). You can combine this into series.html.
Sorry, something went wrong.
| name='patch-list', | ||
| ), | ||
| path( | ||
| 'project/<project_id>/series-list/', |
There was a problem hiding this comment.
We should align this with the URL structure of the rest of the URLs. For example, project/<project_id>/series/.
We'll also eventually need a series detail view (and a new-style mbox and patch view), but it's okay to tackle that separately.
Sorry, something went wrong.
|
|
||
| if patches is None: | ||
| patches = Patch.objects.filter(project=project) | ||
| if series_view: |
There was a problem hiding this comment.
Given we're not modifying anything here, I don't think there's any reason to re-use this function. It's already way too complicated for it's own good. Better to split this out into a new view function, IMO.
Sorry, something went wrong.
| ) | ||
|
|
||
| if request.user.is_authenticated: | ||
| context['bundles'] = request.user.bundles.all() |
There was a problem hiding this comment.
This isn't used anywhere so it doesn't need to be here.
Sorry, something went wrong.
|
hi @stephenfin, any plans to merge this PR or a similar one to Patchwork? During last media summit, people asked about their need to have such feature. I ended applying this one on media as a test, as it doesn't require any migrations. It did work, but the result is not so great, as it currently misses a way to filter patch series and group patch series versions. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
Add a series list view - as opposed to the default view which shows patches, this new view shows a list of all series. This is a much easier way to navigate and manage large repositories with 100+ patches (Some series alone contain more than 20-30 patches in a single series). This view will allow simple management of patch series. This version is MVP - and contains the basic view needed to navigate around.
Closes #509