Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
D
duiba-h5-frame
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
江思志
duiba-h5-frame
Commits
5c9429ad
Commit
5c9429ad
authored
Apr 04, 2019
by
孙高杰
Browse files
Options
Browse Files
Download
Plain Diff
隐藏拦截弹窗
parents
eaefe4b5
bf154c4b
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
80 additions
and
40 deletions
+80
-40
ossupload.js
build/ossupload.js
+2
-1
index.js
config/index.js
+1
-0
shareFooter.vue
src/pages/kejiji/webview/components/shareFooter.vue
+12
-4
home.less
src/pages/kejiji/webview/content/page/home.less
+3
-3
home.vue
src/pages/kejiji/webview/content/page/home.vue
+25
-13
today.less
src/pages/kejiji/webview/daily/page/today.less
+19
-13
today.vue
src/pages/kejiji/webview/daily/page/today.vue
+18
-6
No files found.
build/ossupload.js
View file @
5c9429ad
...
...
@@ -71,7 +71,8 @@ class OssUpload {
co(function*() {
let relativeDir = _this.getRelativePath(fileDir);
const originPath = `${_this.options.originDir}${relativeDir}`; // cdn 路径
console.log("上传文件 " + config.build.assetsPublicPath + originPath);
console.log(originPath);
console.log("上传文件 " + config.build.host + originPath);
try {
originFile = yield _this.client.head(originPath);
} catch (error) {
...
...
config/index.js
View file @
5c9429ad
...
...
@@ -36,6 +36,7 @@ module.exports = {
build
:
{
// Template for index.html
host
:
process
.
env
.
NODE_ENV
===
'production'
?
prodDomain
:
testDomain
,
index
:
path
.
resolve
(
__dirname
,
'../dist/index.html'
),
// Paths
assetsRoot
:
path
.
resolve
(
__dirname
,
'../dist'
),
...
...
src/pages/kejiji/webview/components/shareFooter.vue
View file @
5c9429ad
...
...
@@ -6,16 +6,16 @@
</section>
<section
class=
"dui-share__methods"
v-if=
"showMask"
>
<div
class=
"mask"
@
click=
"onClose"
></div>
<div
class=
"share-wrap"
>
<
!--
<
div
class=
"share-wrap"
>
<div
class=
"close"
@
click=
"onClose"
></div>
<h5>
分享到微信
</h5>
<ul>
<li
class=
"J_weixin"
@
click=
"onGroup"
>
<div>
微信群
</div>
</li>
<li
class=
"J_pengyouquan"
@
click=
"onFriend"
>
<div>
朋友圈
</div>
</li>
</ul>
</div>
<div
class=
"gudide-des"
v-if=
"showGuider"
>
从菜单中点击转发分享
</div>
<div
class=
"share-yindao"
v-if=
"showGuider"
>
</div>
-->
<div
class=
"gudide-des"
>
从菜单中点击转发分享
</div>
<div
class=
"share-yindao"
>
<img
src=
"//yun.dui88.com/h5/miniprogram/kejiji/images/guide.png"
alt=
""
>
</div>
</section>
...
...
@@ -67,6 +67,10 @@ export default {
type
:
String
,
default
:
''
},
push
:
{
type
:
Boolean
,
default
:
false
},
sellerid
:
{
type
:
Number
,
default
:
null
...
...
@@ -86,6 +90,10 @@ export default {
}
},
async
onSend
()
{
if
(
this
.
push
){
this
.
showMask
=
true
;
return
;
}
let
res
=
await
get
(
API
.
info
,
{
scid
:
SCID
});
//暂时去掉信息拦截
// if (res.success) {
...
...
src/pages/kejiji/webview/content/page/home.less
View file @
5c9429ad
...
...
@@ -31,8 +31,8 @@
background: url("//yun.dui88.com/h5/miniprogram/kejiji/web/dianji-tip.png") no-repeat center;
background-size: 100% 100%;
position: absolute;
z-index:
1
;
right:
88
px;
z-index:
2
;
right:
110
px;
top: 206px;
}
}
...
...
@@ -356,7 +356,7 @@
.act-shadow{
background: #fff;
border-radius: 12px;
width: 6
89
px;
width: 6
66
px;
height: 301px;
margin: 20px auto 30px;
display: flex;
...
...
src/pages/kejiji/webview/content/page/home.vue
View file @
5c9429ad
...
...
@@ -25,7 +25,7 @@
<div
class=
"act-desc"
>
{{
getText
(
item
.
desc
,
90
)
}}
</div>
<div
class=
"act-btns"
>
<div
class=
"act-btn"
@
click=
"tryGame(item)"
>
试玩
</div>
<div
class=
"act-btn act-share"
@
click=
"shareGame(item)"
>
分享
</div>
<div
class=
"act-btn act-share"
@
click=
"shareGame(item
, true
)"
>
分享
</div>
</div>
</div>
<div
class=
"act-ico"
:class=
"'type'+(index+1)"
>
{{
item
.
contentTag
}}
</div>
...
...
@@ -120,7 +120,8 @@ export default {
activitLyist
:
[],
weixinQrcode
:
''
,
showInterceptModal
:
false
,
sellerId
:
""
sellerId
:
""
,
loading
:
false
};
},
props
:
{
...
...
@@ -294,7 +295,7 @@ export default {
});
},
getH5Authorize
(){
let
url
=
'/kjy/authorize/wxh5base?uri=
/kjy/mp/content?mini=1'
;
let
url
=
'/kjy/authorize/wxh5base?uri=
'
+
encodeURIComponent
(
'/kjy/mp/content'
+
location
.
search
)
;
window
.
location
.
href
=
url
;
},
jump
(
item
){
...
...
@@ -316,16 +317,26 @@ export default {
wx
.
miniProgram
.
navigateTo
({
url
:
`/pages/webview/main?url=
${
url
}
`
});
}
},
async
shareGame
(
item
){
let
res_
=
await
get
(
API
.
userInfo
,
{});
if
(
res_
.
success
)
{
this
.
weixinQrcode
=
res_
.
data
.
sellerWxQrCode
;
this
.
sellerId
=
res_
.
data
.
sellerId
;
}
// if (!this.weixinQrcode) {
// this.showInterceptModal = true;
// return;
// }
async
shareGame
(
item
,
jump
){
if
(
this
.
loading
){
return
;
}
this
.
loading
=
true
;
setTimeout
(()
=>
{
this
.
loading
=
false
;
},
300
);
if
(
!
jump
){
// let res_ = await get(API.userInfo, {});
// if (res_.success) {
// this.weixinQrcode = res_.data.sellerWxQrCode;
// this.sellerId = res_.data.sellerId;
// }
// if (!this.weixinQrcode) {
// this.showInterceptModal = true;
// return;
// }
}
this
.
hiding
=
false
;
this
.
$emit
(
"close"
);
if
(
this
.
hiding
){
...
...
@@ -334,6 +345,7 @@ export default {
let
params
=
{
contentId
:
item
.
id
};
// wx.miniProgram.postMessage({data: "guide"});
let
res
=
await
get
(
API
.
getScId
,
params
);
if
(
res
.
success
)
{
let
id
=
res
.
data
;
...
...
src/pages/kejiji/webview/daily/page/today.less
View file @
5c9429ad
...
...
@@ -60,25 +60,25 @@
}
.rili{
background: url("//yun.dui88.com/h5/miniprogram/kejiji/web/rili.png") no-repeat center;
background: url("//yun.dui88.com/h5/miniprogram/kejiji/web/rili
3
.png") no-repeat center;
background-size: contain;
position: relative;
width: 724px;
height: 294px;
margin: 0 auto 0 28px;
.img{
background: url("//yun.dui88.com/h5
-mami/webgame/kejiji/webview/img/ren.png
") no-repeat center;
background: url("//yun.dui88.com/h5
/miniprogram/kejiji/images/rilis.gif
") no-repeat center;
background-size: contain;
position: absolute;
width:
2
00px;
height:
15
0px;
left:
6
0px;
top:
6
0px;
width:
3
00px;
height:
24
0px;
left:
2
0px;
top:
2
0px;
}
.day{
width: 100px;
text-align: center;
font-size:
80
px;
font-size:
72
px;
color: #FFFFFF;
position: absolute;
left: 328px;
...
...
@@ -99,8 +99,11 @@
position: absolute;
left: 504px;
top: 87px;
width: 1
08
px;
width: 1
16
px;
text-align: center;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
.bad{
font-size: 24px;
...
...
@@ -108,8 +111,11 @@
position: absolute;
left: 504px;
top: 148px;
width: 1
08
px;
width: 1
16
px;
text-align: center;
text-overflow: ellipsis;
white-space: nowrap;
overflow: hidden;
}
}
.header{
...
...
@@ -277,7 +283,7 @@
.new-title{
font-size: 32px;
color: #E21C2E;
line-height:
42
px;
line-height:
56
px;
margin-bottom: 30px;
font-weight: 600;
}
...
...
@@ -403,10 +409,10 @@
display: flex;
align-items: center;
.long-line{
width:
135
px;
height:
1
px;
width:
90
px;
height:
2
px;
margin-right: 18px;
background: #
999999
;
background: #
ccc
;
}
}
}
...
...
src/pages/kejiji/webview/daily/page/today.vue
View file @
5c9429ad
...
...
@@ -72,7 +72,7 @@
</div>
<share-footer
v-if=
"showShare"
@
doshare=
"doshare"
:sellerid=
"sellerId"
:wxqrcode=
"wechatQrCode"
></share-footer>
<share-footer
v-if=
"showShare"
@
doshare=
"doshare"
:sellerid=
"sellerId"
:wxqrcode=
"wechatQrCode"
:push=
"push"
></share-footer>
<toastTip
ref=
"toastTip"
></toastTip>
<div
class=
"dui-share__methods"
v-if=
"isShow"
@
click=
"closeModal"
>
<div
class=
"gudide-des"
>
从菜单中点击转发分享
</div>
...
...
@@ -92,6 +92,7 @@ import toastTip from '../../components/toastTip'
import
{
startTime
,
endTime
}
from
'../../../comm/readSec'
const
SCID
=
getUrlParameter
(
'scid'
);
const
PUSH
=
getUrlParameter
(
'push'
)
==
"push"
;
const
API
=
{
h5info
:
'/kjy/mp/content/h5info'
}
...
...
@@ -119,7 +120,8 @@ export default {
wechatQrCode
:
""
,
loaded
:
false
,
sellerId
:
null
,
inMini
:
false
inMini
:
false
,
push
:
false
};
},
components
:
{
ShareFooter
,
toastTip
},
...
...
@@ -170,11 +172,17 @@ export default {
if
(
inMiniprogram
&&
res
.
data
.
myself
){
this
.
showShare
=
true
;
}
if
(
PUSH
){
this
.
showShare
=
true
;
}
if
(
FROM
===
'singlemessage'
&&
res
.
data
.
myself
)
{
this
.
isShow
=
true
;
}
var
link
=
location
.
origin
+
location
.
pathname
+
location
.
search
;
link
=
link
.
replace
(
"mini=1"
,
"mini=0"
);
link
=
link
.
replace
(
"push=push"
,
"push=0"
);
shareConfig
({
link
:
l
ocation
.
origin
+
location
.
pathname
+
location
.
search
,
link
:
l
ink
,
title
:
this
.
title
,
desc
:
'来自'
+
this
.
sellerName
+
'的分享'
,
img
:
location
.
protocol
+
this
.
mainImgUrl
,
...
...
@@ -190,7 +198,8 @@ export default {
},
getH5Authorize
(){
let
url
=
'/kjy/authorize/wxh5base?uri=/kjy/mp/daily?scid='
+
SCID
;
// let url = '/kjy/authorize/wxh5base?uri=' + encodeURIComponent(`/kjy/mp/daily?scid=${SCID}&mini=${inMiniprogram?1:0}&push=${PUSH?1:0}`);
let
url
=
'/kjy/authorize/wxh5base?uri='
+
encodeURIComponent
(
'/kjy/mp/daily'
+
encodeURIComponent
(
location
.
search
));
window
.
location
.
href
=
url
;
},
closeModal
()
{
...
...
@@ -234,8 +243,7 @@ export default {
}
},
doshare
(){
console
.
log
(
123
);
// updateLink(123);
},
showTip
(){
this
.
$refs
.
toastTip
.
showTip
(
"小程序中不支持跳转"
);
...
...
@@ -245,6 +253,10 @@ export default {
this
.
inMini
=
inMiniprogram
;
this
.
initData
();
startTime
(
SCID
);
if
(
PUSH
){
this
.
showShare
=
true
;
this
.
push
=
true
;
}
}
};
</
script
>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment