|
|
@@ -15,6 +15,7 @@ import org.apache.http.util.EntityUtils;
|
|
|
|
|
|
import java.io.IOException;
|
|
|
import java.nio.charset.Charset;
|
|
|
+import java.util.HashMap;
|
|
|
import java.util.Map;
|
|
|
import java.util.Set;
|
|
|
|
|
|
@@ -101,5 +102,14 @@ public class HttpUtils {
|
|
|
return substring;
|
|
|
}
|
|
|
|
|
|
+ public static void main(String[] args) {
|
|
|
+// JSONObject jsonObject = httpGet("https://oapi.dingtalk.com/gettoken?appkey=dingdstdmazod2ghnj2y&appsecret=E4b_1VJaL1_m3hUr2D4vvoP3KzLQpHB5pibRmWRr8cwq28vLPbpgFUO4MuryH39n");
|
|
|
+// System.out.println(jsonObject.toJSONString());
|
|
|
+ //{"errcode":0,"access_token":"3c9596da886b366084a1e02a6683e2f9","errmsg":"ok","expires_in":7200}
|
|
|
+ Map<String ,Object >param=new HashMap<>();
|
|
|
+ param.put("userid","10086");
|
|
|
+ param.put("work_date","2024-03-01");
|
|
|
+ JSONObject jsonObject = httpPost("https://oapi.dingtalk.com/topapi/attendance/getupdatedata", param, 1);
|
|
|
|
|
|
+ }
|
|
|
}
|