230320a303 2 gadi atpakaļ
vecāks
revīzija
6b2eb7313b
1 mainītis faili ar 11 papildinājumiem un 1 dzēšanām
  1. 11 1
      wxnews.html

+ 11 - 1
wxnews.html

@@ -176,7 +176,7 @@ if (novelId) {
 var shareImgUrl = 'https://icon.honglouplus.com/plus.png';
 function configJsSDKAndDoSomething(config, title, imgUrl, desc){
     wx.config({
-        debug: false,
+        debug: true,
         appId: config.appId,
         timestamp: config.timestamp,
         nonceStr: config.nonceStr,
@@ -205,6 +205,16 @@ function configJsSDKAndDoSomething(config, title, imgUrl, desc){
 	            console.log("success2");
 	        }
 	     });
+
+		 wx.checkJsApi({
+			jsApiList: ['updateAppMessageShareData', 'updateTimelineShareData'], // 需要检测的JS接口列表,所有JS接口列表见附录2,
+			success: function(res) {
+				alert(JSON.stringify(res))
+			// 以键值对的形式返回,可用的api值true,不可用为false
+			// 如:{"checkResult":{"chooseImage":true},"errMsg":"checkJsApi:ok"}
+			}
+			});
+
     });
 }
 </script>