Пример #1
0
        protected virtual IInOutLineStateCreated MapCreate(ICreateInOutLine c, IInOutCommand outerCommand, long version, IInOutState outerState)
        {
            c.RequesterId = outerCommand.RequesterId;
            var stateEventId         = new InOutLineStateEventId(c.InOutDocumentNumber, c.SkuId, version);
            IInOutLineStateCreated e = NewInOutLineStateCreated(stateEventId);
            var s = outerState.InOutLines.Get(c.SkuId);

            e.LineNumber             = c.LineNumber;
            e.Description            = c.Description;
            e.LocatorId              = c.LocatorId;
            e.Product                = c.Product;
            e.UomId                  = c.UomId;
            e.MovementQuantity       = c.MovementQuantity;
            e.ConfirmedQuantity      = c.ConfirmedQuantity;
            e.ScrappedQuantity       = c.ScrappedQuantity;
            e.TargetQuantity         = c.TargetQuantity;
            e.PickedQuantity         = c.PickedQuantity;
            e.IsInvoiced             = c.IsInvoiced;
            e.AttributeSetInstanceId = c.AttributeSetInstanceId;
            e.IsDescription          = c.IsDescription;
            e.Processed              = c.Processed;
            e.QuantityEntered        = c.QuantityEntered;
            e.RmaLineNumber          = c.RmaLineNumber;
            e.ReversalLineNumber     = c.ReversalLineNumber;
            e.Active                 = c.Active;

            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = DateTime.Now;
            return(e);
        }// END Map(ICreate... ////////////////////////////
Пример #2
0
        }// END Map(IMergePatch... ////////////////////////////

        protected virtual IInOutLineStateRemoved MapRemove(IRemoveInOutLine c, IInOutCommand outerCommand, long version)
        {
            c.RequesterId = outerCommand.RequesterId;
            var stateEventId         = new InOutLineStateEventId(c.InOutDocumentNumber, c.SkuId, version);
            IInOutLineStateRemoved e = NewInOutLineStateRemoved(stateEventId);


            e.CreatedBy = (string)c.RequesterId;
            e.CreatedAt = DateTime.Now;

            return(e);
        }// END Map(IRemove... ////////////////////////////
Пример #3
0
        public override bool Equals(object obj)
        {
            if (Object.ReferenceEquals(this, obj))
            {
                return(true);
            }

            InOutLineStateEventId other = obj as InOutLineStateEventId;

            if (other == null)
            {
                return(false);
            }

            return(true &&
                   Object.Equals(this.InOutDocumentNumber, other.InOutDocumentNumber) &&
                   Object.Equals(this.SkuId, other.SkuId) &&
                   Object.Equals(this.InOutVersion, other.InOutVersion)
                   );
        }
Пример #4
0
        protected InOutLineStateEventId NewInOutLineStateEventId(SkuId skuId)
        {
            var stateEventId = new InOutLineStateEventId(this.StateEventId.DocumentNumber, skuId, this.StateEventId.Version);

            return(stateEventId);
        }
Пример #5
0
 private InOutLineStateRemoved NewInOutLineStateRemoved(InOutLineStateEventId stateEventId)
 {
     return(new InOutLineStateRemoved(stateEventId));
 }
Пример #6
0
 private InOutLineStateMergePatched NewInOutLineStateMergePatched(InOutLineStateEventId stateEventId)
 {
     return(new InOutLineStateMergePatched(stateEventId));
 }
Пример #7
0
 public InOutLineStateEventIdFlattenedDto(InOutLineStateEventId val)
 {
     this._value = val;
 }
Пример #8
0
 public InOutLineStateRemoved(InOutLineStateEventId stateEventId) : base(stateEventId)
 {
 }
Пример #9
0
 public InOutLineStateMergePatched(InOutLineStateEventId stateEventId) : base(stateEventId)
 {
 }
Пример #10
0
 public InOutLineStateCreated(InOutLineStateEventId stateEventId) : base(stateEventId)
 {
 }
Пример #11
0
 protected InOutLineStateEventBase(InOutLineStateEventId stateEventId)
 {
     this.StateEventId = stateEventId;
 }