|
|
@@ -23,7 +23,12 @@
|
|
|
</view>
|
|
|
<!-- 公众号图片展示 -->
|
|
|
<view class="gzh-img-box" @click="openOfficialAccount">
|
|
|
- <image class="gzh-img" src="../static/gzh.png" mode="widthFix" style="width: 100vw;margin-top: 100rpx;"></image>
|
|
|
+ <image
|
|
|
+ class="gzh-img"
|
|
|
+ src="../static/gzh.png"
|
|
|
+ mode="widthFix"
|
|
|
+ style="width: 100vw; margin-top: 100rpx"
|
|
|
+ ></image>
|
|
|
</view>
|
|
|
<OrderSuccessPopup ref="orderPopupRef" />
|
|
|
</view>
|
|
|
@@ -34,7 +39,7 @@ import OrderSuccessPopup from "../components/OrderSuccessPopup.vue";
|
|
|
export default {
|
|
|
data() {
|
|
|
return {
|
|
|
- startX: 0
|
|
|
+ startX: 0,
|
|
|
};
|
|
|
},
|
|
|
components: {
|
|
|
@@ -81,10 +86,32 @@ export default {
|
|
|
},
|
|
|
// 打开公众号
|
|
|
openOfficialAccount() {
|
|
|
+ uni.getProvider({
|
|
|
+ service: "oauth",
|
|
|
+ success: function (res) {
|
|
|
+ console.log(res,'xxxx');
|
|
|
+ if (res.provider.includes("weixin")) {
|
|
|
+ // 调用微信小程序的 wx.openOfficialAccountProfile
|
|
|
+ wx.openOfficialAccountProfile({
|
|
|
+ username: "bookersea",
|
|
|
+ success: function (res) {
|
|
|
+ console.log("打开公众号资料页成功", res);
|
|
|
+ },
|
|
|
+ fail: function (err) {
|
|
|
+ console.log("打开公众号资料页失败", err);
|
|
|
+ },
|
|
|
+ complete: function () {
|
|
|
+ console.log("接口调用结束");
|
|
|
+ },
|
|
|
+ });
|
|
|
+ }
|
|
|
+ },
|
|
|
+ });
|
|
|
+ return;
|
|
|
uni.navigateTo({
|
|
|
- url: '/pages-home/pages/official-account'
|
|
|
+ url: "/pages-home/pages/official-account",
|
|
|
});
|
|
|
- }
|
|
|
+ },
|
|
|
},
|
|
|
onLoad() {
|
|
|
let frequency = uni.getStorageSync("frequency");
|