Hide() public method

public Hide ( ) : void
return void
示例#1
0
    protected void btnReservar_Click(object sender, EventArgs e)
    {
        AjaxControlToolkit.ModalPopupExtender mpterminos = (AjaxControlToolkit.ModalPopupExtender)Parent.FindControl("MPEEBanner");

        //MPEEReserva.Show();
        if (rblFormasPago.Items.Count > 0)
        {
            if (ValidacamposTarjeta())
            {
                if (!cbAcepto.Checked)
                {
                    rbltapspagos();
                    lblError.Text = "Por favor acepta los terminos y condicones";
                    return;
                }
                else
                {
                    csResultadoPlanes.btnReservarCotizador_Click(sender, e, this);
                    if (this.Session["$CodigoReservaPlan"] != null)
                    {
                        //MPEEReserva.Hide();
                        lblRecord.Text = this.Session["$CodigoReservaPlan"].ToString();
                        if (mpterminos != null)
                        {
                            mpterminos.Hide();
                        }

                        MPEEConfirm.Show();
                    }
                }
            }
        }
        //MPEEReserva.Hide();sValidaciones.GetKeyOrAdd("sMensajeNoCreacionUsuario", "No se pudo generar tu reserva, por favor completa la información obligatoria o contacta un asesor");
    }
示例#2
0
    protected void btnReservar_Click(object sender, EventArgs e)
    {
        AjaxControlToolkit.ModalPopupExtender mpterminos = (AjaxControlToolkit.ModalPopupExtender)Parent.FindControl("MPEEBanner");


        if (rblFormasPago.Items.Count > 0)
        {
            if (!cbAcepto.Checked)
            {
                lblError.Text = "Por favor acepta los terminos y condicones";
                return;
            }
            else
            {
                clsParametros Registro = csResultadoPlanes.setCrearNoRegistro(this, ucRegistro, Enum_Login.LoginGen, false);
                if (Registro.Id != 0)
                {
                    csResultadoPlanes.btnReservarCotizador_Click(sender, e, this);
                    if (this.Session["$CodigoReservaPlan"] != null)
                    {
                        lblRecord.Text = this.Session["$CodigoReservaPlan"].ToString();
                        if (mpterminos != null)
                        {
                            mpterminos.Hide();
                        }

                        MPEEConfirm.Show();
                    }
                }
            }
        }
    }
