Exemplo n.º 1
0
        public void CreateGeoTypes(List <GeoTypeArg> geoTypeArgs)
        {
            var geoTypes = geoTypeArgs.Select(geoType => new GeoType {
                GeoTypeId = geoType.GeoTypeId, Description = geoType.Description, GeoTypePurposeId = geoType.GeoTypePurposeId
            }).ToList();

            _geoTypeRepository.AddRange(geoTypes);
        }
Exemplo n.º 2
0
        public void CreateGeoAssoces(List <GeoAssocArg> geoAssocArgs)
        {
            var geoAssoces = new List <GeoAssoc>();

            geoAssocArgs.ForEach(t => geoAssoces
                                 .Add(new GeoAssoc
            {
                GeoId          = t.GeoId,
                GeoIdTo        = t.GeoIdTo,
                GeoAssocTypeId = t.GeoAssocTypeId
            }));
            _geoAssocRepository.AddRange(geoAssoces);
        }