Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
B
biz.qingxiao.com
Project
Project
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wangxuelai
biz.qingxiao.com
Commits
cbade5a1
Commit
cbade5a1
authored
Dec 06, 2019
by
wangxuelai
Browse files
Options
Browse Files
Download
Plain Diff
Merge remote-tracking branch 'origin/bww-v1' into wxl-guide
parents
ffeaa2a4
d18f0268
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
56 additions
and
10 deletions
+56
-10
api.js
src/common/api.js
+1
-0
deployschool.js
src/models/deployschool.js
+20
-0
index.js
src/pages/deployschool/index.js
+23
-7
index.less
src/pages/deployschool/index.less
+2
-2
QxLogin.js
src/pages/login/QxLogin.js
+1
-1
newregister.js
src/services/newregister.js
+9
-0
No files found.
src/common/api.js
View file @
cbade5a1
...
...
@@ -207,4 +207,5 @@ export default {
send_code
:
`
${
dakaapi
}
common/sms`
,
},
deployschool
:
`
${
dakaapi
}
member/one_key_deploy`
,
selectdeployschool
:
`
${
dakaapi
}
member/one_key_deploy_status`
,
};
src/models/deployschool.js
View file @
cbade5a1
...
...
@@ -18,6 +18,7 @@ export default {
deployType
:
3
,
// 类型 1-口才 2-美术 3-书法 4-跆拳道 5-通用
sid
:
0
,
schoolUserInfo
:
{},
schoolStatus
:
''
,
// 1-部署中 2-部署结束
},
subscriptions
:
{
setup
({
dispatch
,
history
})
{
// eslint-disable-line
...
...
@@ -35,6 +36,9 @@ export default {
yield
put
({
type
:
'querymemberinfo'
,
});
yield
put
({
type
:
'selectStatus'
,
});
},
*
querymemberinfo
({
payload
},
{
call
,
put
,
select
})
{
// 释放该页面存储的所有状态
const
{
sid
}
=
yield
select
(
state
=>
state
.
deployschool
);
...
...
@@ -50,6 +54,20 @@ export default {
});
}
},
*
selectStatus
({
payload
},
{
call
,
put
,
select
})
{
// 释放该页面存储的所有状态
const
{
sid
}
=
yield
select
(
state
=>
state
.
deployschool
);
const
data
=
yield
call
(
newregister
.
selectDeploySchool
,
{
school_id
:
sid
,
});
if
(
data
.
code
==
200
)
{
yield
put
({
type
:
'updateState'
,
payload
:
{
schoolStatus
:
data
.
data
.
status
,
},
});
}
},
*
developSchool
({
payload
},
{
call
,
put
,
select
})
{
const
{
deployType
,
sid
}
=
yield
select
(
state
=>
state
.
deployschool
);
const
data
=
yield
call
(
newregister
.
deploySchool
,
{
...
...
@@ -61,6 +79,7 @@ export default {
type
:
'updateState'
,
payload
:
{
deployType
:
3
,
schoolStatus
:
2
,
},
});
}
else
{
...
...
@@ -150,6 +169,7 @@ export default {
type
:
'updateState'
,
payload
:
{
deployType
:
3
,
schoolStatus
:
''
,
},
});
},
...
...
src/pages/deployschool/index.js
View file @
cbade5a1
...
...
@@ -26,6 +26,11 @@ class DeploySchoolForm extends React.Component {
handleClick
=
()
=>
{
const
{
curStep
,
numberPercent
}
=
this
.
state
;
const
{
dispatch
}
=
this
.
props
;
dispatch
({
type
:
'deployschool/developSchool'
,
payload
:
{
},
});
this
.
setState
({
deployVisible
:
true
,
});
...
...
@@ -55,11 +60,6 @@ class DeploySchoolForm extends React.Component {
numberPercent
:
this
.
state
.
numberPercent
+=
1
,
});
},
45
);
dispatch
({
type
:
'deployschool/developSchool'
,
payload
:
{
},
});
}
handleCancelDeploy
=
()
=>
{
this
.
setState
({
...
...
@@ -91,10 +91,20 @@ class DeploySchoolForm extends React.Component {
},
});
}
handleGoIndex
=
()
=>
{
const
{
dispatch
}
=
this
.
props
;
dispatch
({
type
:
'deployschool/goHome'
,
payload
:
{
},
});
}
render
()
{
const
{
deployType
,
schoolStatus
,
}
=
this
.
props
;
console
.
log
(
schoolStatus
,
'schoolStatus'
);
const
{
deployVisible
,
curStep
,
numberPercent
}
=
this
.
state
;
const
typeList
=
[
{
id
:
3
,
title
:
'书法练字'
,
img
:
'/developschool/type_icon1.png'
},
...
...
@@ -116,7 +126,7 @@ class DeploySchoolForm extends React.Component {
{
typeList
.
map
((
item
,
index
)
=>
{
return
(
<
div
className
=
{
pageStyle
.
typeItem
}
onClick
=
{()
=>
this
.
handleChooseType
(
item
.
id
)}
>
<
div
key
=
{
index
}
className
=
{
pageStyle
.
typeItem
}
onClick
=
{()
=>
this
.
handleChooseType
(
item
.
id
)}
>
<
div
className
=
{
pageStyle
.
typeImg
}
>
<
img
className
=
{
pageStyle
.
img
}
src
=
{
`
${
__IMGCDN__
}${
item
.
img
}
`
}
alt
=
""
/>
{
...
...
@@ -130,7 +140,11 @@ class DeploySchoolForm extends React.Component {
})
}
<
/div
>
<
Button
type
=
"primary"
className
=
{
pageStyle
.
createBtn
}
onClick
=
{
this
.
handleClick
}
>
一键部署(
30899
位校长已部署)
<
/Button
>
{
schoolStatus
===
2
?
<
div
><
Button
type
=
"primary"
className
=
{
pageStyle
.
createBtn
}
onClick
=
{
this
.
handleGoIndex
}
>
您已部署成功,请直接进入体验
<
/Button></
div
>
:
<
div
><
Button
type
=
"primary"
className
=
{
pageStyle
.
createBtn
}
onClick
=
{
this
.
handleClick
}
>
一键部署(
30899
位校长已部署)
<
/Button></
div
>
}
<
div
className
=
{
pageStyle
.
skip
}
onClick
=
{
this
.
handleSkip
}
>
跳过
<
/div
>
<
Modal
visible
=
{
deployVisible
}
...
...
@@ -260,11 +274,13 @@ DeploySchool.propTypes = {
function
mapStateToProps
(
state
)
{
const
{
deployType
,
schoolStatus
,
}
=
state
.
deployschool
;
const
{
locationQuery
}
=
state
.
webapp
;
return
{
locationQuery
,
deployType
,
schoolStatus
,
};
}
export
default
connect
(
mapStateToProps
)(
DeploySchool
);
src/pages/deployschool/index.less
View file @
cbade5a1
...
...
@@ -36,7 +36,7 @@
display: flex;
align-items: center;
justify-content: center;
margin-top:
4
0px;
margin-top:
7
0px;
.typeItem {
.typeImg {
width: 115px;
...
...
@@ -72,7 +72,7 @@
line-height: 60px;
font-size: 16px;
color: #fff;
margin-top: 1
1
0px;
margin-top: 1
3
0px;
width: 390px;
}
.modalWrap {
...
...
src/pages/login/QxLogin.js
View file @
cbade5a1
...
...
@@ -185,7 +185,7 @@ class QxLoginForm extends React.Component {
<
/Form
>
<
div
className
=
{
LoginStyles
.
registerbox
}
>
<
div
className
=
{
LoginStyles
.
noaccount
}
>
还没有账号?
<
/div
>
<
Link
className
=
{
LoginStyles
.
goregister
}
to
=
"/register"
>
去注册
<
/Link
>
<
Link
className
=
{
LoginStyles
.
goregister
}
to
=
"/register"
target
=
"_blank"
>
去注册
<
/Link
>
<
/div
>
<
/div
>
<
/div
>
...
...
src/services/newregister.js
View file @
cbade5a1
...
...
@@ -36,3 +36,12 @@ export function forgetPassword(params) {
needAuth
:
false
,
});
}
export
function
selectDeploySchool
(
params
)
{
const
data
=
qs
.
stringify
(
params
);
return
request
({
url
:
`
${
api
.
selectdeployschool
}
?
${
data
}
`
,
method
:
'GET'
,
data
,
});
}
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