import React, { useState } from "react"; import PaginatedList from "../../Pagination/PaginatedList"; import { handlePagingFunc } from "../../Pagination/HandlePagination"; import { currencySymbol } from '../../Helpers/PriceFormatter'; function RecentActivityTable({ payment }) { const [currentPage, setCurrentPage] = useState(0); const indexOfFirstItem = Number(currentPage); const indexOfLastItem = Number(indexOfFirstItem) + Number(process.env.REACT_APP_ITEM_PER_PAGE); const currentActivity = payment?.data?.slice( indexOfFirstItem, indexOfLastItem ); const handlePagination = (e) => { handlePagingFunc(e, setCurrentPage); }; return (
| Date | Trx. | Amnt./Fee | Status |
|---|---|---|---|
| {item.trx_date} |
{currencySymbol(item.currency, item.amount)}
{currencySymbol(item.currency, item.fee)} |
{item.status} |