Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
nomad-lab
encyclopedia-gui
Commits
41057a23
Commit
41057a23
authored
Apr 17, 2018
by
Iker Hurtado
Browse files
Bugfix of the previous commit
parent
2577e18a
Pipeline
#27455
passed with stages
in 6 seconds
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
client/bundle.js
View file @
41057a23
...
...
@@ -421,7 +421,7 @@
const
IMAGE_DIR
=
'
img/
'
;
let
API_HOST
=
'
http://enc-staging-nomad.esc.rzg.mpg.de
'
;
// my local dev environment
let
API_HOST
=
'
http://enc-staging-nomad.esc.rzg.mpg.de
/
'
;
// my local dev environment
let
USER_COOKIE_DOMAIN
=
'
localhost
'
;
if
(
document
.
location
.
href
.
indexOf
(
'
nomad-coe.eu
'
)
>
0
){
// production environment
API_HOST
=
'
https://encyclopedia.nomad-coe.eu/
'
;
// old host -> API_HOST= 'https://encyclopedia-api.nomad-coe.eu/'; //***
...
...
@@ -435,7 +435,9 @@
}
console
.
log
(
'
API host:
'
,
API_HOST
,
'
USER_COOKIE_DOMAIN:
'
,
USER_COOKIE_DOMAIN
);
const
API_BASE_URL
=
API_HOST
+
'
api/v1.0/
'
;
// for the old host -> API_HOST+'v1.0/';
let
API_BASE_URL
=
API_HOST
+
'
v1.0/
'
;
// for the old host -> API_HOST+'v1.0/';
if
(
document
.
location
.
href
.
indexOf
(
'
gui
'
)
>
0
)
API_BASE_URL
=
API_HOST
+
'
api/v1.0/
'
;
document
.
querySelector
(
'
#guest-user a
'
).
href
=
API_BASE_URL
+
'
saml/?sso2
'
;
...
...
client/index.html
View file @
41057a23
...
...
@@ -118,6 +118,6 @@
</div>
<!-- <script type='text/javascript' src='http://www.x3dom.org/download/x3dom.js'> </script>-->
<script
type=
"text/javascript"
src=
"bundle
-es5
.js"
charset=
"utf-8"
></script>
<script
type=
"text/javascript"
src=
"bundle.js"
charset=
"utf-8"
></script>
</body>
</html>
client/src/common/util.js
View file @
41057a23
...
...
@@ -10,7 +10,7 @@ let searchResults = false;
const
IMAGE_DIR
=
'
img/
'
;
let
API_HOST
=
'
http://enc-staging-nomad.esc.rzg.mpg.de
'
;
// my local dev environment
let
API_HOST
=
'
http://enc-staging-nomad.esc.rzg.mpg.de
/
'
;
// my local dev environment
let
USER_COOKIE_DOMAIN
=
'
localhost
'
;
if
(
document
.
location
.
href
.
indexOf
(
'
nomad-coe.eu
'
)
>
0
){
// production environment
API_HOST
=
'
https://encyclopedia.nomad-coe.eu/
'
;
// old host -> API_HOST= 'https://encyclopedia-api.nomad-coe.eu/'; //***
...
...
@@ -24,7 +24,9 @@ else if (document.location.href.indexOf('gui') > 0){
}
console
.
log
(
'
API host:
'
,
API_HOST
,
'
USER_COOKIE_DOMAIN:
'
,
USER_COOKIE_DOMAIN
);
const
API_BASE_URL
=
API_HOST
+
'
api/v1.0/
'
;
// for the old host -> API_HOST+'v1.0/';
let
API_BASE_URL
=
API_HOST
+
'
v1.0/
'
;
// for the old host -> API_HOST+'v1.0/';
if
(
document
.
location
.
href
.
indexOf
(
'
gui
'
)
>
0
)
API_BASE_URL
=
API_HOST
+
'
api/v1.0/
'
;
document
.
querySelector
(
'
#guest-user a
'
).
href
=
API_BASE_URL
+
'
saml/?sso2
'
;
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment