forked from vikunja/vikunja
feat: Update date-time parser in update:task event
This commit is contained in:
parent
fe104334a1
commit
d8dcf65284
|
@ -52,6 +52,7 @@ import {colorIsDark} from '@/helpers/color/colorIsDark'
|
||||||
import {isoToKebabDate} from '@/helpers/time/isoToKebabDate'
|
import {isoToKebabDate} from '@/helpers/time/isoToKebabDate'
|
||||||
import {isoToKebabDatetime} from '@/helpers/time/isoToKebabDatetime'
|
import {isoToKebabDatetime} from '@/helpers/time/isoToKebabDatetime'
|
||||||
import {parseKebabDate} from '@/helpers/time/parseKebabDate'
|
import {parseKebabDate} from '@/helpers/time/parseKebabDate'
|
||||||
|
import {parseKebabDatetime} from '@/helpers/time/parseKebabDatetime'
|
||||||
|
|
||||||
import type {ITask, ITaskPartialWithId} from '@/modelTypes/ITask'
|
import type {ITask, ITaskPartialWithId} from '@/modelTypes/ITask'
|
||||||
import type {DateISO} from '@/types/DateISO'
|
import type {DateISO} from '@/types/DateISO'
|
||||||
|
@ -180,8 +181,8 @@ async function updateGanttTask(e: {
|
||||||
}) {
|
}) {
|
||||||
emit('update:task', {
|
emit('update:task', {
|
||||||
id: Number(e.bar.ganttBarConfig.id),
|
id: Number(e.bar.ganttBarConfig.id),
|
||||||
startDate: new Date(parseKebabDate(e.bar.startDate).setHours(0,0,0,0)),
|
startDate: new Date(parseKebabDatetime(e.bar.startDate)),
|
||||||
endDate: new Date(parseKebabDate(e.bar.endDate).setHours(23,59,0,0)),
|
endDate: new Date(parseKebabDatetime(e.bar.endDate)),
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user