Пример #1
0
 public XtraUserControl Init()
 {
     DataSet dt = HelpDB.getDatabase().LoadDataSet("select * from DANH_BA where id=-1", "DANH_BA");
     DMTreeGroupElement pl = new DMTreeGroupElement();
     pl.Init(GroupElementType.ONLY_INPUT,
         "DM_NHOM_DANH_BA", null, "ID", "PARENT_ID",
          new string[] { "NAME" }, new string[] { "Tên nhóm danh bạ" }, dt,
         "ID", "LOAI_DANH_BA", "NAME", HelpGen.G_FW_DM_ID, CreateDM_DANH_BA, GetRuleDM_DANHBA);
     if (isPermission) pl.DefinePermission(DanhMucParams.GetPermission(pl, DMTaiLieu.N, "Danh mục tài liệu"));
     return pl;
 }
Пример #2
0
        public DevExpress.XtraEditors.XtraUserControl Init()
        {
            //DataSet dt = DABase.getDatabase().LoadTable("DM_NHAN_VIEN");
            DataSet dt = DABase.getDatabase().LoadDataSet("SELECT * FROM DM_NHAN_VIEN WHERE -1=1", "DM_NHAN_VIEN");

            DMTreeGroupElement pl = new DMTreeGroupElement();
            pl.Init(GroupElementType.ONLY_INPUT,
                "DEPARTMENT", null, "ID", "PARENT_ID",
                new string[] { "NAME" }, new string[] { "Tên phòng ban" }, dt,
                "ID", "DEPARTMENT_ID", "NAME", HelpGen.G_FW_DM_ID, InitColumns, GetBizRule);
            if(isPermission) pl.DefinePermission(DanhMucParams.GetPermission(pl, DMFWNhanVien.N, "Danh mục nhân viên"));
            return pl;
        }