Revision 55027
Added by Konstantinos Triantafyllou about 5 years ago
init_db.js | ||
---|---|---|
8 | 8 |
function createCollections(){ |
9 | 9 |
print("\n\n Create Collections \n\n") |
10 | 10 |
db.createCollection("community") |
11 |
db.createCollection("layout") |
|
11 | 12 |
db.createCollection("divHelpContent") |
12 | 13 |
db.createCollection("divId") |
13 | 14 |
db.createCollection("entity") |
... | ... | |
220 | 221 |
community_entities[projectId] = true; |
221 | 222 |
community_entities[organizationId] = true; |
222 | 223 |
community_entities[datasourceId] = true; |
224 |
var layoutId = db.layout.insertOne({"color": "#EBB13E"}).insertedId.str; |
|
225 |
print("Layout:" + layoutId); |
|
226 |
db.community.save({ "name" : name, |
|
227 |
"pid" : communityPid, "pages" : community_pages, "entities" : community_entities, "layout": layoutId}) |
|
223 | 228 |
|
224 |
db.community.save({ "name" : name, "pid" : communityPid, "pages" : community_pages, "entities" : community_entities}) |
|
225 |
|
|
226 | 229 |
openaireCommunity = db.community.find( { pid: communityPid }).map( function(community) { return community._id.str; } ).toString() |
227 | 230 |
|
228 | 231 |
var numbers_map = {}; |
Also available in: Unified diff
[Trunk|AdminTools]: 1. Add Layout Collection 2. Create getLayout, updateLayout, resetLayout in CommunityController 3. Add at admintooles.properties default color=color of connect