Ejemplo n.º 1
0
        private void AddAddProduceLineItemCommandToExecute(ActivityProduceItem item)
        {
            if (item == null) return;

            var cmd = new AddActivityProduceLineItemCommand();

            cmd.CommandCreatedDateTime = DateTime.Now;
            cmd.CommandGeneratedByCostCentreApplicationId = DocumentIssuerCostCentreApplicationId;
            cmd.CommandGeneratedByCostCentreId = FieldClerk.Id;
            cmd.CommandId = Guid.NewGuid();
            cmd.DocumentId = Id;
            cmd.CommodityId = item.Commodity.Id;
            cmd.GradeId = item.Grade.Id;
            cmd.Weight = item.Weight;
            cmd.ServiceProviderId = item.ServiceProvider.Id;
            cmd.Description = item.Description;
            cmd.LineItemId = item.Id;
            cmd.Description = item.Description;
            _AddCommand(cmd);
        }
Ejemplo n.º 2
0
 public void Add(ActivityProduceItem item)
 {
     _activityProduceItems.Add(item);
     AddAddProduceLineItemCommandToExecute(item);
 }