Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
7
Merge Requests
7
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Jobs
Commits
Open sidebar
Jérome Perrin
erp5
Commits
d181977c
Commit
d181977c
authored
Sep 20, 2018
by
Jérome Perrin
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
graph_editor: make it a iframe gadget
This is compatible with both ERP5JS and erp5_xhml_style
parent
807701f2
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
39 additions
and
15 deletions
+39
-15
bt5/erp5_graph_editor/SkinTemplateItem/portal_skins/erp5_graph_editor/BusinessProcess_viewGraphEditor/my_jsplumb_graph.xml
...itor/BusinessProcess_viewGraphEditor/my_jsplumb_graph.xml
+15
-1
bt5/erp5_graph_editor/SkinTemplateItem/portal_skins/erp5_graph_editor/dream_graph_editor/jsplumb/index.html.html
...5_graph_editor/dream_graph_editor/jsplumb/index.html.html
+7
-11
bt5/erp5_graph_editor/SkinTemplateItem/portal_skins/erp5_graph_editor/dream_graph_editor/jsplumb/jsplumb.js.js
...rp5_graph_editor/dream_graph_editor/jsplumb/jsplumb.js.js
+2
-2
bt5/erp5_item/SkinTemplateItem/portal_skins/erp5_item/Item_viewTrackingList/my_jsplumb_graph.xml
...kins/erp5_item/Item_viewTrackingList/my_jsplumb_graph.xml
+15
-1
No files found.
bt5/erp5_graph_editor/SkinTemplateItem/portal_skins/erp5_graph_editor/BusinessProcess_viewGraphEditor/my_jsplumb_graph.xml
View file @
d181977c
...
...
@@ -225,7 +225,13 @@
</item>
<item>
<key>
<string>
js_sandbox
</string>
</key>
<value>
<string></string>
</value>
<value>
<string>
iframe
</string>
</value>
</item>
<item>
<key>
<string>
renderjs_extra
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
required
</string>
</key>
...
...
@@ -235,6 +241,14 @@
<key>
<string>
title
</string>
</key>
<value>
<string>
Graph
</string>
</value>
</item>
<item>
<key>
<string>
validator_field_id
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
validator_form_id
</string>
</key>
<value>
<string></string>
</value>
</item>
</dictionary>
</value>
</item>
...
...
bt5/erp5_graph_editor/SkinTemplateItem/portal_skins/erp5_graph_editor/dream_graph_editor/jsplumb/index.html.html
View file @
d181977c
...
...
@@ -5,23 +5,17 @@
<link
rel=
"stylesheet"
href=
"../lib/jquery-ui.css"
>
<link
rel=
"stylesheet"
href=
"jsplumb.css"
>
<title>
JSPlumb gadget
</title>
<!--
FIXME: renderjs fails if we include renderjs.js twice (this one has a different URL from ERP5's one)
<script src="renderjs.js" type="text/javascript"></script>
<script src="rsvp.js" type="text/javascript"></script>
-->
<!--
FIXME: Including jQuery twice cause the jsplumb to be loaded twice.
For now we assume that it has already been loaded at this point.
<script src="../lib/jquery.js" type="text/javascript"></script>
-->
<script
src=
"../../rsvp.js"
type=
"text/javascript"
></script>
<script
src=
"../../renderjs.js"
type=
"text/javascript"
></script>
<script
src=
"../lib/jquery.js"
type=
"text/javascript"
></script>
<script
src=
"../lib/jquery-ui.js"
type=
"text/javascript"
></script>
<script
src=
"../lib/jquery.jsplumb.js"
type=
"text/javascript"
></script>
<script
src=
"../lib/handlebars.min.js"
type=
"text/javascript"
></script>
<script
src=
"../lib/springy.js"
type=
"text/javascript"
></script>
<script
src=
"../dream/mixin_promise.js"
type=
"text/javascript"
></script>
<script
src=
"jsplumb.js"
type=
"text/javascript"
></script>
<script
id=
"node-template"
type=
"text/x-handlebars-template"
>
<
div
class
=
"
window {{class}}
"
...
...
@@ -47,6 +41,8 @@
<
/form
>
<
/div
>
</script>
<script
src=
"jsplumb.js"
type=
"text/javascript"
></script>
</head>
<body>
<div
class=
"graph_container"
></div>
...
...
bt5/erp5_graph_editor/SkinTemplateItem/portal_skins/erp5_graph_editor/dream_graph_editor/jsplumb/jsplumb.js.js
View file @
d181977c
...
...
@@ -31,9 +31,9 @@
*/
var
gadget_klass
=
rJS
(
window
);
var
domParser
=
new
DOMParser
();
var
node_template_source
=
gadget_klass
.
__template_ele
ment
.
getElementById
(
"
node-template
"
).
innerHTML
;
var
node_template_source
=
docu
ment
.
getElementById
(
"
node-template
"
).
innerHTML
;
var
node_template
=
Handlebars
.
compile
(
node_template_source
);
var
popup_edit_template
=
gadget_klass
.
__template_ele
ment
.
getElementById
(
"
popup-edit-template
"
).
innerHTML
;
var
popup_edit_template
=
docu
ment
.
getElementById
(
"
popup-edit-template
"
).
innerHTML
;
function
layoutGraph
(
graph_data
)
{
// Promise returning the graph once springy calculated the layout.
...
...
bt5/erp5_item/SkinTemplateItem/portal_skins/erp5_item/Item_viewTrackingList/my_jsplumb_graph.xml
View file @
d181977c
...
...
@@ -231,7 +231,13 @@
</item>
<item>
<key>
<string>
js_sandbox
</string>
</key>
<value>
<string></string>
</value>
<value>
<string>
iframe
</string>
</value>
</item>
<item>
<key>
<string>
renderjs_extra
</string>
</key>
<value>
<list/>
</value>
</item>
<item>
<key>
<string>
required
</string>
</key>
...
...
@@ -241,6 +247,14 @@
<key>
<string>
title
</string>
</key>
<value>
<string>
Graph
</string>
</value>
</item>
<item>
<key>
<string>
validator_field_id
</string>
</key>
<value>
<string></string>
</value>
</item>
<item>
<key>
<string>
validator_form_id
</string>
</key>
<value>
<string></string>
</value>
</item>
</dictionary>
</value>
</item>
...
...
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