Skip to content

Commit

Permalink
Merge pull request #148 from arenadata/bugfix/ADH-5565
Browse files Browse the repository at this point in the history
[ui] bugfix-5565 action details page, runtime fix
  • Loading branch information
remizov-arena authored Jan 20, 2025
2 parents f5b7c58 + bd95d48 commit b89aca0
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@
import React from 'react';
import { type TableCellProps } from '@uikit/Table/TableCell/TableCell';
import TableCell from '@uikit/Table/TableCell/TableCell';
import { getToday } from '@utils/date/calendarUtils';
import { millisecondsToDuration } from '@utils/date/dateConvertUtils';

interface PassedTimeCellProps extends Omit<TableCellProps, 'children'> {
Expand All @@ -27,7 +26,7 @@ interface PassedTimeCellProps extends Omit<TableCellProps, 'children'> {
}

const PassedTimeCell = ({ startTime, finishTime, ...props }: PassedTimeCellProps) => {
const timeDiff = finishTime ? finishTime - startTime : getToday().getTime() - startTime;
const timeDiff = finishTime ? finishTime - startTime : new Date().getTime() - startTime;
return <TableCell {...props}>{millisecondsToDuration(timeDiff)}</TableCell>;
};

Expand Down

0 comments on commit b89aca0

Please sign in to comment.