Skip to content
GitLab
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
6fc0670f
Commit
6fc0670f
authored
Oct 07, 2015
by
Matija Obreza
Browse files
URL Shortener: layout
parent
57a0e4e6
Changes
2
Hide whitespace changes
Inline
Side-by-side
src/main/resources/content/language.properties
View file @
6fc0670f
...
...
@@ -676,6 +676,8 @@ twitter.tweet-this=Tweet!
twitter.follow-X
=
Follow @{0}
linkedin.share-this
=
Share on LinkedIn
share.link
=
Share Link
share.link.placeholder
=
Please wait...
share.link.text
=
Please use the shortened version of the full URL to this page:
welcome.read-more
=
Read more about Genesys
twitter.latest-on-twitter
=
Latest on Twitter
...
...
src/main/webapp/WEB-INF/jsp/accession/explore.jsp
View file @
6fc0670f
...
...
@@ -17,7 +17,7 @@
<spring:message
code=
"accessions.number"
arguments=
"
${
pagedData
.
totalElements
}
"
/>
</div>
<div
class=
"row"
>
<div
class=
"col-
s
m-12 col-
md
-6"
>
<div
class=
"col-m
d
-12 col-
lg
-6"
>
<form
method=
"get"
action=
""
>
<input
type=
"hidden"
name=
"filter"
value=
"
<c:out
value=
"
${
jsonFilter
}
"
/>
"
/>
<div
class=
"pagination"
>
...
...
@@ -28,18 +28,30 @@
</div>
</form>
</div>
<div
class=
"col-sm-12 col-md-6 text-right"
style=
"padding-top: 12px"
>
<div
class=
"col-md-12 col-lg-6 text-right"
style=
"padding-top: 12px"
>
<div
class=
"btn-group"
>
<button
type=
"button"
class=
"btn btn-default dropdown-toggle"
data-toggle=
"dropdown"
aria-haspopup=
"true"
aria-expanded=
"false"
id=
"menuShareLink"
>
<span
class=
"glyphicon glyphicon-share"
></span><span><spring:message
code=
"share.link"
/></span>
<span
class=
"caret"
></span>
</button>
<ul
class=
"dropdown-menu"
>
<li
class=
"padding10"
>
<p><spring:message
code=
"share.link.text"
/></p>
<input
id=
"shortLink"
type=
"text"
placeholder=
"
<spring:message
code=
"share.link.placeholder"
/>
"
value=
""
/>
</li>
</ul>
</div>
<c:if
test=
"
${
pagedData
.
totalElements
le
200000
}
"
>
<form
style=
"display: inline-block"
method=
"post"
action=
"
<c:url
value=
"/download/explore/dwca"
/>
"
>
<input
type=
"hidden"
name=
"${_csrf.parameterName}"
value=
"${_csrf.token}"
/>
<input
type=
"hidden"
name=
"filter"
value=
"
<c:out
value=
"
${
jsonFilter
}
"
/>
"
/>
<button
class=
"btn btn-default"
type=
"submit"
><spring:message
code=
"filter.download-dwca"
/></button>
<button
class=
"btn btn-default"
type=
"submit"
><
span
class=
"glyphicon glyphicon-download"
></span><span><
spring:message
code=
"filter.download-dwca"
/></
span></
button>
</form>
<security:authorize
access=
"isAuthenticated()"
>
<form
style=
"display: inline-block"
method=
"post"
action=
"
<c:url
value=
"/download/explore/download/mcpd"
/>
"
>
<input
type=
"hidden"
name=
"${_csrf.parameterName}"
value=
"${_csrf.token}"
/>
<input
type=
"hidden"
name=
"filter"
value=
"
<c:out
value=
"
${
jsonFilter
}
"
/>
"
/>
<button
class=
"btn btn-default"
type=
"submit"
><spring:message
code=
"filter.download-mcpd"
/></button>
<button
class=
"btn btn-default"
type=
"submit"
><
span
class=
"glyphicon glyphicon-download"
></span><span><
spring:message
code=
"filter.download-mcpd"
/></
span></
button>
</form>
</security:authorize>
</c:if>
...
...
@@ -90,14 +102,6 @@
<span
class=
"${fn:length(currentFilters) gt 0 ? '' : 'hide'}"
><spring:message
code=
"filter.filters-applied"
/></span>
<span
class=
"${fn:length(currentFilters) gt 0 ? 'hide' : ''}"
><spring:message
code=
"filter.filters-not-applied"
/></span>
</li>
<li
class=
"active dropdown form-horizontal"
style=
"float: right"
id=
"menuShareLink"
>
<a
class=
"dropdown-toggle"
data-toggle=
"dropdown"
href=
"#"
>
<spring:message
code=
"share.link"
/>
</a>
<ul
class=
"dropdown-menu"
>
<input
id=
"shortLink"
type=
"text"
value=
""
>
</ul>
</li>
</ul>
<%-- Only render currently present filters --%>
...
...
@@ -432,6 +436,7 @@
});
$
(
"
#menuShareLink
"
).
on
(
"
click
"
,
function
()
{
if
(
$
(
'
#shortLink
'
).
val
()
===
''
)
{
$
.
ajax
({
type
:
'
POST
'
,
url
:
'
/explore/shorten-url
'
,
...
...
@@ -444,6 +449,9 @@
inp
.
select
();
}
});
}
else
{
console
.
log
(
'
No repeat.
'
);
}
});
GenesysFilterUtil
.
registerAutocomplete
(
"
#allfilters
"
,
jsonData
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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