예제 #1
0
        protected void Finsh(object sender, EventArgs e)
        {
            var objSecurePage = new SecurePage();
            var objConsulling = new Consulling();

            _objCommon = new Common();
            var objMailTemplates = new MailTemplates();
            var ddNumber         = string.Empty;
            var formNum          = "ADMJ" + DateTime.Now.Year + _objCommon.CourseId.ToString() + objSecurePage.LoggedInUserId.ToString();
            var tranctionDetails = string.Empty;

            if (rbtnPaymentType.SelectedValue == "OnPayment")
            {
                OnlinePayment();
            }

            int i    = objConsulling.InsertUpdateUserTransctionalDetails(objSecurePage.LoggedInUserId, formNum, false, rbtnPaymentType.SelectedItem.ToString(), "", "", "26100");
            var mail = new MailMessage
            {
                From    = new MailAddress(ApplicationSettings.Instance.Email),
                Subject = "Direct Admission:Form Number" + formNum
            };

            var body = objMailTemplates.SendValidationMailForTheBookSeat("http://www.admissionjankari.com/", objSecurePage.LoggedInUserName, formNum, rbtnPaymentType.SelectedItem.ToString(), _objCommon.CourseName);

            mail.Body = body;
            mail.To.Add(objSecurePage.LoggedInUserEmailId);
            mail.Bcc.Add(ClsSingelton.bccDirectAdmission);
            Utils.SendMailMessageAsync(mail);
            if (rbtnPaymentType.SelectedValue != "OnPayment")
            {
                Response.Redirect(Utils.AbsoluteWebRoot + "ConformationPage.aspx/");
            }
        }