Commit 4ca2dc93 authored by wangxuelai's avatar wangxuelai

''

parent d681ca91
......@@ -745,13 +745,7 @@ class ClassDetailForm extends React.Component {
});
return;
}
// if (classStudentTotal == 0) {
// Modal.warn({
// title: '该班级还没有学员,无法点名,请先添加学员',
// });
// return;
// }
if (new Date(datetime.replace(/-/g, '/')).getTime() - new Date(schedule.start_time.replace(/-/g, '/')).getTime() < -2 * 3600) {
if (new Date(datetime.replace(/-/g, '/')).getTime() - new Date(schedule.start_time.replace(/-/g, '/')).getTime() < (-2 * 3600 * 1000)) {
message.error(' 开课前两小时才能点名');
return;
}
......
......@@ -57,7 +57,7 @@ class teachersForm extends React.Component {
}
toCallStudents = (schedule) => {
const { dispatch, datetime } = this.props;
if (new Date(datetime.replace(/-/g, '/')).getTime() - new Date(schedule.start_time.replace(/-/g, '/')).getTime() < -2 * 3600) {
if (new Date(datetime.replace(/-/g, '/')).getTime() - new Date(schedule.start_time.replace(/-/g, '/')).getTime() < (-2 * 3600 * 1000)) {
message.error('开课前两小时才能点名');
return;
}
......
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