DataTable IInvoiceContext.GetInvoiceByID(int InvoiceID)
        {
            string query = "SELECT* FROM Invoice WHERE ID = @InvID";
            List <KeyValuePair <string, object> > parameters = new List <KeyValuePair <string, object> >
            {
                new KeyValuePair <string, object>("@InvID", InvoiceID)
            };

            return(SQL_CRUD_Methods.SQLReadParameterized(query, parameters));
        }
예제 #2
0
        DataTable IEmployeeContext.GetEmployeeByID(int EmployeeID)
        {
            string query = "SELECT * FROM Employee WHERE ID = @EmpID";
            List <KeyValuePair <string, object> > parameters = new List <KeyValuePair <string, object> >
            {
                new KeyValuePair <string, object>("@EmpID", EmployeeID)
            };

            return(SQL_CRUD_Methods.SQLReadParameterized(query, parameters));
        }
        DataTable ICustomerContext.GetCustomerByID(int CustomerID)
        {
            string query = "SELECT * FROM [Customer] WHERE ID = @CustID";
            List <KeyValuePair <string, object> > parameters = new List <KeyValuePair <string, object> >
            {
                new KeyValuePair <string, object>("@CustID", CustomerID)
            };

            return(SQL_CRUD_Methods.SQLReadParameterized(query, parameters));
        }
예제 #4
0
        DataTable IRentableContext.GetRentableByID(int RentableID)
        {
            string query = "SELECT * FROM Rentable WHERE ID = @RentID";
            List <KeyValuePair <string, object> > parameters = new List <KeyValuePair <string, object> >
            {
                new KeyValuePair <string, object>("@RentID", RentableID)
            };

            return(SQL_CRUD_Methods.SQLReadParameterized(query, parameters));
        }