feat: 添加无双相关
This commit is contained in:
+15
-1
@@ -307,8 +307,22 @@
|
||||
};
|
||||
const openThirdPartyService = (item) => {
|
||||
if (!item?.url) return;
|
||||
const title = encodeURIComponent(item.title || item.name || '第三方服务');
|
||||
const targetUrl = encodeURIComponent(item.url);
|
||||
if (typeof plus !== 'undefined' && plus?.runtime) {
|
||||
uni.navigateTo({
|
||||
url: `/pages/public/webview?title=${title}&url=${targetUrl}`,
|
||||
});
|
||||
return;
|
||||
}
|
||||
if (typeof window !== 'undefined' && typeof window.open === 'function') {
|
||||
const opened = window.open(item.url, '_blank');
|
||||
if (opened) return;
|
||||
window.location.href = item.url;
|
||||
return;
|
||||
}
|
||||
uni.navigateTo({
|
||||
url: `/pages/public/webview?title=${encodeURIComponent(item.title || item.name || '第三方服务')}&url=${encodeURIComponent(item.url)}`,
|
||||
url: `/pages/public/webview?title=${title}&url=${targetUrl}`,
|
||||
});
|
||||
};
|
||||
const updateAvatar = async (avatar) => {
|
||||
|
||||
Reference in New Issue
Block a user