Skip to content

Commit a898c4e

Browse files
committed
fix : 兼容qq小程序
1 parent 3c87b07 commit a898c4e

10 files changed

Lines changed: 39 additions & 33 deletions

File tree

‎pages.json‎

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -464,7 +464,7 @@
464464
"onReachBottomDistance": 20
465465
}
466466
},
467-
// #ifdef APP-PLUS || MP-WEIXIN || H5
467+
// #ifdef APP-PLUS || MP-WEIXIN || H5 || MP-QQ
468468
{
469469
"path": "uparse-md/uparse-md",
470470
"style": {
@@ -484,7 +484,7 @@
484484
"navigationBarTitleText": "uCharts 图表"
485485
}
486486
},
487-
// #ifdef APP-PLUS || H5 || MP-WEIXIN
487+
// #ifdef APP-PLUS || H5 || MP-WEIXIN || MP-QQ
488488
{
489489
"path": "gesture-lock/gesture-lock",
490490
"style": {
@@ -750,7 +750,7 @@
750750
"navigationBarTitleText": "时间轴 timeline"
751751
}
752752
},
753-
// #ifdef APP-PLUS || MP-WEIXIN
753+
// #ifdef APP-PLUS || MP-WEIXIN || MP-QQ
754754
{
755755
"path": "vant-button/vant-button",
756756
"style": {
@@ -881,7 +881,7 @@
881881
"navigationBarTitleText": "节点信息"
882882
}
883883
},
884-
// #ifdef APP-PLUS || MP-WEIXIN || MP-BAIDU || H5
884+
// #ifdef APP-PLUS || MP-WEIXIN || MP-BAIDU || H5 || MP-QQ
885885
{
886886
"path": "intersection-observer/intersection-observer",
887887
"style": {
@@ -1057,7 +1057,7 @@
10571057
}
10581058
},
10591059
// #endif
1060-
// #ifdef APP-PLUS || MP-WEIXIN
1060+
// #ifdef APP-PLUS || MP-WEIXIN || MP-QQ
10611061
{
10621062
"path": "bluetooth/bluetooth",
10631063
"style": {
@@ -1069,14 +1069,16 @@
10691069
"style": {
10701070
"navigationBarTitleText": "指纹"
10711071
}
1072-
},
1073-
{
1074-
"path": "ibeacon/ibeacon",
1075-
"style": {
1076-
"navigationBarTitleText": "iBeacon"
1077-
}
1078-
},
1079-
// #endif
1072+
},
1073+
// #endif
1074+
// #ifdef APP-PLUS || MP-WEIXIN
1075+
{
1076+
"path": "ibeacon/ibeacon",
1077+
"style": {
1078+
"navigationBarTitleText": "iBeacon"
1079+
}
1080+
},
1081+
// #endif
10801082
{
10811083
"path": "vibrate/vibrate",
10821084
"style": {

‎pages/API/fingerprint/fingerprint.vue‎

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,11 +33,11 @@ export default {
3333
this.disabled = false;
3434
}
3535
// #endif
36-
// #ifdef MP-WEIXIN
36+
// #ifdef MP-WEIXIN || MP-QQ
3737
this.disabled = false;
3838
this.result = '请在微信真机中使用,模拟器不支持';
3939
// #endif
40-
// #ifndef APP-PLUS || MP-WEIXIN
40+
// #ifndef APP-PLUS || MP-WEIXIN || MP-QQ
4141
this.result = '此平台不支持指纹识别';
4242
// #endif
4343
},
@@ -76,7 +76,7 @@ export default {
7676
}
7777
// #endif
7878
79-
// #ifdef MP-WEIXIN
79+
// #ifdef MP-WEIXIN || MP-QQ
8080
wx.startSoterAuthentication({
8181
requestAuthModes: ['fingerPrint'],
8282
challenge: '123456',

‎pages/API/get-location/get-location.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
return;
6666
}
6767
// #endif
68-
// #ifdef MP-WEIXIN || MP-TOUTIAO
68+
// #ifdef MP-WEIXIN || MP-TOUTIAO || MP-QQ
6969
let status = await this.getSetting();
7070
if (status === 2) {
7171
this.showConfirm();

‎pages/API/get-user-info/get-user-info.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
<!-- #ifdef APP-PLUS || MP-ALIPAY || MP-TOUTIAO -->
2020
<button type="primary" @click="getUserInfo">获取用户信息</button>
2121
<!-- #endif -->
22-
<!-- #ifdef MP-WEIXIN || MP-BAIDU -->
22+
<!-- #ifdef MP-WEIXIN || MP-BAIDU || MP-QQ -->
2323
<button type="primary" open-type="getUserInfo" @getuserinfo="mpGetUserInfo">获取用户信息</button>
2424
<!-- #endif -->
2525
<button @click="clear">清空</button>

‎pages/API/request-payment/request-payment.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
</view>
1111
</view>
1212
<view class="uni-btn-v uni-common-mt">
13-
<!-- #ifdef MP-WEIXIN -->
13+
<!-- #ifdef MP-WEIXIN || MP-QQ -->
1414
<button type="primary" @click="weixinPay" :loading="loading">微信支付</button>
1515
<!-- #endif -->
1616
<!-- #ifdef APP-PLUS -->

‎pages/API/video/video.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
</view>
1616
</view>
1717
</view>
18-
<!-- #ifdef APP-PLUS || MP-WEIXIN -->
18+
<!-- #ifdef APP-PLUS || MP-WEIXIN || MP-QQ -->
1919
<view class="uni-title uni-common-mt uni-common-pl">摄像头位置</view>
2020
<view class="uni-hello-text camera-tips">注意:部分 Android 手机下由于系统 ROM 不支持无法生效,打开拍摄界面后可操作切换</view>
2121
<view class="uni-list">

‎pages/component/button/button.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
<button class="mini-btn" type="default" size="mini">按钮</button>
2424
<button class="mini-btn" type="warn" size="mini">按钮</button>
2525
</view>
26-
<!-- #ifdef MP-WEIXIN -->
26+
<!-- #ifdef MP-WEIXIN || MP-QQ -->
2727
<button open-type="launchApp" app-parameter="uni-app" @error="openTypeError">打开APP</button>
2828
<button open-type="feedback">意见反馈</button>
2929
<!-- #endif -->

‎pages/tabBar/API/API.nvue‎

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
name: '图片',
4242
url: 'image'
4343
},
44-
// #ifdef APP-PLUS || MP-WEIXIN || MP-BAIDU
44+
// #ifdef APP-PLUS || MP-WEIXIN || MP-BAIDU || MP-QQ
4545
{
4646
name: '录音',
4747
url: 'voice'
@@ -111,7 +111,7 @@
111111
name: '节点信息',
112112
url: 'get-node-info'
113113
},
114-
//#ifdef APP-PLUS || MP-WEIXIN || MP-BAIDU || H5
114+
//#ifdef APP-PLUS || MP-WEIXIN || MP-BAIDU || H5 || MP-QQ
115115
{
116116
name: '节点布局交互状态',
117117
url: 'intersection-observer'
@@ -175,7 +175,7 @@
175175
url: 'brightness'
176176
},
177177
// #endif
178-
// #ifdef APP-PLUS || MP-WEIXIN
178+
// #ifdef APP-PLUS || MP-WEIXIN || MP-QQ
179179
{
180180
name: '蓝牙',
181181
url: 'bluetooth'
@@ -184,6 +184,8 @@
184184
name: '指纹',
185185
url: 'fingerprint'
186186
},
187+
// #endif
188+
// #ifdef APP-PLUS || MP-WEIXIN
187189
{
188190
name: 'iBeacon',
189191
url: 'ibeacon'

‎pages/tabBar/template/template.nvue‎

Lines changed: 10 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -101,11 +101,13 @@
101101
name: '时间轴 timeline',
102102
url: 'timeline'
103103
},
104-
{
105-
name: 'uCharts 图表',
106-
url: 'ucharts'
107-
},
108-
// #ifdef APP-PLUS || H5 || MP-WEIXIN
104+
// #ifndef MP-QQ
105+
{
106+
name: 'uCharts 图表',
107+
url: 'ucharts'
108+
},
109+
// #endif
110+
// #ifdef APP-PLUS || H5 || MP-WEIXIN || MP-QQ
109111
{
110112
name: '手势图案锁屏',
111113
url: 'gesture-lock'
@@ -119,7 +121,7 @@
119121
// name: '二维码生成',
120122
// url: 'qrcode'
121123
// },
122-
// #ifdef APP-PLUS || MP-WEIXIN || H5
124+
// #ifdef APP-PLUS || MP-WEIXIN || H5 || MP-QQ
123125
{
124126
id: 'uparse',
125127
name: '富文本渲染',
@@ -160,14 +162,14 @@
160162
url: 'im-chat'
161163
},
162164
// #endif
163-
// #ifdef APP-PLUS || MP-WEIXIN
165+
// #ifdef APP-PLUS || MP-WEIXIN || MP-QQ
164166
{
165167
name: '微信自定义组件示例(vant ui)',
166168
url: 'vant-button'
167169
}
168170
// #endif
169171
],
170-
navigateFlag: false
172+
navigateFlag: false
171173
}
172174
},
173175
onLoad() {

‎pages/template/list2detail-detail/list2detail-detail.vue‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<view class="article-content">
1313
<rich-text :nodes="htmlNodes"></rich-text>
1414
</view>
15-
<!-- #ifdef MP-WEIXIN -->
15+
<!-- #ifdef MP-WEIXIN || MP-QQ -->
1616
<ad v-if="htmlNodes.length > 0" unit-id="adunit-01b7a010bf53d74e"></ad>
1717
<!-- #endif -->
1818
</view>

0 commit comments

Comments
 (0)