private void BindForm() { var response = tutorService.GetActionResponse("TutorFilter"); if (response.IsSuccessStatusCode) { var tutori = response.Content.ReadAsAsync <List <Tutor_SearchSelect_Result> >().Result; TutorGridView.DataSource = tutori; TutorGridView.ClearSelection(); } }
private void TraziBtn_Click(object sender, EventArgs e) { string parametar = searchNameInput.Text.Trim() + '/' + GradoviCmb.SelectedValue.ToString() + '/' + PredmetCmb.SelectedValue.ToString(); if (String.IsNullOrEmpty(searchNameInput.Text)) { parametar = "Empty" + '/' + GradoviCmb.SelectedValue.ToString() + '/' + PredmetCmb.SelectedValue.ToString(); } var response = tutorService.GetActionResponse("TutorFilter", parametar); if (response.IsSuccessStatusCode) { var tutori = response.Content.ReadAsAsync <List <Tutor_SearchSelect_Result> >().Result; TutorGridView.DataSource = tutori; TutorGridView.ClearSelection(); } }