1
0
mirror of https://github.com/ascribe/onion.git synced 2024-11-15 01:25:17 +01:00

application constants

This commit is contained in:
ddejongh 2015-06-11 16:24:37 +02:00
parent 5e7f7983e1
commit 5e746295bc
2 changed files with 7 additions and 7 deletions

View File

@ -15,15 +15,15 @@ let headers = {
'Content-Type': 'application/json'
};
if (window.DEBUG) {
headers.Authorization = 'Basic ' + window.CREDENTIALS;
}
//if (window.DEBUG) {
// headers.Authorization = 'Basic ' + window.CREDENTIALS;
//}
fetch.defaults({
urlMap: ApiUrls,
http: {
headers: headers,
credentials: 'same-origin'
credentials: 'include'
},
fatalErrorHandler: (err) => {
console.log(err);

View File

@ -5,10 +5,10 @@ let constants = {
//FIXME: referring to a global variable in `window` is not
// super pro. What if we render stuff on the server?
//'baseUrl': window.BASE_URL,
'baseUrl': window.BASE_URL,
'apiEndpoint': window.API_ENDPOINT,
'baseUrl': 'http://staging.ascribe.io/api/',
'debugCredentialBase64': 'ZGltaUBtYWlsaW5hdG9yLmNvbTowMDAwMDAwMDAw', // dimi@mailinator:0000000000
//'baseUrl': 'http://staging.ascribe.io/api/',
//'debugCredentialBase64': 'ZGltaUBtYWlsaW5hdG9yLmNvbTowMDAwMDAwMDAw', // dimi@mailinator:0000000000
'aclList': ['edit', 'consign', 'consign_request', 'unconsign', 'unconsign_request', 'transfer',
'loan', 'loan_request', 'share', 'download', 'view', 'delete', 'del_from_collection', 'add_to_collection']
};