|
|
@@ -70,6 +70,8 @@ public class JdyTool
|
|
|
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+
|
|
|
//测试-调用金蝶云官方测试数据的凭证列表
|
|
|
public static String testGetVoucherList (String url,String accountId,String groupName)
|
|
|
{
|
|
|
@@ -88,6 +90,25 @@ public class JdyTool
|
|
|
return result.toJSONString();
|
|
|
}
|
|
|
|
|
|
+ public static List<checkitementry> testGetCheckitementryList(String token,String accountId,String groupName,String number)
|
|
|
+ {
|
|
|
+ String url="http://api.kingdee.com/jdy/gl/account_detail?access_token="+token;
|
|
|
+ HttpRequest httpRequest = new HttpRequest(url,"POST");
|
|
|
+ httpRequest.header("accountId",accountId);
|
|
|
+ httpRequest.header("groupName",groupName);
|
|
|
+ httpRequest.header("Content-Type","application/json");
|
|
|
+ JSONObject data = new JSONObject();
|
|
|
+ data.put("number",number);//科目的编码
|
|
|
+ httpRequest.send(data.toJSONString());
|
|
|
+ String body = httpRequest.body().toString();
|
|
|
+
|
|
|
+ //获取返回对象
|
|
|
+ accountDetailResponse accountDetailResponse = JSONObject.parseObject(body, accountDetailResponse.class);
|
|
|
+ List<checkitementry> checkitementryList = accountDetailResponse.data.checkitementry;
|
|
|
+ return checkitementryList;
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
public static List<Employee> testGetEmployeeList(String token,String accountId,String groupName,String search)
|
|
|
{
|
|
|
String url="http://api.kingdee.com/jdy/basedata/emp_list?access_token="+token;
|
|
|
@@ -111,6 +132,7 @@ public class JdyTool
|
|
|
}
|
|
|
|
|
|
|
|
|
+
|
|
|
public static List<Customer> testGetCustomerList(String token,String accountId,String groupName,String search)
|
|
|
{
|
|
|
String url="http://api.kingdee.com/jdy/basedata/customer_list?access_token="+token;
|
|
|
@@ -379,6 +401,34 @@ public class JdyTool
|
|
|
private String id;
|
|
|
}
|
|
|
|
|
|
+ @Data
|
|
|
+ public static class accountDetailResponse implements Serializable
|
|
|
+ {
|
|
|
+ private accountDetail data;
|
|
|
+ private String success;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Data
|
|
|
+ public static class accountDetail implements Serializable
|
|
|
+ {
|
|
|
+ private String name;
|
|
|
+ private String number;
|
|
|
+ private List<checkitementry> checkitementry;
|
|
|
+ }
|
|
|
+
|
|
|
+ @Data
|
|
|
+ public static class checkitementry implements Serializable
|
|
|
+ {
|
|
|
+ private String asstactitem_id;
|
|
|
+ private String bd_auxinfo_type_id;
|
|
|
+ private String asstactitem_name;
|
|
|
+ private String id;
|
|
|
+ private String isrequire;
|
|
|
+ private String type;
|
|
|
+ private String seq;
|
|
|
+ private String asstactitem_number;
|
|
|
+ }
|
|
|
+
|
|
|
|
|
|
|
|
|
|