Hi all,
I'm trying to modify the webflow to use json views instead of html ones.
For that we are trying to add new View Resolvers. Basically in one of our
configuration classes, we have added:
@Bean(name = "jsonView")
public MappingJackson2JsonView jsonView() {
MappingJackson2JsonView mappingJacksonJsonView = new
MappingJackson2JsonView();
return mappingJacksonJsonView;
}
@Bean(name = "beanNameViewResolver")
public BeanNameViewResolver beanNameViewResolver(){
BeanNameViewResolver beanNameViewResolver = new BeanNameViewResolver();
beanNameViewResolver.setOrder(-10000);
return beanNameViewResolver;
}
@RefreshScope
@Bean
public ViewFactoryCreator viewFactoryCreator() {
final MvcViewFactoryCreator resolver = new MvcViewFactoryCreator();
resolver.setViewResolvers(Collections.singletonList(beanNameViewResolver()));
return resolver;
}
We have checked we have these new View Resolvers loaded and working, but
when returning "jsonView" from the webflow, it always says
*2017-11-01 10:32:58,375 ERROR [org.thymeleaf.TemplateEngine] -
<[THYMELEAF][https-jsse-nio-8888-exec-4] Exception processing template
"jsonView [text/html]": Error resolving template "jsonView", template might
not exist or might not be accessible by any of the configured Template
Resolvers>*
*org.thymeleaf.exceptions.TemplateInputException: Error resolving template
"jsonView", template might not exist or might not be accessible by any of
the configured Template Resolvers*
So our BeanNameResolver and MappingJackson2JsonView are not working.
Is there someone returning JSON from the webflow like we are trying?
--
- Website: https://apereo.github.io/cas
- Gitter Chatroom: https://gitter.im/apereo/cas
- List Guidelines: https://goo.gl/1VRrw7
- Contributions: https://goo.gl/mh7qDG
---
You received this message because you are subscribed to the Google Groups "CAS
Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/a/apereo.org/d/msgid/cas-user/833a2739-a6a9-4846-83d3-c7b46cdba17a%40apereo.org.