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
c09a89c7
Commit
c09a89c7
authored
Feb 01, 2018
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Converted branch_graph.js to axios
parent
b5b30446
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
app/assets/javascripts/network/branch_graph.js
app/assets/javascripts/network/branch_graph.js
+8
-8
No files found.
app/assets/javascripts/network/branch_graph.js
View file @
c09a89c7
/* eslint-disable func-names, space-before-function-paren, no-var, wrap-iife, quotes, comma-dangle, one-var, one-var-declaration-per-line, no-mixed-operators, no-loop-func, no-floating-decimal, consistent-return, no-unused-vars, prefer-template, prefer-arrow-callback, camelcase, max-len */
/* eslint-disable func-names, space-before-function-paren, no-var, wrap-iife, quotes, comma-dangle, one-var, one-var-declaration-per-line, no-mixed-operators, no-loop-func, no-floating-decimal, consistent-return, no-unused-vars, prefer-template, prefer-arrow-callback, camelcase, max-len */
import
{
__
}
from
'
../locale
'
;
import
axios
from
'
../lib/utils/axios_utils
'
;
import
flash
from
'
../flash
'
;
import
Raphael
from
'
./raphael
'
;
import
Raphael
from
'
./raphael
'
;
export
default
(
function
()
{
export
default
(
function
()
{
...
@@ -26,16 +29,13 @@ export default (function() {
...
@@ -26,16 +29,13 @@ export default (function() {
}
}
BranchGraph
.
prototype
.
load
=
function
()
{
BranchGraph
.
prototype
.
load
=
function
()
{
return
$
.
ajax
({
axios
.
get
(
this
.
options
.
url
)
url
:
this
.
options
.
url
,
.
then
(({
data
})
=>
{
method
:
"
get
"
,
dataType
:
"
json
"
,
success
:
$
.
proxy
(
function
(
data
)
{
$
(
"
.loading
"
,
this
.
element
).
hide
();
$
(
"
.loading
"
,
this
.
element
).
hide
();
this
.
prepareData
(
data
.
days
,
data
.
commits
);
this
.
prepareData
(
data
.
days
,
data
.
commits
);
return
this
.
buildGraph
();
this
.
buildGraph
();
}
,
this
)
})
}
);
.
catch
(()
=>
__
(
'
Error fetching network graph.
'
)
);
};
};
BranchGraph
.
prototype
.
prepareData
=
function
(
days
,
commits
)
{
BranchGraph
.
prototype
.
prepareData
=
function
(
days
,
commits
)
{
...
...
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