public double GetInvoicesAmountMonth(int year, int month, Invoice.InvoiceType type) { if (type == Invoice.InvoiceType.Total) { return Invoices.GetAmount(year, month); } return Invoices.GetAmount(type, year, month); }