예제 #1
0
        protected void gvResult_ItemCommand(object source, DataGridCommandEventArgs e)
        {
            if (e.CommandSource is Button)
            {
                if (e.CommandName == "Delete")
                {
                    int Id  = (int)gvResult.DataKeys[e.Item.ItemIndex];
                    int cnt = PE_DAL.DeleteVK_LP(Id, e.Item.Cells[2].Text, System.Convert.ToInt32(this.IsVK));
                    BindDataVK_LP(this.IsVK);
                }
                else if (e.CommandName == "edit")
                {
                    int    Id         = (int)gvResult.DataKeys[e.Item.ItemIndex];
                    string interface_ = e.Item.Cells[2].Text;

                    if (PubEntAdminManager.TamperProof)
                    {
                        PubEntAdminManager.RedirectEncodedURLWithQS(ChildPage,
                                                                    PubEntAdminManager.strPubID + "=" + Id.ToString() + "&" +
                                                                    PubEntAdminManager.strInterface + "=" + this.WhatInt(interface_) +
                                                                    "&" + PubEntAdminManager.strVK_LPType + "=" + (this.blnIsVK ? PubEntAdminManager.strVKType : PubEntAdminManager.strLPType));
                    }
                    else
                    {
                        Response.Redirect(ChildPage + "?" + PubEntAdminManager.strPubID + "=" + Id.ToString() + "&" +
                                          PubEntAdminManager.strInterface + "=" + this.WhatInt(interface_) +
                                          "&" + PubEntAdminManager.strVK_LPType + "=" + (this.blnIsVK ? PubEntAdminManager.strVKType : PubEntAdminManager.strLPType), true);
                    }
                }
            }
        }
예제 #2
0
        protected void AddSubsubcat1Save_Click(object sender, EventArgs e)
        {
            AddSubsubcat l_AddSubsubcat = ((AddSubsubcat)((MultiView)SubsubcategoryStep.
                                                          ContentTemplateContainer.FindControl("MultiView1")).Views[0].FindControl("AddSubsubcat1"));

            l_AddSubsubcat.SecVal();

            int  l_subsubcatid    = 0;
            bool blnSaveSubSubCat = false;

            if (this.SubcatID > 0 && this.SubcatMode.Length >= 0)
            {
                blnSaveSubSubCat = PE_DAL.SetSubSubCat(ref l_subsubcatid, l_AddSubsubcat.SubSubCatName,
                                                       this.SubcatID, 1);
            }
            else
            {
                blnSaveSubSubCat = PE_DAL.SetSubSubCat(ref l_subsubcatid, l_AddSubsubcat.SubSubCatName,
                                                       l_AddSubsubcat.AssignToSubCatID, 1);
            }

            if (blnSaveSubSubCat)
            {
                if (PubEntAdminManager.TamperProof)
                {
                    PubEntAdminManager.RedirectEncodedURLWithQS("LookupMgmt.aspx", "sub=" + this.RetSub + "&mode=edit&subcatid=" + this.SubcatID);
                }
                else
                {
                    Response.Redirect("~/LookupMgmt.aspx?sub=" + this.RetSub + "&mode=edit&subcatid=" + this.SubcatID, true);
                }

                //l_AddSubsubcat.ClearAll();
                //this.EnableSubsubcategoryEditTab();
                //if (this.SubcatID > 0)
                //{
                //    this.BindOptions(this.SubcatID);
                //}
                //else
                //{
                //    this.BindOptions();
                //}
                //this.hidSubSubCatIndex.Value = "1";
            }
        }
예제 #3
0
        protected void EditSubcat1EditSubsubcat_Click(object sender, EventArgs e)
        {
            Session[PubEntAdminManager.strCurrCatName] =
                ((Label)SubCategoryAddEditStep.ContentTemplateContainer.FindControl("lblCategoryStep")).Text;

            EditSubcat l_EditSubcat = ((EditSubcat)SubCategoryEditStep.ContentTemplateContainer.
                                       FindControl("EditSubcat1"));

            Session[PubEntAdminManager.strCurrSubcatName] = l_EditSubcat.SubCatName;

            if (PubEntAdminManager.TamperProof)
            {
                PubEntAdminManager.RedirectEncodedURLWithQS("LookupMgmt.aspx", "sub=subsubcat&mode=edit&subcatid=" + l_EditSubcat.SubCatID);
            }
            else
            {
                Response.Redirect("~/LookupMgmt.aspx?sub=subsubcat&mode=edit&subcatid=" + l_EditSubcat.SubCatID);
            }
        }