Esempio n. 1
0
        public static EntityList <Invoice> GetInvoicesForDownloadByCustomer(int customerID)
        {
            List <SqlParameter> parameters = new List <SqlParameter>();

            parameters.Add(new SqlParameter("@customer_id", customerID));
            string where = "where customer_id = @customer_id and is_downloaded = 0";

            EntityList <Invoice> invoices = Invoice.GetInvoices(where, parameters);

            return(invoices);
        }
Esempio n. 2
0
        public static EntityList <Invoice> GetInvoicesBySupplier(int supplierID)
        {
            List <SqlParameter> parameters = new List <SqlParameter>();

            parameters.Add(new SqlParameter("@supplier_id", supplierID));

            string where = "where customer_id = @customer_id";

            EntityList <Invoice> invoices = Invoice.GetInvoices(where, parameters);

            return(invoices);
        }