|
|
@@ -1,9 +1,14 @@ |
|
|
|
package me.chanjar.weixin.mp.api.impl; |
|
|
|
|
|
|
|
import java.util.List; |
|
|
|
|
|
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
|
|
|
|
|
import com.google.gson.JsonArray; |
|
|
|
import com.google.gson.JsonObject; |
|
|
|
import com.google.gson.JsonParser; |
|
|
|
import com.google.gson.reflect.TypeToken; |
|
|
|
|
|
|
|
import me.chanjar.weixin.common.bean.result.WxError; |
|
|
|
import me.chanjar.weixin.common.exception.WxErrorException; |
|
|
|
import me.chanjar.weixin.mp.api.WxMpService; |
|
|
@@ -11,9 +16,6 @@ import me.chanjar.weixin.mp.api.WxMpUserTagService; |
|
|
|
import me.chanjar.weixin.mp.bean.tag.WxTagListUser; |
|
|
|
import me.chanjar.weixin.mp.bean.tag.WxUserTag; |
|
|
|
import me.chanjar.weixin.mp.util.json.WxMpGsonBuilder; |
|
|
|
import org.apache.commons.lang3.StringUtils; |
|
|
|
|
|
|
|
import java.util.List; |
|
|
|
|
|
|
|
/** |
|
|
|
* |
|
|
@@ -144,7 +146,7 @@ public class WxMpUserTagServiceImpl implements WxMpUserTagService { |
|
|
|
} |
|
|
|
|
|
|
|
@Override |
|
|
|
public List<Integer> userTagList(String openid) throws WxErrorException { |
|
|
|
public List<Long> userTagList(String openid) throws WxErrorException { |
|
|
|
String url = API_URL_PREFIX + "/getidlist"; |
|
|
|
|
|
|
|
JsonObject json = new JsonObject(); |
|
|
@@ -154,7 +156,7 @@ public class WxMpUserTagServiceImpl implements WxMpUserTagService { |
|
|
|
|
|
|
|
return WxMpGsonBuilder.create().fromJson( |
|
|
|
new JsonParser().parse(responseContent).getAsJsonObject().get("tagid_list"), |
|
|
|
new TypeToken<List<Integer>>() { |
|
|
|
new TypeToken<List<Long>>() { |
|
|
|
}.getType()); |
|
|
|
} |
|
|
|
} |