Commit 199a8137 authored by wangxuelai's avatar wangxuelai

'最新代码提交'

parent 1b0439ce
<!DOCTYPE html><html lang="en"><head><meta charset="UTF-8"><title>轻校</title><link rel="shortcut icon" href="https://cdn.img.shangjiadao.cn/qingxiao/biz/image/qxlogo4.png"><meta content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=0;" name="viewport"><meta http-equiv="X-UA-Compatible" content="IE=edge"><!-- Polyfills --><!--[if lt IE 10]> <!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>轻校</title>
<link rel="shortcut icon" href="https://cdn.img.shangjiadao.cn/qingxiao/biz/image/qxlogo4.png">
<meta content="width=device-width,initial-scale=1,maximum-scale=1,user-scalable=0;" name="viewport">
<meta http-equiv="X-UA-Compatible" content="IE=edge"><!-- Polyfills -->
<!--[if lt IE 10]>
<script src="js/console-polyfill.js"></script> <script src="js/console-polyfill.js"></script>
<![endif]--><script charset="utf-8" src="https://map.qq.com/api/js?v=2.exp&key=XSZBZ-5LHCV-5I2P7-UQHPW-6456F-JBB3B"></script><link href="/dist/index.css?1566791322338" rel="stylesheet"><script src="/lib/vendor.dll.js?3" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/console-polyfill.js?3" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/es6-shim.min.js?3" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/es5-shim.js?3" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/es5-sham.min.js?3" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/json3.min.js?3" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/html5shiv.min.js?3" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/polyfill.js?3" charset="utf-8"></script></head><body><div id="root"></div><script src="/dist/index.js?1566791322338" charset="utf-8"></script></body></html> <![endif]-->
\ No newline at end of file <script charset="utf-8" src="https://map.qq.com/api/js?v=2.exp&key=XSZBZ-5LHCV-5I2P7-UQHPW-6456F-JBB3B"></script>
<link href="/dist/index.css?1566806592255" rel="stylesheet">
<script src="/lib/vendor.dll.js?3" charset="utf-8"></script>
<script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/console-polyfill.js?3" charset="utf-8"></script>
<script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/es6-shim.min.js?3" charset="utf-8"></script>
<script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/es5-shim.js?3" charset="utf-8"></script>
<script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/es5-sham.min.js?3" charset="utf-8"></script>
<script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/json3.min.js?3" charset="utf-8"></script>
<script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/html5shiv.min.js?3" charset="utf-8"></script>
<script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/polyfill.js?3" charset="utf-8"></script>
</head>
<body>
<div id="root"></div>
<script src="/dist/index.js?1566806592255" charset="utf-8"></script>
</body>
</html>
\ No newline at end of file
...@@ -24,6 +24,7 @@ export default { ...@@ -24,6 +24,7 @@ export default {
courseTemplate: `${dakaapi}member/erp/course_template`, courseTemplate: `${dakaapi}member/erp/course_template`,
erpVerifyCode: `${dakaapi}common/sms`, erpVerifyCode: `${dakaapi}common/sms`,
erpVerifyCodeCheck: `${dakaapi}common/sms/check`, erpVerifyCodeCheck: `${dakaapi}common/sms/check`,
schoolLoginTime: `${dakaapi}member/erp/stronghold/login_time`,
newLogin: { newLogin: {
loginPost: `${dakaapi}common/business_login`, loginPost: `${dakaapi}common/business_login`,
}, },
......
...@@ -181,15 +181,17 @@ class CallStudentsForm extends React.Component { ...@@ -181,15 +181,17 @@ class CallStudentsForm extends React.Component {
type: 'callstudents/updateState', type: 'callstudents/updateState',
payload: { payload: {
bukeStudentModalShow: false, bukeStudentModalShow: false,
},
});
dispatch({
type: 'callstudents/updateState',
payload: {
selectedbukeClassKey: [], selectedbukeClassKey: [],
selectedbukeClassRow: [], selectedbukeClassRow: [],
}, },
}); });
// dispatch({
// type: 'callstudents/updateState',
// payload: {
// selectedbukeClassKey: [],
// selectedbukeClassRow: [],
// },
// });
} }
addbukeStudent = () => { addbukeStudent = () => {
const { dispatch } = this.props; const { dispatch } = this.props;
...@@ -250,6 +252,13 @@ class CallStudentsForm extends React.Component { ...@@ -250,6 +252,13 @@ class CallStudentsForm extends React.Component {
dispatch({ dispatch({
type: 'callstudents/sureaddLinShiStudent', type: 'callstudents/sureaddLinShiStudent',
}); });
// dispatch({
// type: 'callstudents/updateState',
// payload: {
// selectedLinshiClassKey: [],
// selectedLinshiClassRow: [],
// },
// });
} }
sureaddbukeStudent = () => { sureaddbukeStudent = () => {
const { dispatch } = this.props; const { dispatch } = this.props;
......
...@@ -8,4 +8,7 @@ ...@@ -8,4 +8,7 @@
.hasSearch { .hasSearch {
background-color: red; background-color: red;
color: #fff; color: #fff;
}
.endsearchcol {
margin-bottom: 24px;
} }
\ No newline at end of file
import React from 'react';
import { Modal, Icon } from 'antd';
import { imagify } from '../utils/index';
import pageStyle from './qrcodeShow.less';
class qrcodeShow extends React.Component {
constructor(props) {
super(props);
this.state = {
// date: '',
};
}
componentDidMount() { // 挂载
}
componentWillUnmount() { // 卸载
}
render() {
const {
previewQrcodeShow,
previewQrcode,
closeQrcodeShow,
title,
} = this.props;
return (
<div className={pageStyle.container} style={{ display: previewQrcodeShow ? 'flex' : 'none' }}>
<div className={pageStyle.mask}></div>
<div className={pageStyle.qrcodeBox}>
<Icon type="close-circle" className={pageStyle.closeIcon} onClick={closeQrcodeShow} />
<div className={pageStyle.boxHeader}>
<div className={pageStyle.headerTitle}>{title}</div>
</div>
<div className={pageStyle.qrCode}>
<img className={pageStyle.qrCodeImage} src={imagify(previewQrcode)} alt="" />
</div>
</div>
</div>
);
}
}
qrcodeShow.propTypes = {
};
export default qrcodeShow;
@import '../less/variables.less';
@keyframes qrCodefadeIn {
from {
opacity: 0;
}
to {
opacity: 1;
}
}
.container {
position: fixed;
width: 100%;
height: 100%;
left: 0;
top: 0;
z-index: 200;
display: flex;
align-items: center;
justify-content: center;
}
.mask {
position: absolute;
z-index: 1;
width: 100%;
height: 100%;
background-color: rgba(0,0,0,0.5);
}
.qrcodeBox {
width: 520px;
height: 320px;
border-radius: 10px;
background-color: #fff;
position: relative;
z-index: 2;
animation: qrCodefadeIn 0.1s linear 1 forwards;
// overflow: hidden;
}
.boxHeader {
height: 150px;
background-image: url('@{imagesroot}qrboxheader.png');
background-size: 100% 100%;
}
.headerTitle {
color: #fff;
text-align: center;
font-size: 18px;
line-height: 1;
padding-top: 34px;
}
.closeIcon {
position: absolute;
font-size: 30px;
color: rgba(255, 255, 255 ,0.7);
// right: 0;
// top: 0;
right: -15px;
z-index: 2;
top: -15px;
cursor: pointer;
&:hover {
transition: 0.2s;
color: rgba(255, 255, 255 ,1);
}
}
.qrCode {
text-align: center;
}
.qrCodeImage {
width: 160px;
height: 160px;
display: block;
margin: -10px auto 0;
}
\ No newline at end of file
import { routerRedux } from 'dva/router'; import { routerRedux } from 'dva/router';
import { message } from 'antd'; import { message, Modal } from 'antd';
import { import {
LocalStorage, LocalStorage,
SessionStorage, SessionStorage,
...@@ -369,6 +369,15 @@ export default { ...@@ -369,6 +369,15 @@ export default {
message.warn('请选择临时学员'); message.warn('请选择临时学员');
return; return;
} }
for (let i = 0, _length = selectedLinshiClassRow.length; i < _length; i++) {
const currentStudent = selectedLinshiClassRow[i];
if (callStudentOperateList.find(ele => ele.student_id == currentStudent.id)) {
Modal.warn({
title: `学生【${currentStudent.name}】已经在点名列表中,不能重复添加,请将该学员取消勾选后后点击确定`,
});
return;
}
}
selectedLinshiClassRow.forEach((ele) => { selectedLinshiClassRow.forEach((ele) => {
callStudentOperateList.push({ callStudentOperateList.push({
student_id: ele.id, student_id: ele.id,
...@@ -388,6 +397,8 @@ export default { ...@@ -388,6 +397,8 @@ export default {
callStudentTotal: newcallStudentTotal, callStudentTotal: newcallStudentTotal,
callStudentOperateList: [...callStudentOperateList], callStudentOperateList: [...callStudentOperateList],
linshiStudentModalShow: false, linshiStudentModalShow: false,
selectedLinshiClassKey: [],
selectedLinshiClassRow: [],
}, },
}); });
}, },
...@@ -400,6 +411,15 @@ export default { ...@@ -400,6 +411,15 @@ export default {
message.warn('请选择临时学员'); message.warn('请选择临时学员');
return; return;
} }
for (let i = 0, _length = selectedbukeClassRow.length; i < _length; i++) {
const currentStudent = selectedbukeClassRow[i];
if (callStudentOperateList.find(ele => ele.student_id == currentStudent.student_id)) {
Modal.warn({
title: `学生【${currentStudent.formal_school_student.name}】已经在点名列表中,不能重复添加,请将该学员取消勾选后后点击确定`,
});
return;
}
}
selectedbukeClassRow.forEach((ele) => { selectedbukeClassRow.forEach((ele) => {
const ELE = {}; const ELE = {};
ELE.student_id = ele.student_id; ELE.student_id = ele.student_id;
...@@ -421,6 +441,8 @@ export default { ...@@ -421,6 +441,8 @@ export default {
callStudentOperateList: [...callStudentOperateList], callStudentOperateList: [...callStudentOperateList],
linshiStudentModalShow: false, linshiStudentModalShow: false,
bukeStudentModalShow: false, bukeStudentModalShow: false,
selectedbukeClassKey: [],
selectedbukeClassRow: [],
}, },
}); });
}, },
...@@ -556,7 +578,7 @@ export default { ...@@ -556,7 +578,7 @@ export default {
const { sid } = yield select(state => state.webapp); const { sid } = yield select(state => state.webapp);
const callStudent = []; const callStudent = [];
callStudentOperateList.forEach((ele) => { callStudentOperateList.forEach((ele) => {
callStudent.push(`${ele.student_id},${ele.type},${ele.student_type},${ele.expend},${encodeURIComponent(ele.remark)},${ele.call_id || ''}`); callStudent.push(`${ele.student_id},${ele.type},${ele.student_type},${ele.expend || 0},${encodeURIComponent(ele.remark)},${ele.call_id || ''}`);
}); });
const loading = message.loading('点名处理中...', 0); const loading = message.loading('点名处理中...', 0);
const studentCallsDate = yield call(schedulemgtAjax.studentCalls, { const studentCallsDate = yield call(schedulemgtAjax.studentCalls, {
......
...@@ -194,7 +194,7 @@ export default { ...@@ -194,7 +194,7 @@ export default {
studentChangeScheduleListQueryParams, studentChangeScheduleListTotal, classDetail, classId, studentChangeScheduleListLoading, datetime, studentChangeScheduleListQueryParams, studentChangeScheduleListTotal, classDetail, classId, studentChangeScheduleListLoading, datetime,
} = yield select(state => state.classdetail); } = yield select(state => state.classdetail);
const { sid } = yield select(state => state.webapp); const { sid } = yield select(state => state.webapp);
const { params, action } = payload; const { params, action, exclude_student_id } = payload;
let loading = null; let loading = null;
if (action != 'init') { if (action != 'init') {
if (studentChangeScheduleListLoading) { if (studentChangeScheduleListLoading) {
...@@ -213,8 +213,9 @@ export default { ...@@ -213,8 +213,9 @@ export default {
school_id: sid, school_id: sid,
course_id: classDetail.course_id, course_id: classDetail.course_id,
exclude_class_id: params.exclude_class_id || classId, exclude_class_id: params.exclude_class_id || classId,
start_time: datetime.split(' ')[0], start_date: datetime,
end_time: '', exclude_student_id,
// end_time: '',
}); });
const queryScheduleListData = yield call(schedulemgtAjax.scheduleList, newScheduleListQueryParams); const queryScheduleListData = yield call(schedulemgtAjax.scheduleList, newScheduleListQueryParams);
if (action != 'init') { if (action != 'init') {
......
...@@ -10,6 +10,7 @@ import { ...@@ -10,6 +10,7 @@ import {
getRandomFilename, getRandomFilename,
} from '../utils/index'; } from '../utils/index';
import * as getschoollistajax from '../services/schoollist'; import * as getschoollistajax from '../services/schoollist';
import * as commonAjax from '../services/common';
import errorcode from '../common/errorcode'; import errorcode from '../common/errorcode';
import rootMap from '../common/constants'; import rootMap from '../common/constants';
export default { export default {
...@@ -57,7 +58,7 @@ export default { ...@@ -57,7 +58,7 @@ export default {
})); }));
}, },
* goSchoolSystem({ payload }, { call, put, select }) { * goSchoolSystem({ payload }, { call, put, select }) {
const { school, sid } = payload; const { school, sid, type } = payload;
LocalStorage.setItem('sid', sid || school.id); LocalStorage.setItem('sid', sid || school.id);
LocalStorage.setItem('role', school.school_teacher ? school.school_teacher.type : 5); LocalStorage.setItem('role', school.school_teacher ? school.school_teacher.type : 5);
if (school.school_teacher) { if (school.school_teacher) {
...@@ -72,6 +73,10 @@ export default { ...@@ -72,6 +73,10 @@ export default {
role: school.school_teacher ? school.school_teacher.type : '', role: school.school_teacher ? school.school_teacher.type : '',
}, },
}); });
yield call(commonAjax.schoolLoginTime, {
id: school.id,
type,
});
yield put(routerRedux.push({ yield put(routerRedux.push({
pathname: '/sjd/indexstaic', pathname: '/sjd/indexstaic',
})); }));
...@@ -127,7 +132,7 @@ export default { ...@@ -127,7 +132,7 @@ export default {
} }
}, },
* goDepartmentSystem({ payload }, { call, put, select }) { * goDepartmentSystem({ payload }, { call, put, select }) {
const { department } = payload; const { department, type } = payload;
LocalStorage.setItem('departmentid', department.id); LocalStorage.setItem('departmentid', department.id);
yield put({ yield put({
type: 'webapp/updateState', type: 'webapp/updateState',
...@@ -135,6 +140,10 @@ export default { ...@@ -135,6 +140,10 @@ export default {
departmentid: department.id, departmentid: department.id,
}, },
}); });
yield call(commonAjax.schoolLoginTime, {
id: department.id,
type,
});
yield put(routerRedux.push({ yield put(routerRedux.push({
pathname: '/sjd/headquarters/index', pathname: '/sjd/headquarters/index',
})); }));
......
...@@ -254,11 +254,13 @@ export default { ...@@ -254,11 +254,13 @@ export default {
} }
}, },
* createQrcode({ payload }, { call, put, select }) { * createQrcode({ payload }, { call, put, select }) {
const { mobile, callBack } = payload; const { mobile, callBack, random_str } = payload;
const loading = message.loading('绑定小程序二维码生成中...');
const qrcodeData = yield call(commonAjax.generateQrcode, { const qrcodeData = yield call(commonAjax.generateQrcode, {
scene: mobile, scene: `m=${mobile}&uid=${random_str}`,
page: 'src/pages/websiteindex/index', page: 'src/pages/signup/orgBindWx',
}); });
setTimeout(loading);
if (qrcodeData.code == 200) { if (qrcodeData.code == 200) {
message.success('小程序码生成成功', 1); message.success('小程序码生成成功', 1);
yield put({ yield put({
...@@ -303,6 +305,7 @@ export default { ...@@ -303,6 +305,7 @@ export default {
type: 'createQrcode', type: 'createQrcode',
payload: { payload: {
mobile, mobile,
random_str: checkoutData.data.random_str,
callBack, callBack,
}, },
}); });
......
...@@ -649,6 +649,7 @@ class ClassDetailForm extends React.Component { ...@@ -649,6 +649,7 @@ class ClassDetailForm extends React.Component {
dispatch({ dispatch({
type: 'classdetail/querystudentChangeScheduleList', type: 'classdetail/querystudentChangeScheduleList',
payload: { payload: {
exclude_student_id: student.id,
params: { params: {
page: 1, page: 1,
perPage: 10, perPage: 10,
......
...@@ -30,6 +30,7 @@ class JoinSchoolAddForm extends React.Component { ...@@ -30,6 +30,7 @@ class JoinSchoolAddForm extends React.Component {
type: 'schoollist/goSchoolSystem', type: 'schoollist/goSchoolSystem',
payload: { payload: {
school, school,
type: 1,
}, },
}); });
} }
...@@ -87,6 +88,7 @@ class JoinSchoolAddForm extends React.Component { ...@@ -87,6 +88,7 @@ class JoinSchoolAddForm extends React.Component {
type: 'schoollist/goDepartmentSystem', type: 'schoollist/goDepartmentSystem',
payload: { payload: {
department, department,
type: 2,
}, },
}); });
} }
...@@ -160,10 +162,12 @@ class JoinSchoolAddForm extends React.Component { ...@@ -160,10 +162,12 @@ class JoinSchoolAddForm extends React.Component {
<div className={pageStyles.rolename}>总部</div> <div className={pageStyles.rolename}>总部</div>
</Col> </Col>
</Row> </Row>
<Row className={pageStyles.logintimebox} type="flex" justify="space-between" align="middle"> {stronghold.last_login_time &&
<Col span={12} className={pageStyles.timetitle}>上次登录时间:</Col> <Row className={pageStyles.logintimebox} type="flex" justify="space-between" align="middle">
<Col span={12} className={pageStyles.time}>{stronghold.last_login_time}</Col> <Col span={12} className={pageStyles.timetitle}>上次登录时间:</Col>
</Row> <Col span={12} className={pageStyles.time}>{stronghold.last_login_time}</Col>
</Row>
}
</div> </div>
</Col> </Col>
} }
...@@ -173,7 +177,7 @@ class JoinSchoolAddForm extends React.Component { ...@@ -173,7 +177,7 @@ class JoinSchoolAddForm extends React.Component {
<div className={pageStyles.schoolbox}> <div className={pageStyles.schoolbox}>
<Row className={pageStyles.inviteschoolnamebox} type="flex" justify="space-between" align="middle"> <Row className={pageStyles.inviteschoolnamebox} type="flex" justify="space-between" align="middle">
{/* <Col span={24} className={pageStyles.inviteschoolname}>sadasdsadasdsa萨撒多撒sa萨达撒多撒多撒多撒</Col> */} {/* <Col span={24} className={pageStyles.inviteschoolname}>sadasdsadasdsa萨撒多撒sa萨达撒多撒多撒多撒</Col> */}
<Col span={24} className={pageStyles.inviteschooltext}>{ele.school.title}邀请你成为校区老师,你是否愿意加入?</Col> <Col span={24} className={pageStyles.inviteschooltext}><span className={pageStyles.invitefromname}>{ele.school.title}</span>邀请你成为校区老师,你是否愿意加入?</Col>
</Row> </Row>
<Row className={pageStyles.confirmbox} type="flex" justify="space-between" align="middle"> <Row className={pageStyles.confirmbox} type="flex" justify="space-between" align="middle">
<Col span={12} className={pageStyles.cancel} onClick={() => this.joinTeacheroperate(ele, 3)}>取消</Col> <Col span={12} className={pageStyles.cancel} onClick={() => this.joinTeacheroperate(ele, 3)}>取消</Col>
...@@ -189,7 +193,7 @@ class JoinSchoolAddForm extends React.Component { ...@@ -189,7 +193,7 @@ class JoinSchoolAddForm extends React.Component {
<div className={pageStyles.schoolbox}> <div className={pageStyles.schoolbox}>
<Row className={pageStyles.inviteschoolnamebox} type="flex" justify="space-between" align="middle"> <Row className={pageStyles.inviteschoolnamebox} type="flex" justify="space-between" align="middle">
{/* <Col span={24} className={pageStyles.inviteschoolname}>sadasdsadasdsa萨撒多撒sa萨达撒多撒多撒多撒</Col> */} {/* <Col span={24} className={pageStyles.inviteschoolname}>sadasdsadasdsa萨撒多撒sa萨达撒多撒多撒多撒</Col> */}
<Col span={24} className={pageStyles.inviteschooltext}>{ele.title}总部添加你到他的校区总部,你是否同意?</Col> <Col span={24} className={pageStyles.inviteschooltext}><span className={pageStyles.invitefromname}>{ele.stronghold && ele.stronghold.title}</span>添加你到他的校区总部,你是否同意?</Col>
</Row> </Row>
<Row className={pageStyles.confirmbox} type="flex" justify="space-between" align="middle"> <Row className={pageStyles.confirmbox} type="flex" justify="space-between" align="middle">
<Col span={12} className={pageStyles.cancel} onClick={() => this.joinDepartment(ele, 3)}>取消</Col> <Col span={12} className={pageStyles.cancel} onClick={() => this.joinDepartment(ele, 3)}>取消</Col>
......
...@@ -182,6 +182,11 @@ ...@@ -182,6 +182,11 @@
position: absolute; position: absolute;
right: 100px; right: 100px;
} }
.invitefromname {
font-weight: 700;
padding-right: 5px;
color: #000;
}
@media (max-width: 768px){ @media (max-width: 768px){
.content { .content {
padding: 23px 8px 33px; padding: 23px 8px 33px;
......
...@@ -187,23 +187,6 @@ class SelfJoinForm extends React.Component { ...@@ -187,23 +187,6 @@ class SelfJoinForm extends React.Component {
const { getFieldDecorator } = this.props.form; const { getFieldDecorator } = this.props.form;
return ( return (
<div> <div>
<Modal
visible={previewQrcodeShow}
footer={null}
onCancel={closeQrcodeShow}
title={<div style={{ textAlign: 'center', fontWeight: 700 }}>扫描二维码报名</div>}
>
<img
alt=""
src={imagify(previewQrcode)}
style={{
width: 200,
height: 200,
display: 'block',
margin: '0 auto',
}}
/>
</Modal>
<Modal <Modal
visible={visible} visible={visible}
title={<div><span style={{ fontWeight: 700 }}>自主报名</span><Button onClick={this.toAddCourseQrcode} style={{ marginLeft: '30px' }} type="primary" size="small">新&nbsp;&nbsp;增</Button></div>} title={<div><span style={{ fontWeight: 700 }}>自主报名</span><Button onClick={this.toAddCourseQrcode} style={{ marginLeft: '30px' }} type="primary" size="small">新&nbsp;&nbsp;增</Button></div>}
......
...@@ -9,11 +9,13 @@ import EliminateEdit from './eliminateEdit'; ...@@ -9,11 +9,13 @@ import EliminateEdit from './eliminateEdit';
import SelfJoin from './SelfJoin'; import SelfJoin from './SelfJoin';
import StudentAdd from './StudentAdd'; import StudentAdd from './StudentAdd';
import Cropper from '../../components/Cropper'; import Cropper from '../../components/Cropper';
import QrcodeShow from '../../components/qrcodeShow';
const { Option } = Select; const { Option } = Select;
const { TextArea } = Input; const { TextArea } = Input;
class StudentMgt extends React.Component { class StudentMgt extends React.Component {
state = { state = {
cage: 0, cage: 0,
qrCodeTitle: '',
avatorUploader: { avatorUploader: {
maxsize: 8192, // 奖品图片最大尺寸KBcropper: { maxsize: 8192, // 奖品图片最大尺寸KBcropper: {
cropper: { cropper: {
...@@ -177,6 +179,9 @@ class StudentMgt extends React.Component { ...@@ -177,6 +179,9 @@ class StudentMgt extends React.Component {
type: 'students/studentsAdd', type: 'students/studentsAdd',
payload: value, payload: value,
}); });
this.setState({
qrCodeTitle: `请学员${value.name}扫描绑定小程序`,
});
} }
closeEditClassModal = () => { closeEditClassModal = () => {
const { dispatch } = this.props; const { dispatch } = this.props;
...@@ -408,6 +413,9 @@ class StudentMgt extends React.Component { ...@@ -408,6 +413,9 @@ class StudentMgt extends React.Component {
record, record,
}, },
}); });
this.setState({
qrCodeTitle: '扫码自助报名',
});
} }
// 自主报名相关代码 // 自主报名相关代码
// 图片上传的接口 // 图片上传的接口
...@@ -461,6 +469,9 @@ class StudentMgt extends React.Component { ...@@ -461,6 +469,9 @@ class StudentMgt extends React.Component {
payload: { payload: {
}, },
}); });
this.setState({
qrCodeTitle: '微信扫描绑定小程序',
});
} }
// 图片上传的接口 // 图片上传的接口
generateSingleBindQrcode = (student) => { generateSingleBindQrcode = (student) => {
...@@ -472,6 +483,9 @@ class StudentMgt extends React.Component { ...@@ -472,6 +483,9 @@ class StudentMgt extends React.Component {
school_id: student.school_id, school_id: student.school_id,
}, },
}); });
this.setState({
qrCodeTitle: `请学员${student.name}扫描绑定小程序`,
});
} }
render() { render() {
const { getFieldDecorator } = this.props.form; const { getFieldDecorator } = this.props.form;
...@@ -517,6 +531,7 @@ class StudentMgt extends React.Component { ...@@ -517,6 +531,7 @@ class StudentMgt extends React.Component {
modeToCourse, modeToCourse,
// 续课的逻辑代码 // 续课的逻辑代码
} = this.props; } = this.props;
const { qrCodeTitle } = this.state;
const columns = [ const columns = [
{ {
title: '学员姓名', title: '学员姓名',
...@@ -705,7 +720,7 @@ class StudentMgt extends React.Component { ...@@ -705,7 +720,7 @@ class StudentMgt extends React.Component {
</Col> </Col>
<Col className={pageStyle.formitem} xs={{ span: 24 }} sm={{ span: 12 }} md={{ span: 12 }} lg={{ span: 3 }}> <Col className={pageStyle.formitem} xs={{ span: 24 }} sm={{ span: 12 }} md={{ span: 12 }} lg={{ span: 3 }}>
<div className={pageStyle.formitemlabel} >学员年龄</div> <div className={pageStyle.formitemlabel} >学员年龄</div>
<InputNumber style={{ width: 38 }} value={searchstudentListQueryParams.age_start} onChange={e => this.searchParamsChange(e, 'Select', 'age_start')} /> ~ <InputNumber style={{ width: 38 }} value={searchstudentListQueryParams.age_end} onChange={e => this.searchParamsChange(e, 'Select', 'age_end')} /> <InputNumber style={{ width: 38 }} value={searchstudentListQueryParams.age_start} min="0" onChange={e => this.searchParamsChange(e, 'Select', 'age_start')} /> ~ <InputNumber style={{ width: 38 }} min="0" value={searchstudentListQueryParams.age_end} onChange={e => this.searchParamsChange(e, 'Select', 'age_end')} />
</Col> </Col>
<Col className={pageStyle.searchbtnbox} xs={{ span: 12 }} sm={{ span: 12 }} md={{ span: 12 }} lg={{ span: 6 }}> <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.resetbtn} onClick={this.reset}>重置</Button>
...@@ -739,6 +754,19 @@ class StudentMgt extends React.Component { ...@@ -739,6 +754,19 @@ class StudentMgt extends React.Component {
/> />
</div> </div>
</div> </div>
<QrcodeShow
previewQrcodeShow={previewBindQrcodeShow}
closeQrcodeShow={this.closeBindQrcodeShow}
previewQrcode={previewBindQrcode}
title={qrCodeTitle}
/>
<QrcodeShow
previewQrcodeShow={previewQrcodeShow}
closeQrcodeShow={this.closeQrcodeShow}
previewQrcode={previewQrcode}
title={qrCodeTitle}
/>
{/*
<Modal <Modal
visible={previewBindQrcodeShow} visible={previewBindQrcodeShow}
footer={null} footer={null}
...@@ -756,6 +784,7 @@ class StudentMgt extends React.Component { ...@@ -756,6 +784,7 @@ class StudentMgt extends React.Component {
}} }}
/> />
</Modal> </Modal>
*/}
<RenewEdit <RenewEdit
// {...this.props} // {...this.props}
operator={operator} operator={operator}
...@@ -823,9 +852,6 @@ class StudentMgt extends React.Component { ...@@ -823,9 +852,6 @@ class StudentMgt extends React.Component {
editCourseModule={this.editCourseModule} editCourseModule={this.editCourseModule}
closeCourseQrcode={this.closeCourseQrcode} closeCourseQrcode={this.closeCourseQrcode}
toAddCourseQrcode={this.toAddCourseQrcode} toAddCourseQrcode={this.toAddCourseQrcode}
previewQrcode={previewQrcode}
previewQrcodeShow={previewQrcodeShow}
closeQrcodeShow={this.closeQrcodeShow}
seeCourseTmpQrcode={this.seeCourseTmpQrcode} seeCourseTmpQrcode={this.seeCourseTmpQrcode}
/> />
</div> </div>
......
...@@ -237,7 +237,7 @@ class StudentAddForm extends React.Component { ...@@ -237,7 +237,7 @@ class StudentAddForm extends React.Component {
}} }}
> >
{getFieldDecorator('class_ids', { {getFieldDecorator('class_ids', {
initialValue: (selectedCourseInfo.classes.length > 0 && selectedCourseInfo.classes.map(ele => ele.id)) || [], initialValue: (selectedCourseInfo.classes && selectedCourseInfo.classes.length > 0 && selectedCourseInfo.classes.map(ele => ele.id)) || [],
rules: [ rules: [
{ {
required: true, required: true,
......
...@@ -82,7 +82,7 @@ class UserSettingForm extends React.Component { ...@@ -82,7 +82,7 @@ class UserSettingForm extends React.Component {
</Form> </Form>
</div> </div>
</Modal> </Modal>
<Modal {/* <Modal
visible={previewQrcodeShow} visible={previewQrcodeShow}
footer={null} footer={null}
onCancel={closeQrcodeShow} onCancel={closeQrcodeShow}
...@@ -98,7 +98,8 @@ class UserSettingForm extends React.Component { ...@@ -98,7 +98,8 @@ class UserSettingForm extends React.Component {
margin: '0 auto', margin: '0 auto',
}} }}
/> />
</Modal> </Modal> */
}
</div> </div>
); );
} }
......
...@@ -4,6 +4,7 @@ import { Row, Col, Modal, Form, Input, Button, message } from 'antd'; ...@@ -4,6 +4,7 @@ import { Row, Col, Modal, Form, Input, Button, message } from 'antd';
import pageStyles from './index.less'; import pageStyles from './index.less';
import BindWx from './BindWx'; import BindWx from './BindWx';
import Cropper from '../../components/Cropper'; import Cropper from '../../components/Cropper';
import QrcodeShow from '../../components/qrcodeShow';
import { pageIn, imagify } from '../../utils/index'; import { pageIn, imagify } from '../../utils/index';
const { Search } = Input; const { Search } = Input;
const FormItem = Form.Item; const FormItem = Form.Item;
...@@ -361,6 +362,12 @@ class UserSettingForm extends React.Component { ...@@ -361,6 +362,12 @@ class UserSettingForm extends React.Component {
</Form.Item> </Form.Item>
</Form> </Form>
</Modal> </Modal>
<QrcodeShow
previewQrcodeShow={previewQrcodeShow}
closeQrcodeShow={this.closeQrcodeShow}
previewQrcode={previewQrcode}
title="微信扫描绑定机构二维码"
/>
<BindWx <BindWx
visible={bindWxShow} visible={bindWxShow}
userInfo={userInfo} userInfo={userInfo}
...@@ -369,9 +376,6 @@ class UserSettingForm extends React.Component { ...@@ -369,9 +376,6 @@ class UserSettingForm extends React.Component {
sendVerifyCode={this.sendBindWxVerifyCode} sendVerifyCode={this.sendBindWxVerifyCode}
onCancel={() => this.BindWxDiaVisible(false)} onCancel={() => this.BindWxDiaVisible(false)}
bindWxPost={this.bindWxPost} bindWxPost={this.bindWxPost}
previewQrcodeShow={previewQrcodeShow}
previewQrcode={previewQrcode}
closeQrcodeShow={this.closeQrcodeShow}
checkoutVerifyCode={checkoutVerifyCode} checkoutVerifyCode={checkoutVerifyCode}
/> />
</Row> </Row>
......
...@@ -81,3 +81,11 @@ export function erpVerifyCodeCheck(params) { ...@@ -81,3 +81,11 @@ export function erpVerifyCodeCheck(params) {
method: 'GET', method: 'GET',
}); });
} }
export function schoolLoginTime(params) {
const data = qs.stringify(params);
return request({
url: `${api.schoolLoginTime}?${data}`,
method: 'POST',
data,
});
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment