Beispiel #1
0
 protected void onFullCancel(object sender, System.EventArgs e)
 {
     ModalPopupExtender2.Hide();
 }
Beispiel #2
0
    protected void AddButton_Click(object sender, EventArgs e)
    {
        DateTime creationDate;
        int      LeadID              = 0;
        string   prospectCustomer    = string.Empty;
        string   address             = string.Empty;
        string   mobile              = string.Empty;
        string   landline            = string.Empty;
        string   email               = string.Empty;
        string   modeOfContact       = string.Empty;
        string   personalResponsible = string.Empty;
        string   businessType        = string.Empty;
        string   branch              = string.Empty;
        string   status              = string.Empty;
        string   LastCompletedAction = string.Empty;
        //string creationDate = string.Empty;
        string  nextAction = string.Empty;
        string  category   = string.Empty;
        DataSet dsContact;

        string info1 = string.Empty;
        string info2 = string.Empty;
        string info3 = string.Empty;

        string info4 = string.Empty;
        string info5 = string.Empty;

        try
        {
            if (Session["contactDs"] == null || ((DataSet)Session["contactDs"]).Tables[0].Rows.Count < 1)
            {
                ScriptManager.RegisterStartupScript(Page, Page.GetType(), Guid.NewGuid().ToString(), "alert('Please enter atleast one Lead Contact and try again.')", true);
                return;
            }

            if (Page.IsValid)
            {
                //if(txtLeadNo.Text != string.Empty)
                //LeadID = int.Parse(txtLeadNo.Text);

                creationDate = DateTime.Parse(txtCreationDate.Text);
                //creationDate = txtCreationDate.Text.Trim();
                prospectCustomer    = txtProspCustName.Text;
                address             = txtAddress.Text;
                mobile              = txtMobile.Text;
                landline            = txtLandline.Text;
                email               = txtEmail.Text;
                modeOfContact       = cmbModeOfContact.SelectedValue;
                personalResponsible = cmbPersonalResp.Text;
                businessType        = cmbBussType.SelectedValue;
                branch              = cmbBranch.SelectedValue;
                if (cmbnewstatus.SelectedValue == "0")
                {
                    status = cmbStatus.SelectedValue;
                }
                else
                {
                    status = cmbnewstatus.SelectedValue;
                }
                if (cmblastaction.SelectedValue == "0")
                {
                    LastCompletedAction = cmbLastCompAction.SelectedValue;
                }
                else
                {
                    LastCompletedAction = cmblastaction.SelectedValue;
                }
                if (cmbnxtaction.SelectedValue == "0")
                {
                    nextAction = cmbNextAction.SelectedValue;
                }
                else
                {
                    nextAction = cmbnxtaction.SelectedValue;
                }
                category = cmbCategory.SelectedValue;

                info1 = txtInfo1.Text;
                info2 = txtInfo2.Text;

                info3 = ddlinfo3.SelectedValue;
                info4 = ddlinfo4.SelectedValue;
                info5 = ddlinfo5.SelectedValue;

                string callbackflag = DropDownList1.SelectedItem.Text;
                string callbackdate = TextBox1.Text;

                dsContact = (DataSet)Session["contactDs"];

                string connStr = GetConnectionString();

                LeadBusinessLogic bl = new LeadBusinessLogic(connStr);

                //bl.AddUpdateLeadMaster(LeadID, creationDate, prospectCustomer, address, mobile, landline, email, modeOfContact, personalResponsible, businessType, branch, status, LastCompletedAction, nextAction, category, dsContact, info1, info2, info3, info4, info5);
                bl.AddUpdateLeadMaster(LeadID, creationDate, prospectCustomer, address, mobile, landline, email, modeOfContact, personalResponsible, businessType, branch, status, LastCompletedAction, nextAction, category, dsContact, info1, info2, info3, info4, info5, callbackflag, callbackdate);


                GrdViewLead.DataBind();

                ScriptManager.RegisterStartupScript(Page, Page.GetType(), Guid.NewGuid().ToString(), "alert('Lead Details saved successfully.')", true);

                BindGrid("", "");
                UpdatePanelPage.Update();


                ModalPopupExtender2.Hide();


                //return;
            }
        }
        catch (Exception ex)
        {
            TroyLiteExceptionManager.HandleException(ex);
            return;
        }
    }
Beispiel #3
0
 protected void PopupClose2_Click(object sender, EventArgs e)
 {
     ModalPopupExtender2.Hide();
     Labelhiden3.Visible = false;
     Labelhiden4.Visible = false;
 }
 protected void ibtnCancelCabinetAdd_Click(object sender, ImageClickEventArgs e)
 {
     ModalPopupExtender2.Hide();
 }
Beispiel #5
0
 protected void btnDelete_Ok_Click(object sender, EventArgs e)
 {
     deleteExpense(Convert.ToInt16(Session["ExpenseHDRID"]));
     fillGrid(Convert.ToInt16(Session["UserID"]), Convert.ToInt16(Session["MovementID"]));
     ModalPopupExtender2.Hide();
 }
        //protected void btnXuatban_Click(object sender, EventArgs e)
        //{
        //    int Ads_ID = 0;
        //    try
        //    {
        //        HPCBusinessLogic.DAL.T_Customer_AdsDAL _cateDAL = new HPCBusinessLogic.DAL.T_Customer_AdsDAL();
        //        foreach (DataGridItem m_Item in grdListCate.Items)
        //        {

        //            CheckBox chk_Select = (CheckBox)m_Item.FindControl("optSelect");
        //            if (chk_Select != null && chk_Select.Checked)
        //            {
        //                Label lblMota = (Label)m_Item.FindControl("lblMota");
        //                Ads_ID = int.Parse(grdListCate.DataKeys[int.Parse(m_Item.ItemIndex.ToString())].ToString());
        //                bool bolUpdate = _cateDAL.Send2Approver(Ads_ID, 3, _user.UserID);
        //                WriteLogHistory2Database.WriteHistory2Database(_user.UserID, _user.UserFullName, lblMota.Text, strMenuID, "XUẤT BẢN QUẢNG CÁO", double.Parse(Ads_ID.ToString()));
        //            }
        //        }
        //        LoadData();
        //        //Tao cache
        //        //UltilFunc.GenCacheHTML();
        //    }
        //    catch (Exception ex)
        //    {
        //        HPCServerDataAccess.Lib.ShowAlertMessage(ex.Message.ToString());
        //    }
        //}
        #endregion

        #region Event Click


        protected void btnExit_Click(object sender, EventArgs e)
        {
            ModalPopupExtender2.Hide();
        }
Beispiel #7
0
 protected void btnCerrarModalOferta_Click(object sender, EventArgs e)
 {
     lblModalIdOfertaPedido.Text = "";
     ModalPopupExtender2.Hide();
 }
Beispiel #8
0
    protected void btnUpdate_Click(object sender, EventArgs e)
    {
        string[] proid1 = { }; string[] proid2 = { }; string[] proid3 = { };
        string[] proid4 = { }; string[] proid5 = { }; string[] proid6 = { }; string[] proid7 = { };
        string[] brandid1 = { }; string[] brandid2 = { }; string[] brandid3 = { };
        string[] brandid4 = { }; string[] brandid5 = { }; string[] brandid6 = { }; string[] brandid7 = { };
        string[] brandids = { }; string[] proids = { };
        if (LinkButton1.Text == "INDG")
        {
            centerid = "4";
        }
        else if (LinkButton1.Text == "INBH")
        {
            centerid = "1";
        }
        else if (LinkButton1.Text == "USMP")
        {
            centerid = "2";
        }
        else if (LinkButton1.Text == "USWB")
        {
            centerid = "3";
        }
        if (Session["proid1"] != null)
        {
            if (Session["proid1"].ToString().Contains(',') && Session["proid1"].ToString().IndexOf(',') != -1)
            {
                if (Session["proid1"].ToString().LastIndexOf(',') == Session["proid1"].ToString().Length - 1)
                {
                    Session["proid1"] = Session["proid1"].ToString().Substring(0, Session["proid1"].ToString().LastIndexOf(','));
                }
                proid1 = Session["proid1"].ToString().Split(',');
            }
            else
            {
                proid1 = new string[] { Session["proid1"].ToString() };
            }
            foreach (string i in proid1)
            {
                if (i != "")
                {
                    objHotLeadBL.UpdateCentersList(Convert.ToInt32(Session["modid1"].ToString()), Convert.ToInt32(Session["brandid1"].ToString()), Convert.ToInt32(i), Convert.ToInt32(centerid));
                }
            }
        }
        if (Session["proid5"] != null)
        {
            if (Session["proid5"].ToString().Contains(',') && Session["proid5"].ToString().IndexOf(',') != -1)
            {
                if (Session["proid5"].ToString().LastIndexOf(',') == Session["proid5"].ToString().Length - 1)
                {
                    Session["proid5"] = Session["proid5"].ToString().Substring(0, Session["proid5"].ToString().LastIndexOf(','));
                }
                proid5 = Session["proid5"].ToString().Split(',');
            }
            else
            {
                proid5 = new string[] { Session["proid5"].ToString() };
            }
            foreach (string i in proid5)
            {
                if (i != "")
                {
                    objHotLeadBL.UpdateCentersList(Convert.ToInt32(Session["modid5"].ToString()), Convert.ToInt32(Session["brandid5"].ToString()), Convert.ToInt32(i), Convert.ToInt32(centerid));
                }
            }
        }
        if (Session["proid6"] != null)
        {
            if (Session["proid6"].ToString().Contains(',') && Session["proid6"].ToString().IndexOf(',') != -1)
            {
                if (Session["proid6"].ToString().LastIndexOf(',') == Session["proid6"].ToString().Length - 1)
                {
                    Session["proid6"] = Session["proid6"].ToString().Substring(0, Session["proid6"].ToString().LastIndexOf(','));
                }
                proid6 = Session["proid6"].ToString().Split(',');
            }
            else
            {
                proid6 = new string[] { Session["proid6"].ToString() };
            }
            foreach (string i in proid6)
            {
                if (i != "")
                {
                    objHotLeadBL.UpdateCentersList(Convert.ToInt32(Session["modid6"].ToString()), Convert.ToInt32(Session["brandid6"].ToString()), Convert.ToInt32(i), Convert.ToInt32(centerid));
                }
            }
        }
        if (Session["proid7"] != null)
        {
            if (Session["proid7"].ToString().Contains(',') && Session["proid7"].ToString().IndexOf(',') != -1)
            {
                if (Session["proid7"].ToString().LastIndexOf(',') == Session["proid7"].ToString().Length - 1)
                {
                    Session["proid7"] = Session["proid7"].ToString().Substring(0, Session["proid7"].ToString().LastIndexOf(','));
                }
                proid7 = Session["proid7"].ToString().Split(',');
            }
            else
            {
                proid7 = new string[] { Session["proid7"].ToString() };
            }
            foreach (string i in proid7)
            {
                if (i != "")
                {
                    objHotLeadBL.UpdateCentersList(Convert.ToInt32(Session["modid7"].ToString()), Convert.ToInt32(Session["brandid7"].ToString()), Convert.ToInt32(i), Convert.ToInt32(centerid));
                }
            }
        }
        if (Session["brandid2"] != null)
        {
            if (Session["brandid2"].ToString().Contains(',') && Session["brandid2"].ToString().IndexOf(',') != -1)
            {
                if (Session["brandid2"].ToString().LastIndexOf(',') == Session["brandid2"].ToString().Length - 1)
                {
                    Session["brandid2"] = Session["brandid2"].ToString().Substring(0, Session["brandid2"].ToString().LastIndexOf(','));
                }
                brandid2 = Session["brandid2"].ToString().Split(',');
            }
            else
            {
                brandid2 = new string[] { Session["brandid2"].ToString() };
            }
            foreach (string i in brandid2)
            {
                if (i != "")
                {
                    objHotLeadBL.UpdateCentersList(Convert.ToInt32(Session["modid2"].ToString()), Convert.ToInt32(i), Convert.ToInt32(Session["proid2"].ToString()), Convert.ToInt32(centerid));
                }
            }
        }
        if (Session["brandid3"] != null)
        {
            if (Session["brandid3"].ToString().Contains(',') && Session["brandid3"].ToString().IndexOf(',') != -1)
            {
                if (Session["brandid3"].ToString().LastIndexOf(',') == Session["brandid3"].ToString().Length - 1)
                {
                    Session["brandid3"] = Session["brandid3"].ToString().Substring(0, Session["brandid3"].ToString().LastIndexOf(','));
                }
                brandid3 = Session["brandid3"].ToString().Split(',');
            }
            else
            {
                brandid3 = new string[] { Session["brandid3"].ToString() };
            }
            foreach (string i in brandid3)
            {
                if (i != "")
                {
                    objHotLeadBL.UpdateCentersList(Convert.ToInt32(Session["modid3"].ToString()), Convert.ToInt32(i), Convert.ToInt32(Session["proid3"].ToString()), Convert.ToInt32(centerid));
                }
            }
        }
        if (Session["brandid4"] != null)
        {
            if (Session["brandid4"].ToString().Contains(',') && Session["brandid4"].ToString().IndexOf(',') != -1)
            {
                if (Session["brandid4"].ToString().LastIndexOf(',') == Session["brandid4"].ToString().Length - 1)
                {
                    Session["brandid4"] = Session["brandid4"].ToString().Substring(0, Session["brandid4"].ToString().LastIndexOf(','));
                }
                brandid4 = Session["brandid4"].ToString().Split(',');
            }
            else
            {
                brandid4 = new string[] { Session["brandid4"].ToString() };
            }
            foreach (string i in brandid4)
            {
                if (i != "")
                {
                    objHotLeadBL.UpdateCentersList(Convert.ToInt32(Session["modid4"].ToString()), Convert.ToInt32(i), Convert.ToInt32(Session["proid4"].ToString()), Convert.ToInt32(centerid));
                }
            }
        }
        ModalPopupExtender2.Hide();

        GetCentersUpdateLIst();
    }
 protected void ERRbtnCancel_Click(object sender, EventArgs e)
 {
     ModalPopupExtender2.Hide();
     clearAllERR();
     TurnCapchaOnOff(MessageClass.IsSpammer());
 }
    protected void Button3_Click(object sender, EventArgs e)
    {
        DateTime date = Convert.ToDateTime(DateTime.Today.ToString("dd/MM/yyyy"));

        if (TextBox1.Text == "")
        {
            ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "alert Message", "alert('Please enter Account Name')", true);
        }
        else
        {
            company_id = Convert.ToInt32(Session["company_id"].ToString());
            SqlConnection CON = new SqlConnection(ConfigurationManager.AppSettings["connection"]);
            SqlCommand    cmd = new SqlCommand("insert into account_entry values(@Account_name,@Phone,@Email,@website,@Assign_to,@Customer_type,@Source,@ratings,@Industry,@Segment,@Compititors,@Notes,@tin_no,@Cst_no,@Service_tax_no,@Panno,@suplier,@Billing_Add,@billing_city,@billing_state,@Billing_zip,@Billing_country,@no_Of_emp,@Annual_revenue,@ownership,@compaign,@compaign_type,@created,@com_id)", CON);
            cmd.Parameters.AddWithValue("@Account_name", TextBox1.Text);
            cmd.Parameters.AddWithValue("@Phone", TextBox2.Text);
            cmd.Parameters.AddWithValue("@Email", TextBox3.Text);
            cmd.Parameters.AddWithValue("@website", TextBox6.Text);

            cmd.Parameters.AddWithValue("@Assign_to", DBNull.Value);
            cmd.Parameters.AddWithValue("@Customer_type", DropDownList8.SelectedItem.Text);
            cmd.Parameters.AddWithValue("@Source", DropDownList9.SelectedItem.Text);
            cmd.Parameters.AddWithValue("@ratings", DBNull.Value);
            cmd.Parameters.AddWithValue("@Industry", DBNull.Value);
            cmd.Parameters.AddWithValue("@Segment", DBNull.Value);
            cmd.Parameters.AddWithValue("@Compititors", DBNull.Value);
            cmd.Parameters.AddWithValue("@Notes", DBNull.Value);
            cmd.Parameters.AddWithValue("@tin_no", DBNull.Value);
            cmd.Parameters.AddWithValue("@Cst_no", DBNull.Value);
            cmd.Parameters.AddWithValue("@Service_tax_no", DBNull.Value);
            cmd.Parameters.AddWithValue("@Panno", DBNull.Value);

            cmd.Parameters.AddWithValue("@suplier", DBNull.Value);


            cmd.Parameters.AddWithValue("@Billing_Add", DBNull.Value);
            cmd.Parameters.AddWithValue("@billing_city", DBNull.Value);
            cmd.Parameters.AddWithValue("@billing_state", DBNull.Value);
            cmd.Parameters.AddWithValue("@Billing_zip", DBNull.Value);
            cmd.Parameters.AddWithValue("@Billing_country", DBNull.Value);
            cmd.Parameters.AddWithValue("@no_Of_emp", DBNull.Value);
            cmd.Parameters.AddWithValue("@Annual_revenue", DBNull.Value);
            cmd.Parameters.AddWithValue("@ownership", DBNull.Value);
            cmd.Parameters.AddWithValue("@compaign", DBNull.Value);
            cmd.Parameters.AddWithValue("@compaign_type", DBNull.Value);
            cmd.Parameters.AddWithValue("@created", date);
            cmd.Parameters.AddWithValue("@com_id", company_id);

            CON.Open();

            cmd.ExecuteNonQuery();
            CON.Close();

            ScriptManager.RegisterClientScriptBlock(this, this.GetType(), "alert Message", "alert('Account created successfully')", true);
            showCustomerType();
            showsource();
            TextBox9.Text = TextBox1.Text;
            TextBox1.Text = "";
            TextBox2.Text = "";
            TextBox3.Text = "";
            TextBox6.Text = "";

            ModalPopupExtender2.Hide();
        }
    }
Beispiel #11
0
 protected void btnCancel_Click(object sender, EventArgs e)
 {
     txtNumeroPedido.Value = "";
     ModalPopupExtender2.Hide();
 }
Beispiel #12
0
 //取消
 protected void btnClose2_Click(object sender, EventArgs e)
 {
     ModalPopupExtender2.Hide();
     UCPaging1.CurrentPage = 1;
     bindrpt();
 }
Beispiel #13
0
 protected void btnDelete_Ok_Click(object sender, EventArgs e)
 {
     deleteTask(Convert.ToInt16(Session["TaskID"]));
     fillGrid(Convert.ToInt16(ddlProject.SelectedValue));
     ModalPopupExtender2.Hide();
 }
Beispiel #14
0
 protected void onCancelDecline(object sender, EventArgs e)
 {
     ModalPopupExtender2.Hide();
 }
 protected void btnDelete_Ok_Click(object sender, EventArgs e)
 {
     deleteLicense(Convert.ToInt16(Session["LicenseID"]));
     fillLicense();
     ModalPopupExtender2.Hide();
 }
 protected void ImageButton11_Click(object sender, EventArgs e)
 {
     ModalPopupExtender2.Hide();
 }
Beispiel #17
0
    protected void BtnCancelarMantto_Click(object sender, EventArgs e)
    {
        ModalPopupExtender2.Hide();

        RecuperaSectoresSectorizacion(LblIdSectorizacion.Text);
    }
Beispiel #18
0
 protected void btnDelete_cancel_Click(object sender, EventArgs e)
 {
     ModalPopupExtender2.Hide();
 }
Beispiel #19
0
 protected void CancelImage_Click(object sender, EventArgs e)
 {
     Response.Redirect("imageUpload.aspx?UserId=" + UserId);
     ModalPopupExtender2.Hide();
 }