Пример #1
0
        public DataTable GetRequest(UserAccessSectionDTO uasDTO)
        {
            SqlCommand cmd = new SqlCommand();
            DataTable  dt  = new DataTable();

            cmd.Connection  = conn;
            cmd.CommandType = CommandType.StoredProcedure;
            cmd.CommandText = "[dbo].[SP_Get_UserLogTasvie]";
            cmd.Parameters.AddWithValue("@userId", uasDTO.userId);
            cmd.Parameters.AddWithValue("@fdaet", uasDTO.StartDate);
            cmd.Parameters.AddWithValue("@tdate", uasDTO.EndDate);

            try
            {
                conn.Open();
                SqlDataReader rdr;
                rdr = cmd.ExecuteReader();
                dt.Load(rdr);
                conn.Close();
            }
            catch (Exception)
            {
                throw;
            }

            return(dt);
        }
 public DataTable GetRequest(UserAccessSectionDTO uasDTO)
 {
     return(uasDAO.GetRequest(uasDTO));
 }