Fix editable branch dropdown on MR creation screen
is part of https://gitlab.com/gitlab-org/gitlab-ce/issues/27108
Description
It would be nice to be able to change branch on new merge request page, instead of having to go to dedicated page for that.
Why is this as is?
was introduced in !856 (merged) because of #1830 (closed). It seems that enabling the dropdowns to change branches was the original intended functionality, but it did not work correctly, so the solution was to disable the dropdown if the target branch has already been specified (which is the case when creating a MR from the helpful "You pushed to a minute ago / Create Merge Request" button or from clicking the link in the git output after pushing from the CLI).
cc: @stanhu @DouweM @smcgivern @denaje
Proposal
Fetch branches list for dropdown on new merge request page (merge_requests/new
) instead on (merge_requests/new?change_branches=true&..
).
It's ajax call anyway :)
// via https://twitter.com/lesa_ns/status/771251999434153984