Commit fdca8bd0 authored by Phil Hughes's avatar Phil Hughes

Merge branch '5192-fix-epic-date-parsing' into 'master'

Make Epic start and finish dates on Roadmap to be timezone neutral

Closes #5192

See merge request gitlab-org/gitlab-ee!4964
parents ae2f45b6 aa2edd9f
import { convertObjectPropsToCamelCase } from '~/lib/utils/common_utils';
import { parsePikadayDate } from '~/lib/utils/datefix';
export default class RoadmapStore {
constructor(groupId, timeframe) {
......@@ -43,7 +44,7 @@ export default class RoadmapStore {
if (rawEpic.start_date) {
// If startDate is present
const startDate = new Date(rawEpic.start_date);
const startDate = parsePikadayDate(rawEpic.start_date);
if (startDate <= firstTimeframeItem) {
// If startDate is less than first timeframe item
......@@ -69,7 +70,7 @@ export default class RoadmapStore {
// This entire chunk can be moved into generic method
// but we're keeping it here for the sake of simplicity.
if (rawEpic.end_date) {
const endDate = new Date(rawEpic.end_date);
const endDate = parsePikadayDate(rawEpic.end_date);
if (endDate >= lastTimeframeItem) {
epicItem.endDateOutOfRange = true;
epicItem.originalEndDate = endDate;
......
---
title: Make Epic start and finish dates on Roadmap to be timezone neutral
merge_request: 4964
author:
type: fixed
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment