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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
b61e1e7a
Commit
b61e1e7a
authored
Jun 06, 2018
by
Stan Hu
Committed by
Clement Ho
Jun 06, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix invisible rows on importer status
parent
53457cb0
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
9 deletions
+9
-9
app/assets/javascripts/importer_status.js
app/assets/javascripts/importer_status.js
+2
-2
app/helpers/projects_helper.rb
app/helpers/projects_helper.rb
+3
-3
spec/helpers/projects_helper_spec.rb
spec/helpers/projects_helper_spec.rb
+3
-3
spec/javascripts/importer_status_spec.js
spec/javascripts/importer_status_spec.js
+1
-1
No files found.
app/assets/javascripts/importer_status.js
View file @
b61e1e7a
...
...
@@ -58,7 +58,7 @@ class ImporterStatus {
job
.
find
(
'
.import-target
'
).
html
(
`<a href="
${
data
.
full_path
}
">
${
data
.
full_path
}
</a>`
);
$
(
'
table.import-jobs tbody
'
).
prepend
(
job
);
job
.
addClass
(
'
active
'
);
job
.
addClass
(
'
table-
active
'
);
const
connectingVerb
=
this
.
ciCdOnly
?
__
(
'
connecting
'
)
:
__
(
'
importing
'
);
job
.
find
(
'
.import-actions
'
).
html
(
sprintf
(
_
.
escape
(
__
(
'
%{loadingIcon} Started
'
)),
{
...
...
@@ -81,7 +81,7 @@ class ImporterStatus {
switch
(
job
.
import_status
)
{
case
'
finished
'
:
jobItem
.
removeClass
(
'
active
'
).
addClass
(
'
success
'
);
jobItem
.
removeClass
(
'
table-active
'
).
addClass
(
'
table-
success
'
);
statusField
.
html
(
`<span><i class="fa fa-check"></i>
${
__
(
'
Done
'
)}
</span>`
);
break
;
case
'
scheduled
'
:
...
...
app/helpers/projects_helper.rb
View file @
b61e1e7a
...
...
@@ -389,11 +389,11 @@ module ProjectsHelper
def
project_status_css_class
(
status
)
case
status
when
"started"
"active"
"
table-
active"
when
"failed"
"danger"
"
table-
danger"
when
"finished"
"success"
"
table-
success"
end
end
...
...
spec/helpers/projects_helper_spec.rb
View file @
b61e1e7a
...
...
@@ -5,9 +5,9 @@ describe ProjectsHelper do
describe
"#project_status_css_class"
do
it
"returns appropriate class"
do
expect
(
project_status_css_class
(
"started"
)).
to
eq
(
"active"
)
expect
(
project_status_css_class
(
"failed"
)).
to
eq
(
"danger"
)
expect
(
project_status_css_class
(
"finished"
)).
to
eq
(
"success"
)
expect
(
project_status_css_class
(
"started"
)).
to
eq
(
"
table-
active"
)
expect
(
project_status_css_class
(
"failed"
)).
to
eq
(
"
table-
danger"
)
expect
(
project_status_css_class
(
"finished"
)).
to
eq
(
"
table-
success"
)
end
end
...
...
spec/javascripts/importer_status_spec.js
View file @
b61e1e7a
...
...
@@ -45,7 +45,7 @@ describe('Importer Status', () => {
currentTarget
:
document
.
querySelector
(
'
.js-add-to-import
'
),
})
.
then
(()
=>
{
expect
(
document
.
querySelector
(
'
tr
'
).
classList
.
contains
(
'
active
'
)).
toEqual
(
true
);
expect
(
document
.
querySelector
(
'
tr
'
).
classList
.
contains
(
'
table-
active
'
)).
toEqual
(
true
);
done
();
})
.
catch
(
done
.
fail
);
...
...
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