mirror of
https://github.com/mayswind/ezbookkeeping.git
synced 2026-05-17 08:14:25 +08:00
use for-of statements to replace for and for-in
This commit is contained in:
@@ -156,9 +156,7 @@ export const useOverviewStore = defineStore('overview', () => {
|
||||
let hasUnCalculatedTotalExpense = false;
|
||||
|
||||
if (item.amounts) {
|
||||
for (let i = 0; i < item.amounts.length; i++) {
|
||||
const amount = item.amounts[i];
|
||||
|
||||
for (const amount of item.amounts) {
|
||||
if (amount.currency !== defaultCurrency) {
|
||||
const incomeAmount = exchangeRatesStore.getExchangedAmount(amount.incomeAmount, amount.currency, defaultCurrency);
|
||||
const expenseAmount = exchangeRatesStore.getExchangedAmount(amount.expenseAmount, amount.currency, defaultCurrency);
|
||||
|
||||
Reference in New Issue
Block a user