private IList <ScopeType> GetScope() { if (string.IsNullOrEmpty(RegionId)) { throw new Exception(); } return(ScopeService.Init().ScopeCollection.FindAll(m => m.RegionId == this.RegionId)); }
private City GetCity() { RegionType regionType = ScopeService.Init().RegionCollection.Find(m => m.RegionId == this.RegionId); this.CityId = regionType.CityId; this.RegionName = regionType.RegionName; return(new City(regionType.CityId)); }
private Region GetRegion() { ScopeType scopeType = ScopeService.Init().ScopeCollection.Find(m => m.ScopeId == this.ScopeId); this.RegionId = scopeType.RegionId; this.ScopeName = scopeType.ScopeName; return(new Region(scopeType.RegionId)); }
private IList <RegionType> GetRegion() { try { if (string.IsNullOrEmpty(this.CityName)) { throw new Exception(); } return(ScopeService.Init().RegionCollection.FindAll(m => m.CityId == this.CityId)); } catch (Exception ex) { throw ex; } }
public City(string cityId) { this.CityId = cityId; this.CityName = ScopeService.Init().CityCollection.Find(m => m.CityId == this.CityId).CityName; }