Uploaded image for project: 'MyFaces Trinidad'
  1. MyFaces Trinidad
  2. TRINIDAD-2133

Support Thai Buddhist calendar in client DateTimeConverter

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 2.0.0-core
    • 2.0.1-core
    • Components
    • None

    Description

      1. Create and run the following jspx
      <tr:inputText is d="dt" autoSubmit="true" value="#

      {input.date}">
      <tr:convertDateTime locale="th_TH"/>
      </tr:inputText>
      <tr:outputText value="#{input.date}

      " partialTriggers="dt">
      <tr:convertDateTime locale="en_US"/>
      </tr:outputText>

      2. The page will display the date using the Thai Buddhist Calendar, then the date in US format (which uses GregorianCalendar on the server side). The Thai Buddhist calendar is offset by 543 years from the Gregorain, e.g. the inputText shows 22/8/2554 and the outputText shows 8/22/2011 .

      3. Update the inputText to 29/2/2555 which is equivalent to 2/29/2012 Gregorian, a valid date. However this gives an error, "Enter a valid date or time".

      Attachments

        1. branch121260_2133.diff
          5 kB
          Yee-Wah Lee
        2. trunk_2133_ThaiDateTimeConverter.diff
          5 kB
          Yee-Wah Lee
        3. trunk2001_2133_ThaiDateTimeConverter.diff
          5 kB
          Yee-Wah Lee

        Activity

          People

            gabrielle Gabrielle Crawford
            yeelee Yee-Wah Lee
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: