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
a3c93ee8
Commit
a3c93ee8
authored
Nov 12, 2016
by
Regis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
waiting for api changes
parent
0541bffa
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
14 additions
and
12 deletions
+14
-12
app/assets/javascripts/vue_pipelines_index/branch_commit.js.es6
...sets/javascripts/vue_pipelines_index/branch_commit.js.es6
+6
-2
app/assets/javascripts/vue_pipelines_index/time_ago.js.es6
app/assets/javascripts/vue_pipelines_index/time_ago.js.es6
+8
-10
No files found.
app/assets/javascripts/vue_pipelines_index/branch_commit.js.es6
View file @
a3c93ee8
...
...
@@ -11,13 +11,17 @@
alt() {
return `${this.pipeline.commit.author_name}'s avatar`;
},
avatarUrl() {
const author = this.pipeline.commit.author;
if (author) return author.avatar_url;
return this.pipeline.commit.author_gravatar_url;
},
},
template: `
<td class="branch-commit">
<div class="icon-container">
<i class="fa fa-code-fork"></i>
</div>
<!-- ** will need branch_url for this branch ** -->
<a
class="monospace branch-name"
:href='pipeline.ref.url'
...
...
@@ -45,7 +49,7 @@
:alt='alt'
:title='pipeline.commit.author_name'
data-container="body"
src="http://www.gravatar.com/avatar/80d3b651b4be1f1db39435c2d11f1f23?s=40&d=identicon"
:src='avatarUrl'
>
</a>
<a
...
...
app/assets/javascripts/vue_pipelines_index/time_ago.js.es6
View file @
a3c93ee8
...
...
@@ -19,15 +19,13 @@
seconds(date) {
return this.formatSection(date.getSeconds());
},
},
computed: {
// need started_at or created_at for finish and running
// need created_at or created_at for finish and running
finishdate() {
const date = new Date(
new Date(
this.pipeline.details.finished_at
).getTime() - new Date(
this.pipeline.
star
ted_at
this.pipeline.
crea
ted_at
).getTime()
);
return (
...
...
@@ -36,7 +34,7 @@
},
runningdate() {
const date = new Date(
new Date().getTime() - new Date(this.pipeline.
star
ted_at).getTime()
new Date().getTime() - new Date(this.pipeline.
crea
ted_at).getTime()
);
return (
`${this.hours(date)}:${this.minutes(date)}:${this.seconds(date)}`
...
...
@@ -61,8 +59,8 @@
};
},
duration() {
if (this.timeStopped
) return this.finishdate
;
return this.runningdate;
if (this.timeStopped
()) return this.finishdate()
;
return this.runningdate
()
;
},
},
template: `
...
...
@@ -78,9 +76,9 @@
<path d="M29.513 10.134A15.922 15.922 0 0 0 23 7.28V6h2.993C26.55 6 27 5.552 27 5V2a1 1 0 0 0-1.007-1H14.007C13.45 1 13 1.448 13 2v3a1 1 0 0 0 1.007 1H17v1.28C9.597 8.686 4 15.19 4 23c0 8.837 7.163 16 16 16s16-7.163 16-16c0-3.461-1.099-6.665-2.967-9.283l1.327-1.58a2.498 2.498 0 0 0-.303-3.53 2.499 2.499 0 0 0-3.528.315l-1.016 1.212zM20 34c6.075 0 11-4.925 11-11s-4.925-11-11-11S9 16.925 9 23s4.925 11 11 11z"></path><path d="M19 21h-4.002c-.552 0-.998.452-.998 1.01v1.98c0 .567.447 1.01.998 1.01h7.004c.274 0 .521-.111.701-.291a.979.979 0 0 0 .297-.704v-8.01c0-.54-.452-.995-1.01-.995h-1.98a.997.997 0 0 0-1.01.995V21z"></path>
</g>
</svg>
{{duration}}
{{duration
()
}}
</p>
<p class="finished-at" v-if='timeStopped'>
<p class="finished-at" v-if='timeStopped
()
'>
<i class="fa fa-calendar"></i>
<time
data-toggle="tooltip"
...
...
@@ -88,7 +86,7 @@
data-container="body"
:data-original-title='9 + 9'
>
{{timeStopped.words}}
{{timeStopped
()
.words}}
</time>
</p>
</td>
...
...
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