상속: IFeeds
 public static async Task<PeoInfo> GetPerson(string stunum_other)
 {
     var vault = new Windows.Security.Credentials.PasswordVault();
     var credentialList = vault.FindAllByResource(resourceName);
     credentialList[0].RetrievePassword();
     List<KeyValuePair<String, String>> paramList = new List<KeyValuePair<String, String>>();
     //paramList.Add(new KeyValuePair<string, string>("stuNum", appSetting.Values["stuNum"].ToString()));
     //paramList.Add(new KeyValuePair<string, string>("idNum", appSetting.Values["idNum"].ToString()));
     paramList.Add(new KeyValuePair<string, string>("stuNum", credentialList[0].UserName));
     paramList.Add(new KeyValuePair<string, string>("idNum", credentialList[0].Password));
     paramList.Add(new KeyValuePair<string, string>("stunum_other", stunum_other));
     string response = await NetWork.getHttpWebRequest(api, paramList);
     try
     {
         if (response != "" && response != "[]")
         {
             JObject bbddfeeds = JObject.Parse(response);
             if (bbddfeeds["status"].ToString() == "200")
             {
                 JObject feed = (JObject)bbddfeeds["data"];
                 PeoInfo f = new PeoInfo();
                 f.GetAttributes(feed);
                 return f;
             }
         }
     }
     catch (Exception) { }
     return null;
 }
예제 #2
0
 private void EditAppBarButton_Click(object sender, RoutedEventArgs e)
 {
     PeoInfo peoinfo = new PeoInfo(ViewModel.Info.nickname, ViewModel.Info.introduction, ViewModel.Info.phone, ViewModel.Info.qq);
     Frame.Navigate(typeof(SetPersonInfoPage), peoinfo);
 }