Commit 3339d300 authored by sujie@126.com's avatar sujie@126.com

Merge branch 'wxl-develop' of git.server:wangxuelai/biz.qingxiao.com into wxl-develop

parents d96cf023 d10c86d0
<!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>
<![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?1566004402151" 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?1566004402151" charset="utf-8"></script></body></html>
\ No newline at end of file
<![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?1566028670633" 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?1566028670633" charset="utf-8"></script></body></html>
\ No newline at end of file
......@@ -69,6 +69,9 @@ export default {
addClassStudents: `${dakaapi}member/erp/class/student/add`,
plansAdd: `${dakaapi}member/erp/plans`,
},
teacherMgt: {
teacherInvitations: `${dakaapi}member/erp/teacher/invitations`,
},
studentMgt: {
studentsList: `${dakaapi}member/erp/students`,
studentsRemove: `${dakaapi}member/erp/student/remove`,
......
......@@ -41,6 +41,15 @@ export default {
phone: '',
remark: '',
},
queryTeacherInvitationParams: {
school_id: 0,
page: 1,
perPage: 10,
status: '',
},
invitationTeacherList: [],
invitationTeacherTotal: 0,
invitationShow: false,
},
subscriptions: {
setup({ dispatch, history }) { // eslint-disable-line
......@@ -58,6 +67,31 @@ export default {
},
});
},
* queryInvitationList({ payload }, { call, put, select }) {
const { queryTeacherInvitationParams, invitationTeacherTotal } = yield select(state => state.teachers);
const { sid } = yield select(state => state.webapp);
const { params } = payload;
let newinvitationTeacherTotal = invitationTeacherTotal;
const newqueryTeacherInvitationParams = Object.assign({}, queryTeacherInvitationParams, params, {
school_id: sid,
});
const invitationData = yield call(teachersAjax.teacherInvitations, newqueryTeacherInvitationParams);
if (invitationData.code == 200) {
if (invitationData.data.total != undefined) {
newinvitationTeacherTotal = invitationData.data.total;
}
yield put({
type: 'updateState',
payload: {
invitationTeacherList: invitationData.data.list,
invitationTeacherTotal: newinvitationTeacherTotal,
queryTeacherInvitationParams: { ...newqueryTeacherInvitationParams },
},
});
} else {
message.error(invitationData.msg, 1);
}
},
* modalshowORhide({ payload }, { call, put, select }) {
const { visible } = payload;
yield put({
......
......@@ -440,6 +440,25 @@ class StudentAddForm extends React.Component {
)}
</Form.Item>
</Col>
<Col className={pageStyle.course}>
<Form.Item
label={<span>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;</span>}
labelCol={{
xs: { span: 24 },
sm: { span: 6 },
}}
wrapperCol={{
xs: { span: 24 },
sm: { span: 18 },
}}
>
{getFieldDecorator('operator_id', {
})(
<span>马老师</span>,
)}
<a href="javascript:;" className={pageStyle.changeOperate} >修改</a>
</Form.Item>
</Col>
<Col className={pageStyle.course}>
<Form.Item
label="赠送课时"
......
......@@ -8,6 +8,9 @@
text-align: center;
margin:-5px auto 5px;
}
.changeOperate {
margin-left: 10px;
}
:global {
.addstudentcontent {
.ant-form-item {
......
......@@ -240,6 +240,7 @@ class StudentMgt extends React.Component {
renewCourses,
courseRelateClassList,
datetime,
schoolUserInfo,
} = this.props;
const columns = [
{
......@@ -519,6 +520,9 @@ function mapStateToProps(state) {
const {
teacherList,
} = state.classmgt;
const {
schoolUserInfo,
} = state.webapp;
return {
studentsinfo,
addOrUpdateDiaShow,
......@@ -538,6 +542,7 @@ function mapStateToProps(state) {
renewCourses,
courseRelateClassList,
datetime,
schoolUserInfo,
};
}
export default connect(mapStateToProps)(ForgotPassword);
......
......@@ -97,6 +97,30 @@ class ClassMgt extends React.Component {
},
});
}
invitationSizeChange = (page, perPage) => {
const { dispatch } = this.props;
dispatch({
type: 'teachers/queryInvitationList',
payload: {
params: {
page: 1,
perPage,
},
},
});
}
invitationchangePagination = (page, perPage) => {
const { dispatch } = this.props;
dispatch({
type: 'teachers/queryInvitationList',
payload: {
params: {
page,
perPage,
},
},
});
}
handleSubmit = (values) => {
const { dispatch } = this.props;
const {
......@@ -125,6 +149,25 @@ class ClassMgt extends React.Component {
},
});
}
showInvitationTeacherShow = (visible) => {
const { dispatch } = this.props;
if (visible == true) {
dispatch({
type: 'teachers/queryInvitationList',
payload: {
params: {
page: 1,
},
},
});
}
dispatch({
type: 'teachers/updateState',
payload: {
invitationShow: visible,
},
});
}
render() {
const {
teachersinfo,
......@@ -135,6 +178,10 @@ class ClassMgt extends React.Component {
searchteacherListQueryParams,
teacherSubmitting,
editTeacherInfo,
invitationTeacherList,
invitationTeacherTotal,
queryTeacherInvitationParams,
invitationShow,
} = this.props;
const { getFieldDecorator } = this.props.form;
const columns = [
......@@ -256,7 +303,12 @@ class ClassMgt extends React.Component {
</div>
</div>
<div className={pageStyle.table}>
<div className={pageStyle.title}>老师信息</div>
<div className={pageStyle.title}>
<div className={pageStyle.titlename}>老师信息</div>
<div className={pageStyle.teacherNotice} onClick={() => this.showInvitationTeacherShow(true)}>
<span>老师加入通知</span>
</div>
</div>
<div className={pageStyle.tablebox}>
<Table
dataSource={teachersinfo}
......@@ -287,6 +339,44 @@ class ClassMgt extends React.Component {
editTeacherInfo={editTeacherInfo}
editType="add"
/>
<Modal
visible={invitationShow}
title={<span style={{ fontSize: '16px', fontWeight: 700 }}>老师加入通知</span>}
width={570}
heigh={432}
onCancel={() => this.showInvitationTeacherShow(false)}
confirmLoading={teacherSubmitting}
footer={null}
centered
>
<div className={pageStyle.invitationBox}>
{invitationTeacherList.map(ele => (
<div className={pageStyle.invitationitem}>
<div className={pageStyle.invitationteachername}>{ele.name}</div>
<div className={`${pageStyle.invitationstatus} ${ele.status == 1 ? pageStyle.waitjoin : pageStyle.notjoin}`}>{ele.status == 1 && '待加入'}{ele.status == 2 && '已加入'}{ele.status == 3 && '拒绝加入'}</div>
</div>
))}
{/* <div className={pageStyle.invitationitem}>
<div className={pageStyle.invitationteachername}>刘老师</div>
<div className={`${pageStyle.invitationstatus} ${pageStyle.notjoin}`}>待加入</div>
</div>
<div className={pageStyle.invitationitem}>
<div className={pageStyle.invitationteachername}>刘老师</div>
<div className={`${pageStyle.invitationstatus} ${pageStyle.notjoin}`}>拒绝加入</div>
</div> */}
<div className={pageStyle.invitationPagination}>
<Pagination
showSizeChanger
showQuickJumper
onShowSizeChange={this.invitationSizeChange}
total={Number(invitationTeacherTotal)}
onChange={this.invitationchangePagination}
current={Number(queryTeacherInvitationParams.page) || 1}
pageSize={queryTeacherInvitationParams.perPage}
/>
</div>
</div>
</Modal>
</div>
);
}
......@@ -305,6 +395,10 @@ function mapStateToProps(state) {
searchteacherListQueryParams,
teacherSubmitting,
editTeacherInfo,
invitationTeacherList,
queryTeacherInvitationParams,
invitationTeacherTotal,
invitationShow,
} = state.teachers;
const {
courseList,
......@@ -318,6 +412,10 @@ function mapStateToProps(state) {
searchteacherListQueryParams,
teacherSubmitting,
editTeacherInfo,
invitationTeacherList,
queryTeacherInvitationParams,
invitationTeacherTotal,
invitationShow,
};
}
export default connect(mapStateToProps)(ForgotPassword);
......
......@@ -15,13 +15,23 @@
background-color: #fff;
}
.title{
font-size:16px;
font-weight:500;
color:rgba(0,0,0,0.85);
line-height:55px;
height: 55px;
padding-left: 32px;
border-bottom: solid 1px rgba(233,233,233,1);
margin-bottom: 24px;
display: flex;
align-items: center;
.titlename {
margin-right: 36px;
font-size:16px;
font-weight:700;
color:rgba(0,0,0,0.85);
}
.teacherNotice {
color: #FFC042;
font-size: 14px;
cursor: pointer;
}
}
.tablebox {
padding: 0 34px;
......@@ -74,14 +84,35 @@
}
.name{
}
// :global(.ant-modal-body){
// padding:0;
// padding-top: 20px;
// }
// :global(.ant-form-explain){
// padding-left: 100px;
// }
.invitationBox {
.invitationPagination {
display: flex;
justify-content: flex-end;
}
.invitationitem {
display: flex;
align-items: center;
justify-content: space-between;
margin-bottom: 24px;
.invitationteachername {
font-size: 14px;
color: #000;
line-height: 1;
}
.invitationstatus {
font-size: 14px;
line-height: 1;
width: 60px;
text-align: center;
&.waitjoin {
color: #FFC042;
}
&.notjoin {
color: rgba(0,0,0,0.39);;
}
}
}
}
.ant-form-item {
position: relative;
}
......
......@@ -46,3 +46,11 @@ export function teachersSchedule(params) {
data,
});
}
export function teacherInvitations(params) {
const data = qs.stringify(params);
return request({
url: `${api.teacherMgt.teacherInvitations}?${data}`,
method: 'GET',
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