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
Genesys PGR
Genesys Backend
Commits
db62af72
Commit
db62af72
authored
Dec 03, 2015
by
Alexander Basov
Browse files
Map layers. Fixed select appropriate radiobutton in dropdown
parent
cff88353
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/main/webapp/WEB-INF/jsp/accession/map.jsp
View file @
db62af72
...
...
@@ -36,9 +36,9 @@
<ul
class=
"dropdown-menu"
>
<li>
<label><input
class=
"map-provider"
name=
"provider"
style=
'margin-right: 10px;margin-left: 5px'
<label
class=
"label-map-provider"
><input
class=
"map-provider"
name=
"provider"
style=
'margin-right: 10px;margin-left: 5px'
type=
'radio'
>
MapQuest
</label>
<label><input
name=
"provider"
class=
"map-provider"
style=
'margin-right: 10px;margin-left: 5px'
<label
class=
"label-map-provider"
><input
name=
"provider"
class=
"map-provider"
style=
'margin-right: 10px;margin-left: 5px'
type=
'radio'
>
Openstreetmap
</label>
</li>
</ul>
...
...
@@ -187,6 +187,10 @@
})
}
};
[].
forEach
.
call
(
$
(
'
.label-map-provider
'
),
function
(
label
){
label
.
innerText
==
cookieUtils
.
getCookie
(
'
mapProviders
'
)?
$
(
label
).
find
(
'
input:radio
'
).
prop
(
'
checked
'
,
true
)
:
$
(
label
).
find
(
'
input:radio
'
).
prop
(
'
checked
'
,
false
);
});
if
(
cookieUtils
.
getCookie
(
'
mapProviders
'
)
&&
cookieUtils
.
getCookie
(
'
mapProviders
'
)
!=
''
)
{
mapProviders
[
cookieUtils
.
getCookie
(
'
mapProviders
'
)].
addTo
(
map
);
topPane
.
appendChild
(
mapProviders
[
cookieUtils
.
getCookie
(
'
mapProviders
'
)].
getContainer
());
...
...
@@ -212,8 +216,6 @@
});
$
(
"
body
"
).
on
(
"
click
"
,
"
.map-provider
"
,
function
(
e
)
{
var
providerName
=
$
(
this
).
parent
().
text
();
console
.
log
(
$
(
this
).
parent
().
text
());
console
.
log
(
providerName
);
if
(
$
(
this
).
is
(
"
:checked
"
))
{
cookieUtils
.
setCookie
(
'
mapProviders
'
,
providerName
,
0
);
$
(
document
).
trigger
(
'
cookieUpdate
'
);
...
...
@@ -372,7 +374,7 @@
loadDetailsTimeout
=
setTimeout
(
function
()
{
var
filterBounds
=
filterJsonObj
;
console
.
log
(
filterBounds
)
console
.
log
(
filterBounds
)
;
filterBounds
[
'
geo.latitude
'
]
=
[{
range
:
[
sw
.
lat
,
ne
.
lat
]}];
filterBounds
[
'
geo.longitude
'
]
=
[{
range
:
[
sw
.
lng
,
ne
.
lng
]}];
//console.log(JSON.stringify(filterBounds));
...
...
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