Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
S
SURPRISED
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
华国豪
SURPRISED
Commits
4e6a81a6
Commit
4e6a81a6
authored
Nov 13, 2019
by
zhengke
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
xiugia
parent
ab2e936b
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
212 additions
and
75 deletions
+212
-75
coupons.html
html/coupons.html
+10
-6
login.html
html/login.html
+2
-2
pay.html
html/pay.html
+127
-65
paySuccess.html
html/paySuccess.html
+70
-0
gou_big.png
images/login/gou_big.png
+0
-0
jquery.dataStatistics.js
js/jquery.dataStatistics.js
+3
-2
No files found.
html/coupons.html
View file @
4e6a81a6
...
@@ -17,6 +17,8 @@
...
@@ -17,6 +17,8 @@
}
}
.coupons_page
{
.coupons_page
{
width
:
100%
;
width
:
100%
;
min-height
:
100%
;
padding-bottom
:
3rem
;
background-color
:
#F8F5F5
;
background-color
:
#F8F5F5
;
}
}
.coupons_title
{
.coupons_title
{
...
@@ -109,8 +111,8 @@
...
@@ -109,8 +111,8 @@
}
}
.coupons_Content
{
.coupons_Content
{
width
:
100%
;
width
:
100%
;
height
:
87.2%
;
/*
height:87.2%;
overflow
:
scroll
;
overflow: scroll;
*/
}
}
.coupons_List
{
.coupons_List
{
width
:
80%
;
width
:
80%
;
...
@@ -311,7 +313,7 @@
...
@@ -311,7 +313,7 @@
<div
class=
"coupons_page"
>
<div
class=
"coupons_page"
>
<div
class=
"coupons_title"
>
<div
class=
"coupons_title"
>
<div
class=
"coupons_Navone"
onclick=
"showList()"
>
<div
class=
"coupons_Navone"
onclick=
"showList()"
>
<span
class=
"useType"
></span>
<span
class=
"useType"
>
不限
</span>
<div
class=
"arrow_down"
></div>
<div
class=
"arrow_down"
></div>
<i
class=
"bd_right"
></i>
<i
class=
"bd_right"
></i>
</div>
</div>
...
@@ -319,7 +321,7 @@
...
@@ -319,7 +321,7 @@
<div
class=
"Coupons_active"
onclick=
"getAllTicket(0,0,1)"
>
全部
</div>
<div
class=
"Coupons_active"
onclick=
"getAllTicket(0,0,1)"
>
全部
</div>
<div
onclick=
"getAllTicket(0,2,1)"
>
折扣券
</div>
<div
onclick=
"getAllTicket(0,2,1)"
>
折扣券
</div>
<div
onclick=
"getAllTicket(0,1,1)"
>
抵扣券
</div>
<div
onclick=
"getAllTicket(0,1,1)"
>
抵扣券
</div>
<div
onclick=
"getAllTicket(0,
0,4
)"
>
已过期
</div>
<div
onclick=
"getAllTicket(0,
1,3
)"
>
已过期
</div>
</div>
</div>
<div
class=
"coupons_tyList"
>
<div
class=
"coupons_tyList"
>
<span
class=
"activeClick"
onclick=
"getAllTicket(0,'',1)"
>
不限
</span>
<span
class=
"activeClick"
onclick=
"getAllTicket(0,'',1)"
>
不限
</span>
...
@@ -401,8 +403,6 @@
...
@@ -401,8 +403,6 @@
$
(
".coupons_tyList"
).
click
(
function
(
event
){
$
(
".coupons_tyList"
).
click
(
function
(
event
){
event
.
stopPropagation
();
event
.
stopPropagation
();
});
});
let
title
=
'不限'
;
$
(
'.useType'
).
html
(
title
);
$
(
".coupons_tyList span"
).
click
(
function
(){
$
(
".coupons_tyList span"
).
click
(
function
(){
$
(
this
).
addClass
(
'activeClick'
).
siblings
().
removeClass
(
'activeClick'
);
$
(
this
).
addClass
(
'activeClick'
).
siblings
().
removeClass
(
'activeClick'
);
$
(
'.coupons_tyList'
).
slideToggle
(
300
);
$
(
'.coupons_tyList'
).
slideToggle
(
300
);
...
@@ -473,6 +473,10 @@
...
@@ -473,6 +473,10 @@
if
(
dataArr
[
i
].
couponsUseScope
==
4
){
if
(
dataArr
[
i
].
couponsUseScope
==
4
){
str
+=
` <img src="../images/login/jp.png" alt=""/>`
str
+=
` <img src="../images/login/jp.png" alt=""/>`
}
}
if
(
dataArr
[
i
].
couponEffectStatus
==
3
){
str
+=
` <img src="../images/login/guoqi.png" alt=""/>`
}
str
+=
`<div class="dikouPrice">
str
+=
`<div class="dikouPrice">
<span>¥</span>
${
dataArr
[
i
].
denomination
}
<span>¥</span>
${
dataArr
[
i
].
denomination
}
</div>
</div>
...
...
html/login.html
View file @
4e6a81a6
...
@@ -339,7 +339,7 @@
...
@@ -339,7 +339,7 @@
window
.
location
.
href
=
'http://activity.oytour.com/html/GT_activities.html'
;
window
.
location
.
href
=
'http://activity.oytour.com/html/GT_activities.html'
;
}
}
}
catch
(
e
)
{
}
catch
(
e
)
{
//
window.location.href = 'http://activity.oytour.com/html/login.html';
window
.
location
.
href
=
'http://activity.oytour.com/html/login.html'
;
}
}
}
}
//跳转至激活
//跳转至激活
...
@@ -401,7 +401,7 @@
...
@@ -401,7 +401,7 @@
localStorage
.
u
=
JSON
.
stringify
(
userInfo
)
localStorage
.
u
=
JSON
.
stringify
(
userInfo
)
window
.
location
.
href
=
'http://activity.oytour.com/html/GT_activities.html'
;
window
.
location
.
href
=
'http://activity.oytour.com/html/GT_activities.html'
;
//window.location.href
=
'http://127.0.0.1:5500/html/GT_activities.html';
//window.location.href
=
'http://127.0.0.1:5500/html/GT_activities.html';
}
else
{
}
else
{
layer
.
msg
(
res
.
message
);
layer
.
msg
(
res
.
message
);
}
}
...
...
html/pay.html
View file @
4e6a81a6
...
@@ -26,22 +26,7 @@
...
@@ -26,22 +26,7 @@
text-align
:
center
;
text-align
:
center
;
font-size
:
2rem
;
font-size
:
2rem
;
color
:
#999999
;
color
:
#999999
;
margin
:
5rem
0
2rem
0
;
padding
:
5rem
0
2rem
0
;
}
.login_AgreeTitle
{
width
:
100%
;
height
:
8rem
;
text-align
:
center
;
font-size
:
2.3rem
;
line-height
:
8rem
;
border
:
0
;
box-shadow
:
0px
0px
20px
#d1d1d1
;
}
.login_AgreeTitle
img
{
position
:
relative
;
left
:
3rem
;
top
:
3rem
;
float
:
left
;
}
}
.pay_time
span
{
.pay_time
span
{
margin-left
:
1rem
;
margin-left
:
1rem
;
...
@@ -110,22 +95,23 @@
...
@@ -110,22 +95,23 @@
border
:
0
;
border
:
0
;
border-radius
:
1.5rem
;
border-radius
:
1.5rem
;
}
}
.layui-layer-content
{
font-size
:
1.8rem
!important
;
padding
:
2rem
1rem
!important
;
}
</style>
</style>
<body>
<body>
<div
class=
"pay_page"
>
<div
class=
"pay_page"
>
<div
class=
"price_Top"
>
<div
class=
"price_Top"
>
<div
class=
"login_AgreeTitle"
>
<img
onclick=
"gobackList()"
src=
"../images/login/login_arrowleft.png"
/>
支付订单
</div>
<div
class=
"pay_time"
>
<div
class=
"pay_time"
>
支付剩余时间
<span
>
24:00
</span>
支付剩余时间
<span
class=
"daojishi"
>
</span>
</div>
</div>
<div
class=
"pay_price"
>
<div
class=
"pay_price"
>
<span>
¥
</span>
<span>
9.9
</span>
<span>
¥
</span>
<span
id=
"pay_money"
>
</span>
</div>
</div>
<div
class=
"pay_quan"
>
<div
class=
"pay_quan"
>
9.9元抵扣200元代金券
</div>
</div>
<div
class=
"pay_zhifu"
>
<div
class=
"pay_zhifu"
>
<img
class=
"pay_one"
src=
"../images/login/wechat.png"
alt=
""
/>
<img
class=
"pay_one"
src=
"../images/login/wechat.png"
alt=
""
/>
...
@@ -143,49 +129,125 @@
...
@@ -143,49 +129,125 @@
</body>
</body>
<script
type=
"text/javascript"
src=
"../js/jquery-1.10.2.js"
></script>
<script
type=
"text/javascript"
src=
"../js/jquery-1.10.2.js"
></script>
<script
type=
"text/javascript"
src=
"../js/layer/layer.js"
></script>
<script
type=
"text/javascript"
src=
"../js/layer/layer.js"
></script>
<script
type=
"text/javascript"
src=
"../js/mian.js"
></script>
<script
src=
"../js/md5.js"
></script>
<script>
<script>
var
appId
=
urlparameter
(
"appId"
);
$
(
function
(){
var
timeStamp
=
urlparameter
(
"timeStamp"
);
if
(
sessionStorage
.
getItem
(
"payInfo"
)){
var
nonceStr
=
urlparameter
(
"nonceStr"
);
let
msgList
=
JSON
.
parse
(
sessionStorage
.
getItem
(
"payInfo"
));
var
pg
=
urlparameter
(
"pg"
);
$
(
"#pay_money"
).
html
(
msgList
.
dTotalPrice
);
var
signType
=
urlparameter
(
"signType"
);
$
(
".pay_quan"
).
html
(
msgList
.
sProductName
);
var
paySign
=
urlparameter
(
"paySign"
);
}
countdown
();
})
function
onBridgeReady
(){
var
second
=
180000
;
var
payBtn
=
true
;
WeixinJSBridge
.
invoke
(
var
changesecond
=
''
;
'getBrandWCPayRequest'
,
{
//倒计时
"appId"
:
appId
,
//公众号名称,由商户传入
function
countdown
()
{
"timeStamp"
:
timeStamp
,
//时间戳,自1970年以来的秒数
if
(
second
==
0
)
{
"nonceStr"
:
nonceStr
,
//随机串
payBtn
=
false
;
"package"
:
"prepay_id="
+
pg
,
changesecond
=
'00:00'
;
"signType"
:
signType
,
//微信签名方式:
$
(
".daojishi"
).
html
(
changesecond
);
"paySign"
:
paySign
//微信签名
return
;
},
}
var
time
=
setTimeout
(
function
()
{
function
(
res
){
let
str
=
formatSeconds
(
second
);
if
(
res
.
err_msg
==
"get_brand_wcpay_request:ok"
)
{
second
=
second
-
1
;
alert
(
"支付成功"
);
changesecond
=
str
;
}
// 使用以上方式判断前端返回,微信团队郑重提示:res.err_msg将在用户支付成功后返回 ok,但并不保证它绝对可靠。
$
(
".daojishi"
).
html
(
changesecond
);
}
countdown
();
);
},
1000
)
}
};
function
formatSeconds
(
value
)
{
var
theTime
=
parseInt
(
value
);
// 秒
function
pay
(){
var
theTime1
=
0
;
// 分
if
(
theTime
>
60
)
{
if
(
typeof
WeixinJSBridge
==
"undefined"
){
theTime1
=
parseInt
(
theTime
/
60
);
if
(
document
.
addEventListener
){
theTime
=
parseInt
(
theTime
%
60
);
document
.
addEventListener
(
'WeixinJSBridgeReady'
,
onBridgeReady
,
false
);
if
(
theTime1
>
60
)
{
}
else
if
(
document
.
attachEvent
){
theTime1
=
parseInt
(
theTime1
%
60
);
document
.
attachEvent
(
'WeixinJSBridgeReady'
,
onBridgeReady
);
}
document
.
attachEvent
(
'onWeixinJSBridgeReady'
,
onBridgeReady
);
}
}
var
result
=
""
+
parseInt
(
theTime
);
//秒
}
else
{
if
(
10
>
theTime
>
0
)
{
onBridgeReady
();
result
=
"0"
+
parseInt
(
theTime
);
//秒
}
}
else
{
result
=
""
+
parseInt
(
theTime
);
//秒
}
}
if
(
10
>
theTime1
>
0
)
{
result
=
"0"
+
parseInt
(
theTime1
)
+
":"
+
result
;
//分,不足两位数,首位补充0,
}
else
{
result
=
""
+
parseInt
(
theTime1
)
+
":"
+
result
;
//分
}
return
result
;
};
function
pay
(){
if
(
!
localStorage
.
openid
){
window
.
location
.
href
=
'http://activity.oytour.com/html/GT_activities.html'
;
}
if
(
!
payBtn
){
layer
.
msg
(
'您已经超出支付时间!'
);
}
var
payMsg
;
if
(
sessionStorage
.
getItem
(
"payInfo"
)){
payMsg
=
JSON
.
parse
(
sessionStorage
.
getItem
(
"payInfo"
));
}
let
msg
=
{
sOrderNo
:
payMsg
.
sOrderNo
,
//订单号
dTotalPrice
:
payMsg
.
dTotalPrice
,
//总价
sProductName
:
payMsg
.
sProductName
,
sCurOpenID
:
localStorage
.
openid
}
$
.
ajax
({
type
:
"POST"
,
url
:
`https://reborn.oytour.com/api/WeChatNotify/WechatOpenId?sOrderNo=
${
payMsg
.
sOrderNo
}
&sCurOpenID=
${
localStorage
.
openid
}
&domainName=http://reborn.oytour.com/api/WeChatNotify/DoPay`
,
contentType
:
"application/json"
,
async
:
false
,
success
:
function
(
res
)
{
if
(
res
.
resultCode
===
1
)
{
let
d
=
JSON
.
parse
(
res
.
data
);
onBridgeReady
(
d
.
appId
,
d
.
timeStamp
,
d
.
nonceStr
,
d
.
package
,
d
.
paySign
);
}
else
{
layer
.
msg
(
res
.
message
);
}
},
error
:
function
(
res
)
{
// layer.msg(res.message);
}
});
if
(
typeof
WeixinJSBridge
==
"undefined"
){
if
(
document
.
addEventListener
){
document
.
addEventListener
(
'WeixinJSBridgeReady'
,
onBridgeReady
,
false
);
}
else
if
(
document
.
attachEvent
){
document
.
attachEvent
(
'WeixinJSBridgeReady'
,
onBridgeReady
);
document
.
attachEvent
(
'onWeixinJSBridgeReady'
,
onBridgeReady
);
}
}
else
{
// onBridgeReady();
}
}
function
onBridgeReady
(
id
,
ts
,
ns
,
pa
,
ps
)
{
WeixinJSBridge
.
invoke
(
'getBrandWCPayRequest'
,
{
"appId"
:
id
,
//公众号名称,由商户传入
"timeStamp"
:
ts
,
//时间戳,自1970年以来的秒数
"nonceStr"
:
ns
,
//随机串
"package"
:
pa
,
"signType"
:
"MD5"
,
//微信签名方式:
"paySign"
:
ps
//微信签名
},
function
(
res
)
{
if
(
res
.
err_msg
==
"get_brand_wcpay_request:ok"
)
{
// 使用以上方式判断前端返回,微信团队郑重提示:
//res.err_msg将在用户支付成功后返回ok,但并不保证它绝对可靠。
alert
(
"get_brand_wcpay_request:ok"
);
}
});
}
</script>
</script>
</html>
</html>
html/paySuccess.html
0 → 100644
View file @
4e6a81a6
<html
lang=
"en"
>
<head>
<meta
http-equiv=
"Content-Type"
content=
"span/html; charset=utf-8"
/>
<meta
http-equiv=
"X-UA-Compatible"
content=
"IE=edge"
>
<meta
name=
"divport"
content=
"width=device-width, initial-scale=1.0, maximum-scale=1.0, minimum-scale=1.0, user-scalable=no, target-densitydpi=device-dpi"
/>
<meta
name=
"screen-orientation"
content=
"portrait"
>
</meta>
<meta
name=
"x5-orientation"
content=
"portrait"
>
</meta>
<title>
支付订单
</title>
</head>
<style>
body
,
div
,
dl
,
dt
,
dd
,
ul
,
ol
,
li
,
h1
,
h2
,
h3
,
h4
,
h5
,
h6
,
pre
,
code
,
form
,
fieldset
,
legend
,
input
,
button
,
spanarea
,
p
,
blockquote
,
th
,
td
{
margin
:
0
;
padding
:
0
;
}
.paySuccess
{
width
:
100%
;
height
:
100%
;
position
:
relative
;
text-align
:
center
;
}
.paySuccess
img
{
width
:
12rem
;
margin-top
:
15rem
;
}
.payStatus
{
color
:
#e95252
;
font-size
:
3rem
;
margin-top
:
4rem
;
}
.pay_goLook
{
border
:
2px
solid
#e95252
;
font-size
:
2rem
;
color
:
#e95252
;
width
:
15rem
;
height
:
5rem
;
line-height
:
5rem
;
border-radius
:
1rem
;
margin
:
15rem
auto
;
}
.lookQuan
{
position
:
absolute
;
bottom
:
9rem
;
font-size
:
2rem
;
width
:
100%
;
text-align
:
center
;
color
:
#A1A1A1
;
}
</style>
<body>
<div
class=
"paySuccess"
>
<img
src=
"../images/login/gou_big.png"
alt=
""
/>
<div
class=
"payStatus"
>
支付成功
</div>
<div
class=
"pay_goLook"
onclick=
"goDetail()"
>
前往查看
</div>
<div
class=
"lookQuan"
>
您也可以在[我的->我的优惠券]查看优惠券信息
</div>
</div>
</body>
<script
type=
"text/javascript"
src=
"../js/jquery-1.10.2.js"
></script>
<script>
function
goDetail
(){
//window.location.href = 'http://192.168.0.117:5500/html/coupons.html';
window
.
location
.
href
=
'http://activity.oytour.com/html/coupons.html'
;
}
</script>
</html>
images/login/gou_big.png
0 → 100644
View file @
4e6a81a6
7.02 KB
js/jquery.dataStatistics.js
View file @
4e6a81a6
...
@@ -279,8 +279,9 @@ $.fn.dataStatistics = function(options){
...
@@ -279,8 +279,9 @@ $.fn.dataStatistics = function(options){
data
.
dTotalPrice
=
res
.
data
.
preferPrice
;
data
.
dTotalPrice
=
res
.
data
.
preferPrice
;
data
.
customerId
=
userInfo
.
customerId
;
data
.
customerId
=
userInfo
.
customerId
;
sessionStorage
.
setItem
(
"payInfo"
,
JSON
.
stringify
(
data
));
sessionStorage
.
setItem
(
"payInfo"
,
JSON
.
stringify
(
data
));
//window.location.href = 'http://127.0.0.1:5500/html/pay.html';
//window.location.href = 'http://127.0.0.1:5500/html/pay.html';
//window.location.href = 'http://192.168.0.117:5500/html/pay.html';
window
.
location
.
href
=
'http://http://activity.oytour.com/html/pay.html'
;
window
.
location
.
href
=
'http://http://activity.oytour.com/html/pay.html'
;
}
}
...
...
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