public static Invoice ReturnItem(Invoice invoice) { try { SqlConnection connect = RetaloDB.GetConnection(); string selectStatement = "Select *" + "FROM Invoice" + " Where InvID = @id"; SqlCommand selectCommand = new SqlCommand(selectStatement, connect); selectCommand.Parameters.AddWithValue("@id", invoice.ID); Invoice invoice2 = InvoiceOperations.ReturnInvoice(selectCommand, connect); return(invoice2); } catch (Exception ex) { throw ex; } }
public static Boolean AddItem(Invoice invoice) { return(InvoiceOperations.AddInvoice(invoice)); }