Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
fordecyt_2019
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Rodrigo Tapia-McClung
fordecyt_2019
Commits
23f9e254
Commit
23f9e254
authored
Mar 26, 2021
by
Rodrigo Tapia-McClung
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix baseUrl for localhost or server instances
parent
f451e38f
Changes
5
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
21 additions
and
6 deletions
+21
-6
centropais_periurbano.js
public/js/centropais_periurbano.js
+4
-1
cuerpos_functions.js
public/js/cuerpos_functions.js
+4
-1
evolucion_urbana.js
public/js/evolucion_urbana.js
+4
-1
grijalva_functions.js
public/js/grijalva_functions.js
+5
-2
riesgos_functions.js
public/js/riesgos_functions.js
+4
-1
No files found.
public/js/centropais_periurbano.js
View file @
23f9e254
...
...
@@ -37,7 +37,10 @@ let regions = {
previousClick
,
currentClick
;
const
baseUrl
=
new
URL
(
window
.
location
.
href
).
origin
;
// returns "http://localhost:8090"
const
windowUrl
=
new
URL
(
window
.
location
.
href
);
const
baseUrl
=
windowUrl
.
hostname
==
"localhost"
?
`
${
windowUrl
.
origin
}
`
:
// returns "http://localhost:8090"
`
${
windowUrl
.
origin
}
/fordecyt_2019`
;
// returns "http://servername/fordecyt_2019"
// use `${baseUrl}/something`
let
timeParse
=
d3
.
timeParse
(
"%Y"
);
...
...
public/js/cuerpos_functions.js
View file @
23f9e254
...
...
@@ -63,7 +63,10 @@ d3.json("https://unpkg.com/d3-time-format@2.1.1/locale/es-MX.json").then(async l
const
sortInitialDateAscending
=
(
a
,
b
)
=>
a
-
b
;
// Dates will be cast to numbers automagically:
const
baseUrl
=
new
URL
(
window
.
location
.
href
).
origin
;
// returns "http://localhost:8090"
const
windowUrl
=
new
URL
(
window
.
location
.
href
);
const
baseUrl
=
windowUrl
.
hostname
==
"localhost"
?
`
${
windowUrl
.
origin
}
`
:
// returns "http://localhost:8090"
`
${
windowUrl
.
origin
}
/fordecyt_2019`
;
// returns "http://servername/fordecyt_2019"
// use `${baseUrl}/something`
// query available dates on DB
...
...
public/js/evolucion_urbana.js
View file @
23f9e254
...
...
@@ -17,7 +17,10 @@ let timeDimensionControl,
layerControl
,
tiles
;
const
baseUrl
=
new
URL
(
window
.
location
.
href
).
origin
;
// returns "http://localhost:8090"
const
windowUrl
=
new
URL
(
window
.
location
.
href
);
const
baseUrl
=
windowUrl
.
hostname
==
"localhost"
?
`
${
windowUrl
.
origin
}
`
:
// returns "http://localhost:8090"
`
${
windowUrl
.
origin
}
/fordecyt_2019`
;
// returns "http://servername/fordecyt_2019"
// use `${baseUrl}/something`
const
getMinMax
=
table
=>
{
...
...
public/js/grijalva_functions.js
View file @
23f9e254
...
...
@@ -96,8 +96,11 @@ const sortInitialDateAscending = (a, b) => {
return
a
-
b
;
}
const
baseUrl
=
new
URL
(
window
.
location
.
href
).
origin
;
// returns "http://localhost:8090"
// use `${baseUrl}/something`
const
windowUrl
=
new
URL
(
window
.
location
.
href
);
const
baseUrl
=
windowUrl
.
hostname
==
"localhost"
?
`
${
windowUrl
.
origin
}
`
:
// returns "http://localhost:8090"
`
${
windowUrl
.
origin
}
/fordecyt_2019`
;
// returns "http://servername/fordecyt_2019"
// use `${baseUrl}/something`
// query available dates on DB
const
setupDates
=
()
=>
{
...
...
public/js/riesgos_functions.js
View file @
23f9e254
...
...
@@ -96,7 +96,10 @@ const sortInitialDateAscending = (a, b) => {
return
a
-
b
;
}
const
baseUrl
=
new
URL
(
window
.
location
.
href
).
origin
;
// returns "http://localhost:8090"
const
windowUrl
=
new
URL
(
window
.
location
.
href
);
const
baseUrl
=
windowUrl
.
hostname
==
"localhost"
?
`
${
windowUrl
.
origin
}
`
:
// returns "http://localhost:8090"
`
${
windowUrl
.
origin
}
/fordecyt_2019`
;
// returns "http://servername/fordecyt_2019"
// use `${baseUrl}/something`
// query available dates on DB
...
...
Write
Preview
Markdown
is supported
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