Skip to content

Commit

Permalink
Reset AppModels and index.html and loader.js for tag
Browse files Browse the repository at this point in the history
  • Loading branch information
laurenwalker committed Mar 29, 2018
1 parent 21a9ed1 commit 403bacc
Show file tree
Hide file tree
Showing 6 changed files with 110 additions and 111 deletions.
12 changes: 6 additions & 6 deletions src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,14 @@
<div class="loading-icon"><div class="wBall" id="wBall_1"><div class="wInnerBall"></div></div><div class="wBall" id="wBall_2"><div class="wInnerBall"></div></div><div class="wBall" id="wBall_3"><div class="wInnerBall"></div></div><div class="wBall" id="wBall_4"><div class="wInnerBall"></div></div><div class="wBall" id="wBall_5"><div class="wInnerBall"></div></div></div>
<span>Loading...</span>
</div>


<!-- Pull in correct theme configuration, then use Require.js to manage dependencies -->
<script id="loader" type="text/javascript" src="loader.js?v=2.0.0RC4"
data-theme="default"
<script id="loader" type="text/javascript" src="loader.js?v=2.0.0RC5"
data-theme="default"
data-metacat-context="metacat"
data-map-key="YOUR-GOOGLE-MAPS-API-KEY"
></script>

</body>
</html>
</html>
34 changes: 17 additions & 17 deletions src/js/models/AppModel.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ define(['jquery', 'underscore', 'backbone'],

userProfiles: true,
profileUsername: null,

maxDownloadSize: 3000000000,

// set this variable to true, if the content being published is moderated by the data team.
contentIsModerated: false,

/*
* emlEditorRequiredFields is a hash map of all the required fields in the EML Editor.
* Any field set to true will prevent the user from saving the Editor until a value has been given
Expand All @@ -54,9 +54,9 @@ define(['jquery', 'underscore', 'backbone'],
temporalCoverage: true,
title: true
},

editableFormats: ["eml://ecoinformatics.org/eml-2.1.1"],

defaultAccessPolicy: [],

baseUrl: window.location.origin || (window.location.protocol + "//" + window.location.host),
Expand All @@ -76,8 +76,8 @@ define(['jquery', 'underscore', 'backbone'],
metacatBaseUrl: null,
metacatServiceUrl: null,
objectServiceUrl: null,
formatsServiceUrl: null,
formatsUrl: "/formats",
formatsServiceUrl: null,
formatsUrl: "/formats",
//grantsUrl: null,
//bioportalSearchUrl: null,
//orcidSearchUrl: null,
Expand Down Expand Up @@ -139,17 +139,17 @@ define(['jquery', 'underscore', 'backbone'],

if(typeof this.get("d1LogServiceUrl") != "undefined")
this.set('d1LogServiceUrl', this.get('d1CNBaseUrl') + this.get('d1CNService') + '/query/logsolr/?');

this.set("nodeServiceUrl", this.get("d1CNBaseUrl") + this.get("d1CNService") + "/node/");
this.set('resolveServiceUrl', this.get('d1CNBaseUrl') + this.get('d1CNService') + '/resolve/');

//Token URLs
if(typeof this.get("tokenUrl") != "undefined"){
this.set("portalUrl", this.get("d1CNBaseUrl") + "portal/");
this.set("tokenUrl", this.get("portalUrl") + "token");

this.set("checkTokenUrl", this.get("d1CNBaseUrl") + this.get("d1CNService") + "/diag/subject");

//The sign-in and out URLs - allow these to be turned off by removing them in the defaults above (hence the check for undefined)
if(typeof this.get("signInUrl") !== "undefined")
this.set("signInUrl", this.get('portalUrl') + "startRequest?target=");
Expand All @@ -159,17 +159,17 @@ define(['jquery', 'underscore', 'backbone'],
this.set("signInUrlLdap", this.get('portalUrl') + "ldap?target=");
if(this.get('orcidBaseUrl'))
this.set('orcidSearchUrl', this.get('orcidBaseUrl') + '/v1.1/search/orcid-bio?q=');

if((typeof this.get("signInUrl") !== "undefined") || (typeof this.get("signInUrlOrcid") !== "undefined"))
this.set("signOutUrl", this.get('portalUrl') + "logout");

}

// Object format list
if ( typeof this.get("formatsUrl") != "undefined" ) {
this.set("formatsServiceUrl",
this.get("d1CNBaseUrl") + this.get("d1CNService") + this.get("formatsUrl"));
}
if ( typeof this.get("formatsUrl") != "undefined" ) {
this.set("formatsServiceUrl",
this.get("d1CNBaseUrl") + this.get("d1CNService") + this.get("formatsUrl"));
}

//ORCID search
if(typeof this.get("orcidBaseUrl") != "undefined")
Expand Down
28 changes: 14 additions & 14 deletions src/js/themes/arctic/models/AppModel.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,12 +29,12 @@ define(['jquery', 'underscore', 'backbone'],

userProfiles: true,
profileUsername: null,

maxDownloadSize: 3000000000,

// set this variable to true, if the content being published is moderated by the data team.
contentIsModerated: true,

/*
* emlEditorRequiredFields is a hash map of all the required fields in the EML Editor.
* Any field set to true will prevent the user from saving the Editor until a value has been given
Expand All @@ -54,11 +54,11 @@ define(['jquery', 'underscore', 'backbone'],
temporalCoverage: true,
title: true
},

editableFormats: ["eml://ecoinformatics.org/eml-2.1.1"],

defaultAccessPolicy: [{

subject: "CN=arctic-data-admins,DC=dataone,DC=org",
read: true,
write: true,
Expand All @@ -83,7 +83,7 @@ define(['jquery', 'underscore', 'backbone'],
metacatServiceUrl: null,
objectServiceUrl: null,
formatsServiceUrl: null,
formatsUrl: "/formats",
formatsUrl: "/formats",
resolveServiceUrl: null,
//bioportalSearchUrl: null,
orcidBaseUrl: "https:/orcid.org",
Expand Down Expand Up @@ -132,7 +132,7 @@ define(['jquery', 'underscore', 'backbone'],

//DataONE CN API
if(this.get("d1CNBaseUrl")){

//Account services
if(typeof this.get("accountsUrl") != "undefined"){
this.set("accountsUrl", this.get("d1CNBaseUrl") + this.get("d1CNService") + "/accounts/");
Expand All @@ -149,15 +149,15 @@ define(['jquery', 'underscore', 'backbone'],

if(typeof this.get("d1LogServiceUrl") != "undefined")
this.set('d1LogServiceUrl', this.get('d1CNBaseUrl') + this.get('d1CNService') + '/query/logsolr/?');

this.set("nodeServiceUrl", this.get("d1CNBaseUrl") + this.get("d1CNService") + "/node/");
this.set('resolveServiceUrl', this.get('d1CNBaseUrl') + this.get('d1CNService') + '/resolve/');

// Object format list
if ( typeof this.get("formatsUrl") != "undefined" ) {
this.set("formatsServiceUrl",
this.get("d1CNBaseUrl") + this.get("d1CNService") + this.get("formatsUrl"));
}
if ( typeof this.get("formatsUrl") != "undefined" ) {
this.set("formatsServiceUrl",
this.get("d1CNBaseUrl") + this.get("d1CNService") + this.get("formatsUrl"));
}

//Authentication / portal URLs
this.set('portalUrl', this.get('d1CNBaseUrl') + 'portal/');
Expand All @@ -181,7 +181,7 @@ define(['jquery', 'underscore', 'backbone'],
this.set("signOutUrl", this.get('portalUrl') + "logout");

}

//The package service for v2 DataONE API
this.set('packageServiceUrl', this.get('baseUrl') + this.get('context') + this.get('d1Service') + '/packages/application%2Fbagit-097/');

Expand Down
34 changes: 17 additions & 17 deletions src/js/themes/knb/models/AppModel.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ define(['jquery', 'underscore', 'backbone'],

// set this variable to true, if the content being published is moderated by the data team.
contentIsModerated: false,

/*
* emlEditorRequiredFields is a hash map of all the required fields in the EML Editor.
* Any field set to true will prevent the user from saving the Editor until a value has been given
Expand All @@ -54,11 +54,11 @@ define(['jquery', 'underscore', 'backbone'],
temporalCoverage: true,
title: true
},

editableFormats: ["eml://ecoinformatics.org/eml-2.1.1"],

defaultAccessPolicy: [{

subject: "CN=knb-data-admins,DC=dataone,DC=org",
read: true,
write: true,
Expand Down Expand Up @@ -88,8 +88,8 @@ define(['jquery', 'underscore', 'backbone'],
metacatServiceUrl: null,
objectServiceUrl: null,
formatsServiceUrl: null,
formatsUrl: "/formats",
//grantsUrl: null,
formatsUrl: "/formats",
//grantsUrl: null,
//bioportalSearchUrl: null,
//orcidSearchUrl: null,
//orcidBioUrl: null,
Expand Down Expand Up @@ -127,21 +127,21 @@ define(['jquery', 'underscore', 'backbone'],
this.set('objectServiceUrl', this.get('baseUrl') + this.get('context') + this.get('d1Service') + '/object/');
//this.set('ldapwebServiceUrl', this.get('baseUrl') + this.get('context') + '/cgi-bin/ldapweb.cgi');
this.set('metacatServiceUrl', this.get('baseUrl') + this.get('context') + '/metacat');
//The package service
//The package service
this.set('packageServiceUrl', this.get('baseUrl') + this.get('context') + this.get('d1Service') + '/packages/application%2Fbagit-097/');

if(typeof this.get("grantsUrl") !== "undefined")
this.set("grantsUrl", this.get("baseUrl") + "/api.nsf.gov/services/v1/awards.json");

//ORCID search
if(typeof this.get("orcidBaseUrl") != "undefined")
this.set('orcidSearchUrl', this.get('orcidBaseUrl') + '/search/orcid-bio?q=');

// Object format list
if ( typeof this.get("formatsUrl") != "undefined" ) {
this.set("formatsServiceUrl",
this.get("d1CNBaseUrl") + this.get("d1CNService") + this.get("formatsUrl"));
}
if ( typeof this.get("formatsUrl") != "undefined" ) {
this.set("formatsServiceUrl",
this.get("d1CNBaseUrl") + this.get("d1CNService") + this.get("formatsUrl"));
}

//DataONE CN API
if(this.get("d1CNBaseUrl")){
Expand All @@ -166,7 +166,7 @@ define(['jquery', 'underscore', 'backbone'],
//Token URLs
this.set("portalUrl", this.get("d1CNBaseUrl") + "portal/");
this.set("tokenUrl", this.get("portalUrl") + "token");

//The sign-in and out URLs - allow these to be turned off by removing them in the defaults above (hence the check for undefined)
if(typeof this.get("signInUrl") !== "undefined")
this.set("signInUrl", this.get('portalUrl') + "startRequest?target=");
Expand All @@ -176,15 +176,15 @@ define(['jquery', 'underscore', 'backbone'],
this.set("signInUrlLdap", this.get('portalUrl') + "ldap?target=");
if(this.get('orcidBaseUrl'))
this.set('orcidSearchUrl', this.get('orcidBaseUrl') + '/v1.1/search/orcid-bio?q=');

if((typeof this.get("signInUrl") !== "undefined") || (typeof this.get("signInUrlOrcid") !== "undefined"))
this.set("signOutUrl", this.get('portalUrl') + "logout");

if(typeof this.get("d1LogServiceUrl") != "undefined")
this.set('d1LogServiceUrl', this.get('d1CNBaseUrl') + this.get('d1CNService') + '/query/logsolr/?');

}

this.on("change:pid", this.changePid);
},

Expand Down
42 changes: 21 additions & 21 deletions src/js/themes/nceas/models/AppModel.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*global define */
define(['jquery', 'underscore', 'backbone'],
define(['jquery', 'underscore', 'backbone'],
function($, _, Backbone) {
'use strict';

Expand All @@ -21,7 +21,7 @@ define(['jquery', 'underscore', 'backbone'],

// set this variable to true, if the content being published is moderated by the data team.
contentIsModerated: false,

/*
* emlEditorRequiredFields is a hash map of all the required fields in the EML Editor.
* Any field set to true will prevent the user from saving the Editor until a value has been given
Expand All @@ -41,11 +41,11 @@ define(['jquery', 'underscore', 'backbone'],
temporalCoverage: true,
title: true
},

editableFormats: ["eml://ecoinformatics.org/eml-2.1.1"],

defaultAccessPolicy: [{

subject: "CN=knb-data-admins,DC=dataone,DC=org",
read: true,
write: true,
Expand All @@ -55,7 +55,7 @@ define(['jquery', 'underscore', 'backbone'],
subject: "public",
read: true
}],

baseUrl: "https://knb.ecoinformatics.org",
// the most likely item to change is the Metacat deployment context
context: '/metacat',
Expand Down Expand Up @@ -83,9 +83,9 @@ define(['jquery', 'underscore', 'backbone'],
//annotatorUrl: null,
accountsUrl: null
},

defaultView: "submit",

initialize: function() {

// these are pretty standard, but can be customized if needed
Expand All @@ -98,18 +98,18 @@ define(['jquery', 'underscore', 'backbone'],
this.set('objectServiceUrl', this.get('baseUrl') + this.get('context') + this.get('d1Service') + '/object/');
this.set('metacatServiceUrl', this.get('baseUrl') + this.get('context') + '/metacat');
this.set("accountsUrl", this.get("d1CNBaseUrl") + this.get("d1CNService") + "/accounts/");

// Object format list
if ( typeof this.get("formatsUrl") != "undefined" ) {
this.set("formatsServiceUrl",
this.get("d1CNBaseUrl") + this.get("d1CNService") + this.get("formatsUrl"));
}
if ( typeof this.get("formatsUrl") != "undefined" ) {
this.set("formatsServiceUrl",
this.get("d1CNBaseUrl") + this.get("d1CNService") + this.get("formatsUrl"));
}

//Token URLs
if(typeof this.get("tokenUrl") != "undefined"){
this.set("portalUrl", this.get("d1CNBaseUrl") + "portal/");
this.set("tokenUrl", this.get("portalUrl") + "token");

//The sign-in and out URLs - allow these to be turned off by removing them in the defaults above (hence the check for undefined)
if(typeof this.get("signInUrl") !== "undefined")
this.set("signInUrl", this.get('portalUrl') + "startRequest?target=");
Expand All @@ -119,21 +119,21 @@ define(['jquery', 'underscore', 'backbone'],
this.set("signInUrlLdap", this.get('portalUrl') + "ldap?target=");
if(this.get('orcidBaseUrl'))
this.set('orcidSearchUrl', this.get('orcidBaseUrl') + '/v1.1/search/orcid-bio?q=');

if((typeof this.get("signInUrl") !== "undefined") || (typeof this.get("signInUrlOrcid") !== "undefined"))
this.set("signOutUrl", this.get('portalUrl') + "logout");

if(typeof this.get("d1LogServiceUrl") != "undefined")
this.set('d1LogServiceUrl', this.get('d1CNBaseUrl') + this.get('d1CNService') + '/query/logsolr/?');

}

this.on("change:pid", this.changePid);
},
changePid: function(model, name){

changePid: function(model, name){
this.set("previousPid", model.previous("pid"));
}
});
return AppModel;
return AppModel;
});
Loading

0 comments on commit 403bacc

Please sign in to comment.