Esempio n. 1
0
 public Dictionary <string, object> BankBind(string userid)
 {
     try
     {
         var Result = Common.Getdata(dbcontext.MultipleResults("[dbo].[Sp_Mandate]").With <BankBind>().Execute("@QueryType", "@UserId", "UserBank", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(userid.Replace("_", "%")))));
         return(Result);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Esempio n. 2
0
 public Dictionary <string, object> BindUser(string UserId)
 {
     try
     {
         var Result = Common.Getdata(dbcontext.MultipleResults("[dbo].[SP_Report]").With <BindUser>().Execute("@QueryType", "@UserId", "BindDdluser", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(UserId.Replace("_", "%")))));
         return(Result);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Esempio n. 3
0
 public Dictionary <string, object> getEntity()
 {
     try
     {
         var Result = Common.Getdata(dbcontext.MultipleResults("[dbo].[Sp_Entity]").With <Entity>().Execute("@QueryType", "GetEntity"));
         return(Result);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Esempio n. 4
0
        //public IEnumerable<GridData> GridBind(string Entityid, string Pageno)
        //{
        //    try
        //    {

        //        var Result = dbcontext.MultipleResults("[dbo].[Sp_Uploaddata]").With<GridData>().Execute("@QueryType", "@PageCount", "@EntityID", "UMRNUpload", Pageno, DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(Entityid.Replace("_", "%"))));
        //        foreach (var employe in Result)
        //        {

        //            dataList = employe.Cast<GridData>().ToList();
        //        }
        //        return dataList;

        //    }
        //    catch (Exception ex)
        //    {
        //        throw ex;
        //    }
        //}
        public Dictionary <string, object> GridBind1(string Entityid, string Pageno)
        {
            try
            {
                var Result = Common.Getdata(dbcontext.MultipleResults("[dbo].[Sp_Uploaddata]").With <GridData>().With <Paging>().Execute("@QueryType", "@PageCount", "@EntityID", "UMRNUpload", Pageno, DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(Entityid.Replace("_", "%")))));
                return(Result);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
 public Dictionary <string, object> GetPageLoaddata(string UserId, string EntityId)
 {
     try
     {
         var Result = Common.Getdata(dbcontext.MultipleResults("[dbo].[Sp_Mandate]").With <BindEntityDetails> ().With <BindLogoImageDetails>().With <BindBankNameDetails>().With <BindSponserCode>().With <BindBankUtilityCode>().With <BindBankPaymentMode>().With <BindEntityDetailsdata>().With <BindDebitType>().With <Bindfrequency>().With <BindEntityPeriods>().With <BindEntitydebitcredit>().With <BindEntityCategorytype>().With <BindLogincheck>().Execute("@QueryType", "@UserId", "@EntityId", "UserData", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(UserId.Replace("_", "%"))), DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(EntityId.Replace("_", "%")))));
         return(Result);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Esempio n. 6
0
        public Dictionary <string, object> BindGrid()
        {
            try
            {
                var Result = Common.Getdata(dbcontext.MultipleResults("[dbo].[Sp_LinkSetup_AccessRights]").With <BindGrid>().Execute("@QueryType", "BindGridLinkItems"));
                return(Result);
            }

            catch (Exception ex)
            {
                throw ex;
            }
        }
Esempio n. 7
0
        public Dictionary <string, object> BindGrid(string EntityId)
        {
            try
            {
                var Result = Common.Getdata(dbcontext.MultipleResults("[dbo].[Sp_Uploaddata]").With <MainGrid>().Execute("@QueryType", "@EntityId", "BindRecord", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(EntityId.Replace("_", "%")))));
                return(Result);
            }

            catch (Exception ex)
            {
                throw ex;
            }
        }
 //  downloadOldMandateTableAttibute
 public IEnumerable <downloadOldMandateTableAttibute> GetUserBankData(string UserId)
 {
     try
     {
         var Data = dbcontext.MultipleResults("[dbo].[Sp_Mandate]").With <downloadOldMandateTableAttibute>().Execute("@QueryType", "@UserId", "UserBank", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(UserId.Replace("_", "%"))));
         foreach (var dt in Data)
         {
             downlodmanlist = dt.Cast <downloadOldMandateTableAttibute>().ToList();
         }
         return(downlodmanlist);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
        public IEnumerable <DownloadMandateDetails> Binddropdownbank(string userId)
        {
            // List<DownloadMandateDetails> dataList = new List<DownloadMandateDetails>();
            try
            {
                var Result = dbcontext.MultipleResults("[dbo].[Sp_Mandate]").With <DownloadMandateDetails>().Execute("@QueryType", "@UserId", "UserBank", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(userId.Replace("_", "%"))));

                foreach (var employe in Result)
                {
                    dataList = employe.Cast <DownloadMandateDetails>().ToList();
                }
                return(dataList);

                // return Result;
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
        public Dictionary <string, object> BindCountryAndBank()
        {
            try
            {
                var Result = Common.Getdata(dbcontext.MultipleResults("[dbo].[Sp_Entity]").With <BindCountry>().With <BindBank>().With <EntityBusinessCode>().Execute("@QueryType", "BindCountry"));
                return(Result);
            }

            catch (Exception ex)
            {
                throw ex;
            }
        }
Esempio n. 11
0
        public IEnumerable <AccessRightsEntityDetails> BindEntityDetails(string UserType, string ReferenceId)
        {
            // List<DownloadMandateDetails> dataList = new List<DownloadMandateDetails>();
            try
            {
                var Result = dbcontext.MultipleResults("[dbo].[Sp_LinkSetup_AccessRights]").With <AccessRightsEntityDetails>().Execute("@QueryType", "@userType", "@EntityID", "GetUsersType", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(UserType.Replace("_", "%"))), DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(ReferenceId.Replace("_", "%"))));

                foreach (var employe in Result)
                {
                    dataList = employe.Cast <AccessRightsEntityDetails>().ToList();
                }
                return(dataList);

                // return Result;
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
Esempio n. 12
0
        //public Dictionary<string, object> BankBind(string UserId,string EntityId)
        public IEnumerable <Nachtransactionpresentation> BankBind(string UserId, string EntityId)
        {
            try

            {
                var Result = dbcontext.MultipleResults("[dbo].[Sp_Presenment]").With <Nachtransactionpresentation>().Execute("@QueryType", "@UserId", "@EntityId", "Dropdown", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(UserId.Replace("_", "%"))), DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(EntityId.Replace("_", "%"))));
                foreach (var Nachtransactionpresentation in Result)
                {
                    dataList = Nachtransactionpresentation.Cast <Nachtransactionpresentation>().ToList();
                }
                return(dataList);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
Esempio n. 13
0
 public Dictionary <string, object> GetAllUsers(string EntityId, string PageCount, string Search_Text)
 {
     try
     {
         var Result = Common.Getdata(dbcontext.MultipleResults("[dbo].[Sp_user]").With <UserData>().With <UtilityCodes>().With <SponsorBankCode>().With <EntityPaymentMode>().With <UserEntity>().With <EntityMandateMode>().With <TempData>().With <CategoryCodes>().Execute("@QueryType", "@EntityId", "@PageCount", "@Search_Text", "BindUser", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(EntityId.Replace("_", "%"))), PageCount, Search_Text));
         return(Result);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Esempio n. 14
0
 public IEnumerable <HistoricalMandateClass> GetDataFromDB(string FromDate, string ToDate, string UserId)
 {
     try
     {
         var Result = dbcontext.MultipleResults("[dbo].[Sp_Mandate]").With <HistoricalMandateClass>().Execute("@QueryType", "@ToDate", "@FromDate", "@UserId", "grdMandateDataDateWise", ToDate, FromDate, DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(UserId.Replace("_", "%"))));
         foreach (var HistoricalMandateData in Result)
         {
             dataList = HistoricalMandateData.Cast <HistoricalMandateClass>().ToList();
         }
         return(dataList);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
Esempio n. 15
0
 public IEnumerable <UMRNHistoryClass> GetDataFromDB(UMRNHistoryClass UMRNHistoryClass)
 {
     try
     {
         var Result = dbcontext.MultipleResults("[dbo].[Sp_Presenment]").With <UMRNHistoryClass>().Execute("@QueryType", "@UMRN", "@customer1", "@Refrence1", "@UserID", "UMRNHistoryDetails", UMRNHistoryClass.UMRN, UMRNHistoryClass.customer1, UMRNHistoryClass.RefrNo, DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(UMRNHistoryClass.UserId.Replace("_", "%"))));
         foreach (var Data in Result)
         {
             dataList = Data.Cast <UMRNHistoryClass>().ToList();
         }
         return(dataList);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
 public Dictionary <string, object> GetData(string UserId, string EntityId, string topVal, string ActivityType)
 {
     try
     {
         var Data = Common.Getdata(dbcontext.MultipleResults("[dbo].[Sp_Mandate]").With <BulkEmandateAttribute>().With <BulkEmandateTabledatacount>().Execute("@QueryType", "@UserId", "@EntityId", "@topVal", "@ActivityType", "DataActivity", DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(UserId.Replace("_", "%"))), DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(EntityId.Replace("_", "%"))), topVal, ActivityType));
         //foreach (var dt in Data)
         //{
         //    dataList= dt.Cast<BulkEmandateAttribute>().ToList();
         //}
         return(Data);
     }
     catch (Exception ex)
     {
         throw ex;
     }
 }
        //   List<OldMandateAttribute> dataList = new List<OldMandateAttribute>();
        //  List<downloadOldMandateTableAttibute> downlodmanlist = new List<downloadOldMandateTableAttibute>();
        public Dictionary <string, object> GetData(string ActivityID, string UserId, string EntityId, string TEUHID, string LoadData)
        {
            try
            {
                var Data = Common.Getdata(dbcontext.MultipleResults("Sp_Bulkmandate").With <MainGridAttribute>().With <MainGridTableCountAttribute>().With <InvalidDataAttribute>().With <InvalidGridTableCountAttribute>().With <ValidatedDataAttribute>().With <ValidatedDataTableCountAttribute>().With <ActivityIDAttribute>().With <AccountRelatedIssueAttribute>().With <AccountRelatedIssueTableCount>().With <MisMatchAttribute>().With <MisMatchTableCount>().With <ValidDataAttribute>().With <ValidDataTableCountAttibute>().Execute("@QueryType", "@ActivityId", "@UserId", "@EntityId", "@TEUHID", "@topVal", "ActivityWiseViewData", ActivityID, DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(UserId.Replace("_", "%"))), DbSecurity.Decrypt(HttpContext.Current.Server.UrlDecode(EntityId.Replace("_", "%"))), TEUHID, LoadData));
                //foreach (var dt in Data)
                //{
                //    dataList= dt.Cast<BulkEmandateAttribute>().ToList();

                //}
                return(Data);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
Esempio n. 18
0
        public TestmodelMandateList GridBind1(string Entityid, string Pageno)
        {
            TestmodelMandateList    obj       = new TestmodelMandateList();
            List <Testmodel>        dataList  = new List <Testmodel>();
            List <TestmodelMandate> dataList1 = new List <TestmodelMandate>();

            try
            {
                var Result = dbcontext.MultipleResults("[dbo].[Sp_WebAPI]").With <Testmodel>().With <TestmodelMandate>().Execute("@QueryType", "GetLiveBank");
                dataList  = Result.FirstOrDefault().Cast <Testmodel>().ToList();
                dataList1 = Result.LastOrDefault().Cast <TestmodelMandate>().ToList();
                //foreach (var Logindata in Result)
                //{
                //    dataList = Logindata.Cast<Testmodel>().ToList();
                //}
                obj.BankList   = dataList;
                obj.StatusList = dataList1;
                return(obj);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
Esempio n. 19
0
        public IEnumerable <CommonFlag> Binddetails(string Username, string Password)
        {
            List <Logindetails> dataList = new List <Logindetails>();

            try
            {
                var Result = dbcontext.MultipleResults("[dbo].[sp_UserLogin]").With <Logindetails>().Execute("@QueryType", "@UserName", "GetUser", Username);
                foreach (var Logindata in Result)
                {
                    dataList = Logindata.Cast <Logindetails>().ToList();
                    if (dataList.Count > 0)
                    {
                        string strDbPassword = DbSecurity.Decrypt(Convert.ToString(Logindata.Cast <Logindetails>().ToList().Select(x => x.Password).First().ToString()), Convert.ToString(Logindata.Cast <Logindetails>().ToList().Select(x => x.PasswordKey).First().ToString()));
                        if (strDbPassword.Trim() != Password)
                        {
                            Flag.Flag      = "0";
                            Flag.FlagValue = "Wrong Username or Password!!";
                            common.Add(Flag);
                        }
                        else
                        {
                            Random generator = new Random();
                            QuickCheckEmandate_AngularEntities dbcontext = new QuickCheckEmandate_AngularEntities();
                            var SaveLoginSessionTrxn = dbcontext.MultipleResults("[dbo].[sp_UserLogin]").With <SaveLoginSessionTrxn>().Execute("@QueryType", "@UserId", "@TokenID", "@IPAddress", "@MacAddress", "@IsLogin", "SaveLoginSessionTrxn", Convert.ToString(Logindata.Cast <Logindetails>().ToList().Select(x => x.UserId).First().ToString()), Convert.ToString(generator.Next(1, 1000000)), Convert.ToString(GetIpAddress()), Convert.ToString(GetMacAddress()), Convert.ToString(1));
                            foreach (var Existlogin in SaveLoginSessionTrxn)
                            {
                                //  if (Existlogin.Cast<SaveLoginSessionTrxn>().ToList().Select(x => x.SessionActive).First().ToString() == "0")
                                //  {
                                #region Session creation
                                // Iace.User.User.SaveUserToSession(dataList);
                                Flag.IsRefrenceCheck    = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsRefrenceCheck).First().ToString()))).Replace("%", "_");
                                Flag.IsOverPrintMandate = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsOverPrintMandate).First().ToString()))).Replace("%", "_");
                                Flag.IsBulkMandate      = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsBulkMandate).First().ToString()))).Replace("%", "_");
                                Flag.IsMandate          = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsMandate).First().ToString()))).Replace("%", "_");
                                //NewCode
                                Flag.IsMandateEdit       = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsMandateEdit).First().ToString()))).Replace("%", "_");
                                Flag.IsRefrenceEdit      = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsRefrenceEdit).First().ToString()))).Replace("%", "_");
                                Flag.IsEmandate          = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsEmandate).First().ToString()))).Replace("%", "_");
                                Flag.IsPhysical          = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsPhysical).First().ToString()))).Replace("%", "_");
                                Flag.IsZipShoreABPS      = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsZipShoreABPS).First().ToString()))).Replace("%", "_");
                                Flag.UserId              = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.UserId).First().ToString()))).Replace("%", "_");
                                Flag.ReferenceId         = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(dataList.Cast <Logindetails>().ToList().Select(x => x.ReferenceId).First().ToString())).Replace("%", "_");
                                Flag.UserName            = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.UserName).First().ToString()))).Replace("%", "_");
                                Flag.Password            = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.Password).First().ToString()))).Replace("%", "_");
                                Flag.PasswordKey         = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.PasswordKey).First().ToString()))).Replace("%", "_");
                                Flag.UserCode            = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.UserCode).First().ToString()))).Replace("%", "_");
                                Flag.UserType            = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.UserType).First().ToString()))).Replace("%", "_");
                                Flag.BranchId            = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(dataList.Cast <Logindetails>().ToList().Select(x => x.BranchId).First().ToString())).Replace("%", "_");
                                Flag.BranchName          = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.BranchName).First().ToString()))).Replace("%", "_");
                                Flag.IsDefaultPswdChange = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsDefaultPswdChange).First().ToString()))).Replace("%", "_");
                                Flag.LastLogin           = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.LastLogin).First().ToString()))).Replace("%", "_");
                                Flag.IsActive            = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsActive).First().ToString()))).Replace("%", "_");
                                Flag.IsDeleted           = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(Convert.ToString(dataList.Cast <Logindetails>().ToList().Select(x => x.IsDeleted).First().ToString()))).Replace("%", "_");
                                Flag.CreatedBy           = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(dataList.Cast <Logindetails>().ToList().Select(x => x.CreatedBy).First().ToString())).Replace("%", "_");
                                Flag.CreatedOn           = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(dataList.Cast <Logindetails>().ToList().Select(x => x.CreatedOn).First().ToString())).Replace("%", "_");
                                #endregion

                                Flag.Flag = "1";
                                common.Add(Flag);
                                //}
                                //else {
                                //    Flag.Flag = "0";
                                //    Flag.FlagValue = "User already logged on. Either Try logging in after closing the current session or Try after some time!!";
                                //    common.Add(Flag);
                                //}
                            }
                        }
                    }
                    else
                    {
                        Flag.Flag      = "0";
                        Flag.FlagValue = "Invalid User!!";
                        common.Add(Flag);
                    }
                }
                return(common);
            }
            catch (Exception ex)
            {
                throw ex;
            }
        }
