File tree 2 files changed +22
-0
lines changed
weixin-java-cp/src/main/java/me/chanjar/weixin/cp/bean
2 files changed +22
-0
lines changed Original file line number Diff line number Diff line change @@ -47,6 +47,12 @@ public static WxCpMessageSendResult fromJson(String json) {
47
47
@ SerializedName ("msgid" )
48
48
private String msgId ;
49
49
50
+ /**
51
+ * 仅消息类型为“按钮交互型”,“投票选择型”和“多项选择型”的模板卡片消息返回,应用可使用response_code调用更新模版卡片消息接口,24小时内有效,且只能使用一次
52
+ */
53
+ @ SerializedName ("response_code" )
54
+ private String responseCode ;
55
+
50
56
public List <String > getInvalidUserList () {
51
57
return this .content2List (this .invalidUser );
52
58
}
Original file line number Diff line number Diff line change @@ -34,6 +34,18 @@ public class TemplateCardButton implements Serializable {
34
34
*/
35
35
private String key ;
36
36
37
+ /**
38
+ * 按钮点击事件类型,0 或不填代表回调点击事件,1 代表跳转url
39
+ */
40
+ private int type ;
41
+
42
+ /**
43
+ * 跳转事件的url,button_list.type是1时必填
44
+ */
45
+ private String url ;
46
+
47
+
48
+
37
49
public JsonObject toJson () {
38
50
JsonObject btnObject = new JsonObject ();
39
51
@@ -44,6 +56,10 @@ public JsonObject toJson() {
44
56
btnObject .addProperty ("style" , this .getStyle ());
45
57
}
46
58
btnObject .addProperty ("key" , this .getKey ());
59
+ btnObject .addProperty ("type" , this .getType ());
60
+ if (null != this .getUrl ()) {
61
+ btnObject .addProperty ("url" , this .getUrl ());
62
+ }
47
63
return btnObject ;
48
64
}
49
65
}
You can’t perform that action at this time.
0 commit comments