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
a500adfc
Commit
a500adfc
authored
Oct 09, 2019
by
sujie@126.com
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dd
parent
050dce64
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
75 additions
and
24 deletions
+75
-24
launch.json
.vscode/launch.json
+14
-0
classmgt.js
src/models/classmgt.js
+2
-3
teachers.js
src/models/teachers.js
+18
-13
classrRgistration.js
src/pages/classmgt/classrRgistration.js
+22
-5
classrRgistration.less
src/pages/classmgt/classrRgistration.less
+15
-0
index.js
src/pages/classmgt/index.js
+2
-1
index.js
src/pages/student/index.js
+1
-1
index.less
src/pages/student/index.less
+1
-1
No files found.
.vscode/launch.json
0 → 100644
View file @
a500adfc
{
//
使用
IntelliSense
了解相关属性。
//
悬停以查看现有属性的描述。
//
欲了解更多信息,请访问
:
https
:
//go.microsoft.com/fwlink/?linkid=
830387
"version"
:
"0.2.0"
,
"configurations"
:
[
{
"type"
:
"node"
,
"request"
:
"launch"
,
"name"
:
"启动程序"
,
"program"
:
"${workspaceFolder}
\\
server"
}
]
}
\ No newline at end of file
src/models/classmgt.js
View file @
a500adfc
...
...
@@ -853,10 +853,9 @@ export default {
});
},
*
classInviteCode
({
payload
},
{
call
,
put
,
select
})
{
const
{
params
}
=
payload
;
const
{
params
,
type
}
=
payload
;
const
{
sid
,
schoolUserInfo
}
=
yield
select
(
state
=>
state
.
webapp
);
const
{
inviteClassInfo
}
=
yield
select
(
state
=>
state
.
classmgt
);
console
.
log
(
params
,
inviteClassInfo
,
schoolUserInfo
);
const
saveData
=
yield
call
(
commonAjax
.
courseTemplateAdd
,
{
school_id
:
sid
,
teacher_id
:
schoolUserInfo
.
id
,
...
...
@@ -879,7 +878,7 @@ export default {
yield
put
({
type
:
'updateState'
,
payload
:
{
classInviteqrcodeShow
:
true
,
classInviteqrcodeShow
:
!!
(
type
==
2
)
,
classInviteqrcodeUrl
:
qrcodeData
.
data
.
url
,
},
});
...
...
src/models/teachers.js
View file @
a500adfc
...
...
@@ -379,21 +379,26 @@ export default {
},
*
createInviteQrcode
({
payload
},
{
call
,
put
,
select
})
{
const
{
sid
}
=
yield
select
(
state
=>
state
.
webapp
);
const
qrcodeData
=
yield
call
(
commonAjax
.
generateQrcode
,
{
scene
:
`s=
${
sid
}
`
,
page
:
'src/pages/setting/bindmobile'
,
const
scholluuidData
=
yield
call
(
commonAjax
.
getschooluuid
,
{
school_id
:
sid
,
});
if
(
qrcodeData
.
code
==
200
)
{
message
.
success
(
'小程序码生成成功'
,
1
);
yield
put
({
type
:
'updateState'
,
payload
:
{
inviteCode
:
qrcodeData
.
data
.
url
,
inviteCodeShow
:
true
,
},
if
(
scholluuidData
.
code
==
200
)
{
const
qrcodeData
=
yield
call
(
commonAjax
.
generateQrcode
,
{
scene
:
`s=
${
sid
}
uuid=
${
scholluuidData
.
data
}
`
,
page
:
'src/pages/setting/bindmobile'
,
});
}
else
{
message
.
error
(
'小程序码生成失败'
,
1
);
if
(
qrcodeData
.
code
==
200
)
{
message
.
success
(
'小程序码生成成功'
,
1
);
yield
put
({
type
:
'updateState'
,
payload
:
{
inviteCode
:
qrcodeData
.
data
.
url
,
inviteCodeShow
:
true
,
},
});
}
else
{
message
.
error
(
'小程序码生成失败'
,
1
);
}
}
},
},
...
...
src/pages/classmgt/classrRgistration.js
View file @
a500adfc
import
{
connect
}
from
'dva'
;
import
React
from
'react'
;
import
PropTypes
from
'prop-types'
;
import
{
message
,
Row
,
Col
,
Input
,
Select
,
Modal
,
Form
,
Radio
,
InputNumber
}
from
'antd'
;
import
{
message
,
Row
,
Col
,
Input
,
Select
,
Modal
,
Form
,
Radio
,
InputNumber
,
Button
}
from
'antd'
;
import
ClipboardJS
from
'clipboard'
;
import
pageStyle
from
'./classrRgistration.less'
;
import
{
pageIn
,
imagify
}
from
'../../utils/index'
;
...
...
@@ -38,8 +38,8 @@ class ClassrRgistration extends React.Component {
}
save
=
()
=>
{
const
{
save
}
=
this
.
props
;
const
{
parmas
}
=
this
.
state
;
save
(
parmas
);
const
{
parmas
,
type
}
=
this
.
state
;
save
(
parmas
,
type
);
}
close
=
()
=>
{
const
{
close
}
=
this
.
props
;
...
...
@@ -54,8 +54,8 @@ class ClassrRgistration extends React.Component {
type
:
e
.
target
.
value
,
parmas
:
{
mode_type
:
1
,
buy
:
0
,
give
:
0
,
buy
:
1
,
give
:
1
,
},
});
}
...
...
@@ -125,6 +125,7 @@ class ClassrRgistration extends React.Component {
confirmLoading
=
{
classSubmitting
}
maskClosable
=
{
false
}
zIndex
=
{
110
}
footer
=
{
<
div
className
=
{
pageStyle
.
modalfooter
}
><
Button
key
=
"submit"
type
=
"primary"
onClick
=
{
this
.
save
}
>
生成报名码
<
/Button></
div
>
}
>
<
div
className
=
{
pageStyle
.
tipsBox
}
>
<
div
className
=
{
pageStyle
.
tipsIcon
}
><
/div
>
...
...
@@ -145,6 +146,22 @@ class ClassrRgistration extends React.Component {
<
Radio
value
=
{
2
}
>
批量给学员购买课时
/
天同时自动邀请进班
<
/Radio
>
<
/Radio.Group
>
<
/div
>
{
type
==
1
&&
<
div
className
=
{
`
${
pageStyle
.
codeImgBox
}
${
pageStyle
.
innerCodeImgBox
}
`
}
>
<
div
className
=
{
pageStyle
.
title
}
>
{
inviteClassInfo
.
title
}
<
/div
>
<
div
className
=
{
pageStyle
.
tips
}
>
长按识别进入“轻校通”小程序
,
填写信息自己的信息加入班级
<
/div
>
<
div
className
=
{
pageStyle
.
imgBox
}
>
<
img
className
=
{
pageStyle
.
qrCodeImage
}
src
=
{
imagify
(
qrcodeUrl
)}
alt
=
""
/>
<
/div
>
<
div
className
=
{
pageStyle
.
saveBtn
}
onClick
=
{
this
.
saveImg
}
>
保存邀请码图片至桌面
<
/div
>
<
div
className
=
{
pageStyle
.
footer
}
>
<
div
className
=
{
pageStyle
.
text
}
id
=
"copy"
>
各位同学家长,为了更好地服务于大家请点开图片长按识别填写自己的信息,加入班级;
<
/div
>
<
div
className
=
{
pageStyle
.
copyBtn
}
data
-
clipboard
-
target
=
"#copy"
id
=
"btnCopyLink"
>
复制文字
<
/div
>
<
/div
>
<
/div
>
}
{
type
==
2
&&
<
div
className
=
{
pageStyle
.
fromBox
}
>
<
div
className
=
{
pageStyle
.
fromTitle
}
>
收费模式
<
/div
>
...
...
src/pages/classmgt/classrRgistration.less
View file @
a500adfc
...
...
@@ -150,4 +150,19 @@
cursor: pointer;
}
}
}
.innerCodeImgBox{
position: relative;
left: 0;
top: 0;
margin-left: 0;
border-radius:4px;
border:1px solid rgba(0,0,0,0.15);
box-shadow:0px 0px 0px 0px rgba(0,0,0,0);
margin: 0 auto;
margin-top: 22px;
}
.modalfooter{
display: flex;
justify-content: center;
}
\ No newline at end of file
src/pages/classmgt/index.js
View file @
a500adfc
...
...
@@ -388,13 +388,14 @@ class ClassMgtForm extends React.Component {
},
});
}
classrRgistrationSave
=
(
params
)
=>
{
classrRgistrationSave
=
(
params
,
type
)
=>
{
//
const
{
dispatch
}
=
this
.
props
;
dispatch
({
type
:
'classmgt/classInviteCode'
,
payload
:
{
params
,
type
,
},
});
}
...
...
src/pages/student/index.js
View file @
a500adfc
...
...
@@ -687,6 +687,7 @@ class StudentMgt extends React.Component {
{
hasBtnPower
(
'sjd/student'
,
'enrolCode'
)
&&
<
Button
className
=
{
pageStyle
.
headerbtn
}
onClick
=
{
this
.
toSetSelfJoin
}
>
自助报名二维码
<
/Button>
}
{
hasBtnPower
(
'sjd/student'
,
'bundlingCode'
)
&&
<
Button
id
=
{
pageStyle
.
headerself
}
className
=
{
pageStyle
.
headerbtn
}
onClick
=
{
this
.
bindQrcodeShow
}
>
自助绑定二维码
<
/Button>
}
{
hasBtnPower
(
'sjd/student'
,
'bundlingCode'
)
&&
<
Button
id
=
{
pageStyle
.
headerself
}
loading
=
{
Inviteloading
}
className
=
{
pageStyle
.
headerbtn
}
onClick
=
{()
=>
this
.
inviteCodeDialogVisible
(
true
)}
>
快捷邀请学员
<
/Button>
}
<
Button
icon
=
"download"
className
=
{
pageStyle
.
downloadbtn
}
onClick
=
{()
=>
this
.
exportExcel
(
columns
)}
>
导出
<
/Button
>
<
/div
>
<
div
className
=
{
pageStyle
.
search
}
>
<
div
className
=
{
pageStyle
.
title
}
>
...
...
@@ -775,7 +776,6 @@ class StudentMgt extends React.Component {
<
Col
className
=
{
pageStyle
.
searchbtnbox
}
xs
=
{{
span
:
12
}}
sm
=
{{
span
:
12
}}
md
=
{{
span
:
12
}}
lg
=
{{
span
:
6
}}
>
<
Button
className
=
{
pageStyle
.
resetbtn
}
onClick
=
{
this
.
reset
}
>
重置
<
/Button
>
<
Button
className
=
{
pageStyle
.
searchbtn
}
type
=
"primary"
onClick
=
{
this
.
search
}
>
搜索
<
/Button
>
<
Button
icon
=
"download"
className
=
{
pageStyle
.
downloadbtn
}
onClick
=
{()
=>
this
.
exportExcel
(
columns
)}
>
导出
<
/Button
>
<
/Col
>
<
/Row
>
<
/div
>
...
...
src/pages/student/index.less
View file @
a500adfc
...
...
@@ -179,7 +179,7 @@
}
.downloadbtn{
margin-left: 15px;
//
margin-left: 15px;
}
@media (max-width: 988px) {
.searchbtnbox {
...
...
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