Exemplo n.º 1
0
        public GarmentAvalComponent(Guid identity, string avalComponentNo, UnitDepartmentId unitId, string unitCode, string unitName, string avalComponentType, string rONo, string article, GarmentComodityId comodityId, string comodityCode, string comodityName, DateTimeOffset date) : base(identity)
        {
            Identity          = identity;
            AvalComponentNo   = avalComponentNo;
            UnitId            = unitId;
            UnitCode          = unitCode;
            UnitName          = unitName;
            AvalComponentType = avalComponentType;
            RONo         = rONo;
            Article      = article;
            ComodityId   = comodityId;
            ComodityCode = comodityCode;
            ComodityName = comodityName;
            Date         = date;

            ReadModel = new GarmentAvalComponentReadModel(Identity)
            {
                AvalComponentNo   = avalComponentNo,
                UnitId            = unitId.Value,
                UnitCode          = unitCode,
                UnitName          = unitName,
                AvalComponentType = avalComponentType,
                RONo         = rONo,
                Article      = article,
                ComodityId   = comodityId.Value,
                ComodityCode = comodityCode,
                ComodityName = comodityName,
                Date         = date
            };
        }
Exemplo n.º 2
0
        public GarmentComodityPrice(Guid identity, bool isValid, DateTimeOffset date, UnitDepartmentId unitId, string unitCode, string unitName, GarmentComodityId comodityId, string comodityCode, string comodityName, decimal price) : base(identity)
        {
            Validator.ThrowIfNull(() => unitId);

            //MarkTransient();

            Identity     = identity;
            IsValid      = isValid;
            UnitId       = unitId;
            UnitCode     = unitCode;
            UnitName     = unitName;
            Date         = date;
            ComodityId   = comodityId;
            ComodityCode = comodityCode;
            ComodityName = comodityName;
            Price        = price;

            ReadModel = new GarmentComodityPriceReadModel(Identity)
            {
                IsValid      = IsValid,
                UnitId       = UnitId.Value,
                UnitCode     = UnitCode,
                UnitName     = UnitName,
                Date         = Date,
                ComodityId   = ComodityId.Value,
                ComodityCode = ComodityCode,
                ComodityName = ComodityName,
                Price        = Price
            };

            ReadModel.AddDomainEvent(new OnGarmentComodityPricePlaced(Identity));
        }
        public GarmentSubconCutting(Guid identity, string roNo, SizeId sizeId, string sizeName, double quantity, ProductId productId, string productCode, string productName, GarmentComodityId comodityId, string comodityCode, string comodityName, string designColor, string remark, double basicPrice) : base(identity)
        {
            RONo         = roNo;
            SizeId       = sizeId;
            SizeName     = sizeName;
            Quantity     = quantity;
            ProductId    = productId;
            ProductCode  = productCode;
            ProductName  = productName;
            ComodityId   = comodityId;
            ComodityName = comodityName;
            ComodityCode = comodityCode;
            DesignColor  = designColor;
            Remark       = remark;
            BasicPrice   = basicPrice;

            ReadModel = new GarmentSubconCuttingReadModel(Identity)
            {
                RONo         = RONo,
                SizeId       = SizeId.Value,
                SizeName     = SizeName,
                Quantity     = Quantity,
                ProductId    = ProductId.Value,
                ProductCode  = ProductCode,
                ProductName  = ProductName,
                ComodityId   = ComodityId.Value,
                ComodityName = ComodityName,
                ComodityCode = ComodityCode,
                DesignColor  = DesignColor,
                Remark       = Remark,
                BasicPrice   = BasicPrice
            };

            ReadModel.AddDomainEvent(new OnGarmentSubconCuttingPlaced(Identity));
        }
 public GarmentFinishedGoodStockHistory(GarmentFinishedGoodStockHistoryReadModel readModel) : base(readModel)
 {
     FinishedGoodStockId         = readModel.FinishedGoodStockId;
     FinishingOutItemId          = readModel.FinishingOutItemId;
     FinishingOutDetailId        = readModel.FinishingOutDetailId;
     ExpenditureGoodId           = readModel.ExpenditureGoodId;
     ExpenditureGoodItemId       = readModel.ExpenditureGoodItemId;
     AdjustmentItemId            = readModel.AdjustmentItemId;
     AdjustmentId                = readModel.AdjustmentId;
     ExpenditureGoodReturnId     = readModel.ExpenditureGoodReturnId;
     ExpenditureGoodReturnItemId = readModel.ExpenditureGoodReturnItemId;
     StockType    = readModel.StockType;
     RONo         = readModel.RONo;
     Article      = readModel.Article;
     UnitId       = new UnitDepartmentId(readModel.UnitId);
     UnitCode     = readModel.UnitCode;
     UnitName     = readModel.UnitName;
     ComodityId   = new GarmentComodityId(readModel.ComodityId);
     ComodityCode = readModel.ComodityCode;
     ComodityName = readModel.ComodityName;
     SizeId       = new SizeId(readModel.SizeId);
     SizeName     = readModel.SizeName;
     Quantity     = readModel.Quantity;
     UomUnit      = readModel.UomUnit;
     UomId        = new UomId(readModel.UomId);
     BasicPrice   = readModel.BasicPrice;
     Price        = readModel.Price;
 }
Exemplo n.º 5
0
 public GarmentComodityPrice(GarmentComodityPriceReadModel readModel) : base(readModel)
 {
     IsValid      = readModel.IsValid;
     UnitId       = new UnitDepartmentId(readModel.UnitId);;
     UnitCode     = readModel.UnitCode;
     UnitName     = readModel.UnitName;
     Date         = readModel.Date;
     ComodityId   = new GarmentComodityId(readModel.ComodityId);
     ComodityCode = readModel.ComodityCode;
     ComodityName = readModel.ComodityName;
     Price        = readModel.Price;
 }
        public GarmentSewingOut(Guid identity, string sewingOutNo, BuyerId buyerId, string buyerCode, string buyerName, UnitDepartmentId unitToId, string unitToCode, string unitToName, string sewingTo, DateTimeOffset sewingOutDate, string rONo, string article, UnitDepartmentId unitId, string unitCode, string unitName, GarmentComodityId comodityId, string comodityCode, string comodityName, bool isDifferentSize) : base(identity)
        {
            Validator.ThrowIfNull(() => unitId);
            Validator.ThrowIfNull(() => unitToId);
            Validator.ThrowIfNull(() => rONo);

            //MarkTransient();

            Identity        = identity;
            SewingOutNo     = sewingOutNo;
            SewingTo        = sewingTo;
            UnitToId        = unitToId;
            UnitToCode      = unitToCode;
            UnitToName      = unitToName;
            SewingOutDate   = sewingOutDate;
            RONo            = rONo;
            Article         = article;
            UnitId          = unitId;
            UnitCode        = unitCode;
            UnitName        = unitName;
            ComodityId      = comodityId;
            ComodityCode    = comodityCode;
            ComodityName    = comodityName;
            BuyerCode       = buyerCode;
            BuyerId         = buyerId;
            BuyerName       = buyerName;
            IsDifferentSize = isDifferentSize;

            ReadModel = new GarmentSewingOutReadModel(Identity)
            {
                SewingOutNo     = SewingOutNo,
                SewingTo        = SewingTo,
                UnitToId        = UnitToId.Value,
                UnitToCode      = UnitToCode,
                UnitToName      = UnitToName,
                SewingOutDate   = SewingOutDate,
                RONo            = RONo,
                Article         = Article,
                UnitId          = UnitId.Value,
                UnitCode        = UnitCode,
                UnitName        = UnitName,
                ComodityId      = ComodityId.Value,
                ComodityCode    = ComodityCode,
                ComodityName    = ComodityName,
                BuyerCode       = BuyerCode,
                BuyerId         = BuyerId.Value,
                BuyerName       = BuyerName,
                IsDifferentSize = IsDifferentSize,
            };

            ReadModel.AddDomainEvent(new OnGarmentSewingOutPlaced(Identity));
        }
        public GarmentExpenditureGood(Guid identity, string expenditureGoodNo, string expenditureType, UnitDepartmentId unitId, string unitCode, string unitName, string rONo, string article, GarmentComodityId comodityId, string comodityCode, string comodityName, BuyerId buyerId, string buyerCode, string buyerName, DateTimeOffset expenditureDate, string invoice, string contractNo, double carton, string description, bool isReceived) : base(identity)
        {
            Validator.ThrowIfNull(() => unitId);

            //MarkTransient();
            ExpenditureGoodNo = expenditureGoodNo;
            Identity          = identity;
            ExpenditureType   = expenditureType;
            UnitId            = unitId;
            UnitCode          = unitCode;
            UnitName          = unitName;
            RONo            = rONo;
            Article         = article;
            ComodityId      = comodityId;
            ComodityCode    = comodityCode;
            ComodityName    = comodityName;
            BuyerId         = buyerId;
            BuyerCode       = buyerCode;
            BuyerName       = buyerName;
            ExpenditureDate = expenditureDate;
            Invoice         = invoice;
            ContractNo      = contractNo;
            Carton          = carton;
            Description     = description;
            IsReceived      = isReceived;

            ReadModel = new GarmentExpenditureGoodReadModel(Identity)
            {
                ExpenditureGoodNo = ExpenditureGoodNo,
                ExpenditureType   = ExpenditureType,
                ExpenditureDate   = ExpenditureDate,
                RONo         = RONo,
                Article      = Article,
                UnitId       = UnitId.Value,
                UnitCode     = UnitCode,
                UnitName     = UnitName,
                BuyerCode    = BuyerCode,
                BuyerName    = BuyerName,
                BuyerId      = BuyerId.Value,
                ComodityId   = ComodityId.Value,
                ComodityCode = ComodityCode,
                ComodityName = ComodityName,
                Invoice      = Invoice,
                ContractNo   = ContractNo,
                Carton       = Carton,
                Description  = Description,
                IsReceived   = IsReceived
            };

            ReadModel.AddDomainEvent(new OnGarmentExpenditureGoodPlaced(Identity));
        }
