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
eb337554
Commit
eb337554
authored
Apr 20, 2017
by
Phil Hughes
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'rollback-component-vue' into 'master'
Refactor into .vue files See merge request !10788
parents
9c59667f
d4021122
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
58 additions
and
20 deletions
+58
-20
app/assets/javascripts/environments/components/environment_item.js
...s/javascripts/environments/components/environment_item.js
+2
-2
app/assets/javascripts/environments/components/environment_monitoring.vue
...cripts/environments/components/environment_monitoring.vue
+33
-0
app/assets/javascripts/environments/components/environment_rollback.vue
...ascripts/environments/components/environment_rollback.vue
+21
-16
spec/javascripts/environments/environment_monitoring_spec.js
spec/javascripts/environments/environment_monitoring_spec.js
+1
-1
spec/javascripts/environments/environment_rollback_spec.js
spec/javascripts/environments/environment_rollback_spec.js
+1
-1
No files found.
app/assets/javascripts/environments/components/environment_item.js
View file @
eb337554
...
...
@@ -3,9 +3,9 @@ import '../../lib/utils/text_utility';
import
ActionsComponent
from
'
./environment_actions
'
;
import
ExternalUrlComponent
from
'
./environment_external_url.vue
'
;
import
StopComponent
from
'
./environment_stop.vue
'
;
import
RollbackComponent
from
'
./environment_rollback
'
;
import
RollbackComponent
from
'
./environment_rollback
.vue
'
;
import
TerminalButtonComponent
from
'
./environment_terminal_button.vue
'
;
import
MonitoringButtonComponent
from
'
./environment_monitoring
'
;
import
MonitoringButtonComponent
from
'
./environment_monitoring
.vue
'
;
import
CommitComponent
from
'
../../vue_shared/components/commit
'
;
import
eventHub
from
'
../event_hub
'
;
...
...
app/assets/javascripts/environments/components/environment_monitoring.
js
→
app/assets/javascripts/environments/components/environment_monitoring.
vue
View file @
eb337554
<
script
>
/**
* Renders the Monitoring (Metrics) link in environments table.
*/
...
...
@@ -5,7 +6,6 @@ export default {
props
:
{
monitoringUrl
:
{
type
:
String
,
default
:
''
,
required
:
true
,
},
},
...
...
@@ -15,16 +15,19 @@ export default {
return
'
Monitoring
'
;
},
},
template
:
`
};
</
script
>
<
template
>
<a
class=
"btn monitoring-url has-tooltip"
data-container=
"body"
:href="monitoringUrl
"
target=
"_blank
"
rel=
"noopener noreferrer nofollow"
:href=
"monitoringUrl"
:title=
"title"
:aria-label=
"title"
>
<i class="fa fa-area-chart" aria-hidden="true"></i>
<i
class=
"fa fa-area-chart"
aria-hidden=
"true"
/>
</a>
`
,
};
</
template
>
app/assets/javascripts/environments/components/environment_rollback.
js
→
app/assets/javascripts/environments/components/environment_rollback.
vue
View file @
eb337554
<
script
>
/* global Flash */
/* eslint-disable no-new */
/**
...
...
@@ -49,9 +50,11 @@ export default {
});
},
},
template
:
`
<button type="button"
};
</
script
>
<
template
>
<button
type=
"button"
class=
"btn"
@
click=
"onClick"
:disabled=
"isLoading"
>
...
...
@@ -63,7 +66,9 @@ export default {
Rollback
</span>
<i v-if="isLoading" class="fa fa-spinner fa-spin" aria-hidden="true"></i>
<i
v-if=
"isLoading"
class=
"fa fa-spinner fa-spin"
aria-hidden=
"true"
/>
</button>
`
,
};
</
template
>
spec/javascripts/environments/environment_monitoring_spec.js
View file @
eb337554
import
Vue
from
'
vue
'
;
import
monitoringComp
from
'
~/environments/components/environment_monitoring
'
;
import
monitoringComp
from
'
~/environments/components/environment_monitoring
.vue
'
;
describe
(
'
Monitoring Component
'
,
()
=>
{
let
MonitoringComponent
;
...
...
spec/javascripts/environments/environment_rollback_spec.js
View file @
eb337554
import
Vue
from
'
vue
'
;
import
rollbackComp
from
'
~/environments/components/environment_rollback
'
;
import
rollbackComp
from
'
~/environments/components/environment_rollback
.vue
'
;
describe
(
'
Rollback Component
'
,
()
=>
{
const
retryURL
=
'
https://gitlab.com/retry
'
;
...
...
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