on-http-y1
Version:
OnRack Http Server
17 lines (16 loc) • 602 B
JSON
{
"@odata.context" : "<%= basepath %>/$metadata#Systems/Links/Members/<%= identifier %>/Volume/$entity",
"@odata.id": "<%= url %>",
"@odata.type": "#VolumeCollection.VolumeCollection",
"Oem" : {},
"Name": "Volume Collection",
"Members@odata.count": <%= virtualDisks.length %>,
"Members": [
<% virtualDisks.forEach(function(n, i, arr) { %>
{
"@odata.id": "<%= basepath %>/Systems/<%=identifier%>/Storage/<%=index%>/Volumes/<%=i%>"
}
<%= ( arr.length > 0 && i < arr.length-1 ) ? ',': '' %>
<% }); %>
]
}