Commit 90fb70f3 authored by baixian's avatar baixian

优化

parent 45ff5538
......@@ -57,7 +57,7 @@ class OpeartorChangeForm extends React.Component {
message: '请选择操作人',
},
],
})(<Select>{teacherList.map(ele => <Option key={ele.id} value={ele.id}>{ele.nickname}</Option>)}</Select>)
})(<Select placeholder="请选择操作人">{teacherList.map(ele => <Option key={ele.id} value={ele.id}>{ele.nickname}</Option>)}</Select>)
}
</Form.Item>
</Form>
......
import { routerRedux } from 'dva/router';
import { message } from 'antd';
import { delay } from 'redux-saga';
import {
LocalStorage,
SessionStorage,
......@@ -439,12 +440,13 @@ export default {
const newStudentAddParams = { ...studentAddParams };
newStudentAddParams.force = 1;
if (params && params.type === 'index') {
yield put(routerRedux.push('/sjd/student'));
yield put({
type: 'studentsAdd',
payload: {
...newStudentAddParams,
params: {
type: 'index', // 首页
type: 'sureAdd',
},
},
});
......@@ -565,6 +567,11 @@ export default {
indexQrcodeTitle: `请学员${data.data.name}扫描绑定小程序`,
},
});
yield delay(350);
}
console.log(params, 'params');
if (params && params.type === 'sureAdd') {
yield delay(300);
}
if (isBuycourse) {
const { courseList } = yield select(state => state.students);
......
......@@ -134,7 +134,7 @@ class StaticCenter extends React.Component {
goDeadlineStudent = () => {
const { dispatch, renew } = this.props;
if (renew.total === 0) {
message.warning('还没有续费提醒噢~');
message.warning('暂无学员课时数过低需要续费喔');
return;
}
dispatch({
......@@ -144,7 +144,7 @@ class StaticCenter extends React.Component {
goBirthStudent = () => {
const { dispatch, birthday } = this.props;
if (birthday.total === 0) {
message.warning('还没有学员过生日噢~');
message.warning('今天没有学员生日喔');
return;
}
dispatch({
......@@ -154,7 +154,7 @@ class StaticCenter extends React.Component {
goCallStudent = () => {
const { dispatch, callData } = this.props;
if (callData.total === 0) {
message.warning('还没有未点名的学生噢~');
message.warning('当前暂无未点名课次喔');
return;
}
dispatch({
......@@ -170,7 +170,7 @@ class StaticCenter extends React.Component {
goPlanStudent = () => {
const { dispatch, assign } = this.props;
if (assign.total === 0) {
message.warning('还没有分配的学员噢~');
message.warning('当前暂无未分配学员喔');
return;
}
dispatch({
......
......@@ -755,6 +755,7 @@ class StudentMgt extends React.Component {
qrCodeTitle, isExpendMore, isChecked, isShowQuestion,
verifyValue,
} = this.state;
console.log(operator, 'operator');
const columns = [
{
title: '学员姓名',
......
import { connect } from 'dva';
import React from 'react';
import { Icon, Button, Row, Col, Input, InputNumber, Select, Checkbox, Table, Modal, Form, Alert } from 'antd';
import { message, Button, Row, Col, Input, InputNumber, Select, Checkbox, Table, Modal, Form, Alert } from 'antd';
import pageStyle from './newRenewEdit.less';
import { pageIn } from '../../utils/index';
const { Option } = Select;
......@@ -23,6 +23,10 @@ class NewRenewEdit extends React.Component {
e.preventDefault();
this.props.form.validateFields((err, values) => {
if (!err) {
if (values.operator_id === undefined || values.operator_id === '') {
message.warning('请先选择修改人');
return;
}
save(values, () => {
form.resetFields();
});
......@@ -221,7 +225,7 @@ class NewRenewEdit extends React.Component {
{getFieldDecorator('buy', {
rules: [
{
required: false,
required: true,
message: '请输入购买课时',
},
],
......@@ -245,7 +249,7 @@ class NewRenewEdit extends React.Component {
{getFieldDecorator('give', {
rules: [
{
required: false,
required: true,
message: '请输入赠送课时',
},
],
......@@ -273,7 +277,7 @@ class NewRenewEdit extends React.Component {
{getFieldDecorator('buy', {
rules: [
{
required: false,
required: true,
message: '请输入购买天数',
},
],
......@@ -298,7 +302,7 @@ class NewRenewEdit extends React.Component {
{getFieldDecorator('give', {
rules: [
{
required: false,
required: true,
message: '请输入赠送天数',
},
],
......
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