Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
clowdflows
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Alain Shakour
clowdflows
Commits
50e67f24
Commit
50e67f24
authored
Nov 10, 2015
by
vpodpecan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
updates
parent
b608c3a0
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
6 deletions
+32
-6
workflows/graphs/templates/visualizations/graphs_visualize_visjs.html
...aphs/templates/visualizations/graphs_visualize_visjs.html
+32
-6
No files found.
workflows/graphs/templates/visualizations/graphs_visualize_visjs.html
View file @
50e67f24
...
...
@@ -14,7 +14,7 @@
</style>
<script>
$
(
'
head
'
).
append
(
'
<link rel="stylesheet" type="text/css" href="https://cdn
js.cloudflare.com/ajax/libs/vis/4.9.0
/vis.min.css">
'
);
$
(
'
head
'
).
append
(
'
<link rel="stylesheet" type="text/css" href="https://cdn
.rawgit.com/almende/vis/v4.9.0/dist
/vis.min.css">
'
);
$
(
"
#widgetvisualization-{{ widget.pk }}
"
).
bind
(
"
dialogresize
"
,
function
(
event
,
ui
)
{
$
(
'
#networkvis
'
).
height
(
$
(
'
#networkvis
'
).
parent
().
height
());
...
...
@@ -26,7 +26,7 @@
$
.
getScript
(
'
https://cdn.rawgit.com/ryanve/verge/master/verge.min.js
'
,
function
()
{
$
(
'
#networkvis
'
).
height
(
$
(
'
#networkvis
'
).
parent
().
height
());
$
(
'
#networkvis
'
).
width
(
$
(
'
#networkvis
'
).
parent
().
width
());
$
.
getScript
(
"
https://cdn
js.cloudflare.com/ajax/libs/vis/4.9.0
/vis.min.js
"
,
function
()
{
$
.
getScript
(
"
https://cdn
.rawgit.com/almende/vis/v4.9.0/dist
/vis.min.js
"
,
function
()
{
var
network
=
null
;
var
nodes
=
new
vis
.
DataSet
();
var
edges
=
new
vis
.
DataSet
();
...
...
@@ -42,8 +42,8 @@
autoResize
:
true
,
edges
:
{
smooth
:
{
//
type: 'dynamic'
type
:
'
continuous
'
type
:
'
dynamic
'
//
type: 'continuous'
}
},
nodes
:
{
...
...
@@ -57,17 +57,43 @@
interaction
:
{
hover
:
true
},
manipulation
:
{
enabled
:
true
,
initiallyActive
:
false
,
addNode
:
function
(
nodeData
,
callback
)
{
nodeData
.
label
=
'
new node
'
;
var
name
=
prompt
(
'
Enter node label
'
,
nodeData
.
label
);
if
(
name
!=
null
)
{
nodeData
.
label
=
name
;
};
callback
(
nodeData
);
}
},
physics
:
{
enabled
:
true
,
stabilization
:
{
enabled
:
false
}
},
layout
:
{
randomSeed
:
undefined
,
improvedLayout
:
true
,
}
};
var
container
=
document
.
getElementById
(
'
networkvis
'
);
network
=
new
vis
.
Network
(
container
,
data
,
options
);
}).
fail
(
function
(
jqxhr
,
settings
,
exception
)
{
alert
(
"
Network error: cannot load verge JS library!
"
);
});
}).
fail
(
function
(
jqxhr
,
settings
,
exception
)
{
alert
(
"
Network error: cannot load verge JS library!
"
);
});
function
getFromIframe
(
eid
)
{
return
$
(
'
iframe
'
).
contents
().
find
(
eid
)[
0
];
}
</script>
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