Exemplo n.º 8
0
 public GarmentAvalComponent(GarmentAvalComponentReadModel readModel) : base(readModel)
 {
     AvalComponentNo   = readModel.AvalComponentNo;
     UnitId            = new UnitDepartmentId((int)readModel.UnitId);
     UnitCode          = readModel.UnitCode;
     UnitName          = readModel.UnitName;
     AvalComponentType = readModel.AvalComponentType;
     RONo         = readModel.RONo;
     Article      = readModel.Article;
     ComodityId   = new GarmentComodityId((int)readModel.ComodityId);
     ComodityCode = readModel.ComodityCode;
     ComodityName = readModel.ComodityName;
     Date         = readModel.Date;
 }
Exemplo n.º 9
0
 public GarmentAdjustment(GarmentAdjustmentReadModel readModel) : base(readModel)
 {
     AdjustmentNo   = readModel.AdjustmentNo;
     AdjustmentType = readModel.AdjustmentType;
     RONo           = readModel.RONo;
     Article        = readModel.Article;
     UnitId         = new UnitDepartmentId(readModel.UnitId);
     UnitCode       = readModel.UnitCode;
     UnitName       = readModel.UnitName;
     ComodityId     = new GarmentComodityId(readModel.ComodityId);
     ComodityName   = readModel.ComodityName;
     ComodityCode   = readModel.ComodityCode;
     AdjustmentDate = readModel.AdjustmentDate;
     AdjustmentDesc = readModel.AdjustmentDesc;
 }
Exemplo n.º 10
0
        public GarmentFinishedGoodStock(Guid identity, string finishedGoodStockNo, string rONo, string article, UnitDepartmentId unitId, string unitCode, string unitName, GarmentComodityId comodityId, string comodityCode, string comodityName, SizeId sizeId, string sizeName, UomId uomId, string uomUnit, double quantity, double basicPrice, double price) : base(identity)
        {
            Validator.ThrowIfNull(() => unitId);
            Validator.ThrowIfNull(() => rONo);

            //MarkTransient();

            Identity            = identity;
            FinishedGoodStockNo = finishedGoodStockNo;
            RONo         = rONo;
            Article      = article;
            UnitId       = unitId;
            UnitCode     = unitCode;
            UnitName     = unitName;
            ComodityId   = comodityId;
            ComodityCode = comodityCode;
            ComodityName = comodityName;
            SizeId       = sizeId;
            SizeName     = sizeName;
            Quantity     = quantity;
            UomId        = uomId;
            UomUnit      = uomUnit;
            BasicPrice   = basicPrice;
            Price        = price;

            ReadModel = new GarmentFinishedGoodStockReadModel(Identity)
            {
                FinishedGoodStockNo = FinishedGoodStockNo,
                RONo         = RONo,
                Article      = Article,
                UnitId       = UnitId.Value,
                UnitCode     = UnitCode,
                UnitName     = UnitName,
                ComodityId   = ComodityId.Value,
                ComodityCode = ComodityCode,
                ComodityName = ComodityName,
                SizeId       = SizeId.Value,
                SizeName     = SizeName,
                Quantity     = Quantity,
                UomId        = UomId.Value,
                UomUnit      = UomUnit,
                BasicPrice   = BasicPrice,
                Price        = Price
            };

            ReadModel.AddDomainEvent(new OnGarmentFinishedGoodStockPlaced(Identity));
        }
Exemplo n.º 11
0
 public GarmentCuttingOut(GarmentCuttingOutReadModel readModel) : base(readModel)
 {
     CutOutNo       = readModel.CutOutNo;
     CuttingOutType = readModel.CuttingOutType;
     UnitFromId     = new UnitDepartmentId(readModel.UnitFromId);
     UnitFromCode   = readModel.UnitFromCode;
     UnitFromName   = readModel.UnitFromName;
     CuttingOutDate = readModel.CuttingOutDate;
     RONo           = readModel.RONo;
     Article        = readModel.Article;
     UnitId         = new UnitDepartmentId(readModel.UnitId);
     UnitCode       = readModel.UnitCode;
     UnitName       = readModel.UnitName;
     ComodityId     = new GarmentComodityId(readModel.ComodityId);
     ComodityCode   = ReadModel.ComodityCode;
     ComodityName   = ReadModel.ComodityName;
 }