示例#3
0
 protected void Select_Click(object sender, EventArgs e)
 {
     try
     {
         if (ddlInstallers.SelectedIndex > -1)
         {
             Session[enumSessions.SelectedInstaller.ToString()]  = ddlInstallers.SelectedItem.Text;
             Session[enumSessions.InstallerCompanyID.ToString()] = ddlInstallers.SelectedValue.ToString();
             LinqToSqlDataContext dataCtxt = new LinqToSqlDataContext();
             if (Session[enumSessions.BulkUploadMultipleOrderId.ToString()] != null)
             {
                 int addressId = 0;
                 dataCtxt.USP_SaveInstallerDetailsInOrder(Session[enumSessions.InstallerCompanyID.ToString()].ToString(), Convert.ToInt32(Session[enumSessions.BulkUploadMultipleOrderId.ToString()]));
                 var insContactName = (from insAdd in dataCtxt.InstallerAddresses
                                       join ins in dataCtxt.Installers on insAdd.AddressID equals ins.AddressID
                                       where ins.InstallerCompanyID == new Guid(Session[enumSessions.InstallerCompanyID.ToString()].ToString())
                                       select insAdd.ContactName).Single();
                 if (insContactName != null)
                 {
                     addressId = InstallerBAL.SaveInstallerAddress(Session[enumSessions.InstallerCompanyID.ToString()].ToString(), insContactName, "", 0, "", "", "", "", "", "", Session[enumSessions.User_Name.ToString()].ToString());
                 }
                 var orderDetail = dataCtxt.Orders.Single(x => x.OrderId == Convert.ToInt32(Session[enumSessions.BulkUploadMultipleOrderId.ToString()]));
                 if (orderDetail.DeliveryAddressId == 0)
                 {
                     orderDetail.DeliveryAddressId = addressId;
                 }
                 orderDetail.ModifiedBy = Session[enumSessions.User_Name.ToString()].ToString();
                 orderDetail.ModifiedOn = DateTime.Now;
                 dataCtxt.SubmitChanges();
                 getBulkuploadOrderItems(e);
                 // Session[enumSessions.BulkUploadMultipleOrderId.ToString()] = null;
                 AjaxControlToolkit.ModalPopupExtender mpInstaller = Parent.FindControl("mpInstaller") as AjaxControlToolkit.ModalPopupExtender;
                 mpInstaller.Hide();
             }
             else
             {
                 dataCtxt.USP_SaveInstallerDetailsInOrder(Session[enumSessions.InstallerCompanyID.ToString()].ToString(), Convert.ToInt32(Session[enumSessions.OrderId.ToString()]));
                 dataCtxt.Dispose();
                 Response.Redirect("Checkout.aspx");
             }
         }
         else
         {
             string script = "alertify.alert('" + ltrSelect.Text + "');";
             ScriptManager.RegisterStartupScript(this.Page, this.GetType(), "alert", script, true);
         }
     }
     catch (System.Threading.ThreadAbortException ex)
     {
         //
     }
     catch (Exception objException)
     {
         CSLOrderingARCBAL.LinqToSqlDataContext db;
         db = new CSLOrderingARCBAL.LinqToSqlDataContext();
         db.USP_SaveErrorDetails(Request.Url.ToString(), ((System.Reflection.MemberInfo)(objException.TargetSite)).Name, Convert.ToString(objException.Message), Convert.ToString(objException.InnerException), Convert.ToString(objException.StackTrace), "", HttpContext.Current.Request.UserHostAddress, false, Convert.ToString(HttpContext.Current.Session[enumSessions.User_Id.ToString()]));
     }
 }
 protected void rptInstallerCompanies_ItemCommand(object source, RepeaterCommandEventArgs e)
 {
     try
     {
         Session[enumSessions.SelectedInstaller.ToString()]  = e.CommandName;
         Session[enumSessions.InstallerCompanyID.ToString()] = e.CommandArgument;
         Session["selectInstaller"] = "selected";
         LinqToSqlDataContext dataCtxt = new LinqToSqlDataContext();
         if (Session[enumSessions.BulkUploadMultipleOrderId.ToString()] != null)
         {
             int addressId = 0;
             dataCtxt.USP_SaveInstallerDetailsInOrder(Session[enumSessions.InstallerCompanyID.ToString()].ToString(), Convert.ToInt32(Session[enumSessions.BulkUploadMultipleOrderId.ToString()]));
             var insContactName = (from insAdd in dataCtxt.InstallerAddresses
                                   join ins in dataCtxt.Installers on insAdd.AddressID equals ins.AddressID
                                   where ins.InstallerCompanyID == new Guid(Session[enumSessions.InstallerCompanyID.ToString()].ToString())
                                   select insAdd.ContactName).Single();
             if (insContactName != null)
             {
                 addressId = InstallerBAL.SaveInstallerAddress(Session[enumSessions.InstallerCompanyID.ToString()].ToString(), insContactName, "", 0, "", "", "", "", "", "", Session[enumSessions.User_Name.ToString()].ToString());
             }
             var orderDetail = dataCtxt.Orders.Single(x => x.OrderId == Convert.ToInt32(Session[enumSessions.BulkUploadMultipleOrderId.ToString()]));
             if (orderDetail.DeliveryAddressId == 0)
             {
                 orderDetail.DeliveryAddressId = addressId;
             }
             orderDetail.ModifiedBy = Session[enumSessions.User_Name.ToString()].ToString();
             orderDetail.ModifiedOn = DateTime.Now;
             dataCtxt.SubmitChanges();
             getBulkuploadOrderItems(e);
             // Session[enumSessions.BulkUploadMultipleOrderId.ToString()] = null;
             AjaxControlToolkit.ModalPopupExtender mpInstaller = Parent.FindControl("mpInstaller") as AjaxControlToolkit.ModalPopupExtender;
             mpInstaller.Hide();
         }
         else
         {
             dataCtxt.USP_SaveInstallerDetailsInOrder(Session[enumSessions.InstallerCompanyID.ToString()].ToString(), Convert.ToInt32(Session[enumSessions.OrderId.ToString()]));
             dataCtxt.Dispose();
             Response.Redirect("Checkout.aspx");
         }
     }
     catch (System.Threading.ThreadAbortException ex)
     {
         //
     }
     catch (Exception objException)
     {
         CSLOrderingARCBAL.LinqToSqlDataContext db;
         db = new CSLOrderingARCBAL.LinqToSqlDataContext();
         db.USP_SaveErrorDetails(Request.Url.ToString(), ((System.Reflection.MemberInfo)(objException.TargetSite)).Name, Convert.ToString(objException.Message), Convert.ToString(objException.InnerException), Convert.ToString(objException.StackTrace), "", HttpContext.Current.Request.UserHostAddress, false, Convert.ToString(HttpContext.Current.Session[enumSessions.User_Id.ToString()]));
     }
 }