Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Set JSON as a default content type #68

Closed
gorbunkov opened this issue Sep 11, 2019 · 0 comments
Closed

Set JSON as a default content type #68

gorbunkov opened this issue Sep 11, 2019 · 0 comments
Assignees
Labels
state: fixed Fixed by the developer type: enhancement New feature or request ver: 7.2.0 Fixed in version
Milestone

Comments

@gorbunkov
Copy link
Contributor

In rest dispatcher spring xml the content negotiation manager bean must e defined with a default content type application/json:

    <bean id="contentNegotiationManager"
          class="org.springframework.web.accept.ContentNegotiationManagerFactoryBean">
        <property name="defaultContentType" value="application/json"/>
    </bean>

    <mvc:annotation-driven content-negotiation-manager="contentNegotiationManager" />

Forum topic: https://www.cuba-platform.com/discuss/t/how-to-set-default-output-to-json-for-rest/10089

@gorbunkov gorbunkov added this to the Release 7.2 milestone Sep 11, 2019
@gorbunkov gorbunkov self-assigned this Sep 11, 2019
@natfirst natfirst added type: enhancement New feature or request ver: 7.2.0 Fixed in version state: fixed Fixed by the developer labels Nov 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
state: fixed Fixed by the developer type: enhancement New feature or request ver: 7.2.0 Fixed in version
Projects
None yet
Development

No branches or pull requests

2 participants