private async void Button_Click(object sender, RoutedEventArgs e)
        {
            if (String.IsNullOrWhiteSpace(_originalDistrictCountText))
            {
                _originalDistrictCountText = districtCount_lbl.Text;
            }
            var districtTotalCount = await _districtService.GetDistrictCount();

            districtCount_lbl.Text = _originalDistrictCountText + districtTotalCount.Content.ToString();

            var response = await _districtService.GetAllDistricts();

            if (response.HttpResponse == HttpStatusCode.OK)
            {
                _districts = response.Content;
                CreateDistrictButtons(response.Content);
            }
        }
Esempio n. 2
0
 public List <DistrictModel> Get()
 {
     return(DistrictService.GetAllDistricts(dbConn));
 }