BigW Consortium Gitlab
Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gitlab-ce
Project
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Forest Godfrey
gitlab-ce
Commits
a0a0a570
Commit
a0a0a570
authored
Nov 10, 2016
by
Regis
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
about to pull pipeline_url change
parent
0c835170
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
13 deletions
+8
-13
pipelines.js.es6
app/assets/javascripts/vue_pipelines_index/pipelines.js.es6
+4
-6
store.js.es6
app/assets/javascripts/vue_pipelines_index/store.js.es6
+4
-7
No files found.
app/assets/javascripts/vue_pipelines_index/pipelines.js.es6
View file @
a0a0a570
...
@@ -30,12 +30,9 @@
...
@@ -30,12 +30,9 @@
created() {
created() {
const url = window.location.toString();
const url = window.location.toString();
if (~url.indexOf('?')) this.pagenum = url.split('?')[1].split('=')[1];
if (~url.indexOf('?')) this.pagenum = url.split('?')[1].split('=')[1];
this.store.fetchDataLoop.call(this, Vue, this.pagenum);
this.store.fetchDataLoop.call(this, Vue, this.pagenum
, this.scope
);
},
},
methods: {
methods: {
shortsha(pipeline) {
return pipeline.sha.slice(0, 8);
},
changepage(event, last) {
changepage(event, last) {
const text = event.target.innerText;
const text = event.target.innerText;
if (text === '...') return;
if (text === '...') return;
...
@@ -47,7 +44,8 @@
...
@@ -47,7 +44,8 @@
window.history.pushState({}, null, `?p=${this.pagenum}`);
window.history.pushState({}, null, `?p=${this.pagenum}`);
clearInterval(this.intervalId);
clearInterval(this.intervalId);
this.store.fetchDataLoop.call(this, Vue, this.pagenum);
debugger
this.store.fetchDataLoop.call(this, Vue, this.pagenum, this.scope);
},
},
pipelineurl(id) {
pipelineurl(id) {
return `pipelines/${id}`;
return `pipelines/${id}`;
...
@@ -72,7 +70,7 @@
...
@@ -72,7 +70,7 @@
</vue-pipeline-url>
</vue-pipeline-url>
<vue-branch-commit
<vue-branch-commit
:pipeline='pipeline'
:pipeline='pipeline'
:shortsha='shortsha'
:shortsha='
pipeline.commit.
shortsha'
>
>
</vue-branch-commit>
</vue-branch-commit>
<vue-stages></vue-stages>
<vue-stages></vue-stages>
...
...
app/assets/javascripts/vue_pipelines_index/store.js.es6
View file @
a0a0a570
...
@@ -2,17 +2,14 @@
...
@@ -2,17 +2,14 @@
/* eslint-disable no-param-reassign */
/* eslint-disable no-param-reassign */
((gl) => {
((gl) => {
const api = '/api/v3/projects';
const paginate = '?per_page=5&page=';
gl.PipelineStore = class {
gl.PipelineStore = class {
fetchDataLoop(Vue, pageNum) {
fetchDataLoop(Vue, pageNum
, url
) {
const goFetch = () =>
const goFetch = () =>
// const url = `${api}/${this.scope}/pipelines${paginate}${pageNum}`
this.$http.get(`${url}?page=${pageNum}`)
this.$http.get('/gitlab-org/gitlab-shell/pipelines.json?page=1')
.then((response) => {
.then((response) => {
debugger
debugger
Vue.set(this, 'pipelines', JSON.parse(response.body));
const res = JSON.parse(response.body)
Vue.set(this, 'pipelines', res.pipelines);
}, () => new Flash(
}, () => new Flash(
'Something went wrong on our end.'
'Something went wrong on our end.'
));
));
...
...
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