Exemplo n.º 12
0
 public GarmentSewingDO(GarmentSewingDOReadModel readModel) : base(readModel)
 {
     SewingDONo   = readModel.SewingDONo;
     CuttingOutId = readModel.CuttingOutId;
     UnitFromId   = new UnitDepartmentId(readModel.UnitFromId);
     UnitFromCode = readModel.UnitFromCode;
     UnitFromName = readModel.UnitFromName;
     UnitId       = new UnitDepartmentId(readModel.UnitId);
     UnitCode     = readModel.UnitCode;
     UnitName     = readModel.UnitName;
     RONo         = readModel.RONo;
     Article      = readModel.Article;
     ComodityId   = new GarmentComodityId(readModel.ComodityId);
     ComodityCode = readModel.ComodityCode;
     ComodityName = readModel.ComodityName;
     SewingDODate = readModel.SewingDODate;
 }
 public GarmentSubconCutting(GarmentSubconCuttingReadModel readModel) : base(readModel)
 {
     RONo                = readModel.RONo;
     SizeId              = new SizeId(readModel.SizeId);
     SizeName            = readModel.SizeName;
     Quantity            = readModel.Quantity;
     FinishingInQuantity = readModel.FinishingInQuantity;
     ProductId           = new ProductId(readModel.ProductId);
     ProductCode         = readModel.ProductCode;
     ProductName         = readModel.ProductName;
     ComodityId          = new GarmentComodityId(readModel.ComodityId);
     ComodityName        = readModel.ComodityName;
     ComodityCode        = readModel.ComodityCode;
     DesignColor         = readModel.DesignColor;
     Remark              = readModel.Remark;
     BasicPrice          = readModel.BasicPrice;
 }
Exemplo n.º 14
0
 public GarmentSubconCuttingOut(GarmentCuttingOutReadModel readModel) : base(readModel)
 {
     CutOutNo       = readModel.CutOutNo;
     CuttingOutType = readModel.CuttingOutType;
     UnitFromId     = new UnitDepartmentId(readModel.UnitFromId);
     UnitFromCode   = readModel.UnitFromCode;
     UnitFromName   = readModel.UnitFromName;
     CuttingOutDate = readModel.CuttingOutDate;
     RONo           = readModel.RONo;
     Article        = readModel.Article;
     ComodityId     = new GarmentComodityId(readModel.ComodityId);
     ComodityCode   = ReadModel.ComodityCode;
     ComodityName   = ReadModel.ComodityName;
     EPOId          = readModel.EPOId;
     EPOItemId      = readModel.EPOItemId;
     POSerialNumber = readModel.POSerialNumber;
 }
        public GarmentFinishingIn(Guid identity, string finishingInNo, string finishingInType, UnitDepartmentId unitFromId, string unitFromCode, string unitFromName, string rONo, string article, UnitDepartmentId unitId, string unitCode, string unitName, DateTimeOffset finishingInDate, GarmentComodityId comodityId, string comodityCode, string comodityName, long doId, string doNo) : base(identity)
        {
            Validator.ThrowIfNull(() => unitId);

            //MarkTransient();
            FinishingInNo   = finishingInNo;
            Identity        = identity;
            FinishingInType = finishingInType;
            UnitFromCode    = unitFromCode;
            UnitFromName    = unitFromName;
            UnitFromId      = unitFromId;
            RONo            = rONo;
            Article         = article;
            UnitId          = unitId;
            UnitCode        = unitCode;
            UnitName        = unitName;
            ComodityId      = comodityId;
            FinishingInDate = finishingInDate;
            ComodityCode    = comodityCode;
            ComodityName    = comodityName;
            DOId            = doId;
            DONo            = doNo;

            ReadModel = new GarmentFinishingInReadModel(Identity)
            {
                FinishingInDate = FinishingInDate,
                FinishingInNo   = FinishingInNo,
                FinishingInType = FinishingInType,
                RONo            = RONo,
                Article         = Article,
                UnitId          = UnitId.Value,
                UnitCode        = UnitCode,
                UnitName        = UnitName,
                UnitFromCode    = UnitFromCode,
                UnitFromName    = UnitFromName,
                UnitFromId      = UnitFromId.Value,
                ComodityId      = ComodityId.Value,
                ComodityCode    = ComodityCode,
                ComodityName    = ComodityName,
                DOId            = DOId,
                DONo            = DONo
            };

            ReadModel.AddDomainEvent(new OnGarmentFinishingInPlaced(Identity));
        }
        public GarmentExpenditureGoodReturn(Guid identity, string returNo, string returType, UnitDepartmentId unitId, string unitCode, string unitName, string rONo, string article, GarmentComodityId comodityId, string comodityCode, string comodityName, BuyerId buyerId, string buyerCode, string buyerName, DateTimeOffset returDate, string invoice, string returDesc) : base(identity)
        {
            Validator.ThrowIfNull(() => unitId);

            //MarkTransient();
            ReturNo      = returNo;
            Identity     = identity;
            ReturType    = returType;
            UnitId       = unitId;
            UnitCode     = unitCode;
            UnitName     = unitName;
            RONo         = rONo;
            Article      = article;
            ComodityId   = comodityId;
            ComodityCode = comodityCode;
            ComodityName = comodityName;
            BuyerId      = buyerId;
            BuyerCode    = buyerCode;
            BuyerName    = buyerName;
            ReturDate    = returDate;
            Invoice      = invoice;
            ReturDesc    = returDesc;

            ReadModel = new GarmentExpenditureGoodReturnReadModel(Identity)
            {
                ReturNo      = ReturNo,
                ReturType    = ReturType,
                ReturDate    = ReturDate,
                RONo         = RONo,
                Article      = Article,
                UnitId       = UnitId.Value,
                UnitCode     = UnitCode,
                UnitName     = UnitName,
                BuyerCode    = BuyerCode,
                BuyerName    = BuyerName,
                BuyerId      = BuyerId.Value,
                ComodityId   = ComodityId.Value,
                ComodityCode = ComodityCode,
                ComodityName = ComodityName,
                Invoice      = Invoice,
                ReturDesc    = ReturDesc
            };

            ReadModel.AddDomainEvent(new OnGarmentExpenditureGoodReturnPlaced(Identity));
        }
