예제 #1
0
        protected virtual IAttributeAliasMvoStateMergePatched Map(IMergePatchAttributeAliasMvo c)
        {
            var stateEventId = new AttributeAliasMvoEventId(c.AttributeAliasId, c.AttributeVersion);
            IAttributeAliasMvoStateMergePatched e = NewAttributeAliasMvoStateMergePatched(stateEventId);

            e.Name    = c.Name;
            e.Version = c.Version;
            e.Active  = c.Active;
            e.AttributeAttributeName        = c.AttributeAttributeName;
            e.AttributeOrganizationId       = c.AttributeOrganizationId;
            e.AttributeDescription          = c.AttributeDescription;
            e.AttributeIsMandatory          = c.AttributeIsMandatory;
            e.AttributeAttributeValueType   = c.AttributeAttributeValueType;
            e.AttributeAttributeValueLength = c.AttributeAttributeValueLength;
            e.AttributeIsList          = c.AttributeIsList;
            e.AttributeFieldName       = c.AttributeFieldName;
            e.AttributeReferenceId     = c.AttributeReferenceId;
            e.AttributeCreatedBy       = c.AttributeCreatedBy;
            e.AttributeCreatedAt       = c.AttributeCreatedAt;
            e.AttributeUpdatedBy       = c.AttributeUpdatedBy;
            e.AttributeUpdatedAt       = c.AttributeUpdatedAt;
            e.AttributeActive          = c.AttributeActive;
            e.AttributeDeleted         = c.AttributeDeleted;
            e.IsPropertyNameRemoved    = c.IsPropertyNameRemoved;
            e.IsPropertyVersionRemoved = c.IsPropertyVersionRemoved;
            e.IsPropertyActiveRemoved  = c.IsPropertyActiveRemoved;
            e.IsPropertyAttributeAttributeNameRemoved        = c.IsPropertyAttributeAttributeNameRemoved;
            e.IsPropertyAttributeOrganizationIdRemoved       = c.IsPropertyAttributeOrganizationIdRemoved;
            e.IsPropertyAttributeDescriptionRemoved          = c.IsPropertyAttributeDescriptionRemoved;
            e.IsPropertyAttributeIsMandatoryRemoved          = c.IsPropertyAttributeIsMandatoryRemoved;
            e.IsPropertyAttributeAttributeValueTypeRemoved   = c.IsPropertyAttributeAttributeValueTypeRemoved;
            e.IsPropertyAttributeAttributeValueLengthRemoved = c.IsPropertyAttributeAttributeValueLengthRemoved;
            e.IsPropertyAttributeIsListRemoved      = c.IsPropertyAttributeIsListRemoved;
            e.IsPropertyAttributeFieldNameRemoved   = c.IsPropertyAttributeFieldNameRemoved;
            e.IsPropertyAttributeReferenceIdRemoved = c.IsPropertyAttributeReferenceIdRemoved;
            e.IsPropertyAttributeCreatedByRemoved   = c.IsPropertyAttributeCreatedByRemoved;
            e.IsPropertyAttributeCreatedAtRemoved   = c.IsPropertyAttributeCreatedAtRemoved;
            e.IsPropertyAttributeUpdatedByRemoved   = c.IsPropertyAttributeUpdatedByRemoved;
            e.IsPropertyAttributeUpdatedAtRemoved   = c.IsPropertyAttributeUpdatedAtRemoved;
            e.IsPropertyAttributeActiveRemoved      = c.IsPropertyAttributeActiveRemoved;
            e.IsPropertyAttributeDeletedRemoved     = c.IsPropertyAttributeDeletedRemoved;

            e.CommandId = c.CommandId;


            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>();

            var attributeVersion = c.AttributeVersion;


            return(e);
        }
 void IAttributeAliasMvoApplicationService.When(IMergePatchAttributeAliasMvo c)
 {
     this.When((MergePatchAttributeAliasMvoDto)c);
 }
 public virtual void When(IMergePatchAttributeAliasMvo c)
 {
     Update(c, ar => ar.MergePatch(c));
 }
예제 #4
0
        public virtual void MergePatch(IMergePatchAttributeAliasMvo c)
        {
            IAttributeAliasMvoStateMergePatched e = Map(c);

            Apply(e);
        }