Skip to content

Commit

Permalink
Merge pull request #9 from Wechat-Group/develop
Browse files Browse the repository at this point in the history
更新成最新
  • Loading branch information
f00lish authored Nov 5, 2020
2 parents a2dd7f6 + b693c5f commit b290713
Show file tree
Hide file tree
Showing 49 changed files with 1,057 additions and 522 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.github.binarywang</groupId>
<artifactId>wx-java</artifactId>
<version>3.9.6.B</version>
<version>3.9.7.B</version>
<packaging>pom</packaging>
<name>WxJava - Weixin/Wechat Java SDK</name>
<description>微信开发Java SDK</description>
Expand Down
2 changes: 1 addition & 1 deletion spring-boot-starters/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.github.binarywang</groupId>
<artifactId>wx-java</artifactId>
<version>3.9.6.B</version>
<version>3.9.7.B</version>
</parent>
<packaging>pom</packaging>
<artifactId>wx-java-spring-boot-starters</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<artifactId>wx-java-spring-boot-starters</artifactId>
<groupId>com.github.binarywang</groupId>
<version>3.9.6.B</version>
<version>3.9.7.B</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<artifactId>wx-java-spring-boot-starters</artifactId>
<groupId>com.github.binarywang</groupId>
<version>3.9.6.B</version>
<version>3.9.7.B</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<artifactId>wx-java-spring-boot-starters</artifactId>
<groupId>com.github.binarywang</groupId>
<version>3.9.6.B</version>
<version>3.9.7.B</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<parent>
<artifactId>wx-java-spring-boot-starters</artifactId>
<groupId>com.github.binarywang</groupId>
<version>3.9.6.B</version>
<version>3.9.7.B</version>
</parent>
<modelVersion>4.0.0</modelVersion>

Expand Down
2 changes: 1 addition & 1 deletion weixin-graal/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.github.binarywang</groupId>
<artifactId>wx-java</artifactId>
<version>3.9.6.B</version>
<version>3.9.7.B</version>
</parent>

<artifactId>weixin-graal</artifactId>
Expand Down
2 changes: 1 addition & 1 deletion weixin-java-common/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<parent>
<groupId>com.github.binarywang</groupId>
<artifactId>wx-java</artifactId>
<version>3.9.6.B</version>
<version>3.9.7.B</version>
</parent>

<artifactId>weixin-java-common</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ public class WxMenuRule implements Serializable {
private String country;
private String province;
private String city;
@SerializedName("client_platform_type")
private String clientPlatformType;
private String language;

Expand Down
2 changes: 1 addition & 1 deletion weixin-java-cp/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>com.github.binarywang</groupId>
<artifactId>wx-java</artifactId>
<version>3.9.6.B</version>
<version>3.9.7.B</version>
</parent>

<artifactId>weixin-java-cp</artifactId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@
import me.chanjar.weixin.common.error.WxErrorException;
import me.chanjar.weixin.cp.bean.WxCpBaseResp;
import me.chanjar.weixin.cp.bean.external.*;
import me.chanjar.weixin.cp.bean.external.contact.WxCpExternalContactBatchInfo;
import me.chanjar.weixin.cp.bean.external.contact.WxCpExternalContactInfo;

import java.util.Date;
import java.util.List;
Expand Down Expand Up @@ -109,7 +111,7 @@ public interface WxCpExternalContactService {
* @deprecated 建议使用 {@link #getContactDetail(String)}
*/
@Deprecated
WxCpUserExternalContactInfo getExternalContact(String userId) throws WxErrorException;
WxCpExternalContactInfo getExternalContact(String userId) throws WxErrorException;

/**
* 获取客户详情.
Expand All @@ -130,7 +132,7 @@ public interface WxCpExternalContactService {
* @return . contact detail
* @throws WxErrorException .
*/
WxCpUserExternalContactInfo getContactDetail(String userId) throws WxErrorException;
WxCpExternalContactInfo getContactDetail(String userId) throws WxErrorException;

/**
* 批量获取客户详情.
Expand All @@ -153,8 +155,8 @@ public interface WxCpExternalContactService {
* @return wx cp user external contact batch info
* @throws WxErrorException .
*/
WxCpUserExternalContactBatchInfo getContactDetailBatch(String userId, String cursor,
Integer limit)
WxCpExternalContactBatchInfo getContactDetailBatch(String userId, String cursor,
Integer limit)
throws WxErrorException;

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
import me.chanjar.weixin.common.error.WxErrorException;
import me.chanjar.weixin.cp.bean.WxCpInviteResult;
import me.chanjar.weixin.cp.bean.WxCpUser;
import me.chanjar.weixin.cp.bean.external.WxCpUserExternalContactInfo;
import me.chanjar.weixin.cp.bean.external.contact.WxCpExternalContactInfo;

import java.util.List;
import java.util.Map;
Expand Down Expand Up @@ -167,7 +167,7 @@ public interface WxCpUserService {
* @return 联系人详情
* @throws WxErrorException .
*/
WxCpUserExternalContactInfo getExternalContact(String userId) throws WxErrorException;
WxCpExternalContactInfo getExternalContact(String userId) throws WxErrorException;


}
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,8 @@
import me.chanjar.weixin.cp.api.WxCpService;
import me.chanjar.weixin.cp.bean.WxCpBaseResp;
import me.chanjar.weixin.cp.bean.external.*;
import me.chanjar.weixin.cp.bean.external.contact.WxCpExternalContactBatchInfo;
import me.chanjar.weixin.cp.bean.external.contact.WxCpExternalContactInfo;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.commons.lang3.StringUtils;

Expand Down Expand Up @@ -91,23 +93,23 @@ public WxCpBaseResp closeTempChat(@NonNull String userId, @NonNull String extern
}

@Override
public WxCpUserExternalContactInfo getExternalContact(String userId) throws WxErrorException {
public WxCpExternalContactInfo getExternalContact(String userId) throws WxErrorException {
final String url = this.mainService.getWxCpConfigStorage().getApiUrl(GET_EXTERNAL_CONTACT + userId);
String responseContent = this.mainService.get(url, null);
return WxCpUserExternalContactInfo.fromJson(responseContent);
return WxCpExternalContactInfo.fromJson(responseContent);
}

@Override
public WxCpUserExternalContactInfo getContactDetail(String userId) throws WxErrorException {
public WxCpExternalContactInfo getContactDetail(String userId) throws WxErrorException {
final String url = this.mainService.getWxCpConfigStorage().getApiUrl(GET_CONTACT_DETAIL + userId);
String responseContent = this.mainService.get(url, null);
return WxCpUserExternalContactInfo.fromJson(responseContent);
return WxCpExternalContactInfo.fromJson(responseContent);
}

@Override
public WxCpUserExternalContactBatchInfo getContactDetailBatch(String userId,
String cursor,
Integer limit)
public WxCpExternalContactBatchInfo getContactDetailBatch(String userId,
String cursor,
Integer limit)
throws WxErrorException {
final String url =
this.mainService
Expand All @@ -122,7 +124,7 @@ public WxCpUserExternalContactBatchInfo getContactDetailBatch(String userId,
json.addProperty("limit", limit);
}
String responseContent = this.mainService.post(url, json.toString());
return WxCpUserExternalContactBatchInfo.fromJson(responseContent);
return WxCpExternalContactBatchInfo.fromJson(responseContent);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
import me.chanjar.weixin.cp.api.WxCpUserService;
import me.chanjar.weixin.cp.bean.WxCpInviteResult;
import me.chanjar.weixin.cp.bean.WxCpUser;
import me.chanjar.weixin.cp.bean.external.WxCpUserExternalContactInfo;
import me.chanjar.weixin.cp.bean.external.contact.WxCpExternalContactInfo;
import me.chanjar.weixin.cp.util.json.WxCpGsonBuilder;

import java.util.List;
Expand Down Expand Up @@ -193,9 +193,9 @@ public String getUserId(String mobile) throws WxErrorException {
}

@Override
public WxCpUserExternalContactInfo getExternalContact(String userId) throws WxErrorException {
public WxCpExternalContactInfo getExternalContact(String userId) throws WxErrorException {
String url = this.mainService.getWxCpConfigStorage().getApiUrl(GET_EXTERNAL_CONTACT + userId);
String responseContent = this.mainService.get(url, null);
return WxCpUserExternalContactInfo.fromJson(responseContent);
return WxCpExternalContactInfo.fromJson(responseContent);
}
}

This file was deleted.

Loading

0 comments on commit b290713

Please sign in to comment.