Commit 7fe1dc43 authored by Jacob Schatz's avatar Jacob Schatz

Merge branch 'ee-dispatcher-projects-mr-creation-new' into 'master'

Refactor dispatcher project mr creations new path (EE)

See merge request gitlab-org/gitlab-ee!4031
parents 76f90950 9b42e8a5
...@@ -4,7 +4,6 @@ import NotificationsForm from './notifications_form'; ...@@ -4,7 +4,6 @@ import NotificationsForm from './notifications_form';
import notificationsDropdown from './notifications_dropdown'; import notificationsDropdown from './notifications_dropdown';
import LineHighlighter from './line_highlighter'; import LineHighlighter from './line_highlighter';
import MergeRequest from './merge_request'; import MergeRequest from './merge_request';
import Compare from './compare';
import initCompareAutocomplete from './compare_autocomplete'; import initCompareAutocomplete from './compare_autocomplete';
import Sidebar from './right_sidebar'; import Sidebar from './right_sidebar';
import Flash from './flash'; import Flash from './flash';
...@@ -240,19 +239,9 @@ import initLDAPGroupsSelect from 'ee/ldap_groups_select'; // eslint-disable-line ...@@ -240,19 +239,9 @@ import initLDAPGroupsSelect from 'ee/ldap_groups_select'; // eslint-disable-line
shortcut_handler = true; shortcut_handler = true;
break; break;
case 'projects:merge_requests:creations:new': case 'projects:merge_requests:creations:new':
const mrNewCompareNode = document.querySelector('.js-merge-request-new-compare'); import('./pages/projects/merge_requests/creations/new')
if (mrNewCompareNode) { .then(callDefault)
new Compare({ .catch(fail);
targetProjectUrl: mrNewCompareNode.dataset.targetProjectUrl,
sourceBranchUrl: mrNewCompareNode.dataset.sourceBranchUrl,
targetBranchUrl: mrNewCompareNode.dataset.targetBranchUrl,
});
} else {
const mrNewSubmitNode = document.querySelector('.js-merge-request-new-submit');
new MergeRequest({
action: mrNewSubmitNode.dataset.mrSubmitAction,
});
}
new UserCallout(); new UserCallout();
case 'projects:merge_requests:creations:diffs': case 'projects:merge_requests:creations:diffs':
import('./pages/projects/merge_requests/creations/diffs') import('./pages/projects/merge_requests/creations/diffs')
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment