mirror of https://gitee.com/bigwinds/arangodb
graph management
This commit is contained in:
parent
3cc95a23fd
commit
e4f23d2b23
|
@ -6,7 +6,7 @@
|
||||||
mandatory = '*';
|
mandatory = '*';
|
||||||
}
|
}
|
||||||
%>
|
%>
|
||||||
<tr>
|
<tr class="tableRow" id="<%='row_' + row.id%>">
|
||||||
<th class="collectionTh"><%=row.label%><%=mandatory%>:</th>
|
<th class="collectionTh"><%=row.label%><%=mandatory%>:</th>
|
||||||
<th class="collectionTh">
|
<th class="collectionTh">
|
||||||
<%
|
<%
|
||||||
|
|
|
@ -47,6 +47,7 @@
|
||||||
graphs: this.collection,
|
graphs: this.collection,
|
||||||
searchString : ''
|
searchString : ''
|
||||||
}));
|
}));
|
||||||
|
this.events["click .tableRow"] = this.showHideDefinition.bind(this);
|
||||||
return this;
|
return this;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -264,6 +265,16 @@
|
||||||
window.modalView.show("modalTable.ejs", "Graph Properties", buttons, tableContent);
|
window.modalView.show("modalTable.ejs", "Graph Properties", buttons, tableContent);
|
||||||
|
|
||||||
},
|
},
|
||||||
|
|
||||||
|
showHideDefinition : function(e) {
|
||||||
|
var id = $(e.currentTarget).attr("id");
|
||||||
|
if (id == "row_newEdgeDefinitions1") {
|
||||||
|
$('#row_fromCollections1').toggle();
|
||||||
|
$('#row_toCollections1').toggle();
|
||||||
|
}
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
createNewGraphModal2: function() {
|
createNewGraphModal2: function() {
|
||||||
var buttons = [],
|
var buttons = [],
|
||||||
tableContent = [];
|
tableContent = [];
|
||||||
|
@ -278,9 +289,10 @@
|
||||||
true
|
true
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
tableContent.push(
|
tableContent.push(
|
||||||
window.modalView.createTextEntry(
|
window.modalView.createTextEntry(
|
||||||
"newEdgeDefinitions",
|
"newEdgeDefinitions1",
|
||||||
"Edge definitions",
|
"Edge definitions",
|
||||||
"",
|
"",
|
||||||
"Some info for edge definitions",
|
"Some info for edge definitions",
|
||||||
|
@ -288,6 +300,29 @@
|
||||||
true
|
true
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
tableContent.push(
|
||||||
|
window.modalView.createSelect2Entry(
|
||||||
|
"fromCollections1",
|
||||||
|
"fromCollections",
|
||||||
|
"",
|
||||||
|
"The collection that contain the start vertices of the relation.",
|
||||||
|
"",
|
||||||
|
true
|
||||||
|
)
|
||||||
|
);
|
||||||
|
tableContent.push(
|
||||||
|
window.modalView.createSelect2Entry(
|
||||||
|
"toCollections1",
|
||||||
|
"toCollections",
|
||||||
|
"",
|
||||||
|
"The collection that contain the end vertices of the relation.",
|
||||||
|
"",
|
||||||
|
true
|
||||||
|
)
|
||||||
|
);
|
||||||
|
|
||||||
|
|
||||||
tableContent.push(
|
tableContent.push(
|
||||||
window.modalView.createSelect2Entry(
|
window.modalView.createSelect2Entry(
|
||||||
"newVertexCollections",
|
"newVertexCollections",
|
||||||
|
@ -302,7 +337,10 @@
|
||||||
window.modalView.createSuccessButton("Create", this.createNewGraph.bind(this))
|
window.modalView.createSuccessButton("Create", this.createNewGraph.bind(this))
|
||||||
);
|
);
|
||||||
|
|
||||||
window.modalView.show("modalTable.ejs", "Add new Graph", buttons, tableContent);
|
|
||||||
|
window.modalView.show("modalTable.ejs", "Add new Graph", buttons, tableContent, null, this.events);
|
||||||
|
$('#row_fromCollections1').hide();
|
||||||
|
$('#row_toCollections1').hide();
|
||||||
},
|
},
|
||||||
|
|
||||||
createEditGraphModal2: function(name, vertices, edges) {
|
createEditGraphModal2: function(name, vertices, edges) {
|
||||||
|
|
Loading…
Reference in New Issue