Commit 27a6d65c authored by Clement Ho's avatar Clement Ho

Add dispatcher imports for job details bundle

parent efdde042
......@@ -192,6 +192,11 @@ var Dispatcher;
.catch(fail);
shortcut_handler = true;
break;
case 'projects:jobs:show':
import('./pages/projects/jobs/show')
.then(callDefault)
.catch(fail);
break;
case 'projects:merge_requests:creations:new':
import('./pages/projects/merge_requests/creations/new')
.then(callDefault)
......
......@@ -3,7 +3,7 @@ import JobMediator from './job_details_mediator';
import jobHeader from './components/header.vue';
import detailsBlock from './components/sidebar_details_block.vue';
document.addEventListener('DOMContentLoaded', () => {
export default () => {
const dataset = document.getElementById('js-job-details-vue').dataset;
const mediator = new JobMediator({ endpoint: dataset.endpoint });
......@@ -55,4 +55,4 @@ document.addEventListener('DOMContentLoaded', () => {
});
},
});
});
};
import initJobDetails from '~/jobs/job_details_bundle';
export default initJobDetails;
......@@ -112,7 +112,3 @@
.js-build-options{ data: javascript_build_options }
#js-job-details-vue{ data: { endpoint: project_job_path(@project, @build, format: :json) } }
- content_for :page_specific_javascripts do
= webpack_bundle_tag('common_vue')
= webpack_bundle_tag('job_details')
......@@ -68,7 +68,6 @@ var config = {
help: './help/help.js',
how_to_merge: './how_to_merge.js',
issue_show: './issue_show/index.js',
job_details: './jobs/job_details_bundle.js',
locale: './locale/index.js',
main: './main.js',
merge_conflicts: './merge_conflicts/merge_conflicts_bundle.js',
......@@ -263,7 +262,6 @@ var config = {
'filtered_search',
'groups',
'issue_show',
'job_details',
'merge_conflicts',
'monitoring',
'notebook_viewer',
......
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