Ejemplo n.º 1
0
        protected void btnDel_Click(object sender, EventArgs e)
        {
            if (grid1.SelectedRowIndexArray != null && grid1.SelectedRowIndexArray.Length > 0)
            {
                string strSelectID = "0";
                for (int i = 0, count = grid1.SelectedRowIndexArray.Length; i < count; i++)
                {
                    int rowIndex = grid1.SelectedRowIndexArray[i];
                    foreach (object key in grid1.DataKeys[rowIndex])
                    {
                        strSelectID = key.ToString();
                    }
                }
                #region  除逻辑

                zlzw.BLL.JobTypeListBLL     jobTypeListBLL   = new zlzw.BLL.JobTypeListBLL();
                zlzw.Model.JobTypeListModel jobTypeListModal = jobTypeListBLL.GetModel(int.Parse(strSelectID));
                jobTypeListModal.IsEnable = 0;
                jobTypeListBLL.Update(jobTypeListModal);
                JobTypeList_BindGrid();

                #endregion
            }
            else
            {
                return;
            }
        }
Ejemplo n.º 2
0
        private void LoadData(string strType)
        {
            if (strType == "1")
            {
                string strID = Request.QueryString["value"];//操作ID
                zlzw.BLL.JobTypeListBLL     jobTypeListBLL   = new zlzw.BLL.JobTypeListBLL();
                zlzw.Model.JobTypeListModel jobTypeListModal = jobTypeListBLL.GetModel(int.Parse(strID));
                txbJobTypeName.Text = jobTypeListModal.JobTypeName;//职位名称
                if (jobTypeListModal.IsEnable == 1)
                {
                    ckbIsEnable.Checked = true;
                }
                else
                {
                    ckbIsEnable.Checked = false;
                }

                ViewState["PublishDate"] = jobTypeListModal.PublishDate.ToString();
                ToolbarText2.Text        = "编辑一个岗位类型";
            }
            btnClose.OnClientClick = ActiveWindow.GetConfirmHideReference();
        }