File tree Expand file tree Collapse file tree 2 files changed +27
-2
lines changed
miniprogram/packageAPI/pages/api/jump Expand file tree Collapse file tree 2 files changed +27
-2
lines changed Original file line number Diff line number Diff line change @@ -55,6 +55,26 @@ Page({
55
55
}
56
56
} )
57
57
} ,
58
+ // 打开公众号主页
59
+ openofficialaccountprofile ( ) {
60
+ wx . openOfficialAccountProfile ( {
61
+ username : 'gh_56fc3b00cc4f' ,
62
+ success : ( res ) => {
63
+ } ,
64
+ fail : ( res ) => {
65
+ }
66
+ } )
67
+ } ,
68
+ // 打开公众号文章
69
+ openofficialaccountarticle ( ) {
70
+ wx . openOfficialAccountArticle ( {
71
+ url : 'https://mp.weixin.qq.com/s/vTt8sZ_tTkTEVYgcydKqew' , // 此处填写公众号文章连接
72
+ success : ( res ) => {
73
+ } ,
74
+ fail : ( res ) => {
75
+ }
76
+ } )
77
+ } ,
58
78
onUnload ( ) {
59
79
if ( wx . offThemeChange ) {
60
80
wx . offThemeChange ( )
Original file line number Diff line number Diff line change 1
1
<import src="../../../../common/head.wxml" />
2
2
<import src="../../../../common/foot.wxml" />
3
-
4
3
<view class="container page" data-weui-theme="{{theme}}">
5
- <template is="head" />
4
+ <template is="head" data="{{title: 'jumpApi'}}" />
6
5
<view class="page-body">
7
6
<!-- 暂时下架 -->
8
7
<!-- <view class="btn-area">
17
16
<view class="btn-area">
18
17
<button type="primary" data-mode="fingerPrint" bindtap="exitminiprogram">退出当前小程序</button>
19
18
</view>
19
+ <view class="btn-area">
20
+ <button type="primary" data-mode="fingerPrint" bindtap="openofficialaccountprofile">打开公众号主页</button>
21
+ </view>
22
+ <view class="btn-area">
23
+ <button type="primary" data-mode="fingerPrint" bindtap="openofficialaccountarticle">打开公众号文章</button>
24
+ </view>
20
25
</view>
21
26
<template is="foot" />
22
27
</view>
You can’t perform that action at this time.
0 commit comments