File tree Expand file tree Collapse file tree 2 files changed +31
-1
lines changed
main/java/me/chanjar/weixin/cp/bean/external/contact
test/java/me/chanjar/weixin/cp/bean/external Expand file tree Collapse file tree 2 files changed +31
-1
lines changed Original file line number Diff line number Diff line change @@ -52,6 +52,12 @@ public class FollowedUser implements Serializable {
5252 @ SerializedName ("oper_userid" )
5353 private String operatorUserId ;
5454
55+ /**
56+ * 该成员添加此客户的来源add_way为10时,对应的视频号信息
57+ */
58+ @ SerializedName ("wechat_channels" )
59+ private WechatChannels wechatChannels ;
60+
5561 /**
5662 * The type Tag.
5763 */
@@ -82,4 +88,22 @@ public static class Tag implements Serializable {
8288 */
8389 private int type ;
8490 }
91+
92+ /**
93+ * The type WechatChannels.
94+ */
95+ @ Data
96+ public static class WechatChannels implements Serializable {
97+ private static final long serialVersionUID = -7940080094561469369L ;
98+
99+ /**
100+ * 视频号名称
101+ */
102+ private String nickname ;
103+
104+ /**
105+ * 视频号添加场景,0-未知 1-视频号主页 2-视频号直播间 3-视频号留资服务(微信版本要求:iOS ≥ 8.0.20,Android ≥ 8.0.21,且添加时间不早于2022年4月21日。否则添加场景值为0)
106+ */
107+ private Integer source ;
108+ }
85109}
Original file line number Diff line number Diff line change @@ -76,7 +76,11 @@ public void testFromJson() {
7676 " \" userid\" : \" rocky\" ,\n " +
7777 " \" remark\" : \" 李部长\" ,\n " +
7878 " \" description\" : \" 对接采购事物\" ,\n " +
79- " \" createtime\" : 1525779812\n " +
79+ " \" createtime\" : 1525779812,\n " +
80+ " \" wechat_channels\" : {\n " +
81+ " \" nickname\" : \" 视频号名称\" ,\n " +
82+ " \" source\" : 1\n " +
83+ " }" +
8084 " },\n " +
8185 " {\n " +
8286 " \" userid\" : \" tommy\" ,\n " +
@@ -172,6 +176,8 @@ public void testFromJson() {
172176 assertThat (followedUsers .get (0 ).getRemark ()).isEqualTo ("李部长" );
173177 assertThat (followedUsers .get (0 ).getDescription ()).isEqualTo ("对接采购事物" );
174178 assertThat (followedUsers .get (0 ).getCreateTime ()).isEqualTo (1525779812 );
179+ assertThat (followedUsers .get (0 ).getWechatChannels ().getNickname ()).isEqualTo ("视频号名称" );
180+ assertThat (followedUsers .get (0 ).getWechatChannels ().getSource ()).isEqualTo (1 );
175181
176182 assertThat (followedUsers .get (1 ).getUserId ()).isEqualTo ("tommy" );
177183 assertThat (followedUsers .get (1 ).getRemark ()).isEqualTo ("李总" );
You can’t perform that action at this time.
0 commit comments