diff --git a/app/assets/javascripts/vue_pipelines_index/components/nav_controls.js b/app/assets/javascripts/vue_pipelines_index/components/nav_controls.js index 73eaaf6aa720529d3af69cfc91923e425259c1c8..6aa10531034593ebcbc82aee316ec09e8a4af578 100644 --- a/app/assets/javascripts/vue_pipelines_index/components/nav_controls.js +++ b/app/assets/javascripts/vue_pipelines_index/components/nav_controls.js @@ -5,7 +5,7 @@ export default { required: true, }, - hasCIEnabled: { + hasCiEnabled: { type: Boolean, required: true, }, @@ -36,7 +36,7 @@ export default { </a> <a - v-if="!hasCIEnabled" + v-if="!hasCiEnabled" :href="helpPagePath" class="btn btn-info"> Get started with Pipelines diff --git a/app/assets/javascripts/vue_pipelines_index/pipelines.js b/app/assets/javascripts/vue_pipelines_index/pipelines.js index b6721600415279c5eec8092f3efeeb2850275238..48f0e9036e8fda4134c2fdd0f10cfa8d8d815fbc 100644 --- a/app/assets/javascripts/vue_pipelines_index/pipelines.js +++ b/app/assets/javascripts/vue_pipelines_index/pipelines.js @@ -106,7 +106,7 @@ export default { this.state.pageInfo.total > this.state.pageInfo.perPage; }, - hasCIEnabled() { + hasCiEnabled() { return this.hasCi !== undefined; }, @@ -190,11 +190,11 @@ export default { :paths="paths" /> <navigation-controls - :newPipelinePath="newPipelinePath" - :hasCIEnabled="hasCIEnabled" - :helpPagePath="helpPagePath" + :new-pipeline-path="newPipelinePath" + :has-ci-enabled="hasCiEnabled" + :help-page-path="helpPagePath" :ciLintPath="ciLintPath" - :canCreatePipeline="canCreatePipelineParsed " /> + :can-create-pipeline="canCreatePipelineParsed " /> </div> <div class="content-list pipelines"> diff --git a/spec/javascripts/vue_pipelines_index/nav_controls_spec.js b/spec/javascripts/vue_pipelines_index/nav_controls_spec.js index 8283e53c8b16cefca68aaf7dd8adeefa58c0a7b6..659c4854a561408b88b62f129015849340302f0e 100644 --- a/spec/javascripts/vue_pipelines_index/nav_controls_spec.js +++ b/spec/javascripts/vue_pipelines_index/nav_controls_spec.js @@ -11,7 +11,7 @@ describe('Pipelines Nav Controls', () => { it('should render link to create a new pipeline', () => { const mockData = { newPipelinePath: 'foo', - hasCIEnabled: true, + hasCiEnabled: true, helpPagePath: 'foo', ciLintPath: 'foo', canCreatePipeline: true, @@ -28,7 +28,7 @@ describe('Pipelines Nav Controls', () => { it('should not render link to create pipeline if no permission is provided', () => { const mockData = { newPipelinePath: 'foo', - hasCIEnabled: true, + hasCiEnabled: true, helpPagePath: 'foo', ciLintPath: 'foo', canCreatePipeline: false, @@ -44,7 +44,7 @@ describe('Pipelines Nav Controls', () => { it('should render link for CI lint', () => { const mockData = { newPipelinePath: 'foo', - hasCIEnabled: true, + hasCiEnabled: true, helpPagePath: 'foo', ciLintPath: 'foo', canCreatePipeline: true, @@ -61,7 +61,7 @@ describe('Pipelines Nav Controls', () => { it('should render link to help page when CI is not enabled', () => { const mockData = { newPipelinePath: 'foo', - hasCIEnabled: false, + hasCiEnabled: false, helpPagePath: 'foo', ciLintPath: 'foo', canCreatePipeline: true, @@ -78,7 +78,7 @@ describe('Pipelines Nav Controls', () => { it('should not render link to help page when CI is enabled', () => { const mockData = { newPipelinePath: 'foo', - hasCIEnabled: true, + hasCiEnabled: true, helpPagePath: 'foo', ciLintPath: 'foo', canCreatePipeline: true,