Exemplo n.º 1
0
 public List <BusinessLogic.Associate.Associate> GetAssociatesPerGroup(string groupid)
 {
     try
     {
         MLIADMobileService.SetNoCache();
         return(repository.GetAssociatesPerGroup(Convert.ToInt32(groupid)));
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemplo n.º 2
0
 public string ChangePassword(Cog.MLIAD.BusinessLogic.Associate.ChangePassword obj)
 {
     try
     {
         MLIADMobileService.SetNoCache();
         return(repository.ChangePassword(obj));
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemplo n.º 3
0
 public BusinessLogic.Associate.Associate GetAssociate(string userid)
 {
     try
     {
         MLIADMobileService.SetNoCache();
         return(repository.GetAssociate(userid));
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemplo n.º 4
0
 public List <Group> GetGroups()
 {
     try
     {
         MLIADMobileService.SetNoCache();
         return(repository.GetGroup());
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemplo n.º 5
0
 public List <Group> GetGroupsByUser(string uid)
 {
     try
     {
         MLIADMobileService.SetNoCache();
         return(repository.GetGroupsByUser(Convert.ToInt32(uid)));
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemplo n.º 6
0
 public List <Category> GetCategories()
 {
     try
     {
         MLIADMobileService.SetNoCache();
         return(repository.GetCategories());
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemplo n.º 7
0
        public int ReplyToPostTopic(Cog.MLIAD.BusinessLogic.Associate.Discussion replytopic)
        {
            int retVal = 0;

            try
            {
                MLIADMobileService.SetNoCache();
                retVal = repository.ReplyToPostTopic(replytopic);
            }
            catch (Exception e)
            {
                throw e;
            }
            return(retVal);
        }
Exemplo n.º 8
0
        public List <DiscussionDetails> GetTopicDetails(string topicid)
        {
            try
            {
                MLIADMobileService.SetNoCache();
                int intTopicID = -1;
                if (!string.IsNullOrEmpty(topicid))
                {
                    int.TryParse(topicid, out intTopicID);
                }

                return(repository.GetTopicDetails(intTopicID));
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
Exemplo n.º 9
0
 public string AddAssociate(Cog.MLIAD.BusinessLogic.Associate.Associate associate)
 {
     try
     {
         MLIADMobileService.SetNoCache();
         var result = repository.AddMobileAssociate(associate);
         //if(result == "success")
         //{
         //    string smstext = "Thanks " + associate.FirstName + " " + associate.LastName + ". Your registration is successful. Your username is: '" + associate .AssociateID+ "'. You password is: 'password'. Please login to https://massociatecon.cognizant.com/mobile/login.htm";
         //    try
         //    {
         //        SendSMS(smstext, "91" + associate.Mobile);
         //    }
         //    catch (Exception ex)
         //    {
         //    }
         //    finally
         //    {
         //        //try
         //        //{
         //        //    repository.SendEmail("Registration Successful!", smstext, associate.email, associate.email, true);
         //        //}
         //        //catch (Exception ex) { }
         //        //finally
         //        //{
         //        //    //return result;
         //        //}
         //    }
         //    return result;
         //}
         return(result);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Exemplo n.º 10
0
        public List <Discussion> GetTopics(string catid, string groupid)
        {
            try
            {
                MLIADMobileService.SetNoCache();
                int intCatID   = -1;
                int intGroupID = -1;

                if (!string.IsNullOrEmpty(catid))
                {
                    int.TryParse(catid, out intCatID);
                }
                if (!string.IsNullOrEmpty(groupid))
                {
                    int.TryParse(groupid, out intGroupID);
                }

                return(repository.GetTopics(intCatID, intGroupID));
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }