Beispiel #1
0
        private async Task Search()
        {
            string responseResult   = string.Empty;
            string requestParamJson = string.Empty;

            EmployeeList.Clear();
            EmployeeList.AddRange(await ResourceService.GetInstance().GetResources <Employee>(), System.Collections.Specialized.NotifyCollectionChangedAction.Reset);
        }
Beispiel #2
0
        private Department CreateDepartment()
        {
            Employee employee1 = new Employee("John", "Developer", new DateTime(1980, 1, 1));
            Employee employee2 = new Employee("Peter", "Tester", new DateTime(1970, 1, 1));

            var employeeList = new EmployeeList();

            employeeList.AddRange(new[] { employee1, employee2 });

            var department = new Department("Technology", employeeList);

            return(department);
        }
Beispiel #3
0
        private async Task Search()
        {
            string responseResult   = string.Empty;
            string requestParamJson = string.Empty;

            Dictionary <string, string> requestDic = new Dictionary <string, string>();

            requestDic.Add("USP", "{? = call usp_get_emp_json(?)}"); //프로시저
            requestDic.Add("p_emp_nm", "");                          //프로시저 파라미터와 동일하게

            responseResult = await BaseHttpService.Instance.SendRequestAsync(HttpCommand.GET, requestDic);

            //EmployeeList = new ObservableCollection<Employee>(JsonConvert.DeserializeObject<List<Employee>>(responseResult));

            EmployeeList.Clear();
            EmployeeList.AddRange(JsonConvert.DeserializeObject <List <Employee> >(responseResult), System.Collections.Specialized.NotifyCollectionChangedAction.Reset);
        }