liform-react icon indicating copy to clipboard operation
liform-react copied to clipboard

fixed DateTimeWidget to generate a value according to json schema date-time format

Open pavel-kh opened this issue 5 years ago • 0 comments

There was a problem with DateTimeWidget, it generated a value not according to json schema date-time format, which is YYYY-MM-DDTHH:mm:ssZ (the generated value was of YYYY-MM-DDTHH:mm format). For example for schema like this one

const schema = {
      title: "A schema", 
      properties: {
        datetime: {
          type: "string",
          format: "date-time",
          widget: "datetime"
        }
      },
      required: ["datetime"]
};

you couldn't enter a valid value using DateTimeWidget

pavel-kh avatar Nov 09 '18 19:11 pavel-kh