Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
campSite
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
杨梦雪
campSite
Commits
6b424068
Commit
6b424068
authored
Dec 29, 2021
by
杨梦雪
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
11
parent
31c22665
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
28 additions
and
19 deletions
+28
-19
src/components/index/SignUp/ConfirmSignUp.vue
src/components/index/SignUp/ConfirmSignUp.vue
+26
-17
src/components/index/SignUp/paying.vue
src/components/index/SignUp/paying.vue
+2
-2
No files found.
src/components/index/SignUp/ConfirmSignUp.vue
View file @
6b424068
...
...
@@ -9,16 +9,18 @@
@
close=
"cancelBtn()"
>
<div
class=
"pay_code"
>
<div
v-if=
"isShowqr"
>
<div
v-if=
"isShowqr
== 1
"
>
<!--
<div
class=
"pay_time"
>
支付剩余时间
<span>
15分30秒
</span></div>
-->
<div
class=
"money"
>
¥
{{
has_amount
}}
</div>
<div
class=
"img_qr"
>
<div
class=
"qrcode"
ref=
"qrCodeUrl"
></div>
</div>
<div>
请使用
<span>
微信
</span>
扫一扫,扫描二维码支付
</div>
<div>
付款码为动态码,仅支持通过本页面进行扫描付款操作,不支持另存图片后扫描支付。
</div>
<div>
付款码为动态码,仅支持通过本页面进行扫描付款操作,不支持另存图片后扫描支付。
</div>
<div
v-if=
"!isShowqr"
>
</div>
<div
v-if=
"isShowqr == 2"
>
<div
class=
"info_2"
style=
"color: #000; font-size: 18px"
>
<i
class=
"el-icon-warning"
></i>
{{
message
}}
</div>
...
...
@@ -35,7 +37,6 @@
<
script
>
/* eslint-disable */
import
Cookie
from
"
js-cookie
"
import
{
getWxConfig
}
from
"
r/index/pay
"
;
import
{
SERVER_WS_URL
}
from
"
config/server
"
;
import
QRCode
from
"
qrcodejs2
"
;
...
...
@@ -48,7 +49,7 @@ export default {
return
{
dialogVisible
:
this
.
confirmSignUpDialogFu
,
message
:
""
,
isShowqr
:
true
,
// 展示支付二维码
isShowqr
:
0
,
// 展示支付二维码
token
:
""
,
websocket
:
null
,
//websocket连接
lockReconnect
:
false
,
//是否真正建立连接
...
...
@@ -60,15 +61,18 @@ export default {
};
},
created
()
{
this
.
token
=
window
.
localStorage
.
getItem
(
"
index-token
"
+
this
.
$store
.
state
.
indexIdentity
);
this
.
has_amount
=
window
.
localStorage
.
getItem
(
"
has_amount
"
+
this
.
$store
.
state
.
indexIdentity
);
this
.
token
=
window
.
localStorage
.
getItem
(
"
index-token
"
+
this
.
$store
.
state
.
indexIdentity
);
this
.
has_amount
=
window
.
localStorage
.
getItem
(
"
has_amount
"
+
this
.
$store
.
state
.
indexIdentity
);
},
methods
:
{
async
confirm
()
{
// console.log(SERVER_WS_URL);
let
{
data
:
res
}
=
await
getWxConfig
({
// exam_uuid: this.examuuid,
pay_type
:
1
,
pay_type
:
3
,
});
// console.log(res);
...
...
@@ -76,11 +80,12 @@ export default {
if
(
res
.
code
==
400801
)
{
return
this
.
cancelBtn
();
}
this
.
isShowqr
=
2
;
this
.
message
=
res
.
message
;
this
.
isShowqr
=
false
;
return
;
}
this
.
isShowqr
=
true
;
this
.
isShowqr
=
1
;
this
.
createQrCode
(
res
.
code_url
);
//初始化 websocket 链接
this
.
initWebSocket
();
...
...
@@ -130,9 +135,9 @@ export default {
}
else
if
(
!
this
.
dialogVisible
)
{
return
;
}
else
{
let
code
=
this
.
$store
.
state
.
indexIdentity
let
code
=
this
.
$store
.
state
.
indexIdentity
;
if
(
!
this
.
token
||
this
.
token
==
""
)
{
this
.
token
=
window
.
localStorage
.
getItem
(
"
index-token
"
+
code
);
this
.
token
=
window
.
localStorage
.
getItem
(
"
index-token
"
+
code
);
}
let
token
=
this
.
token
;
const
wssURL
=
SERVER_WS_URL
+
"
/order?token=
"
+
token
+
"
&channel=pc
"
;
...
...
@@ -217,8 +222,12 @@ export default {
websocketSend
()
{
//数据发送
let
sendData
=
{
order_no
:
window
.
localStorage
.
getItem
(
"
order_no
"
+
this
.
$store
.
state
.
indexIdentity
),
cam_id
:
window
.
localStorage
.
getItem
(
"
campsite_id
"
+
this
.
$store
.
state
.
indexIdentity
),
order_no
:
window
.
localStorage
.
getItem
(
"
order_no
"
+
this
.
$store
.
state
.
indexIdentity
),
cam_id
:
window
.
localStorage
.
getItem
(
"
campsite_id
"
+
this
.
$store
.
state
.
indexIdentity
),
token
:
this
.
token
,
};
this
.
websocket
.
send
(
JSON
.
stringify
(
sendData
));
...
...
@@ -238,7 +247,7 @@ export default {
// status=6,跳转到报名成功页面
// this.$emit("getstatus", res.data.status.status);
let
code
=
this
.
$store
.
state
.
indexIdentity
;
this
.
$router
.
push
(
"
/signUp/success?code=
"
+
code
);
this
.
$router
.
push
(
"
/signUp/success?code=
"
+
code
);
}
else
{
//收到服务器信息,心跳重置
this
.
reset
();
...
...
src/components/index/SignUp/paying.vue
View file @
6b424068
...
...
@@ -133,10 +133,10 @@ export default {
}
},
toWeichat
()
{
this
.
dialogChoose
=
false
;
//
this.dialogChoose = false;
this
.
confirmSignUpDialogFu
=
true
;
// getWxConfig({
// pay_type:
1
,
// pay_type:
3
,
// }).then((res) => {
// console.log(res, "getWxConfig");
// if (res.data.code != 200) {
...
...
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