1
|
//version compatibility: 1.1.0-SNAPSHOT
|
2
|
|
3
|
//function createOtherResearchProducts() {
|
4
|
// db.entity.save({"pid" : "orp", "name" : "Other Research Products"});
|
5
|
// orpId = db.entity.find( { pid: "orp" }).map( function(entity) { return entity._id.str; } ).toString();
|
6
|
//
|
7
|
// db.page.save({"name" : "Other Research Products Landing", "route" : "/search/other", "type" : "landing", "connect":true,"openaire":true,"entities" : [orpId]});
|
8
|
// db.page.save({"name" : "Search Other Research Products", "route" : "/search/find/other", "type" : "search", "connect":true,"openaire":true,"entities" : [orpId]});
|
9
|
// db.page.save({"name" : "Advanced Search Other Research Products", "route" : "/search/advanced/other", "type" : "search", "connect":true,"openaire":true,"entities" : [orpId]});
|
10
|
//
|
11
|
// orpLanding = db.page.find( { route: "/search/other" }).map( function(page) { return page._id.str; } ).toString();
|
12
|
// searchOrp = db.page.find( { route: "/search/find/other" }).map( function(page) { return page._id.str; } ).toString();
|
13
|
// advancedSearchOrp = db.page.find( { route: "/search/advanced/other" }).map( function(page) { return page._id.str; } ).toString();
|
14
|
//
|
15
|
// communities = db.community.find().map( function(community) { return community; } );
|
16
|
//
|
17
|
// for (var i = 0; i < communities.length; i++) {
|
18
|
// community_pages = communities[i].pages;
|
19
|
//
|
20
|
// community_pages[orpLanding] = true;
|
21
|
// community_pages[searchOrp] = true;
|
22
|
// community_pages[advancedSearchOrp] = true;
|
23
|
//
|
24
|
// community_pid = communities[i].pid;
|
25
|
// db.community.update({ "pid" : community_pid },{$set: { "pages": community_pages}});
|
26
|
// print("Update pages for " + community_pid);
|
27
|
//
|
28
|
// community_entities = communities[i].entities;
|
29
|
//
|
30
|
// community_entities[orpId] = true;
|
31
|
//
|
32
|
// community_pid = communities[i].pid;
|
33
|
// db.community.update({ "pid" : community_pid },{$set: { "entities": community_entities}});
|
34
|
// print("Update entities for " + community_pid);
|
35
|
// }
|
36
|
//}
|
37
|
|
38
|
use openaire_admin;
|
39
|
|
40
|
//updatePages();
|
41
|
|
42
|
//updateTypeOfLandingPages();
|
43
|
//removeEntitiesFromSearchFindPage();
|
44
|
//initDivHelpContents();
|
45
|
|
46
|
//createContentPageWithTypeOther();
|
47
|
//createPagesWithTypeHtml();
|
48
|
//addContent_About_Organizations_PagesToCommunities();
|
49
|
//createCollectionForHtmlPageContents();
|
50
|
//addDefaultHtmlToHtmlPages();
|
51
|
|
52
|
//createMonitorPageWithTypeOther();
|
53
|
//addMonitorPageToCommunities();
|
54
|
|
55
|
//createOtherResearchProducts();
|