diff --git a/view/peko/activity/act-ocean/css/index.css b/view/peko/activity/act-ocean/css/index.css
index eb71729..f5d089f 100644
--- a/view/peko/activity/act-ocean/css/index.css
+++ b/view/peko/activity/act-ocean/css/index.css
@@ -627,7 +627,7 @@ body {
}
.wrap .info-bottom .info-wrap .diamond-num,
.wrap .info-bottom .info-wrap .fragment-num {
- width: 3.3333333333rem;
+ width: 4rem;
height: 0.56rem;
background-color: #BD7F38;
border-radius: 0.2666666667rem;
diff --git a/view/peko/activity/act-ocean/css/index.scss b/view/peko/activity/act-ocean/css/index.scss
index 2520440..1ac3748 100644
--- a/view/peko/activity/act-ocean/css/index.scss
+++ b/view/peko/activity/act-ocean/css/index.scss
@@ -777,7 +777,8 @@ body {
.diamond-num,
.fragment-num {
- width: px2rem(250);
+ // width: px2rem(250);
+ width: 4rem;
height: px2rem(42);
background-color: #BD7F38;
border-radius: px2rem(20);
diff --git a/view/peko/activity/act-ocean/js/index.js b/view/peko/activity/act-ocean/js/index.js
index 80b0ae3..6c4587b 100644
--- a/view/peko/activity/act-ocean/js/index.js
+++ b/view/peko/activity/act-ocean/js/index.js
@@ -32,7 +32,7 @@ const toastMsg = (content = '操作完成', time = 2) => {
})
}
-if (false) { //!browser.app
+if (!browser.app) { //false
toastMsg('請在app內打開!');
} else {
$('.wrap').removeClass('no-in-app')
@@ -784,7 +784,7 @@ const renderRankList = () => {
}
topThreeStr = `
-
+

@@ -795,6 +795,10 @@ const renderRankList = () => {
`
})
$('.topthree-wrap').html(topThreeStr)
+ $('.topthree-wrap .info-wrap').click(function () {
+ let uid = $(this).attr('uid')
+ openPerson(uid)
+ })
// 渲染非前3
@@ -809,7 +813,7 @@ const renderRankList = () => {
num = item.num
}
others += `
-
+
${index + 2}

@@ -820,6 +824,10 @@ const renderRankList = () => {
`
})
$('.other-rank').html(others)
+ $('.other-rank li').click(function(){
+ let uid = $(this).attr('uid')
+ openPerson(uid)
+ })
} else {
// 歐皇榜單
// 渲染前3
@@ -839,7 +847,7 @@ const renderRankList = () => {
num = '猜中' + item.num + '次'
}
topThreeStr = `
-
+

@@ -850,6 +858,10 @@ const renderRankList = () => {
`
})
$('.topthree-wrap').html(topThreeStr)
+ $('.topthree-wrap .info-wrap').click(function () {
+ let uid = $(this).attr('uid')
+ openPerson(uid)
+ })
// 渲染非前3
let othersArr = rankListN.slice(1)
@@ -861,7 +873,7 @@ const renderRankList = () => {
num = '猜中' + item.num + '次'
}
others += `
-
+
${index + 2}

@@ -872,10 +884,27 @@ const renderRankList = () => {
`
})
$('.other-rank').html(others)
+ $('.other-rank li').click(function(){
+ let uid = $(this).attr('uid')
+ openPerson(uid)
+ })
}
}
+//跳转个人主页
+function openPerson(uid) {
+ console.log('跳转个人主页方法');
+ if (!browser.app) return
+ if (browser.ios) {
+ window.webkit.messageHandlers.openPersonPage.postMessage(uid);
+ } else if (browser.android) {
+ if (androidJsObj && typeof androidJsObj === 'object') {
+ window.androidJsObj.openPersonPage(uid);
+ }
+ }
+}
+
$(function () {
getInfoFromClient()
@@ -1077,17 +1106,6 @@ $(function () {
console.log('uid', uid);
openPerson(uid)
})
- //跳转个人主页
- function openPerson(uid) {
- if (!browser.app) return
- if (browser.ios) {
- window.webkit.messageHandlers.openPersonPage.postMessage(uid);
- } else if (browser.android) {
- if (androidJsObj && typeof androidJsObj === 'object') {
- window.androidJsObj.openPersonPage(uid);
- }
- }
- }
// 關閉碎片不足提示彈窗
$('.cancel-btn').on('click', function () {