Пример #1
0
        public void AddDetailBulider(IDetailBulider item)
        {
            DetailContent content = item.GetContent();

            if (content == null)
            {
                return;
            }

            if (Attribute.IsDefined(content.GetType(), typeof(FeatureCodeAttribute)))
            {
                FeatureCodeAttribute fca = Attribute.GetCustomAttribute(content.GetType(), typeof(FeatureCodeAttribute)) as FeatureCodeAttribute;
                if (fca != null)
                {
                    if (Framework.Legacy.GlobalOld.Acl[content.GetType()].Viewable)
                    {
                        Present.AddDetailBulider(item);
                    }
                }
            }
            else
            {
                Present.AddDetailBulider(item);
            }
        }
Пример #2
0
        public new void AddDetailBulider(IDetailBulider item)
        {
            DetailContent content = item.GetContent();

            if (content == null)
            {
                return;
            }

            if (Attribute.IsDefined(content.GetType(), typeof(FeatureCodeAttribute)))
            {
                FeatureCodeAttribute fca = Attribute.GetCustomAttribute(content.GetType(), typeof(FeatureCodeAttribute)) as FeatureCodeAttribute;
                if (fca != null)
                {
                    if (Framework.Legacy.GlobalOld.Acl[content.GetType()].Viewable)
                    {
                        base.AddDetailBulider(item);
                    }
                }
            }
            else if (Attribute.IsDefined(content.GetType(), typeof(FISCA.Permission.FeatureCodeAttribute)))
            {
                FISCA.Permission.FeatureCodeAttribute fca = Attribute.GetCustomAttribute(content.GetType(), typeof(FISCA.Permission.FeatureCodeAttribute)) as FISCA.Permission.FeatureCodeAttribute;
                if (fca != null)
                {
                    if (FISCA.Permission.UserAcl.Current[fca.Code].Viewable)
                    {
                        base.AddDetailBulider(item);
                    }
                }
            }
            else
            {
                base.AddDetailBulider(item);
            }
        }