Skip to content

Allow a submission to have multiple projects associated#4897

Open
frjo wants to merge 6 commits into
mainfrom
feature/multiprojects
Open

Allow a submission to have multiple projects associated#4897
frjo wants to merge 6 commits into
mainfrom
feature/multiprojects

Conversation

@frjo

@frjo frjo commented Jul 1, 2026

Copy link
Copy Markdown
Member

Fixes #4869

Test Steps

  • Tests that PROJECTS_ALLOW_MULTIPLE, default false, makes everything work as before, single project per submission.
  • Test that setting PROJECTS_ALLOW_MULTIPLE to true allow multiple projects to be created.
  • Test that multiple projects works with reports, invoices etc. Functionality within each project should be unchanged.
  • Test that all project url:s work as expected. They are now in the form "apply/submissions/1234/project/4/". The last part, project id, was added to handle multiple projects per submission.

@frjo frjo marked this pull request as draft July 1, 2026 08:11
@frjo frjo marked this pull request as ready for review July 1, 2026 08:28
@frjo frjo requested a review from wes-otf July 1, 2026 08:32

@wes-otf wes-otf left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is such an elegant solution! Did a pretty intensive test and it seems like everything is working as expected. The fact that I even changed MULTIPLE_PROJECTS_ENABLED=1MULTIPLE_PROJECTS_ENABLED=0 and nothing broke but preserved the multiple projects while not allowing multiples to be created moving forward was also really impressive. All the x.submission.idx.pk changes look like they must've been painful hahaha.

Overall great work!

Comment on lines +2 to +10
{% comment %}
Renders the "Project(s)" tab inside a submission/project tablist.

Params:
submission – the ApplicationSubmission
user – the current user (for access filtering)
current_project – the project being viewed, if any (for active item highlight)
active – whether this tab is the active one
{% endcomment %}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like this format of kinda docstringing a template! super useful when trying to track down what the variables used are & where they come from

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.

Allow for submissions to be one to many with projects

2 participants