Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
clinicaltrials
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
david Chavalarias
clinicaltrials
Commits
3bcc2454
Commit
3bcc2454
authored
Sep 18, 2014
by
PkSM3
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
geomap bugfix: labels
parent
651b18db
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
11 deletions
+12
-11
extras_explorerjs.js
extras_explorerjs.js
+3
-2
geo.css
geomap2/css/geo.css
+2
-2
mapael.php
geomap2/php/mapael.php
+7
-7
No files found.
extras_explorerjs.js
View file @
3bcc2454
...
...
@@ -4,7 +4,8 @@
function
callGeomap
(){
db
=
JSON
.
stringify
(
'php/community.db'
);
if
(
is_empty
(
selections
)){
jsonparams
=
'["all"]'
;
jsonparams
=
JSON
.
stringify
(
Object
.
keys
(
getnodesIndex
()));
// pr( Object.keys(getnodesIndex()) )
}
else
{
N
=
0
;
...
...
@@ -25,7 +26,7 @@ function callGeomap(){
temp
=
getNeighs
(
selections
,
arr
);
sel_plus_neigh
=
Object
.
keys
(
temp
);
k
=
sel_plus_neigh
.
length
;
if
(
N
==
k
)
jsonparams
=
'["all"]'
;
if
(
N
==
k
)
jsonparams
=
JSON
.
stringify
(
Object
.
keys
(
getnodesIndex
()))
;
else
jsonparams
=
JSON
.
stringify
(
sel_plus_neigh
);
//jsonparams=JSON.stringify(getSelections());
...
...
geomap2/css/geo.css
View file @
3bcc2454
.geomapCont
{
margin
:
auto
;
width
:
9
0%
;
width
:
8
0%
;
text-align
:
center
;
white-space
:
nowrap
;
}
...
...
@@ -9,7 +9,7 @@
.distBar
{
width
:
200px
;
height
:
10px
;
border-radius
:
3px
;
border-radius
:
3px
;
border
:
1px
solid
#848484
;
display
:
inline-block
;
-moz-border-radius
:
0px
0px
0px
0px
;
...
...
geomap2/php/mapael.php
View file @
3bcc2454
...
...
@@ -115,7 +115,7 @@ if($selectiveQuery){
$info
[
"attrs"
]
=
array
();
$info
[
"attrs"
][
"href"
]
=
"#"
;
$info
[
"tooltip"
]
=
array
();
//$info["tooltip"]["content"] = "<span style='font-weight
=
bold;'>" . $CC[$key] . "</span><br/>" . $realOCC.' '.$pluralnick.' ('.$info["percentage"].'%)';
//$info["tooltip"]["content"] = "<span style='font-weight
:
bold;'>" . $CC[$key] . "</span><br/>" . $realOCC.' '.$pluralnick.' ('.$info["percentage"].'%)';
$norm_country
[
$key
]
=
$info
;
if
(
$percentage
>
$maxF
)
$maxF
=
$percentage
;
...
...
@@ -135,7 +135,7 @@ if($selectiveQuery){
$old
=
$value
[
"percentage"
];
$new
=
$old
*
$constant
;
# da formula!
$norm_country
[
$key
][
"percentage"
]
=
round
(
$new
,
2
);
$norm_country
[
$key
][
"tooltip"
][
"content"
]
=
"<span style='font-weight
=
bold;'>"
.
$CC
[
$key
]
.
"</span><br/>"
.
$value
[
"realValue"
]
.
' '
.
$pluralnick
.
' ('
.
round
(
$new
,
2
)
.
'%)'
;
$norm_country
[
$key
][
"tooltip"
][
"content"
]
=
"<span style='font-weight
:
bold;'>"
.
$CC
[
$key
]
.
"</span><br/>"
.
$value
[
"realValue"
]
.
' '
.
$pluralnick
.
' ('
.
round
(
$new
,
2
)
.
'%)'
;
//pr($value["code"].": ".$value["realValue"].", ".$value["percentage"].", div:".($country_divisor[$key]+1));
}
}
else
{
...
...
@@ -150,7 +150,7 @@ if($selectiveQuery){
$tempcount
=
0
;
if
(
$norm_country
[
$code
])
{
$norm_country
[
$code
][
"value"
]
+=
$row
[
"count(*)"
];
$norm_country
[
$code
][
"tooltip"
][
"content"
]
=
"<span style='font-weight
=
bold;'>"
.
$CC
[
$code
]
.
"</span><br/>"
.
$norm_country
[
$code
][
"value"
]
.
' '
.
$pluralnick
;
$norm_country
[
$code
][
"tooltip"
][
"content"
]
=
"<span style='font-weight
:
bold;'>"
.
$CC
[
$code
]
.
"</span><br/>"
.
$norm_country
[
$code
][
"value"
]
.
' '
.
$pluralnick
;
}
else
{
$info
=
array
();
$info
[
"code"
]
=
$code
;
...
...
@@ -158,7 +158,7 @@ if($selectiveQuery){
$info
[
"attrs"
]
=
array
();
$info
[
"attrs"
][
"href"
]
=
"#"
;
$info
[
"tooltip"
]
=
array
();
$info
[
"tooltip"
][
"content"
]
=
"<span style='font-weight
=
bold;'>"
.
$CC
[
$code
]
.
"</span><br/>"
.
$row
[
"count(*)"
]
.
' '
.
$pluralnick
;
$info
[
"tooltip"
][
"content"
]
=
"<span style='font-weight
:
bold;'>"
.
$CC
[
$code
]
.
"</span><br/>"
.
$row
[
"count(*)"
]
.
' '
.
$pluralnick
;
$norm_country
[
$code
]
=
$info
;
}
}
...
...
@@ -223,12 +223,12 @@ foreach ($temp as $key => $value) {
$moreinfo
[
"tooltip"
]
=
array
();
if
(
$selectiveQuery
){
if
(
$norm_country
[
$j
][
"realValue"
]
==
1
){
$moreinfo
[
"tooltip"
][
"content"
]
=
"<span style='font-weight
=
bold;'>"
.
$CC
[
$j
]
.
"</span><br/>"
.
$norm_country
[
$j
][
"realValue"
]
.
' '
.
$pluralnick
.
' ('
.
$norm_country
[
$j
][
"percentage"
]
.
'%)'
;
$moreinfo
[
"tooltip"
][
"content"
]
=
"<span style='font-weight
:
bold;'>"
.
$CC
[
$j
]
.
"</span><br/>"
.
$norm_country
[
$j
][
"realValue"
]
.
' '
.
$pluralnick
.
' ('
.
$norm_country
[
$j
][
"percentage"
]
.
'%)'
;
}
else
{
$moreinfo
[
"tooltip"
][
"content"
]
=
"<span style='font-weight
=
bold;'>"
.
$CC
[
$j
]
.
"</span><br/>"
.
$norm_country
[
$j
][
"realValue"
]
.
' '
.
$pluralnick
.
' ('
.
$norm_country
[
$j
][
"percentage"
]
.
'%)'
;
$moreinfo
[
"tooltip"
][
"content"
]
=
"<span style='font-weight
:
bold;'>"
.
$CC
[
$j
]
.
"</span><br/>"
.
$norm_country
[
$j
][
"realValue"
]
.
' '
.
$pluralnick
.
' ('
.
$norm_country
[
$j
][
"percentage"
]
.
'%)'
;
}
}
else
{
$moreinfo
[
"tooltip"
][
"content"
]
=
"<span style='font-weight
=
bold;'>"
.
$CC
[
$j
]
.
"</span><br/>"
.
$value
[
"occ"
]
.
' '
.
$pluralnick
;
$moreinfo
[
"tooltip"
][
"content"
]
=
"<span style='font-weight
:
bold;'>"
.
$CC
[
$j
]
.
"</span><br/>"
.
$value
[
"occ"
]
.
' '
.
$pluralnick
;
}
$thedata
[
$j
]
=
$moreinfo
;
}
...
...
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