Esempio n. 1
0
        /// <summary>
        /// CreatedBy : Kanishka SHM
        /// CreatedDate: 2016/01/24
        ///
        /// Check
        ///
        /// argument : email (string)
        ///
        ///
        /// UpdatedBy : nadeeka
        /// UpdatedDate: 2016/03/03
        /// removed existing connection open method and set parameter to object list and pass stored procedure name
        /// call DataHandler class method and getting boolean value,
        ///
        /// </summary>
        /// <returns>true/false</returns>
        public bool IsUniqueEmail(string email)
        {
            DataHandler     dataHandler  = new DataHandler();
            List <object[]> paramertList = new List <object[]>();

            paramertList.Add(new object[] { "@email", email });
            return(dataHandler.GetDataExistance("spIsUniqueEmail", paramertList));
        }
Esempio n. 2
0
        /// <summary>
        /// CreatedBy : Kanishka SHM
        /// CreatedDate: 2016/01/13
        ///
        /// Check
        ///
        /// argument : userName (string)
        ///
        ///
        /// UpdatedBy : nadeeka
        /// UpdatedDate: 2016/03/03
        /// removed existing connection open method and set parameter to object list and pass stored procedure name
        /// call DataHandler class method and getting boolean value,
        ///
        /// </summary>
        /// <returns>true/false</returns>
        public bool IsUniqueUserName(string userName)
        {
            DataHandler     dataHandler  = new DataHandler();
            List <object[]> paramertList = new List <object[]>();

            paramertList.Add(new object[] { "@user_name", userName });
            return(dataHandler.GetDataExistance("spIsUniqueUserName", paramertList));
        }
 /// <summary>
 /// CreatedBy : Kanishka SHM
 /// CreatedDate: 2016/01/24
 /// 
 /// Check 
 /// 
 /// argument : email (string)
 /// 
 /// 
 /// UpdatedBy : nadeeka
 /// UpdatedDate: 2016/03/03
 /// removed existing connection open method and set parameter to object list and pass stored procedure name
 /// call DataHandler class method and getting boolean value,
 /// 
 /// </summary>
 /// <returns>true/false</returns>
 public bool IsUniqueEmail(string email)
 {
     DataHandler dataHandler = new DataHandler();
     List<object[]> paramertList = new List<object[]>();
     paramertList.Add(new object[] { "@email", email });
     return dataHandler.GetDataExistance("spIsUniqueEmail", paramertList);
 }
 /// <summary>
 /// CreatedBy : Kanishka SHM
 /// CreatedDate: 2016/01/13
 /// 
 /// Check 
 /// 
 /// argument : userName (string)
 /// 
 /// 
 /// UpdatedBy : nadeeka
 /// UpdatedDate: 2016/03/03
 /// removed existing connection open method and set parameter to object list and pass stored procedure name
 /// call DataHandler class method and getting boolean value,
 /// 
 /// </summary>
 /// <returns>true/false</returns>
 public bool IsUniqueUserName(string userName)
 {
     DataHandler dataHandler = new DataHandler();
     List<object[]> paramertList = new List<object[]>();
     paramertList.Add(new object[] { "@user_name", userName });
     return dataHandler.GetDataExistance("spIsUniqueUserName", paramertList);
 }
        /// <summary>
        /// CreatedBy : Kanishka SHM
        /// CreatedDate: 2016/01/17
        /// 
        /// Check company name is already exists in thd database
        /// 
        /// argument : companyName (string)
        /// 
        /// 
        /// UpdatedBy : nadeeka
        /// UpdatedDate: 2016/03/06
        /// removed existing connection open method and set parameter to object list and pass stored procedure name
        /// call DataHandler class method and getting boolean value,
        /// 
        /// </summary>
        /// <returns>true/false</returns>
        public bool IsUniqueCompanyName(string companyName)
        {
            DataHandler dataHandler = new DataHandler();
            List<object[]> paramertList = new List<object[]>();
            paramertList.Add(new object[] { "@company_name", companyName });
            try
            {
                return dataHandler.GetDataExistance("spIsUniqueCompanyName", paramertList);
            }

            catch (Exception ex)
            {
                throw ex;
            }
        }