Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    #16
    Hi Isomorphic,

    it is working in my application as well, thanks a lot.
    Real world usage brings a problem and an imperfection, though.

    As this is not DMI but an override, I can't freely change the signature to
    Code:
    @Override public ErrorReport validate(Map data, ErrorReport errors, [B]HttpServletRequest servletRequest[/B]) throws Exception {...}
    For me, this result in non-localisable ErrorMessages.
    It it possible to somehow call/trigger the validation in a new or overridden DMI method, instead?
    This would be great for overview reasons as well:
    • All general stuff that applies to all datasources in my SQLDataSource-subclass
    • All datasource-specific stuff in a DMI
    Right now I have to subclass my SQLDataSource-subclass in order to override validate(). This is of course not a problem in functionality, but in overview.

    Best regards
    Blama

    Comment


      #17
      Hi Isomorphic,

      did you already look into the remaining issue?
      If you decide for a DMI-approach, this should happen fast before other people also @Override validate().

      If it stays the way it is and you somehow include the HttpServletRequest, could you document this approach for multi-field validation somewhere, most likely in the currently links-only Validation-docs?

      Thank you & Best regards
      Blama

      Comment


        #18
        Hi Isomorphic,

        any update on this one?

        Best regards
        Blama

        Comment


          #19
          Just to let you know this is not forgotten - we are discussing the best way to resolve this internally

          Comment


            #20
            Hi Isomorphic,

            any result from the internal discussion of this one?

            Thank you & Best regards
            Blama


            Comment


              #21
              Apologies for the delay. Changes are made and are available for download in latest nightly builds.

              DS.validate(...) API is now deprecated, please use DS.validateRecord(Map, ErrorReport, ValidationContext) instead. ValidationContext has APIs to get DSRequest and RequestContext, which among other things provide access to HttpServletRequest.

              Comment

              Working...
              X