Пример #1
0
 public IdSubAttribute(RefBTAttribute refBTAttribute)
 {
     this.refBTAttribute = refBTAttribute;
     if (refBTAttribute.blAttribute is RefBLAttribute)
     {
         this.blAttribute = (RefBLAttribute)refBTAttribute.blAttribute;
     }
 }
Пример #2
0
        public KnzSubAttribute(RefBTAttribute refBTAttribute)
        {
            this.refBTAttribute = refBTAttribute;
            this.refBLAttribute = refBTAttribute.refBLAttribute;
            this.blAttribute    = refBTAttribute.blAttribute;

            if (refBTAttribute.HasToUseVerionTable)
            {
                var core = refBTAttribute.ReferencedBLInterface.GetCoreInterface();
                var knz  = core.Attributes.Where(a => a.IsPrimaryKey).First();
                this.ShortName = $"{core.Name}_VERSION_{knz.Name}";
                this.Alias     = refBLAttribute.Core.Alias;
            }
            else if (refBLAttribute == null)
            {
                this.ShortName = this.blAttribute.Name;
                this.Alias     = null;
            }
            else
            {
                this.ShortName = this.refBLAttribute.ReferencedAttribute.Name;
                this.Alias     = refBLAttribute.Core.Alias;
            }
        }