BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
1d6adc27
Commit
1d6adc27
authored
May 25, 2018
by
Filipa Lacerda
Committed by
Dmitriy Zaporozhets
May 25, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Handle disabled button state in backend
parent
2ca00a36
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
6 additions
and
21 deletions
+6
-21
application_row.vue
...ssets/javascripts/clusters/components/application_row.vue
+1
-6
applications.vue
app/assets/javascripts/clusters/components/applications.vue
+1
-2
application_row_spec.js
spec/javascripts/clusters/components/application_row_spec.js
+0
-10
applications_spec.js
spec/javascripts/clusters/components/applications_spec.js
+4
-3
No files found.
app/assets/javascripts/clusters/components/application_row.vue
View file @
1d6adc27
...
@@ -52,11 +52,6 @@
...
@@ -52,11 +52,6 @@
type
:
String
,
type
:
String
,
required
:
false
,
required
:
false
,
},
},
disableInstallButton
:
{
type
:
Boolean
,
required
:
false
,
default
:
false
,
},
installApplicationRequestParams
:
{
installApplicationRequestParams
:
{
type
:
Object
,
type
:
Object
,
required
:
false
,
required
:
false
,
...
@@ -77,7 +72,7 @@
...
@@ -77,7 +72,7 @@
// Avoid the potential for the real-time data to say APPLICATION_INSTALLABLE but
// Avoid the potential for the real-time data to say APPLICATION_INSTALLABLE but
// we already made a request to install and are just waiting for the real-time
// we already made a request to install and are just waiting for the real-time
// to sync up.
// to sync up.
return
this
.
disableInstallButton
||
(
this
.
status
!==
APPLICATION_INSTALLABLE
return
(
this
.
status
!==
APPLICATION_INSTALLABLE
&&
this
.
status
!==
APPLICATION_ERROR
)
||
&&
this
.
status
!==
APPLICATION_ERROR
)
||
this
.
requestStatus
===
REQUEST_LOADING
||
this
.
requestStatus
===
REQUEST_LOADING
||
this
.
requestStatus
===
REQUEST_SUCCESS
;
this
.
requestStatus
===
REQUEST_SUCCESS
;
...
...
app/assets/javascripts/clusters/components/applications.vue
View file @
1d6adc27
...
@@ -292,7 +292,6 @@ export default {
...
@@ -292,7 +292,6 @@ export default {
:status-reason=
"applications.jupyter.statusReason"
:status-reason=
"applications.jupyter.statusReason"
:request-status=
"applications.jupyter.requestStatus"
:request-status=
"applications.jupyter.requestStatus"
:request-reason=
"applications.jupyter.requestReason"
:request-reason=
"applications.jupyter.requestReason"
:disable-install-button=
"!ingressInstalled"
:install-application-request-params=
"{ hostname: applications.jupyter.hostname }"
:install-application-request-params=
"{ hostname: applications.jupyter.hostname }"
>
>
<div
slot=
"description"
>
<div
slot=
"description"
>
...
@@ -304,7 +303,7 @@ export default {
...
@@ -304,7 +303,7 @@ export default {
or a scientific research group.`) }}
or a scientific research group.`) }}
</p>
</p>
<
template
v-if=
"ingress
Installed
"
>
<
template
v-if=
"ingress
ExternalIp
"
>
<div
class=
"form-group"
>
<div
class=
"form-group"
>
<label
for=
"jupyter-hostname"
>
<label
for=
"jupyter-hostname"
>
{{
s__
(
'ClusterIntegration|Jupyter Hostname'
)
}}
{{
s__
(
'ClusterIntegration|Jupyter Hostname'
)
}}
...
...
spec/javascripts/clusters/components/application_row_spec.js
View file @
1d6adc27
...
@@ -211,16 +211,6 @@ describe('Application Row', () => {
...
@@ -211,16 +211,6 @@ describe('Application Row', () => {
expect
(
eventHub
.
$emit
).
not
.
toHaveBeenCalled
();
expect
(
eventHub
.
$emit
).
not
.
toHaveBeenCalled
();
});
});
it
(
'is disabled when disableInstallButton prop is provided'
,
()
=>
{
vm
=
mountComponent
(
ApplicationRow
,
{
...
DEFAULT_APPLICATION_STATE
,
status
:
APPLICATION_INSTALLING
,
disableInstallButton
:
true
,
});
expect
(
vm
.
installButtonDisabled
).
toEqual
(
true
);
});
});
});
describe
(
'Error block'
,
()
=>
{
describe
(
'Error block'
,
()
=>
{
...
...
spec/javascripts/clusters/components/applications_spec.js
View file @
1d6adc27
...
@@ -114,7 +114,7 @@ describe('Applications', () => {
...
@@ -114,7 +114,7 @@ describe('Applications', () => {
});
});
describe
(
'Jupyter application'
,
()
=>
{
describe
(
'Jupyter application'
,
()
=>
{
describe
(
'with ingress installed
& jupyter not installed
'
,
()
=>
{
describe
(
'with ingress installed
with ip & jupyter installable
'
,
()
=>
{
it
(
'renders hostname active input'
,
()
=>
{
it
(
'renders hostname active input'
,
()
=>
{
vm
=
mountComponent
(
Applications
,
{
vm
=
mountComponent
(
Applications
,
{
applications
:
{
applications
:
{
...
@@ -122,12 +122,13 @@ describe('Applications', () => {
...
@@ -122,12 +122,13 @@ describe('Applications', () => {
ingress
:
{
title
:
'Ingress'
,
status
:
'installed'
,
externalIp
:
'1.1.1.1'
},
ingress
:
{
title
:
'Ingress'
,
status
:
'installed'
,
externalIp
:
'1.1.1.1'
},
runner
:
{
title
:
'GitLab Runner'
},
runner
:
{
title
:
'GitLab Runner'
},
prometheus
:
{
title
:
'Prometheus'
},
prometheus
:
{
title
:
'Prometheus'
},
jupyter
:
{
title
:
'JupyterHub'
,
hostname
:
''
},
jupyter
:
{
title
:
'JupyterHub'
,
hostname
:
''
,
status
:
'installable'
},
},
},
});
});
expect
(
vm
.
$el
.
querySelector
(
'.js-hostname'
).
getAttribute
(
'readonly'
)).
toEqual
(
null
);
expect
(
vm
.
$el
.
querySelector
(
'.js-hostname'
).
getAttribute
(
'readonly'
)).
toEqual
(
null
);
});
});
describe
(
'with ingress & jupyter installed'
,
()
=>
{
describe
(
'with ingress & jupyter installed'
,
()
=>
{
it
(
'renders readonly input'
,
()
=>
{
it
(
'renders readonly input'
,
()
=>
{
vm
=
mountComponent
(
Applications
,
{
vm
=
mountComponent
(
Applications
,
{
...
@@ -153,7 +154,7 @@ describe('Applications', () => {
...
@@ -153,7 +154,7 @@ describe('Applications', () => {
ingress
:
{
title
:
'Ingress'
},
ingress
:
{
title
:
'Ingress'
},
runner
:
{
title
:
'GitLab Runner'
},
runner
:
{
title
:
'GitLab Runner'
},
prometheus
:
{
title
:
'Prometheus'
},
prometheus
:
{
title
:
'Prometheus'
},
jupyter
:
{
title
:
'JupyterHub'
},
jupyter
:
{
title
:
'JupyterHub'
,
status
:
'not_installable'
},
},
},
});
});
});
});
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment