Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wechat-common
Overview
Overview
Details
Activity
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
xiaomai-cloud-class
wechat-common
Commits
028f4eed
Commit
028f4eed
authored
Jan 05, 2021
by
zhangleyuan
Browse files
Options
Browse Files
Download
Plain Diff
feat:解决合并代码后的冲突
parents
e50196d0
357a8af5
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
6 deletions
+7
-6
src/modules/authorize/index.jsx
+7
-6
No files found.
src/modules/authorize/index.jsx
View file @
028f4eed
...
...
@@ -14,9 +14,6 @@ class Authorize extends React.Component {
}
}
componentDidMount
()
{
// console.log("ticket",window.getParameterByName('ticket'))
// const searchParams = this.props.location.search;
// const {code,ticket} = queryString.parse(searchParams);
const
code
=
window
.
getParameterByName
(
'code'
);
const
ticket
=
window
.
getParameterByName
(
'ticket'
);
this
.
setState
({
...
...
@@ -29,6 +26,7 @@ class Authorize extends React.Component {
},()
=>
this
.
changeCodeState
())
}
else
{
this
.
getWechatUserInfo
();
}
}
changeCodeState
=
()
=>
{
...
...
@@ -48,18 +46,21 @@ class Authorize extends React.Component {
window
.
location
.
href
=
htmlUrl
;
}
getWechatUserInfo
=
()
=>
{
let
{
ticket
,
code
}
=
this
.
state
;
const
code
=
window
.
getParameterByName
(
'code'
);
const
ticket
=
window
.
getParameterByName
(
'ticket'
);
const
params
=
{
appTermEnum
:
"XIAOMAI_CLOUD_CLASS_PC_WEB_ADMIN"
,
code
,
storeId
:
"1192022572770412395"
,
ticket
}
Service
.
hades
(
'/anon/hades/bindWeChat'
,
params
).
then
(
Service
.
hades
(
'/anon/hades/bindWeChat'
,
params
).
then
((
res
)
=>
{
if
(
res
.
success
){
this
.
setState
({
hasBindWechat
:
true
})
)
}
})
}
render
()
{
const
{
hasBindWechat
}
=
this
.
state
...
...
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