Skip to content

Project: allow connecting a project to a remote repository after it has been created #11498

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Aug 5, 2024

Conversation

stsewd
Copy link
Member

@stsewd stsewd commented Jul 24, 2024

  • Several methods were moved from the ProjectBasicsForm class to the ProjectForm class, and UpdateProjectForm now inherits from ProjectForm. This was so we can use the default form field of the remote repository foreign key, while also sharing some code.

vlcsnap-2024-07-24-17h03m38s272

image

Closes #9437

@stsewd stsewd marked this pull request as ready for review July 31, 2024 21:17
@stsewd stsewd requested a review from a team as a code owner July 31, 2024 21:17
@stsewd stsewd requested a review from humitos July 31, 2024 21:17
@stsewd stsewd requested a review from agjohnson July 31, 2024 21:17
@agjohnson
Copy link
Contributor

I have been pushing to use verbose text for the default/initial widget text:

image

If a project has a connected repository, it should be selected in this dropdown, correct? If so, when there is no connected repository the dropdown initial value might be "No connected repository" instead of "-------".

@stsewd
Copy link
Member Author

stsewd commented Aug 1, 2024

If a project has a connected repository, it should be selected in this dropdown, correct?

yep, I'll change the text of the default empty selection.

@agjohnson
Copy link
Contributor

It might also be worth using something like "Connected repository" instead of "Remote repository" in the user UI, to give a stronger framing to the user about the purpose of the field -- "remote repository" doesn't quite do this.

@stsewd Do the view changes affect the project creation views on either dashboard at all? I'm having trouble figuring this out by looking at the code.

@stsewd
Copy link
Member Author

stsewd commented Aug 1, 2024

@stsewd Do the view changes affect the project creation views on either dashboard at all? I'm having trouble figuring this out by looking at the code.

Nope, that input is still hidden from the creation form.

Copy link
Contributor

@agjohnson agjohnson left a comment

Choose a reason for hiding this comment

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

A couple more notes. I think this is looking really good, I had a couple other comments on the PR that might change this a little bit.

@stsewd stsewd requested a review from agjohnson August 1, 2024 23:28
Copy link
Contributor

@agjohnson agjohnson left a comment

Choose a reason for hiding this comment

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

This looks great!

After this as a first pass, I think we'll eventually want a polish pass on this that adds some more UI or maybe just moves the form view too. This is mostly to add a modal warning or something "Hey, don't change this if you're not sure exactly what this is doing".

But also, we talked about making this a nice UI too, so perhaps that's all one project and it all belongs in a dedicated admin UI.

@humitos
Copy link
Member

humitos commented Aug 5, 2024

Is it possible to make the field searchable in the new dashboard? (similar to what we do at "Add project"). Users with a lot of repositories will have issues finding the correct one.

@stsewd
Copy link
Member Author

stsewd commented Aug 5, 2024

Is it possible to make the field searchable in the new dashboard? (similar to what we do at "Add project"). Users with a lot of repositories will have issues finding the correct one.

It's searchable

@stsewd stsewd merged commit 1e1d553 into main Aug 5, 2024
8 checks passed
@stsewd stsewd deleted the allow-connecting-a-project-to-remote-repo branch August 5, 2024 14:32
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.

OAuth: Connect Project to RemoteRepository automatically
3 participants