diff --git a/kmymoney/dialogs/kbalancechartdlg.cpp b/kmymoney/dialogs/kbalancechartdlg.cpp --- a/kmymoney/dialogs/kbalancechartdlg.cpp +++ b/kmymoney/dialogs/kbalancechartdlg.cpp @@ -76,7 +76,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::last3ToNext3Months, - MyMoneyReport::eDetailTotal, + MyMoneyReport::DetailLevel::Total, i18n("%1 Balance History", account.name()), i18n("Generated Report") ); diff --git a/kmymoney/dialogs/kreportconfigurationfilterdlg.cpp b/kmymoney/dialogs/kreportconfigurationfilterdlg.cpp --- a/kmymoney/dialogs/kreportconfigurationfilterdlg.cpp +++ b/kmymoney/dialogs/kreportconfigurationfilterdlg.cpp @@ -156,7 +156,7 @@ m_currentState.setSkipZero(m_tab1->findChild("m_skipZero")->isChecked()); if (m_tab2) { - MyMoneyReport::EDetailLevel dl[4] = { MyMoneyReport::eDetailAll, MyMoneyReport::eDetailTop, MyMoneyReport::eDetailGroup, MyMoneyReport::eDetailTotal }; + MyMoneyReport::DetailLevel::Type dl[4] = { MyMoneyReport::DetailLevel::All, MyMoneyReport::DetailLevel::Top, MyMoneyReport::DetailLevel::Group, MyMoneyReport::DetailLevel::Total }; m_currentState.setDetailLevel(dl[m_tab2->findChild("m_comboDetail")->currentIndex()]); @@ -233,7 +233,7 @@ m_currentState.setLoansOnly(m_tab3->findChild("m_checkLoans")->isChecked()); m_currentState.setDetailLevel(m_tab3->findChild("m_checkHideSplitDetails")->isChecked() ? - MyMoneyReport::eDetailNone : MyMoneyReport::eDetailAll); + MyMoneyReport::DetailLevel::None : MyMoneyReport::DetailLevel::All); } if (m_tabChart) { @@ -300,18 +300,18 @@ if (m_tab2) { KComboBox *combo = m_tab2->findChild("m_comboDetail"); switch (m_initialState.detailLevel()) { - case MyMoneyReport::eDetailNone: - case MyMoneyReport::eDetailEnd: - case MyMoneyReport::eDetailAll: + case MyMoneyReport::DetailLevel::None: + case MyMoneyReport::DetailLevel::End: + case MyMoneyReport::DetailLevel::All: combo->setCurrentItem(i18nc("All accounts", "All"), false); break; - case MyMoneyReport::eDetailTop: + case MyMoneyReport::DetailLevel::Top: combo->setCurrentItem(i18n("Top-Level"), false); break; - case MyMoneyReport::eDetailGroup: + case MyMoneyReport::DetailLevel::Group: combo->setCurrentItem(i18n("Groups"), false); break; - case MyMoneyReport::eDetailTotal: + case MyMoneyReport::DetailLevel::Total: combo->setCurrentItem(i18n("Totals"), false); break; } @@ -440,7 +440,7 @@ m_tab3->findChild("m_checkLoans")->setChecked(m_initialState.isLoansOnly()); m_tab3->findChild("m_checkHideSplitDetails")->setChecked - (m_initialState.detailLevel() == MyMoneyReport::eDetailNone); + (m_initialState.detailLevel() == MyMoneyReport::DetailLevel::None); } if (m_tabChart) { diff --git a/kmymoney/kmymoney.cpp b/kmymoney/kmymoney.cpp --- a/kmymoney/kmymoney.cpp +++ b/kmymoney/kmymoney.cpp @@ -4292,7 +4292,7 @@ MyMoneyReport::Row::Account, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Payee | MyMoneyReport::QueryColumns::Category, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("%1 YTD Account Transactions", d->m_selectedAccount.name()), i18n("Generated Report") ); diff --git a/kmymoney/mymoney/mymoneyreport.h b/kmymoney/mymoney/mymoneyreport.h --- a/kmymoney/mymoney/mymoneyreport.h +++ b/kmymoney/mymoney/mymoneyreport.h @@ -96,15 +96,19 @@ static const QStringList kText; }; - enum EDetailLevel { eDetailNone = 0, eDetailAll, eDetailTop, eDetailGroup, eDetailTotal, eDetailEnd }; + class DetailLevel { + public: + enum Type { None = 0, All, Top, Group, Total, End }; + static const QStringList kText; + }; + enum EChartType { eChartNone = 0, eChartLine, eChartBar, eChartPie, eChartRing, eChartStackedBar, eChartEnd }; - static const QStringList kDetailLevelText; static const QStringList kChartTypeText; public: MyMoneyReport(); - MyMoneyReport(Row::Type _rt, unsigned _ct, dateOptionE _dl, EDetailLevel _ss, const QString& _name, const QString& _comment); + MyMoneyReport(Row::Type _rt, unsigned _ct, dateOptionE _dl, DetailLevel::Type _ss, const QString& _name, const QString& _comment); MyMoneyReport(const QString& id, const MyMoneyReport& right); /** @@ -163,7 +167,7 @@ bool isLoansOnly() const { return m_loans; } - EDetailLevel detailLevel() const { + DetailLevel::Type detailLevel() const { return m_detailLevel; } EChartType chartType() const { @@ -265,7 +269,7 @@ void setLoansOnly(bool _f) { m_loans = _f; if (_f) m_investments = false; } - void setDetailLevel(EDetailLevel _detail) { + void setDetailLevel(DetailLevel::Type _detail) { m_detailLevel = _detail; } void setChartType(EChartType _type) { @@ -536,7 +540,7 @@ /** * How much detail to show in the accounts */ - enum EDetailLevel m_detailLevel; + DetailLevel::Type m_detailLevel; /** * Whether to convert all currencies to the base currency of the file (true). * If this is false, it's up to the report generator to decide how to handle diff --git a/kmymoney/mymoney/mymoneyreport.cpp b/kmymoney/mymoney/mymoneyreport.cpp --- a/kmymoney/mymoney/mymoneyreport.cpp +++ b/kmymoney/mymoney/mymoneyreport.cpp @@ -40,7 +40,7 @@ // if you add names here, don't forget to update the bitmap for QueryColumns::Type // and shift the bit for QueryColumns::end one position to the left const QStringList MyMoneyReport::QueryColumns::kText = QString("none,number,payee,category,tag,memo,account,reconcileflag,action,shares,price,performance,loan,balance").split(','); -const QStringList MyMoneyReport::kDetailLevelText = QString("none,all,top,group,total,invalid").split(','); +const QStringList MyMoneyReport::DetailLevel::kText = QString("none,all,top,group,total,invalid").split(','); const QStringList MyMoneyReport::kChartTypeText = QString("none,line,bar,pie,ring,stackedbar,invalid").split(','); // This should live in mymoney/mymoneytransactionfilter.h @@ -91,7 +91,7 @@ MyMoneyReport::MyMoneyReport() : m_name("Unconfigured Pivot Table Report"), - m_detailLevel(eDetailNone), + m_detailLevel(DetailLevel::None), m_convertCurrency(true), m_favorite(false), m_tax(false), @@ -134,7 +134,7 @@ setId(id); } -MyMoneyReport::MyMoneyReport(Row::Type _rt, unsigned _ct, dateOptionE _dl, EDetailLevel _ss, const QString& _name, const QString& _comment) : +MyMoneyReport::MyMoneyReport(Row::Type _rt, unsigned _ct, dateOptionE _dl, DetailLevel::Type _ss, const QString& _name, const QString& _comment) : m_name(_name), m_comment(_comment), m_detailLevel(_ss), @@ -437,7 +437,7 @@ if (m_reportType == Report::PivotTable) { e.setAttribute("type", "pivottable 1.15"); - e.setAttribute("detail", kDetailLevelText[m_detailLevel]); + e.setAttribute("detail", DetailLevel::kText[m_detailLevel]); e.setAttribute("columntype", Column::kTypeText[m_columnType]); e.setAttribute("showrowtotals", m_showRowTotals); } else if (m_reportType == Report::QueryTable) { @@ -456,7 +456,7 @@ e.setAttribute("querycolumns", columns.join(",")); } else if (m_reportType == Report::InfoTable) { e.setAttribute("type", "infotable 1.0"); - e.setAttribute("detail", kDetailLevelText[m_detailLevel]); + e.setAttribute("detail", DetailLevel::kText[m_detailLevel]); e.setAttribute("showrowtotals", m_showRowTotals); } @@ -684,15 +684,15 @@ //check for reports with older settings which didn't have the detail attribute if (e.hasAttribute("detail")) { - i = kDetailLevelText.indexOf(e.attribute("detail", "all")); + i = DetailLevel::kText.indexOf(e.attribute("detail", "all")); if (i != -1) - m_detailLevel = static_cast(i); + m_detailLevel = static_cast(i); } else if (e.attribute("showsubaccounts", "0").toUInt()) { //set to show all accounts - m_detailLevel = eDetailAll; + m_detailLevel = DetailLevel::All; } else { //set to show the top level account instead - m_detailLevel = eDetailTop; + m_detailLevel = DetailLevel::Top; } m_convertCurrency = e.attribute("convertcurrency", "1").toUInt(); diff --git a/kmymoney/reports/kreportchartview.cpp b/kmymoney/reports/kreportchartview.cpp --- a/kmymoney/reports/kreportchartview.cpp +++ b/kmymoney/reports/kreportchartview.cpp @@ -254,9 +254,9 @@ } switch (config.detailLevel()) { - case MyMoneyReport::eDetailNone: - case MyMoneyReport::eDetailEnd: - case MyMoneyReport::eDetailAll: { + case MyMoneyReport::DetailLevel::None: + case MyMoneyReport::DetailLevel::End: + case MyMoneyReport::DetailLevel::All: { int rowNum = 0; // iterate over outer groups @@ -303,7 +303,7 @@ } break; - case MyMoneyReport::eDetailTop: { + case MyMoneyReport::DetailLevel::Top: { int rowNum = 0; // iterate over outer groups @@ -341,7 +341,7 @@ } break; - case MyMoneyReport::eDetailGroup: { + case MyMoneyReport::DetailLevel::Group: { int rowNum = 0; // iterate over outer groups @@ -397,7 +397,7 @@ } break; - case MyMoneyReport::eDetailTotal: { + case MyMoneyReport::DetailLevel::Total: { int rowNum = 0; //iterate row types diff --git a/kmymoney/reports/objectinfotable.cpp b/kmymoney/reports/objectinfotable.cpp --- a/kmymoney/reports/objectinfotable.cpp +++ b/kmymoney/reports/objectinfotable.cpp @@ -109,7 +109,7 @@ switch (m_config.rowType()) { case MyMoneyReport::Row::Schedule: - if (m_config.detailLevel() == MyMoneyReport::eDetailAll) { + if (m_config.detailLevel() == MyMoneyReport::DetailLevel::All) { m_columns = "name,payee,paymenttype,occurence,nextduedate,category"; // krazy:exclude=spelling } else { m_columns = "name,payee,paymenttype,occurence,nextduedate"; // krazy:exclude=spelling @@ -183,7 +183,7 @@ //the text matches the main split bool transaction_text = m_config.match(&split); - if (m_config.detailLevel() == MyMoneyReport::eDetailAll) { + if (m_config.detailLevel() == MyMoneyReport::DetailLevel::All) { //get the information for all splits QList splits = transaction.splits(); QList::const_iterator split_it = splits.constBegin(); diff --git a/kmymoney/reports/pivottable.cpp b/kmymoney/reports/pivottable.cpp --- a/kmymoney/reports/pivottable.cpp +++ b/kmymoney/reports/pivottable.cpp @@ -1433,7 +1433,7 @@ bool finishrow = true; QString finalRow; bool isUsed = false; - if (m_config_f.detailLevel() == MyMoneyReport::eDetailAll && ((*it_innergroup).size() > 1)) { + if (m_config_f.detailLevel() == MyMoneyReport::DetailLevel::All && ((*it_innergroup).size() > 1)) { // Print the individual rows result += innergroupdata; @@ -1618,7 +1618,7 @@ // Skip the body of the report if the report only calls for totals to be shown - if (m_config_f.detailLevel() != MyMoneyReport::eDetailTotal) { + if (m_config_f.detailLevel() != MyMoneyReport::DetailLevel::Total) { // // Outer groups // @@ -1651,7 +1651,7 @@ result += QString("%2\n").arg(colspan).arg((*it_outergroup).m_displayName); // Skip the inner groups if the report only calls for outer group totals to be shown - if (m_config_f.detailLevel() != MyMoneyReport::eDetailGroup) { + if (m_config_f.detailLevel() != MyMoneyReport::DetailLevel::Group) { // // Inner Groups @@ -1733,7 +1733,7 @@ bool finishrow = true; QString finalRow; bool isUsed = false; - if (m_config_f.detailLevel() == MyMoneyReport::eDetailAll && ((*it_innergroup).size() > 1)) { + if (m_config_f.detailLevel() == MyMoneyReport::DetailLevel::All && ((*it_innergroup).size() > 1)) { // Print the individual rows result += innergroupdata; @@ -1760,7 +1760,7 @@ isUsed |= !rowname.isClosed(); finalRow = QString("%5%6") .arg(rownum & 0x01 ? "even" : "odd") - .arg(m_config_f.detailLevel() == MyMoneyReport::eDetailAll ? "id=\"solo\"" : "") + .arg(m_config_f.detailLevel() == MyMoneyReport::DetailLevel::All ? "id=\"solo\"" : "") .arg(rowname.hierarchyDepth() - 1) .arg(rowname.name().replace(QRegExp(" "), " ")) .arg((m_config_f.isConvertCurrency() || !rowname.isForeignCurrency()) ? QString() : QString(" (%1)").arg(rowname.currency().id())); diff --git a/kmymoney/reports/pivottabletest.cpp b/kmymoney/reports/pivottabletest.cpp --- a/kmymoney/reports/pivottabletest.cpp +++ b/kmymoney/reports/pivottabletest.cpp @@ -234,7 +234,7 @@ MyMoneyReport filter; filter.setRowType(MyMoneyReport::Row::ExpenseIncome); filter.setDateFilter(QDate(2004, 9, 1), QDate(2005, 1, 1).addDays(-1)); - filter.setDetailLevel(MyMoneyReport::eDetailAll); + filter.setDetailLevel(MyMoneyReport::DetailLevel::All); filter.setName("Spending with Sub-Account"); XMLandback(filter); PivotTable spending_f(filter); @@ -417,7 +417,7 @@ MyMoneyReport filter; filter.setRowType(MyMoneyReport::Row::ExpenseIncome); filter.setDateFilter(QDate(2004, 1, 1), QDate(2005, 1, 1).addDays(-1)); - filter.setDetailLevel(MyMoneyReport::eDetailAll); + filter.setDetailLevel(MyMoneyReport::DetailLevel::All); filter.setConvertCurrency(true); filter.setName("Multiple Currency Spending Rerport (with currency conversion)"); XMLandback(filter); @@ -440,7 +440,7 @@ // Test the report type where we DO NOT convert the currency filter.setConvertCurrency(false); - filter.setDetailLevel(MyMoneyReport::eDetailAll); + filter.setDetailLevel(MyMoneyReport::DetailLevel::All); filter.setName("Multiple Currency Spending Report (WITHOUT currency conversion)"); XMLandback(filter); PivotTable spending_fnc(filter); @@ -943,7 +943,7 @@ MyMoneyReport report(MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, "Yearly Budgeted vs. Actual", "Default Report"); PivotTable table(report); } @@ -955,7 +955,7 @@ MyMoneyReport report(MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, "Yearly Budgeted vs. Actual", "Default Report"); PivotTable table(report); } @@ -971,7 +971,7 @@ MyMoneyReport report(MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailTop , + MyMoneyReport::DetailLevel::Top , "Yearly Budgeted vs. Actual", "Default Report"); PivotTable table(report); } @@ -988,7 +988,7 @@ MyMoneyReport report(MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, "Yearly Budgeted vs. Actual", "Default Report"); PivotTable table(report); } @@ -1005,7 +1005,7 @@ MyMoneyReport report(MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, "Yearly Budgeted vs. Actual", "Default Report"); PivotTable table(report); } diff --git a/kmymoney/reports/querytable.cpp b/kmymoney/reports/querytable.cpp --- a/kmymoney/reports/querytable.cpp +++ b/kmymoney/reports/querytable.cpp @@ -424,18 +424,18 @@ case MyMoneyReport::Row::Payee: use_summary = false; use_transfers = false; - hide_details = (m_config.detailLevel() == MyMoneyReport::eDetailNone); + hide_details = (m_config.detailLevel() == MyMoneyReport::DetailLevel::None); break; case MyMoneyReport::Row::Tag: use_summary = false; use_transfers = false; - hide_details = (m_config.detailLevel() == MyMoneyReport::eDetailNone); + hide_details = (m_config.detailLevel() == MyMoneyReport::DetailLevel::None); tag_special_case = true; break; default: use_summary = true; use_transfers = true; - hide_details = (m_config.detailLevel() == MyMoneyReport::eDetailNone); + hide_details = (m_config.detailLevel() == MyMoneyReport::DetailLevel::None); break; } diff --git a/kmymoney/reports/querytabletest.cpp b/kmymoney/reports/querytabletest.cpp --- a/kmymoney/reports/querytabletest.cpp +++ b/kmymoney/reports/querytabletest.cpp @@ -455,7 +455,7 @@ MyMoneyReport::Row::TopAccount, MyMoneyReport::QueryColumns::Action | MyMoneyReport::QueryColumns::Shares | MyMoneyReport::QueryColumns::Price, MyMoneyTransactionFilter::userDefined, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Transactions"), i18n("Test Report") ); @@ -547,7 +547,7 @@ MyMoneyReport::Row::AccountByTopAccount, MyMoneyReport::QueryColumns::Performance, MyMoneyTransactionFilter::userDefined, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Performance by Account"), i18n("Test Report") ); diff --git a/kmymoney/views/kforecastview.cpp b/kmymoney/views/kforecastview.cpp --- a/kmymoney/views/kforecastview.cpp +++ b/kmymoney/views/kforecastview.cpp @@ -1005,7 +1005,7 @@ void KForecastView::loadChartView() { - MyMoneyReport::EDetailLevel detailLevel[4] = { MyMoneyReport::eDetailAll, MyMoneyReport::eDetailTop, MyMoneyReport::eDetailGroup, MyMoneyReport::eDetailTotal }; + MyMoneyReport::DetailLevel::Type detailLevel[4] = { MyMoneyReport::DetailLevel::All, MyMoneyReport::DetailLevel::Top, MyMoneyReport::DetailLevel::Group, MyMoneyReport::DetailLevel::Total }; MyMoneyReport reportCfg = MyMoneyReport( MyMoneyReport::Row::AssetLiability, diff --git a/kmymoney/views/khomeview.cpp b/kmymoney/views/khomeview.cpp --- a/kmymoney/views/khomeview.cpp +++ b/kmymoney/views/khomeview.cpp @@ -299,7 +299,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::userDefined, // overridden by the setDateFilter() call below - MyMoneyReport::eDetailTotal, + MyMoneyReport::DetailLevel::Total, i18n("Net Worth Forecast"), i18n("Generated Report")); @@ -1456,7 +1456,7 @@ MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::currentMonth, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Monthly Budgeted vs. Actual"), i18n("Generated Report")); diff --git a/kmymoney/views/kreportsview.cpp b/kmymoney/views/kreportsview.cpp --- a/kmymoney/views/kreportsview.cpp +++ b/kmymoney/views/kreportsview.cpp @@ -1176,32 +1176,32 @@ MyMoneyReport::Row::ExpenseIncome, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::currentMonth, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Income and Expenses This Month"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::ExpenseIncome, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Income and Expenses This Year"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::ExpenseIncome, MyMoneyReport::Column::Years, MyMoneyTransactionFilter::allDates, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Income and Expenses By Year"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::ExpenseIncome, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::last12Months, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("Income and Expenses Graph"), i18n("Default Report") )); @@ -1213,7 +1213,7 @@ MyMoneyReport::Row::ExpenseIncome, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailGroup, + MyMoneyReport::DetailLevel::Group, i18n("Income and Expenses Pie Chart"), i18n("Default Report") )); @@ -1230,31 +1230,31 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("Net Worth By Month"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::today, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("Net Worth Today"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Years, MyMoneyTransactionFilter::allDates, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("Net Worth By Year"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::next7Days, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("7-day Cash Flow Forecast"), i18n("Default Report") )); @@ -1265,7 +1265,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::last12Months, - MyMoneyReport::eDetailTotal, + MyMoneyReport::DetailLevel::Total, i18n("Net Worth Graph"), i18n("Default Report") )); @@ -1277,16 +1277,16 @@ MyMoneyReport::Row::Institution, MyMoneyReport::QueryColumns::None, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("Account Balances by Institution"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::AccountType, MyMoneyReport::QueryColumns::None, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("Account Balances by Type"), i18n("Default Report") )); @@ -1300,65 +1300,65 @@ MyMoneyReport::Row::Account, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Payee | MyMoneyReport::QueryColumns::Category | MyMoneyReport::QueryColumns::Tag | MyMoneyReport::QueryColumns::Balance, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Transactions by Account"), i18n("Default Report") )); //list.back().setConvertCurrency(false); list.push_back(MyMoneyReport( MyMoneyReport::Row::Category, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Payee | MyMoneyReport::QueryColumns::Account | MyMoneyReport::QueryColumns::Tag, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Transactions by Category"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::Payee, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Category | MyMoneyReport::QueryColumns::Tag, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Transactions by Payee"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::Tag, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Category, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Transactions by Tag"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::Month, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Payee | MyMoneyReport::QueryColumns::Category | MyMoneyReport::QueryColumns::Tag, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Transactions by Month"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::Week, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Payee | MyMoneyReport::QueryColumns::Category | MyMoneyReport::QueryColumns::Tag, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Transactions by Week"), i18n("Default Report") )); list.push_back(MyMoneyReport( MyMoneyReport::Row::Account, MyMoneyReport::QueryColumns::Loan, MyMoneyTransactionFilter::allDates, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Loan Transactions"), i18n("Default Report") )); list.back().setLoansOnly(true); list.push_back(MyMoneyReport( MyMoneyReport::Row::AccountReconcile, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Payee | MyMoneyReport::QueryColumns::Category | MyMoneyReport::QueryColumns::Balance, MyMoneyTransactionFilter::last3Months, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Transactions by Reconciliation Status"), i18n("Default Report") )); @@ -1370,7 +1370,7 @@ MyMoneyReport::Row::CashFlow, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Payee | MyMoneyReport::QueryColumns::Account, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Cash Flow Transactions This Month"), i18n("Default Report") )); @@ -1383,7 +1383,7 @@ MyMoneyReport::Row::TopAccount, MyMoneyReport::QueryColumns::Action | MyMoneyReport::QueryColumns::Shares | MyMoneyReport::QueryColumns::Price, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Transactions"), i18n("Default Report") )); @@ -1393,7 +1393,7 @@ MyMoneyReport::Row::AccountByTopAccount, MyMoneyReport::QueryColumns::Shares | MyMoneyReport::QueryColumns::Price, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Holdings by Account"), i18n("Default Report") )); @@ -1403,7 +1403,7 @@ MyMoneyReport::Row::EquityType, MyMoneyReport::QueryColumns::Shares | MyMoneyReport::QueryColumns::Price, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Holdings by Type"), i18n("Default Report") )); @@ -1413,7 +1413,7 @@ MyMoneyReport::Row::AccountByTopAccount, MyMoneyReport::QueryColumns::Performance, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Performance by Account"), i18n("Default Report") )); @@ -1423,16 +1423,16 @@ MyMoneyReport::Row::EquityType, MyMoneyReport::QueryColumns::Performance, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Performance by Type"), i18n("Default Report") )); list.back().setInvestmentsOnly(true); list.push_back(MyMoneyReport( MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::today, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Holdings Pie"), i18n("Default Report") )); @@ -1445,7 +1445,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::last12Months, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Worth Graph"), i18n("Default Report") )); @@ -1459,7 +1459,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::last12Months, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Price Graph"), i18n("Default Report") )); @@ -1478,7 +1478,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::last12Months, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Moving Average Price Graph"), i18n("Default Report") )); @@ -1497,7 +1497,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::last30Days, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Moving Average"), i18n("Default Report") )); @@ -1513,7 +1513,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::last30Days, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Investment Moving Average vs Actual"), i18n("Default Report") )); @@ -1534,34 +1534,34 @@ MyMoneyReport::Row::Category, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Payee | MyMoneyReport::QueryColumns::Account, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Tax Transactions by Category"), i18n("Default Report") )); list.back().setTax(true); list.push_back(MyMoneyReport( MyMoneyReport::Row::Payee, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Category | MyMoneyReport::QueryColumns::Account, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Tax Transactions by Payee"), i18n("Default Report") )); list.back().setTax(true); list.push_back(MyMoneyReport( MyMoneyReport::Row::Category, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Payee | MyMoneyReport::QueryColumns::Account, MyMoneyTransactionFilter::lastFiscalYear, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Tax Transactions by Category Last Fiscal Year"), i18n("Default Report") )); list.back().setTax(true); list.push_back(MyMoneyReport( MyMoneyReport::Row::Payee, MyMoneyReport::QueryColumns::Number | MyMoneyReport::QueryColumns::Category | MyMoneyReport::QueryColumns::Account, MyMoneyTransactionFilter::lastFiscalYear, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Tax Transactions by Payee Last Fiscal Year"), i18n("Default Report") )); @@ -1575,7 +1575,7 @@ MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToDate, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Budgeted vs. Actual This Year"), i18n("Default Report") )); @@ -1586,7 +1586,7 @@ MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::yearToMonth, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Budgeted vs. Actual This Year (YTM)"), i18n("Default Report") )); @@ -1601,7 +1601,7 @@ MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::currentMonth, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Monthly Budgeted vs. Actual"), i18n("Default Report") )); @@ -1611,7 +1611,7 @@ MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::currentYear, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Yearly Budgeted vs. Actual"), i18n("Default Report") )); @@ -1622,7 +1622,7 @@ MyMoneyReport::Row::Budget, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::currentMonth, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Monthly Budget"), i18n("Default Report") )); @@ -1632,7 +1632,7 @@ MyMoneyReport::Row::Budget, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::currentYear, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Yearly Budget"), i18n("Default Report") )); @@ -1642,7 +1642,7 @@ MyMoneyReport::Row::BudgetActual, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::currentYear, - MyMoneyReport::eDetailGroup, + MyMoneyReport::DetailLevel::Group, i18n("Yearly Budgeted vs Actual Graph"), i18n("Default Report") )); @@ -1660,7 +1660,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::next12Months, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("Forecast By Month"), i18n("Default Report") )); @@ -1670,7 +1670,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::nextQuarter, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("Forecast Next Quarter"), i18n("Default Report") )); @@ -1681,7 +1681,7 @@ MyMoneyReport::Row::ExpenseIncome, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::currentYear, - MyMoneyReport::eDetailTop, + MyMoneyReport::DetailLevel::Top, i18n("Income and Expenses Forecast This Year"), i18n("Default Report") )); @@ -1691,7 +1691,7 @@ MyMoneyReport::Row::AssetLiability, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::next3Months, - MyMoneyReport::eDetailTotal, + MyMoneyReport::DetailLevel::Total, i18n("Net Worth Forecast Graph"), i18n("Default Report") )); @@ -1709,34 +1709,34 @@ MyMoneyReport::Row::Schedule, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::next12Months, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Schedule Information"), i18n("Default Report") )); - list.back().setDetailLevel(MyMoneyReport::eDetailAll); + list.back().setDetailLevel(MyMoneyReport::DetailLevel::All); list.push_back(MyMoneyReport( MyMoneyReport::Row::Schedule, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::next12Months, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Schedule Summary Information"), i18n("Default Report") )); - list.back().setDetailLevel(MyMoneyReport::eDetailTop); + list.back().setDetailLevel(MyMoneyReport::DetailLevel::Top); list.push_back(MyMoneyReport( MyMoneyReport::Row::AccountInfo, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::today, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Account Information"), i18n("Default Report") )); list.back().setConvertCurrency(false); list.push_back(MyMoneyReport( MyMoneyReport::Row::AccountLoanInfo, MyMoneyReport::Column::Months, MyMoneyTransactionFilter::today, - MyMoneyReport::eDetailAll, + MyMoneyReport::DetailLevel::All, i18n("Loan Information"), i18n("Default Report") ));