Uploaded image for project: 'Magnolia UI'
  1. Magnolia UI
  2. MGNLUI-7033

Support Unix timestamps and ISO-8061 format as date model values


    • Icon: New Feature New Feature
    • Resolution: Fixed
    • Icon: Neutral Neutral
    • 6.2.17
    • None
    • None
    • None

      At the moment our DateConverter always assumes that the model value that is passed to the backend is java.util.Date which is the case for JackRabbit, but usually is different in generic backend case. E.g. Norsu, which is backed by JSON documents atm, needs either a string or a long value (unix timestamp).

      As a result Norsu either has to deal with post-conversion of j.u.Dates somewhere on data-binding level (ugly and error-prone), or we can extend the DateFieldDefinition configuration and the related converter to gracefully support other possible ways of storing dates.

      Dev notes:
      The related PR brings support described above, and in addition brings in necessary changes to optionally let the dates to be stored in ISO-8061 compliant format (the one with 'T' separator between date and time vs whitespace as it is currently hardcoded in Magnolia).

        Acceptance criteria

              apchelintcev Aleksandr Pchelintcev
              apchelintcev Aleksandr Pchelintcev
              0 Vote for this issue
              1 Start watching this issue