Merge branch 'develop'
# Conflicts: # pages/my/my.vue
This commit is contained in:
+279
-21
@@ -17,6 +17,7 @@
|
||||
|
||||
<!-- 设置选项列表 -->
|
||||
<view class="settings-list">
|
||||
<!-- #ifdef APP -->
|
||||
<!-- 消息通知 -->
|
||||
<view class="setting-item" @click="toggleNotification">
|
||||
<text class="setting-text">消息通知</text>
|
||||
@@ -25,7 +26,7 @@
|
||||
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- #endif -->
|
||||
<!-- 修改登录密码 -->
|
||||
<view class="setting-item" @click="goToChangePassword">
|
||||
<text class="setting-text">修改登录密码</text>
|
||||
@@ -37,27 +38,27 @@
|
||||
<text class="setting-text">更换手机号</text>
|
||||
<uni-icons type="right" size="20" color="#999"></uni-icons>
|
||||
</view>
|
||||
|
||||
<!-- #ifdef APP -->
|
||||
<!-- 版本更新 -->
|
||||
<view class="setting-item" @click="checkUpdate">
|
||||
<text class="setting-text">版本更新</text>
|
||||
<uni-icons type="right" size="20" color="#999"></uni-icons>
|
||||
</view>
|
||||
|
||||
<!-- #endif -->
|
||||
<!-- 关于肝胆相照 -->
|
||||
<view class="setting-item" @click="goToAbout">
|
||||
<view class="setting-item" @click="goToPage('https://doc.igandan.com/app/html/about/2017/about2.html')">
|
||||
<text class="setting-text">关于肝胆相照</text>
|
||||
<uni-icons type="right" size="20" color="#999"></uni-icons>
|
||||
</view>
|
||||
|
||||
|
||||
<!-- 分享肝胆相照APP -->
|
||||
<view class="setting-item" @click="shareApp">
|
||||
<view class="setting-item" @click="shareToggle">
|
||||
<text class="setting-text">分享肝胆相照APP</text>
|
||||
<uni-icons type="right" size="20" color="#999"></uni-icons>
|
||||
</view>
|
||||
|
||||
|
||||
<!-- 肝胆相照直播群 -->
|
||||
<view class="setting-item" @click="goToLiveGroup">
|
||||
<view class="setting-item" @click="goToPage('https://wx.igandan.com/qun/gdxzqun')">
|
||||
<text class="setting-text">肝胆相照直播群</text>
|
||||
<uni-icons type="right" size="20" color="#999"></uni-icons>
|
||||
</view>
|
||||
@@ -67,7 +68,7 @@
|
||||
<text class="setting-text">微信关联</text>
|
||||
<uni-icons type="right" size="20" color="#999"></uni-icons>
|
||||
</view>
|
||||
|
||||
<!-- #ifdef APP -->
|
||||
<!-- 清除缓存 -->
|
||||
<view class="setting-item" @click="clearCache">
|
||||
<text class="setting-text">清除缓存</text>
|
||||
@@ -76,7 +77,7 @@
|
||||
<uni-icons type="right" size="20" color="#999"></uni-icons>
|
||||
</view>
|
||||
</view>
|
||||
|
||||
<!-- #endif -->
|
||||
<!-- 意见反馈 -->
|
||||
<view class="setting-item" @click="goToFeedback">
|
||||
<text class="setting-text">意见反馈</text>
|
||||
@@ -90,13 +91,13 @@
|
||||
</view>
|
||||
|
||||
<!-- 注册协议 -->
|
||||
<view class="setting-item" @click="goToAgreement">
|
||||
<view class="setting-item" @click="goToPage('https://doc.igandan.com/app/integral/expert_zcxy.html')">
|
||||
<text class="setting-text">注册协议</text>
|
||||
<uni-icons type="right" size="20" color="#999"></uni-icons>
|
||||
</view>
|
||||
|
||||
<!-- 隐私政策 -->
|
||||
<view class="setting-item" @click="goToPrivacy">
|
||||
<view class="setting-item" @click="goToPage('https://doc.igandan.com/app/integral/permission_expert.html')">
|
||||
<text class="setting-text">隐私政策</text>
|
||||
<uni-icons type="right" size="20" color="#999"></uni-icons>
|
||||
</view>
|
||||
@@ -106,13 +107,45 @@
|
||||
<view class="logout-section">
|
||||
<button class="logout-btn" @click="logout">退出登录</button>
|
||||
</view>
|
||||
|
||||
<view>
|
||||
<!-- 分享弹窗 -->
|
||||
<uni-popup ref="shareRef" type="bottom" safeArea backgroundColor="#fff">
|
||||
<view class="share-popup">
|
||||
<view class="share-title">分享到</view>
|
||||
<view class="share-content">
|
||||
<view class="share-item" @click="shareToWechat">
|
||||
<view class="share-icon wechat-icon">
|
||||
<text class="share-icon-text">微</text>
|
||||
</view>
|
||||
<text class="share-text">微信</text>
|
||||
</view>
|
||||
<view class="share-item" @click="shareToMoments">
|
||||
<view class="share-icon moments-icon">
|
||||
<text class="share-icon-text">朋</text>
|
||||
</view>
|
||||
<text class="share-text">朋友圈</text>
|
||||
</view>
|
||||
<view class="share-item" @click="shareToWeibo">
|
||||
<view class="share-icon weibo-icon">
|
||||
<text class="share-icon-text">微</text>
|
||||
</view>
|
||||
<text class="share-text">新浪微博</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="share-cancel" @click="closeShare">
|
||||
<text>取消</text>
|
||||
</view>
|
||||
</view>
|
||||
</uni-popup>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<script setup>
|
||||
import { ref } from 'vue';
|
||||
import { onShow } from "@dcloudio/uni-app";
|
||||
|
||||
import navTo from "@/utils/navTo"
|
||||
// 返回上一页
|
||||
const goBack = () => {
|
||||
uni.navigateBack();
|
||||
@@ -127,6 +160,11 @@
|
||||
});
|
||||
};
|
||||
|
||||
const goToPage = (url) => {
|
||||
uni.navigateTo({
|
||||
url: '/pages/webview/webview?url=' + url
|
||||
});
|
||||
};
|
||||
// 跳转到修改密码页面
|
||||
const goToChangePassword = () => {
|
||||
uni.navigateTo({
|
||||
@@ -157,13 +195,154 @@
|
||||
});
|
||||
};
|
||||
|
||||
const shareRef = ref()
|
||||
// 分享APP
|
||||
const shareApp = () => {
|
||||
uni.showToast({
|
||||
title: '分享APP',
|
||||
icon: 'none'
|
||||
const shareToggle = () => {
|
||||
shareRef.value.open()
|
||||
}
|
||||
|
||||
// 关闭分享弹窗
|
||||
const closeShare = () => {
|
||||
shareRef.value.close()
|
||||
}
|
||||
|
||||
// 分享到微信
|
||||
const shareToWechat = () => {
|
||||
// #ifdef APP-PLUS
|
||||
// 使用系统分享
|
||||
|
||||
uni.share({
|
||||
provider: "weixin",
|
||||
scene: "WXSceneSession",
|
||||
type: 1,
|
||||
summary: "肝胆相照APP - 专业的医疗健康平台,快来下载体验吧!\n下载链接:https://www.igandan.com",
|
||||
success: function (res) {
|
||||
console.log("success:" + JSON.stringify(res));
|
||||
},
|
||||
fail: function (err) {
|
||||
console.log("fail:" + JSON.stringify(err));
|
||||
}
|
||||
});
|
||||
};
|
||||
// #endif
|
||||
|
||||
// #ifdef H5
|
||||
// H5环境下的分享
|
||||
if (navigator.share) {
|
||||
navigator.share({
|
||||
title: '肝胆相照APP',
|
||||
text: '专业的医疗健康平台,快来下载体验吧!',
|
||||
url: 'https://www.igandan.com'
|
||||
}).then(() => {
|
||||
uni.showToast({
|
||||
title: '分享成功',
|
||||
icon: 'success'
|
||||
})
|
||||
}).catch(() => {
|
||||
uni.showToast({
|
||||
title: '分享失败',
|
||||
icon: 'none'
|
||||
})
|
||||
})
|
||||
} else {
|
||||
// 复制到剪贴板
|
||||
uni.setClipboardData({
|
||||
data: '肝胆相照APP - 专业的医疗健康平台,快来下载体验吧!\n下载链接:https://www.igandan.com',
|
||||
success: () => {
|
||||
uni.showToast({
|
||||
title: '已复制到剪贴板',
|
||||
icon: 'success'
|
||||
})
|
||||
}
|
||||
})
|
||||
}
|
||||
// #endif
|
||||
|
||||
// #ifdef MP-WEIXIN
|
||||
// 微信小程序分享
|
||||
uni.showShareMenu({
|
||||
withShareTicket: true,
|
||||
menus: ['shareAppMessage', 'shareTimeline']
|
||||
})
|
||||
// #endif
|
||||
|
||||
closeShare()
|
||||
}
|
||||
|
||||
// 分享到朋友圈
|
||||
const shareToMoments = () => {
|
||||
// #ifdef APP-PLUS
|
||||
uni.share({
|
||||
provider: "weixin",
|
||||
scene: "WXSceneTimeline",
|
||||
type: 1,
|
||||
summary: "肝胆相照APP - 专业的医疗健康平台,快来下载体验吧!\n下载链接:https://www.igandan.com",
|
||||
success: function (res) {
|
||||
console.log("success:" + JSON.stringify(res));
|
||||
},
|
||||
fail: function (err) {
|
||||
console.log("fail:" + JSON.stringify(err));
|
||||
}
|
||||
});
|
||||
// #endif
|
||||
|
||||
// #ifdef H5
|
||||
// 复制到剪贴板
|
||||
uni.setClipboardData({
|
||||
data: '肝胆相照APP - 专业的医疗健康平台,快来下载体验吧!\n下载链接:https://www.igandan.com',
|
||||
success: () => {
|
||||
uni.showToast({
|
||||
title: '已复制到剪贴板,可分享到朋友圈',
|
||||
icon: 'success'
|
||||
})
|
||||
}
|
||||
})
|
||||
// #endif
|
||||
|
||||
// #ifdef MP-WEIXIN
|
||||
uni.showShareMenu({
|
||||
withShareTicket: true,
|
||||
menus: ['shareAppMessage', 'shareTimeline']
|
||||
})
|
||||
// #endif
|
||||
|
||||
closeShare()
|
||||
}
|
||||
|
||||
// 分享到新浪微博
|
||||
const shareToWeibo = () => {
|
||||
// #ifdef APP-PLUS
|
||||
plus.share.sendWithSystem({
|
||||
type: 'text',
|
||||
content: '肝胆相照APP - 专业的医疗健康平台,快来下载体验吧!\n下载链接:https://www.igandan.com'
|
||||
}, () => {
|
||||
uni.showToast({
|
||||
title: '分享成功',
|
||||
icon: 'success'
|
||||
})
|
||||
}, (err) => {
|
||||
console.log('分享失败:', err)
|
||||
uni.showToast({
|
||||
title: '分享失败',
|
||||
icon: 'none'
|
||||
})
|
||||
})
|
||||
// #endif
|
||||
|
||||
// #ifdef H5
|
||||
// 复制到剪贴板
|
||||
uni.setClipboardData({
|
||||
data: '肝胆相照APP - 专业的医疗健康平台,快来下载体验吧!\n下载链接:https://www.igandan.com',
|
||||
success: () => {
|
||||
uni.showToast({
|
||||
title: '已复制到剪贴板,可分享到微博',
|
||||
icon: 'success'
|
||||
})
|
||||
}
|
||||
})
|
||||
// #endif
|
||||
|
||||
closeShare()
|
||||
}
|
||||
|
||||
// 跳转到直播群页面
|
||||
const goToLiveGroup = () => {
|
||||
@@ -247,7 +426,7 @@
|
||||
<style scoped>
|
||||
.content {
|
||||
background-color: #f5f5f5;
|
||||
min-height: 100vh;
|
||||
/* min-height: 100vh; */
|
||||
padding-bottom: 160rpx; /* 为固定的退出登录按钮留出空间 */
|
||||
}
|
||||
|
||||
@@ -331,10 +510,10 @@
|
||||
|
||||
/* 退出登录按钮样式 */
|
||||
.logout-section {
|
||||
position: fixed;
|
||||
/* position: fixed;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
right: 0;
|
||||
right: 0; */
|
||||
padding: 30rpx;
|
||||
background-color: #fff;
|
||||
border-top: 1rpx solid #e0e0e0;
|
||||
@@ -357,4 +536,83 @@
|
||||
.logout-btn:active {
|
||||
background-color: #fff0f0;
|
||||
}
|
||||
|
||||
/* 分享弹窗样式 */
|
||||
.share-popup {
|
||||
background-color: #fff;
|
||||
border-radius: 20rpx 20rpx 0 0;
|
||||
padding: 40rpx 0 0;
|
||||
}
|
||||
|
||||
.share-title {
|
||||
text-align: center;
|
||||
font-size: 32rpx;
|
||||
color: #333;
|
||||
margin-bottom: 40rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.share-content {
|
||||
display: flex;
|
||||
justify-content: space-around;
|
||||
padding: 0 40rpx 40rpx;
|
||||
}
|
||||
|
||||
.share-item {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: center;
|
||||
flex: 1;
|
||||
}
|
||||
|
||||
.share-icon {
|
||||
width: 100rpx;
|
||||
height: 100rpx;
|
||||
border-radius: 50%;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
margin-bottom: 20rpx;
|
||||
}
|
||||
|
||||
.wechat-icon {
|
||||
background-color: #07C160;
|
||||
}
|
||||
|
||||
.moments-icon {
|
||||
background-color: #07C160;
|
||||
}
|
||||
|
||||
.weibo-icon {
|
||||
background-color: #E6162D;
|
||||
}
|
||||
|
||||
.qq-icon {
|
||||
background-color: #12B7F5;
|
||||
}
|
||||
|
||||
.share-icon-text {
|
||||
font-size: 50rpx;
|
||||
color: #fff;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.share-text {
|
||||
font-size: 24rpx;
|
||||
color: #666;
|
||||
}
|
||||
|
||||
.share-cancel {
|
||||
height: 100rpx;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
border-top: 1rpx solid #f0f0f0;
|
||||
font-size: 32rpx;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.share-cancel:active {
|
||||
background-color: #f5f5f5;
|
||||
}
|
||||
</style>
|
||||
|
||||
Reference in New Issue
Block a user