Results 1 to 4 of 4

Thread: @Annotations for allowedFields/disllowedFields

  1. #1

    Default @Annotations for allowedFields/disllowedFields

    Hi.
    Sorry for my English.

    Maybe some people implemented annotations for allowedFields/disllowedFields in Spring MVC?

    I think it is a good idea

    Code:
    public class Project implements Serializable {
        @DisllowedField
        private long id;
        @AllowedField
        private String title;
        private String description;

  2. #2

    Default

    In my opinion such annotations make no sense, as they should be rather defined on per-controller basis, not per-command (or per-entity). Different controllers may need different sets of allowed fields.

  3. #3

    Default

    Quote Originally Posted by macar View Post
    In my opinion such annotations make no sense, as they should be rather defined on per-controller basis, not per-command (or per-entity). Different controllers may need different sets of allowed fields.
    You right.
    Maybe you know how to set allowedFields/disllowedFields declaratively in xml file?

  4. #4

    Default

    Check EnhancedSimpleFormController. I know it supports XML-style configuration of editors, perhaps of allowed fields as well.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •