예제 #1
0
        private void BindSysFunFrom()//绑定待选模块
        {
            DataTable dt = null;

            if (MUserRol.FUN_MODEL != ",")
            {
                dt = BSysFun.GetListChild(" start with model_id=" + GetWhereStr() + " connect by prior model_id = up_model_id  and instr('" + MUserRol.FUN_MODEL + "',','||model_id||',')<=0");
            }
            else
            {
                dt = BSysFun.GetListChild(" start with model_id=" + GetWhereStr() + " connect by prior model_id = up_model_id ");
            }

            lv_From.Items.Clear();
            if (dt.Rows.Count > 0)
            {
                for (int i = 0; i < dt.Rows.Count; i++)
                {
                    ListViewItem li = new ListViewItem(dt.Rows[i]["MODEL_ID"].ToString());
                    li.SubItems.Add(dt.Rows[i]["MODEL_NAME"].ToString());
                    this.lv_From.Items.Add(li);
                }
            }
        }
예제 #2
0
        private void BindSysFun()//绑定二三级模块
        {
            DataTable dt = BSysFun.GetListChild(" start with model_id=" + GetWhereStr() + " connect by prior model_id=up_model_id ");

            if (dt.Rows.Count > 0)
            {
                this.GvSysFun.DataSource   = dt;
                this.GvSysFun.Visible      = true;
                this.gb_PromptInfo.Visible = false;
            }
            else
            {
                this.GvSysFun.DataSource   = null;
                this.GvSysFun.Visible      = false;
                this.gb_PromptInfo.Visible = true;
            }
        }