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
f2af16bf
Commit
f2af16bf
authored
Sep 26, 2017
by
Maxym Borodenko
Committed by
Matija Obreza
Sep 26, 2017
Browse files
HTTP error 500
parent
d0dc1c52
Changes
5
Hide whitespace changes
Inline
Side-by-side
src/main/java/org/genesys2/server/servlet/controller/ExplorerController.java
View file @
f2af16bf
...
...
@@ -442,7 +442,7 @@ public class ExplorerController extends BaseController implements InitializingBe
AppliedFilters
appliedFilters
=
mapper
.
readValue
(
jsonFilter
,
AppliedFilters
.
class
);
try
{
return
new
ResponseEntity
<
Page
>(
filterService
.
listAccessionDetails
(
appliedFilters
,
new
PageRequest
(
page
-
1
,
Integer
.
min
(
results
,
maxPageSize
),
new
Sort
(
"seqNo"
))),
HttpStatus
.
OK
);
}
catch
(
MaxPageLimit
Exception
ex
)
{
}
catch
(
final
Exception
ex
)
{
ErrorResponse
error
=
new
ErrorResponse
();
error
.
setErrorCode
(
HttpStatus
.
BAD_REQUEST
.
value
());
error
.
setMessage
(
ex
.
getMessage
());
...
...
src/main/java/org/genesys2/server/servlet/controller/UserControllerAdvice.java
View file @
f2af16bf
...
...
@@ -16,7 +16,6 @@
package
org.genesys2.server.servlet.controller
;
import
java.text.MessageFormat
;
import
java.util.HashMap
;
import
java.util.List
;
import
java.util.Map
;
...
...
@@ -87,7 +86,7 @@ public class UserControllerAdvice extends BaseController {
@ResponseStatus
(
HttpStatus
.
INTERNAL_SERVER_ERROR
)
@ExceptionHandler
(
value
=
{
Throwable
.
class
})
public
ModelAndView
handleAll
(
final
HttpServletRequest
req
,
final
Throwable
e
)
{
_logger
.
error
(
MessageFormat
.
format
(
"{} on {} {}"
,
e
.
getMessage
(),
req
.
getMethod
(),
req
.
getRequestURL
())
,
e
)
;
_logger
.
error
(
"{} on {} {}"
,
e
.
getMessage
(),
req
.
getMethod
(),
req
.
getRequestURL
());
final
ModelAndView
mav
=
new
ModelAndView
(
"/errors/error"
);
mav
.
addObject
(
"exception"
,
e
);
return
mav
;
...
...
src/main/sourceapp/1/js/crophub.js
View file @
f2af16bf
...
...
@@ -724,6 +724,7 @@ $(document).ready(function() {
var
submitSubmit
=
$
(
'
.searchbox-submit
'
);
var
inputBox
=
$
(
'
.searchbox-input
'
);
var
searchBox
=
$
(
'
.searchbox
'
);
var
body
=
$
(
'
body
'
);
var
isOpen
=
false
;
submitIcon
.
click
(
function
(){
if
(
isOpen
===
false
){
...
...
@@ -756,7 +757,7 @@ $(document).ready(function() {
}
});
$
(
'
body
'
)
.
on
(
'
input
'
,
'
.searchbox-input
'
,
function
()
{
body
.
on
(
'
input
'
,
'
.searchbox-input
'
,
function
()
{
var
inputVal
=
$
(
'
.searchbox-input
'
).
val
();
inputVal
=
$
.
trim
(
inputVal
).
length
;
if
(
inputVal
!==
0
){
...
...
@@ -767,7 +768,17 @@ $(document).ready(function() {
}
});
$
(
'
body
'
).
on
(
'
click
'
,
'
.get_widget
'
,
function
()
{
body
.
on
(
'
input paste
'
,
'
#paginate2-input-field
'
,
function
(
e
)
{
e
.
preventDefault
();
if
(
/
\D
/g
.
test
(
this
.
value
))
{
// Filter non-digits from input value.
this
.
value
=
this
.
value
.
replace
(
/
\D
/g
,
''
);
}
else
if
(
this
.
value
===
'
0
'
)
{
this
.
value
=
''
;
}
});
body
.
on
(
'
click
'
,
'
.get_widget
'
,
function
()
{
var
clientId
=
$
(
this
).
val
();
$
.
ajax
(
'
/
'
+
document
.
documentElement
.
lang
+
'
/get_widget
'
,
{
type
:
'
GET
'
,
...
...
src/main/webapp/WEB-INF/jsp/accession/explore2.jsp
View file @
f2af16bf
...
...
@@ -644,6 +644,8 @@
if
(
/
\D
/g
.
test
(
this
.
value
))
{
// Filter non-digits from input value.
this
.
value
=
this
.
value
.
replace
(
/
\D
/g
,
''
);
}
else
if
(
this
.
value
===
'
0
'
)
{
this
.
value
=
''
;
}
});
...
...
src/main/webapp/WEB-INF/tags/paginate2.tag
View file @
f2af16bf
...
...
@@ -56,7 +56,7 @@
<li><span class="pagination-input">
<form method="get" action="">
<input class="text-center" type="text" name="page"
<input class="text-center" type="text" name="page"
id="paginate2-input-field"
placeholder="<c:out value="${page.number + 1}" />" value="<c:out value="${page.number + 1}" />" />
</form>
</span></li>
...
...
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