Exemplo n.º 17
0
 public GarmentLoading(GarmentLoadingReadModel readModel) : base(readModel)
 {
     LoadingNo    = readModel.LoadingNo;
     RONo         = readModel.RONo;
     Article      = readModel.Article;
     UnitId       = new UnitDepartmentId(readModel.UnitId);
     UnitCode     = readModel.UnitCode;
     UnitName     = readModel.UnitName;
     SewingDOId   = readModel.SewingDOId;
     SewingDONo   = readModel.SewingDONo;
     UnitFromCode = readModel.UnitFromCode;
     UnitFromName = readModel.UnitFromName;
     UnitFromId   = new UnitDepartmentId(readModel.UnitFromId);
     ComodityId   = new GarmentComodityId(readModel.ComodityId);
     ComodityName = readModel.ComodityName;
     ComodityCode = readModel.ComodityCode;
     LoadingDate  = readModel.LoadingDate;
 }
Exemplo n.º 18
0
 public GarmentFinishingOut(GarmentFinishingOutReadModel readModel) : base(readModel)
 {
     FinishingOutNo   = readModel.FinishingOutNo;
     FinishingTo      = readModel.FinishingTo;
     UnitToId         = new UnitDepartmentId(readModel.UnitToId);
     UnitToCode       = readModel.UnitToCode;
     UnitToName       = readModel.UnitToName;
     FinishingOutDate = readModel.FinishingOutDate;
     RONo             = readModel.RONo;
     Article          = readModel.Article;
     UnitId           = new UnitDepartmentId(readModel.UnitId);
     UnitCode         = readModel.UnitCode;
     UnitName         = readModel.UnitName;
     ComodityId       = new GarmentComodityId(readModel.ComodityId);
     ComodityCode     = readModel.ComodityCode;
     ComodityName     = readModel.ComodityName;
     IsDifferentSize  = readModel.IsDifferentSize;
 }
Exemplo n.º 19
0
        public GarmentLoading(Guid identity, string loadingNo, Guid sewingDOId, string sewingDONo, UnitDepartmentId unitFromId, string unitFromCode, string unitFromName, string rONo, string article, UnitDepartmentId unitId, string unitCode, string unitName, DateTimeOffset loadingDate, GarmentComodityId comodityId, string comodityCode, string comodityName) : base(identity)
        {
            Validator.ThrowIfNull(() => unitId);
            //Validator.ThrowIfNull(() => sewingDOId);

            //MarkTransient();
            LoadingNo    = loadingNo;
            Identity     = identity;
            SewingDOId   = sewingDOId;
            SewingDONo   = sewingDONo;
            UnitFromCode = unitFromCode;
            UnitFromName = unitFromName;
            UnitFromId   = unitFromId;
            RONo         = rONo;
            Article      = article;
            UnitId       = unitId;
            UnitCode     = unitCode;
            UnitName     = unitName;
            ComodityId   = comodityId;
            LoadingDate  = loadingDate;
            ComodityCode = comodityCode;
            ComodityName = comodityName;

            ReadModel = new GarmentLoadingReadModel(Identity)
            {
                LoadingDate  = LoadingDate,
                LoadingNo    = LoadingNo,
                RONo         = RONo,
                Article      = Article,
                UnitId       = UnitId.Value,
                UnitCode     = UnitCode,
                UnitName     = UnitName,
                SewingDOId   = SewingDOId,
                SewingDONo   = SewingDONo,
                UnitFromCode = UnitFromCode,
                UnitFromName = UnitFromName,
                UnitFromId   = UnitFromId.Value,
                ComodityId   = ComodityId.Value,
                ComodityCode = ComodityCode,
                ComodityName = ComodityName
            };

            ReadModel.AddDomainEvent(new OnGarmentLoadingPlaced(Identity));
        }
Exemplo n.º 20
0
        public GarmentCuttingOut(Guid identity, string cutOutNo, string cuttingOutType, UnitDepartmentId unitFromId, string unitFromCode, string unitFromName, DateTimeOffset cuttingOutDate, string rONo, string article, UnitDepartmentId unitId, string unitCode, string unitName, GarmentComodityId comodityId, string comodityCode, string comodityName) : base(identity)
        {
            Validator.ThrowIfNull(() => unitFromId);
            Validator.ThrowIfNull(() => unitId);
            Validator.ThrowIfNull(() => rONo);

            //MarkTransient();

            Identity       = identity;
            CutOutNo       = cutOutNo;
            CuttingOutType = cuttingOutType;
            UnitFromId     = unitFromId;
            UnitFromCode   = unitFromCode;
            UnitFromName   = unitFromName;
            CuttingOutDate = cuttingOutDate;
            RONo           = rONo;
            Article        = article;
            UnitId         = unitId;
            UnitCode       = unitCode;
            UnitName       = unitName;
            ComodityId     = comodityId;
            ComodityCode   = comodityCode;
            ComodityName   = comodityName;

            ReadModel = new GarmentCuttingOutReadModel(Identity)
            {
                CutOutNo       = CutOutNo,
                CuttingOutType = CuttingOutType,
                UnitFromId     = UnitFromId.Value,
                UnitFromCode   = UnitFromCode,
                UnitFromName   = UnitFromName,
                CuttingOutDate = CuttingOutDate,
                RONo           = RONo,
                Article        = Article,
                UnitId         = UnitId.Value,
                UnitCode       = UnitCode,
                UnitName       = UnitName,
                ComodityId     = ComodityId.Value,
                ComodityCode   = ComodityCode,
                ComodityName   = ComodityName,
            };

            ReadModel.AddDomainEvent(new OnGarmentCuttingOutPlaced(Identity));
        }
 public GarmentExpenditureGoodReturn(GarmentExpenditureGoodReturnReadModel readModel) : base(readModel)
 {
     ReturNo      = readModel.ReturNo;
     RONo         = readModel.RONo;
     Article      = readModel.Article;
     UnitId       = new UnitDepartmentId(readModel.UnitId);
     UnitCode     = readModel.UnitCode;
     UnitName     = readModel.UnitName;
     BuyerCode    = readModel.BuyerCode;
     BuyerName    = readModel.BuyerName;
     BuyerId      = new BuyerId(readModel.BuyerId);
     ComodityId   = new GarmentComodityId(readModel.ComodityId);
     ComodityName = readModel.ComodityName;
     ComodityCode = readModel.ComodityCode;
     ReturDate    = readModel.ReturDate;
     ReturType    = readModel.ReturType;
     Invoice      = readModel.Invoice;
     ReturDesc    = readModel.ReturDesc;
 }
Exemplo n.º 22
0
 public GarmentFinishedGoodStock(GarmentFinishedGoodStockReadModel readModel) : base(readModel)
 {
     FinishedGoodStockNo = readModel.FinishedGoodStockNo;
     RONo         = readModel.RONo;
     Article      = readModel.Article;
     UnitId       = new UnitDepartmentId(readModel.UnitId);
     UnitCode     = readModel.UnitCode;
     UnitName     = readModel.UnitName;
     ComodityId   = new GarmentComodityId(readModel.ComodityId);
     ComodityCode = readModel.ComodityCode;
     ComodityName = readModel.ComodityName;
     SizeId       = new SizeId(readModel.SizeId);
     SizeName     = readModel.SizeName;
     Quantity     = readModel.Quantity;
     UomUnit      = readModel.UomUnit;
     UomId        = new UomId(readModel.UomId);
     BasicPrice   = readModel.BasicPrice;
     Price        = readModel.Price;
 }
 public GarmentFinishingIn(GarmentFinishingInReadModel readModel) : base(readModel)
 {
     FinishingInNo   = readModel.FinishingInNo;
     RONo            = readModel.RONo;
     Article         = readModel.Article;
     UnitId          = new UnitDepartmentId(readModel.UnitId);
     UnitCode        = readModel.UnitCode;
     UnitName        = readModel.UnitName;
     UnitFromCode    = readModel.UnitFromCode;
     UnitFromName    = readModel.UnitFromName;
     UnitFromId      = new UnitDepartmentId(readModel.UnitFromId);
     ComodityId      = new GarmentComodityId(readModel.ComodityId);
     ComodityName    = readModel.ComodityName;
     ComodityCode    = readModel.ComodityCode;
     FinishingInDate = readModel.FinishingInDate;
     FinishingInType = readModel.FinishingInType;
     DOId            = readModel.DOId;
     DONo            = readModel.DONo;
 }
 public GarmentSewingIn(GarmentSewingInReadModel readModel) : base(readModel)
 {
     SewingInNo   = readModel.SewingInNo;
     SewingFrom   = readModel.SewingFrom;
     LoadingId    = readModel.LoadingId;
     LoadingNo    = readModel.LoadingNo;
     UnitFromId   = new UnitDepartmentId(readModel.UnitFromId);
     UnitFromCode = readModel.UnitFromCode;
     UnitFromName = readModel.UnitFromName;
     UnitId       = new UnitDepartmentId(readModel.UnitId);
     UnitCode     = readModel.UnitCode;
     UnitName     = readModel.UnitName;
     RONo         = readModel.RONo;
     Article      = readModel.Article;
     ComodityId   = new GarmentComodityId(readModel.ComodityId);
     ComodityCode = readModel.ComodityCode;
     ComodityName = readModel.ComodityName;
     SewingInDate = readModel.SewingInDate;
 }
        public GarmentSewingIn(Guid identity, string sewingInNo, string sewingFrom, Guid loadingId, string loadingNo, UnitDepartmentId unitFromId, string unitFromCode, string unitFromName, UnitDepartmentId unitId, string unitCode, string unitName, string roNo, string article, GarmentComodityId comodityId, string comodityCode, string comodityName, DateTimeOffset sewingInDate) : base(identity)
        {
            Identity     = identity;
            SewingInNo   = sewingInNo;
            SewingFrom   = sewingFrom;
            LoadingId    = loadingId;
            LoadingNo    = loadingNo;
            UnitFromId   = unitFromId;
            UnitFromCode = unitFromCode;
            UnitFromName = unitFromName;
            UnitId       = unitId;
            UnitCode     = unitCode;
            UnitName     = unitName;
            RONo         = roNo;
            Article      = article;
            ComodityId   = comodityId;
            ComodityCode = comodityCode;
            ComodityName = comodityName;
            SewingInDate = sewingInDate;

            ReadModel = new GarmentSewingInReadModel(Identity)
            {
                SewingInNo   = SewingInNo,
                SewingFrom   = SewingFrom,
                LoadingId    = LoadingId,
                LoadingNo    = LoadingNo,
                UnitFromId   = UnitFromId.Value,
                UnitFromCode = UnitFromCode,
                UnitFromName = UnitFromName,
                UnitId       = UnitId.Value,
                UnitCode     = UnitCode,
                UnitName     = UnitName,
                RONo         = RONo,
                Article      = Article,
                ComodityId   = ComodityId.Value,
                ComodityCode = ComodityCode,
                ComodityName = ComodityName,
                SewingInDate = SewingInDate
            };
            ReadModel.AddDomainEvent(new OnGarmentSewingInPlaced(Identity));
        }
 public GarmentSewingOut(GarmentSewingOutReadModel readModel) : base(readModel)
 {
     SewingOutNo     = readModel.SewingOutNo;
     SewingTo        = readModel.SewingTo;
     UnitToId        = new UnitDepartmentId(readModel.UnitToId);
     UnitToCode      = readModel.UnitToCode;
     UnitToName      = readModel.UnitToName;
     SewingOutDate   = readModel.SewingOutDate;
     RONo            = readModel.RONo;
     Article         = readModel.Article;
     UnitId          = new UnitDepartmentId(readModel.UnitId);
     UnitCode        = readModel.UnitCode;
     UnitName        = readModel.UnitName;
     ComodityId      = new GarmentComodityId(readModel.ComodityId);
     ComodityCode    = readModel.ComodityCode;
     ComodityName    = readModel.ComodityName;
     BuyerCode       = readModel.BuyerCode;
     BuyerId         = new BuyerId(readModel.BuyerId);
     BuyerName       = readModel.BuyerName;
     IsDifferentSize = readModel.IsDifferentSize;
 }
 public GarmentExpenditureGood(GarmentExpenditureGoodReadModel readModel) : base(readModel)
 {
     ExpenditureGoodNo = readModel.ExpenditureGoodNo;
     RONo            = readModel.RONo;
     Article         = readModel.Article;
     UnitId          = new UnitDepartmentId(readModel.UnitId);
     UnitCode        = readModel.UnitCode;
     UnitName        = readModel.UnitName;
     BuyerCode       = readModel.BuyerCode;
     BuyerName       = readModel.BuyerName;
     BuyerId         = new BuyerId(readModel.BuyerId);
     ComodityId      = new GarmentComodityId(readModel.ComodityId);
     ComodityName    = readModel.ComodityName;
     ComodityCode    = readModel.ComodityCode;
     ExpenditureDate = readModel.ExpenditureDate;
     ExpenditureType = readModel.ExpenditureType;
     Invoice         = readModel.Invoice;
     ContractNo      = readModel.ContractNo;
     Carton          = readModel.Carton;
     Description     = readModel.Description;
     IsReceived      = readModel.IsReceived;
 }
Exemplo n.º 28
0
        public GarmentAdjustment(Guid identity, string adjustmentNo, string adjustmentType, string rONo, string article, UnitDepartmentId unitId, string unitCode, string unitName, DateTimeOffset adjustmentDate, GarmentComodityId comodityId, string comodityCode, string comodityName, string adjustmentDesc) : base(identity)
        {
            Validator.ThrowIfNull(() => unitId);
            //MarkTransient();

            Identity       = identity;
            AdjustmentNo   = adjustmentNo;
            AdjustmentType = adjustmentType;
            RONo           = rONo;
            Article        = article;
            UnitId         = unitId;
            UnitCode       = unitCode;
            UnitName       = unitName;
            ComodityId     = comodityId;
            ComodityCode   = comodityCode;
            ComodityName   = comodityName;
            AdjustmentDate = adjustmentDate;
            AdjustmentDesc = adjustmentDesc;

            ReadModel = new GarmentAdjustmentReadModel(Identity)
            {
                AdjustmentDate = AdjustmentDate,
                AdjustmentNo   = AdjustmentNo,
                AdjustmentType = AdjustmentType,
                RONo           = RONo,
                Article        = Article,
                UnitId         = UnitId.Value,
                UnitCode       = UnitCode,
                UnitName       = UnitName,
                ComodityId     = ComodityId.Value,
                ComodityCode   = ComodityCode,
                ComodityName   = ComodityName,
                AdjustmentDesc = AdjustmentDesc
            };

            ReadModel.AddDomainEvent(new OnGarmentAdjustmentPlaced(Identity));
        }
Exemplo n.º 29
0
        public GarmentSewingDO(Guid identity, string sewingDONo, Guid cuttingOutId, UnitDepartmentId unitFromId, string unitFromCode, string unitFromName, UnitDepartmentId unitId, string unitCode, string unitName, string roNo, string article, GarmentComodityId comodityId, string comodityCode, string comodityName, DateTimeOffset sewingDODate) : base(identity)
        {
            Identity     = identity;
            SewingDONo   = sewingDONo;
            CuttingOutId = cuttingOutId;
            UnitFromId   = unitFromId;
            UnitFromCode = unitFromCode;
            UnitFromName = unitFromName;
            UnitId       = unitId;
            UnitCode     = unitCode;
            UnitName     = unitName;
            RONo         = roNo;
            Article      = article;
            ComodityId   = comodityId;
            ComodityCode = comodityCode;
            ComodityName = comodityName;
            SewingDODate = sewingDODate;

            ReadModel = new GarmentSewingDOReadModel(Identity)
            {
                SewingDONo   = SewingDONo,
                CuttingOutId = CuttingOutId,
                UnitFromId   = UnitFromId.Value,
                UnitFromCode = UnitFromCode,
                UnitFromName = UnitFromName,
                UnitId       = UnitId.Value,
                UnitCode     = UnitCode,
                UnitName     = UnitName,
                RONo         = RONo,
                Article      = Article,
                ComodityId   = ComodityId.Value,
                ComodityCode = ComodityCode,
                ComodityName = ComodityName,
                SewingDODate = SewingDODate
            };
            ReadModel.AddDomainEvent(new OnGarmentSewingDOPlaced(Identity));
        }
        public GarmentFinishedGoodStockHistory(Guid identity, Guid finishedGoodStockId, Guid finishingOutItemId, Guid finishingOutDetailId, Guid expenditureGoodId, Guid expenditureGoodItemId, Guid adjustmentId, Guid adjustmentItemId, Guid expenditureGoodReturnId, Guid expenditureGoodReturnItemId, string stockType, string rONo, string article, UnitDepartmentId unitId, string unitCode, string unitName, GarmentComodityId comodityId, string comodityCode, string comodityName, SizeId sizeId, string sizeName, UomId uomId, string uomUnit, double quantity, double basicPrice, double price) : base(identity)
        {
            Validator.ThrowIfNull(() => unitId);
            Validator.ThrowIfNull(() => rONo);

            //MarkTransient();

            Identity                    = identity;
            FinishedGoodStockId         = finishedGoodStockId;
            FinishingOutItemId          = finishingOutItemId;
            FinishingOutDetailId        = finishingOutDetailId;
            ExpenditureGoodId           = expenditureGoodId;
            ExpenditureGoodItemId       = expenditureGoodItemId;
            ExpenditureGoodReturnId     = expenditureGoodReturnId;
            ExpenditureGoodReturnItemId = expenditureGoodReturnItemId;
            AdjustmentId                = adjustmentId;
            AdjustmentItemId            = adjustmentItemId;
            StockType                   = stockType;
            RONo         = rONo;
            Article      = article;
            UnitId       = unitId;
            UnitCode     = unitCode;
            UnitName     = unitName;
            ComodityId   = comodityId;
            ComodityCode = comodityCode;
            ComodityName = comodityName;
            SizeId       = sizeId;
            SizeName     = sizeName;
            Quantity     = quantity;
            UomId        = uomId;
            UomUnit      = uomUnit;
            BasicPrice   = basicPrice;
            Price        = price;

            ReadModel = new GarmentFinishedGoodStockHistoryReadModel(Identity)
            {
                FinishedGoodStockId         = FinishedGoodStockId,
                FinishingOutItemId          = FinishingOutItemId,
                FinishingOutDetailId        = FinishingOutDetailId,
                ExpenditureGoodId           = ExpenditureGoodId,
                ExpenditureGoodItemId       = ExpenditureGoodItemId,
                ExpenditureGoodReturnId     = ExpenditureGoodReturnId,
                ExpenditureGoodReturnItemId = ExpenditureGoodReturnItemId,
                AdjustmentId     = AdjustmentId,
                AdjustmentItemId = AdjustmentItemId,
                StockType        = StockType,
                RONo             = RONo,
                Article          = Article,
                UnitId           = UnitId.Value,
                UnitCode         = UnitCode,
                UnitName         = UnitName,
                ComodityId       = ComodityId.Value,
                ComodityCode     = ComodityCode,
                ComodityName     = ComodityName,
                SizeId           = SizeId.Value,
                SizeName         = SizeName,
                Quantity         = Quantity,
                UomId            = UomId.Value,
                UomUnit          = UomUnit,
                BasicPrice       = BasicPrice,
                Price            = Price
            };

            ReadModel.AddDomainEvent(new OnGarmentFinishedGoodStockHistoryPlaced(Identity));
        }