Skip to content

Improve presentation#155

Open
evildmp wants to merge 12 commits intocanonical:next-releasefrom
evildmp:improve-presentation
Open

Improve presentation#155
evildmp wants to merge 12 commits intocanonical:next-releasefrom
evildmp:improve-presentation

Conversation

@evildmp
Copy link
Copy Markdown
Collaborator

@evildmp evildmp commented Apr 24, 2026

Depends on #153; merge that first

Added a tabbed interface, fixed up some minor interface misalignment, improved the project overview

I used Copilot to produce most of this as an experiment.

evildmp added 12 commits April 27, 2026 17:36
Updated:

test_toggle_condition_url_patterns (Simplified, and now only checks the
reversed route, rather than the string)

New checks for user permissions:

* test_action_toggle_commitment_denies_user_without_permission
* test_action_toggle_condition_denies_user_without_permission
* test_action_select_reason_denies_user_without_permission

New checks for HTTP methods:

* test_action_toggle_commitment_rejects_non_put_method
* test_action_toggle_condition_rejects_non_put_method
* test_action_select_reason_rejects_non_put_method

New checks for expected results:

new: test_action_toggle_commitment_allows_authorized_put_and_updates_commitment
new: test_action_toggle_condition_allows_authorized_put_and_updates_status
new: test_action_select_reason_allows_authorized_put_and_sets_reason

I used Copilot to help create these tests.
This fixes an auth issue. It was possible to POST a
change to a project, without even being authenticated.
The only safeguard was the user interface, that didn't
offer make it possible.

This adds @permission_required("projects.change_project")
to the view, and some tests.

* added a fixture for a user with  permission to change a project
* added a test: do we reject changes from unauthenticated users?
* added a test: do we reject changes from unauthorised users?
* added a test: do we allow and save changes from users with the right permissions?

I used Copilot to uncover the issue and help create the tests.
Previously, the project list was lazy-loaded with htmx. This update
restores the bulk delivery of the page, along with opportuities for
substantially reducing the number of per-row queries. With luck, this
should turn out to be fast enough in practice that we can keep this
approach.
The interface now has tabs, for each objective group.

The overview tab has been given some basic styling.
@evildmp evildmp force-pushed the improve-presentation branch from 99b82b0 to 1959217 Compare April 27, 2026 17:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant