diff options
author | Kamil Trzciński <ayufan@ayufan.eu> | 2018-02-28 21:11:53 +0100 |
---|---|---|
committer | Kamil Trzciński <ayufan@ayufan.eu> | 2018-02-28 21:11:53 +0100 |
commit | 729391fbfce4dea58478b65c684a24a1bfd125a2 (patch) | |
tree | f9f0d9c391744fed388f99d44e96c908ed7aa1f1 /app/assets/javascripts/jobs/components/header.vue | |
parent | 999118f0ec6edabc9e13c089381ad664970a080a (diff) | |
parent | 8af23def1d6450420d06b8de54d23311a978de20 (diff) | |
download | gitlab-ce-729391fbfce4dea58478b65c684a24a1bfd125a2.tar.gz |
Merge commit '8af23def1d6' into object-storage-ee-to-ce-backport
Diffstat (limited to 'app/assets/javascripts/jobs/components/header.vue')
-rw-r--r-- | app/assets/javascripts/jobs/components/header.vue | 29 |
1 files changed, 17 insertions, 12 deletions
diff --git a/app/assets/javascripts/jobs/components/header.vue b/app/assets/javascripts/jobs/components/header.vue index c660828b30e..357bc9aab17 100644 --- a/app/assets/javascripts/jobs/components/header.vue +++ b/app/assets/javascripts/jobs/components/header.vue @@ -3,7 +3,11 @@ import loadingIcon from '../../vue_shared/components/loading_icon.vue'; export default { - name: 'jobHeaderSection', + name: 'JobHeaderSection', + components: { + ciHeader, + loadingIcon, + }, props: { job: { type: Object, @@ -14,10 +18,6 @@ required: true, }, }, - components: { - ciHeader, - loadingIcon, - }, data() { return { actions: this.getActions(), @@ -30,8 +30,17 @@ shouldRenderContent() { return !this.isLoading && Object.keys(this.job).length; }, + /** + * When job has not started the key will be `false` + * When job started the key will be a string with a date. + */ jobStarted() { - return this.job.started; + return !this.job.started === false; + }, + }, + watch: { + job() { + this.actions = this.getActions(); }, }, methods: { @@ -49,11 +58,6 @@ return actions; }, }, - watch: { - job() { - this.actions = this.getActions(); - }, - }, }; </script> <template> @@ -72,6 +76,7 @@ <loading-icon v-if="isLoading" size="2" - /> + class="prepend-top-default append-bottom-default" + /> </div> </template> |