Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
38183049
Commit
38183049
authored
Sep 06, 2017
by
Filipa Lacerda
Committed by
Phil Hughes
Sep 06, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Sets the deploy board to be closed by default
parent
27665edc
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
6 additions
and
11 deletions
+6
-11
app/assets/javascripts/environments/components/deploy_board_component.vue
...cripts/environments/components/deploy_board_component.vue
+1
-3
app/assets/javascripts/environments/stores/environments_store.js
...ets/javascripts/environments/stores/environments_store.js
+1
-3
spec/javascripts/environments/environments_store_spec.js
spec/javascripts/environments/environments_store_spec.js
+4
-5
No files found.
app/assets/javascripts/environments/components/deploy_board_component.vue
View file @
38183049
...
@@ -66,9 +66,7 @@
...
@@ -66,9 +66,7 @@
<
template
>
<
template
>
<div
class=
"js-deploy-board deploy-board"
>
<div
class=
"js-deploy-board deploy-board"
>
<div
v-if=
"isLoading"
>
<loading-icon
v-if=
"isLoading"
/>
<loading-icon
/>
</div>
<div
v-if=
"canRenderDeployBoard"
>
<div
v-if=
"canRenderDeployBoard"
>
...
...
app/assets/javascripts/environments/stores/environments_store.js
View file @
38183049
...
@@ -68,9 +68,7 @@ export default class EnvironmentsStore {
...
@@ -68,9 +68,7 @@ export default class EnvironmentsStore {
if
(
filtered
.
size
===
1
&&
filtered
.
rollout_status_path
)
{
if
(
filtered
.
size
===
1
&&
filtered
.
rollout_status_path
)
{
filtered
=
Object
.
assign
({},
filtered
,
{
filtered
=
Object
.
assign
({},
filtered
,
{
hasDeployBoard
:
true
,
hasDeployBoard
:
true
,
isDeployBoardVisible
:
oldEnvironmentState
.
isDeployBoardVisible
===
false
?
isDeployBoardVisible
:
oldEnvironmentState
.
isDeployBoardVisible
||
false
,
oldEnvironmentState
.
isDeployBoardVisible
:
true
,
deployBoardData
:
oldEnvironmentState
.
deployBoardData
||
{},
deployBoardData
:
oldEnvironmentState
.
deployBoardData
||
{},
isLoadingDeployBoard
:
oldEnvironmentState
.
isLoadingDeployBoard
||
false
,
isLoadingDeployBoard
:
oldEnvironmentState
.
isLoadingDeployBoard
||
false
,
hasErrorDeployBoard
:
oldEnvironmentState
.
hasErrorDeployBoard
||
false
,
hasErrorDeployBoard
:
oldEnvironmentState
.
hasErrorDeployBoard
||
false
,
...
...
spec/javascripts/environments/environments_store_spec.js
View file @
38183049
...
@@ -31,7 +31,7 @@ describe('Store', () => {
...
@@ -31,7 +31,7 @@ describe('Store', () => {
updated_at
:
'
2017-01-31T10:53:46.894Z
'
,
updated_at
:
'
2017-01-31T10:53:46.894Z
'
,
rollout_status_path
:
'
/path
'
,
rollout_status_path
:
'
/path
'
,
hasDeployBoard
:
true
,
hasDeployBoard
:
true
,
isDeployBoardVisible
:
tru
e
,
isDeployBoardVisible
:
fals
e
,
deployBoardData
:
{},
deployBoardData
:
{},
isLoadingDeployBoard
:
false
,
isLoadingDeployBoard
:
false
,
hasErrorDeployBoard
:
false
,
hasErrorDeployBoard
:
false
,
...
@@ -70,7 +70,7 @@ describe('Store', () => {
...
@@ -70,7 +70,7 @@ describe('Store', () => {
store
.
storeEnvironments
([
environment
]);
store
.
storeEnvironments
([
environment
]);
expect
(
store
.
state
.
environments
[
0
].
hasDeployBoard
).
toEqual
(
true
);
expect
(
store
.
state
.
environments
[
0
].
hasDeployBoard
).
toEqual
(
true
);
expect
(
store
.
state
.
environments
[
0
].
isDeployBoardVisible
).
toEqual
(
tru
e
);
expect
(
store
.
state
.
environments
[
0
].
isDeployBoardVisible
).
toEqual
(
fals
e
);
expect
(
store
.
state
.
environments
[
0
].
deployBoardData
).
toEqual
({});
expect
(
store
.
state
.
environments
[
0
].
deployBoardData
).
toEqual
({});
});
});
...
@@ -201,7 +201,7 @@ describe('Store', () => {
...
@@ -201,7 +201,7 @@ describe('Store', () => {
it
(
'
should toggle deploy board property for given environment id
'
,
()
=>
{
it
(
'
should toggle deploy board property for given environment id
'
,
()
=>
{
store
.
toggleDeployBoard
(
1
);
store
.
toggleDeployBoard
(
1
);
expect
(
store
.
state
.
environments
[
0
].
isDeployBoardVisible
).
toEqual
(
fals
e
);
expect
(
store
.
state
.
environments
[
0
].
isDeployBoardVisible
).
toEqual
(
tru
e
);
});
});
it
(
'
should store deploy board data for given environment id
'
,
()
=>
{
it
(
'
should store deploy board data for given environment id
'
,
()
=>
{
...
@@ -248,8 +248,7 @@ describe('Store', () => {
...
@@ -248,8 +248,7 @@ describe('Store', () => {
store
.
storeEnvironments
([
environment
]);
store
.
storeEnvironments
([
environment
]);
expect
(
store
.
getOpenDeployBoards
().
length
).
toEqual
(
1
);
expect
(
store
.
getOpenDeployBoards
().
length
).
toEqual
(
0
);
expect
(
store
.
getOpenDeployBoards
()[
0
].
id
).
toEqual
(
environment
.
latest
.
id
);
});
});
});
});
});
});
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