diff --git a/src/components/wallet/transaction-item.tsx b/src/components/wallet/transaction-item.tsx index c1d876b..45c0f38 100644 --- a/src/components/wallet/transaction-item.tsx +++ b/src/components/wallet/transaction-item.tsx @@ -1,5 +1,6 @@ import React from 'react'; import { ArrowDownCircle, ArrowDownIcon, ArrowUp, ArrowUpCircle } from 'lucide-react'; +import { formatPriceWithToman } from '@/lib/utils/priceUtils'; interface TransactionItemProps { amount: number; @@ -20,8 +21,6 @@ const TransactionItem = ({ const bgColor = isDeposit ? 'bg-[#2E7D3210]' : 'bg-[#D32F2F10]'; const iconColor = isDeposit ? 'text-[#2E7D32]' : 'text-[#D32F2F]'; - const formattedAmount = amount.toLocaleString('fa-IR'); - return (
- {isDeposit ? '+' : '-'} {formattedAmount} تومان + {isDeposit ? '+' : '-'} {formatPriceWithToman(amount)} ۱۴۰۳/۰۸/۲۴
diff --git a/src/components/wallet/wallet-blanc-card.tsx b/src/components/wallet/wallet-blanc-card.tsx index 08decd0..b87a119 100644 --- a/src/components/wallet/wallet-blanc-card.tsx +++ b/src/components/wallet/wallet-blanc-card.tsx @@ -1,5 +1,6 @@ 'use client'; +import { formatPriceWithToman } from '@/lib/utils/priceUtils'; import { LogOutIcon, PlusIcon } from 'lucide-react' import React from 'react' @@ -7,7 +8,7 @@ const WalletBlancCard = () => { return (

موجودی کیف پول

-

35000000 تومان

+

{formatPriceWithToman(35000000)}