private Dictionary <Type, List <EntityInfo> > AddOrder(Dictionary <Type, List <EntityInfo> > saveMap)
        {
            var order = new Order();

            order.OrderDate = DateTime.Today;
            var ei = ContextProvider.CreateEntityInfo(order);
            List <EntityInfo> orderInfos = ContextProvider.GetEntityInfos(saveMap, typeof(Order));

            orderInfos.Add(ei);

            return(saveMap);
        }
Beispiel #2
0
        private Dictionary <Type, List <EntityInfo> > AddOrder(Dictionary <Type, List <EntityInfo> > saveMap)
        {
            var order = new Order();

            order.OrderDate = DateTime.Today;
            var ei = ContextProvider.CreateEntityInfo(order);
            List <EntityInfo> orderInfos;

            if (!saveMap.TryGetValue(typeof(Order), out orderInfos))
            {
                orderInfos = new List <EntityInfo>();
                saveMap.Add(typeof(Order), orderInfos);
            }
            orderInfos.Add(ei);

            return(saveMap);
        }