guild_front/src/components/ArchiveTableTracker/ArchiveTableTracker.jsx
2023-12-06 18:26:47 +03:00

39 lines
1.0 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import React from "react";
import ArchiveTasksItem from "@components/ArchiveTableTracker/ArchiveTasksItem/ArchiveTasksItem";
import "./archiveTableTracker.scss";
const ArchiveTableTracker = ({ filterCompleteTasks, loader }) => {
return (
<table className="archive__table">
<thead>
<tr>
<th>Задача</th>
<th>Потраченное время</th>
<th>Дата окончания</th>
</tr>
</thead>
<tbody>
{!loader && (
<>
{Boolean(filterCompleteTasks.length) ? (
filterCompleteTasks?.map((task, index) => {
return (
<ArchiveTasksItem task={task} index={index} key={index} />
);
})
) : (
<div className="archive__noItem">
<p>В данном месяце у вас не было задач</p>
</div>
)}
</>
)}
</tbody>
</table>
);
};
export default ArchiveTableTracker;