protected void NewInOutLineMvoDocumentActionCommandAndExecute(ICreateInOutLineMvo c, IInOutLineMvoState s, IInOutLineMvoStateCreated e) { var pCommandHandler = this.InOutLineMvoDocumentActionCommandHandler; var pCmdContent = c.DocumentAction; var pCmd = new PropertyCommand <string, string> { Content = pCmdContent, GetState = () => s.InOutDocumentStatus, SetState = p => e.InOutDocumentStatus = p, OuterCommandType = CommandType.Create }; pCommandHandler.Execute(pCmd); }
void IInOutLineMvoApplicationService.When(ICreateInOutLineMvo c) { this.When((CreateInOutLineMvoDto)c); }
public virtual void When(ICreateInOutLineMvo c) { Update(c, ar => ar.Create(c)); }
public virtual void Create(ICreateInOutLineMvo c) { IInOutLineMvoStateCreated e = Map(c); Apply(e); }
protected virtual IInOutLineMvoStateCreated Map(ICreateInOutLineMvo c) { var stateEventId = new InOutLineMvoStateEventId(c.InOutLineId, c.InOutVersion); IInOutLineMvoStateCreated e = NewInOutLineMvoStateCreated(stateEventId); e.Description = c.Description; e.LocatorId = c.LocatorId; e.ProductId = c.ProductId; 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.Version = c.Version; e.Active = c.Active; e.InOutIsSOTransaction = c.InOutIsSOTransaction; NewInOutLineMvoDocumentActionCommandAndExecute(c, _state, e); e.InOutPosted = c.InOutPosted; e.InOutProcessing = c.InOutProcessing; e.InOutProcessed = c.InOutProcessed; e.InOutDocumentType = c.InOutDocumentType; e.InOutDescription = c.InOutDescription; e.InOutOrderNumber = c.InOutOrderNumber; e.InOutDateOrdered = c.InOutDateOrdered; e.InOutIsPrinted = c.InOutIsPrinted; e.InOutMovementType = c.InOutMovementType; e.InOutMovementDate = c.InOutMovementDate; e.InOutBusinessPartnerId = c.InOutBusinessPartnerId; e.InOutWarehouseId = c.InOutWarehouseId; e.InOutPOReference = c.InOutPOReference; e.InOutFreightAmount = c.InOutFreightAmount; e.InOutShipperId = c.InOutShipperId; e.InOutChargeAmount = c.InOutChargeAmount; e.InOutDatePrinted = c.InOutDatePrinted; e.InOutSalesRepresentative = c.InOutSalesRepresentative; e.InOutNumberOfPackages = c.InOutNumberOfPackages; e.InOutPickDate = c.InOutPickDate; e.InOutShipDate = c.InOutShipDate; e.InOutTrackingNumber = c.InOutTrackingNumber; e.InOutDateReceived = c.InOutDateReceived; e.InOutIsInTransit = c.InOutIsInTransit; e.InOutIsApproved = c.InOutIsApproved; e.InOutIsInDispute = c.InOutIsInDispute; e.InOutVolume = c.InOutVolume; e.InOutWeight = c.InOutWeight; e.InOutRmaNumber = c.InOutRmaNumber; e.InOutReversalNumber = c.InOutReversalNumber; e.InOutIsDropShip = c.InOutIsDropShip; e.InOutDropShipBusinessPartnerId = c.InOutDropShipBusinessPartnerId; e.InOutCreatedBy = c.InOutCreatedBy; e.InOutCreatedAt = c.InOutCreatedAt; e.InOutUpdatedBy = c.InOutUpdatedBy; e.InOutUpdatedAt = c.InOutUpdatedAt; e.InOutActive = c.InOutActive; e.InOutDeleted = c.InOutDeleted; e.CommandId = c.CommandId; e.CreatedBy = (string)c.RequesterId; e.CreatedAt = DateTime.Now; var inOutVersion = c.InOutVersion; return(e); }
protected virtual IInOutLineMvoStateCreated Map(ICreateInOutLineMvo c) { var stateEventId = new InOutLineMvoEventId(c.InOutLineId, c.InOutVersion); IInOutLineMvoStateCreated e = NewInOutLineMvoStateCreated(stateEventId); e.LocatorId = c.LocatorId; e.ProductId = c.ProductId; e.AttributeSetInstanceId = c.AttributeSetInstanceId; e.Description = c.Description; e.QuantityUomId = c.QuantityUomId; e.MovementQuantity = c.MovementQuantity; e.PickedQuantity = c.PickedQuantity; e.IsInvoiced = c.IsInvoiced; e.Processed = c.Processed; e.RmaLineNumber = c.RmaLineNumber; e.ReversalLineNumber = c.ReversalLineNumber; e.Version = c.Version; e.Active = c.Active; e.InOutDocumentStatusId = c.InOutDocumentStatusId; e.InOutPosted = c.InOutPosted; e.InOutProcessed = c.InOutProcessed; e.InOutProcessing = c.InOutProcessing; e.InOutDocumentTypeId = c.InOutDocumentTypeId; e.InOutDescription = c.InOutDescription; e.InOutOrderId = c.InOutOrderId; e.InOutDateOrdered = c.InOutDateOrdered; e.InOutIsPrinted = c.InOutIsPrinted; e.InOutMovementTypeId = c.InOutMovementTypeId; e.InOutMovementDate = c.InOutMovementDate; e.InOutBusinessPartnerId = c.InOutBusinessPartnerId; e.InOutWarehouseId = c.InOutWarehouseId; e.InOutPOReference = c.InOutPOReference; e.InOutFreightAmount = c.InOutFreightAmount; e.InOutShipperId = c.InOutShipperId; e.InOutChargeAmount = c.InOutChargeAmount; e.InOutDatePrinted = c.InOutDatePrinted; e.InOutCreatedFrom = c.InOutCreatedFrom; e.InOutSalesRepresentativeId = c.InOutSalesRepresentativeId; e.InOutNumberOfPackages = c.InOutNumberOfPackages; e.InOutPickDate = c.InOutPickDate; e.InOutShipDate = c.InOutShipDate; e.InOutTrackingNumber = c.InOutTrackingNumber; e.InOutDateReceived = c.InOutDateReceived; e.InOutIsInTransit = c.InOutIsInTransit; e.InOutIsApproved = c.InOutIsApproved; e.InOutIsInDispute = c.InOutIsInDispute; e.InOutRmaDocumentNumber = c.InOutRmaDocumentNumber; e.InOutReversalDocumentNumber = c.InOutReversalDocumentNumber; e.InOutCreatedBy = c.InOutCreatedBy; e.InOutCreatedAt = c.InOutCreatedAt; e.InOutUpdatedBy = c.InOutUpdatedBy; e.InOutUpdatedAt = c.InOutUpdatedAt; e.InOutActive = c.InOutActive; e.CommandId = c.CommandId; e.CreatedBy = (string)c.RequesterId; e.CreatedAt = ApplicationContext.Current.TimestampService.Now <DateTime>(); var inOutVersion = c.InOutVersion; return(e); }