Esempio n. 20
0
        public IEnumerable <CommonFlag> SendMail(string Username)
        {
            try
            {
                List <Value> dataList = new List <Value>(); List <UserDetails> dataList1 = new List <UserDetails>();
                var          Result = dbcontext.MultipleResults("[dbo].[Sp_UserLogin]").With <Value>().With <UserDetails>().Execute("@QueryType", "@EmailId", "ChkEmail", Username);

                dataList  = Result.FirstOrDefault().Cast <Value>().ToList();
                dataList1 = Result.LastOrDefault().Cast <UserDetails>().ToList();
                if (dataList.Cast <Value>().ToList().Select(x => x.value).First().ToString() == "1")
                {
                    if (dataList1.Count > 0)
                    {
                        using (StringWriter sw = new StringWriter())
                        {
                            using (HtmlTextWriter hw = new HtmlTextWriter(sw))
                            {
                                StringBuilder sb            = new StringBuilder();
                                string        WebAppUrl     = ConfigurationManager.AppSettings["WebAppUrl"].ToString();
                                string        SMTPHost      = ConfigurationManager.AppSettings["Amazon_SMTPHost"].ToString();
                                string        UserId        = ConfigurationManager.AppSettings["Amazon_UserId"].ToString();
                                string        MailPassword  = ConfigurationManager.AppSettings["Amazon_MailPassword"].ToString();
                                string        SMTPPort      = ConfigurationManager.AppSettings["Amazon_SMTPPort"].ToString();
                                string        SMTPEnableSsl = ConfigurationManager.AppSettings["Amazon_SMTPEnableSsl"].ToString();
                                string        FromMailId    = ConfigurationManager.AppSettings["Amazon_FromMailId"].ToString();
                                string        Teamtext      = ConfigurationManager.AppSettings["Team"].ToString();
                                sb.Append("Dear " + dataList1.Cast <UserDetails>().ToList().Select(x => x.UserName).First().ToString() + ",<br> <br>");
                                sb.Append("Please click on the below button to set a new Password . <br> <br>");
                                string User = HttpContext.Current.Server.UrlEncode(DbSecurity.Encrypt(dataList1.Cast <UserDetails>().ToList().Select(x => x.UserId).First().ToString())).Replace("%", "_");
                                sb.Append("<a href=' " + WebAppUrl + "ChangePassword/" + User + "' target='_blank'>");
                                sb.Append("<input style='background-color: #3965a9;color: #fff;padding: 3px 10px 3px 10px;' type='button' value='Change Password' /></a> </div>");

                                SmtpClient  smtpClient  = new SmtpClient();
                                MailMessage mailmsg     = new MailMessage();
                                MailAddress mailaddress = new MailAddress(FromMailId);
                                mailmsg.To.Add(Username);
                                mailmsg.From = mailaddress;

                                mailmsg.Subject    = "Recover Password";
                                mailmsg.IsBodyHtml = true;
                                mailmsg.Body       = sb.ToString();

                                smtpClient.Host                  = SMTPHost;
                                smtpClient.Port                  = Convert.ToInt32(SMTPPort);
                                smtpClient.EnableSsl             = Convert.ToBoolean(SMTPEnableSsl);
                                smtpClient.UseDefaultCredentials = true;
                                smtpClient.Credentials           = new System.Net.NetworkCredential(UserId, MailPassword);
                                smtpClient.Send(mailmsg);
                                QuickCheckEmandate_AngularEntities dbcontext = new QuickCheckEmandate_AngularEntities();
                                dbcontext.MultipleResults("[dbo].[Sp_SendEmail]").With <Value>().Execute("@QueryType", "@MandateId", "@EmailCount", "@SmsCount", "SendMail", Convert.ToString(0), "1", "0");
                                Flag.Flag = "1";
                                common.Add(Flag);
                            }
                        }
                    }
                }
            }
            catch (Exception)
            {
                Flag.Flag = "1";
                common.Add(Flag);
            }

            return(common);
        }