Skip to content

dateFormat must define all six date components or NaN is returned #71

@watery

Description

@watery

A date format expressed like:

data: {
    dateFormat : "yyyy-MM-dd HH:mm"

Doesn't assign a value to fmt[secs] in Gantt.utils.createDateParser(format), which results in undefined when passed in:

return new Date(
parts[fmt[year]],
parts[fmt[month]] - 1,
parts[fmt[day]],
parts[fmt[hour]],
parts[fmt[min]],
parts[fmt[secs]]
).getTime();
};

resulting in a NaN value, but without any error thrown.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions