Ejemplo n.º 1
0
        public static InventoryModel ToModel(InventoryRepository.InventoryModel repositoryModel)
        {
            var inventoryModel = new InventoryModel
            {
                ID          = repositoryModel.ID,
                ItemN       = repositoryModel.ItemN,
                Description = repositoryModel.Description,
                Price       = repositoryModel.Price,
                QntyOnHand  = repositoryModel.QntyOnHand,
                SelfCost    = repositoryModel.SelfCost,
                TotalValue  = repositoryModel.TotalValue
            };

            return(inventoryModel);
        }
Ejemplo n.º 2
0
        public InventoryRepository.InventoryModel ToRepositoryModel()
        {
            var repositoryModel = new InventoryRepository.InventoryModel
            {
                ID          = ID,
                ItemN       = ItemN,
                Description = Description,
                Price       = Price,
                QntyOnHand  = QntyOnHand,
                SelfCost    = SelfCost,
                TotalValue  = TotalValue
            };

            return(repositoryModel);
        }