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
95c34810
Commit
95c34810
authored
Oct 16, 2014
by
PkSM3
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
click in country OK
parent
36bd56e1
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
57 additions
and
8 deletions
+57
-8
extras_explorerjs.js
extras_explorerjs.js
+29
-0
examples.js
geomap2/examples.js
+6
-5
conectiontest.php
geomap2/php/conectiontest.php
+2
-2
parameters_details.php
geomap2/php/parameters_details.php
+3
-1
sigmaUtils.js
tinawebJS/js/sigmaUtils.js
+17
-0
No files found.
extras_explorerjs.js
View file @
95c34810
...
...
@@ -62,6 +62,35 @@ function callGeomap(){
// $("#CurrentView").hide();
}
function
clickInCountry
(
CC
)
{
pr
(
"in extras.js: you've clicked "
+
CC
)
var
results
=
[]
for
(
var
i
in
Nodes
)
{
if
(
!
isUndef
(
Nodes
[
i
].
CC
)
&&
Nodes
[
i
].
CC
==
CC
)
results
.
push
(
i
)
}
$
.
doTimeout
(
20
,
function
(){
if
(
swclickActual
==
"social"
)
{
MultipleSelection
(
results
);
return
;
}
if
(
swclickActual
==
"semantic"
)
{
var
oposresults
=
getNeighs2
(
results
,
bipartiteD2N
);
MultipleSelection
(
oposresults
);
return
;
}
});
}
function
callTWJS
(){
// db=getCurrentDBforCurrentGexf();
// db=JSON.stringify(db);
...
...
geomap2/examples.js
View file @
95c34810
...
...
@@ -91,11 +91,12 @@ function initiateMap(db,query,submodName){
},
eventHandlers
:
{
dblclick
:
function
(
e
,
id
,
mapElem
,
textElem
)
{
console
.
log
(
id
);
console
.
log
(
partialGraph
)
$
.
doTimeout
(
30
,
function
(){
$
(
"#closegeomap"
).
click
();
});
if
(
mapElem
.
originalAttrs
.
fill
!=
"#FFFFFF"
)
{
$
.
doTimeout
(
200
,
function
(){
$
(
"#closegeomap"
).
click
();
clickInCountry
(
id
);
});
}
}
}
},
...
...
geomap2/php/conectiontest.php
View file @
95c34810
...
...
@@ -27,9 +27,9 @@ echo "sqlite:" .$mainpath.$db."\n";
echo
"sqlite:"
.
"../../community.db"
;
//$dbname=$db[0];//getDB($mainpath);//'homework-20750-1-homework-db.db';;
$base
=
new
PDO
(
"sqlite:"
.
"/var/www/adasd/community.db"
);
$base
=
new
PDO
(
"sqlite:"
.
$db
);
echo
"succeed
?
\n
"
;
echo
"succeed
\n
"
;
$max_item_displayed
=
6
;
...
...
geomap2/php/parameters_details.php
View file @
95c34810
...
...
@@ -10,10 +10,12 @@ foreach($db as $d){
break
;
}
}
if
(
$mainpath
==
"//"
)
$mainpath
=
""
;
if
(
is_array
(
$db
)
)
$db
=
$db
[
0
];
//$dbname=$db[0];//getDB($mainpath);//'homework-20750-1-homework-db.db';;
$base
=
new
PDO
(
"sqlite:"
.
$mainpath
.
$db
)
or
die
(
"cannot open the database"
)
;
$base
=
new
PDO
(
"sqlite:"
.
$mainpath
.
$db
);
$max_item_displayed
=
6
;
...
...
tinawebJS/js/sigmaUtils.js
View file @
95c34810
...
...
@@ -153,6 +153,23 @@ function getNeighs(sels,arr){
}
//It returns an array not a dict!
//Using bipartiteN2D or bipartiteD2N
//This receives an array not a dict!
function
getNeighs2
(
sels
,
arr
){
neighDict
=
{};
for
(
var
i
in
sels
)
{
id
=
sels
[
i
]
if
(
!
isUndef
(
arr
[
id
]))
{
A
=
arr
[
id
].
neighbours
;
for
(
var
j
in
A
){
neighDict
[
A
[
j
]]
=
1
}
// neighDict[id]=1;
}
}
return
Object
.
keys
(
neighDict
);
}
//It returns an array not a dict!
//to general utils
function
getArrSubkeys
(
arr
,
id
)
{
var
result
=
[]
...
...
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