public string Execute(string json) { bool connect = false; //组建参数字典 Dictionary <string, string> Para = new Dictionary <string, string>(); Para.Add("corpid", ShareData.qyCorpID); Para.Add("corpsecret", ShareData.qySecret); string path = RequestPath.CreatePathqy(RequestType.qyaccess_token); RPGetaccess_token tokenInfo = HTMLHelper.Get <RPGetaccess_token>(path, Para, ref connect); if (tokenInfo != null) { ShareData.qyaccess_token = tokenInfo.access_token; } return(""); }
public string Execute(string type) { bool connect = false; string path = string.Empty; try { //组建参数字典 Dictionary <string, string> Para = new Dictionary <string, string>(); Para.Add("access_token", ShareData.qyaccess_token); path = RequestPath.CreatePathqy(RequestType.Ip_list); RPGetIp_list IpListInfo = HTMLHelper.Get <RPGetIp_list>(path, Para, ref connect); if (IpListInfo == null || IpListInfo.errcode != null) { //重新请求access_token new qyGetAccess_token().Execute(""); } } catch (Exception ex) { TracingHelper.Error(ex, typeof(GetIp_list), path + ex.ToString()); } return(""); }