Commit ac084131 authored by wangxuelai's avatar wangxuelai

'最新代码提交'

parent 68a86984
......@@ -108,7 +108,6 @@ class SjdMenu extends React.Component {
!ele.isFather ?
<Menu.Item key={ele.id} style={menuItemStyle} onClick={() => this.selectedMenu(ele.id, null)}>
<div className={SjdMenuStyle.menuicon} style={defaultMenu == ele.id ? { width: ele.style.width, height: ele.style.height, backgroundImage: `url(${ele.activeurl})` } : { width: ele.style.width, height: ele.style.height, backgroundImage: `url(${ele.notactiveurl})` }} />
<Icon style={{ width: 0, minWidth: 'initial' }} />
<span>{ele.name}</span>
</Menu.Item> :
<SubMenu
......@@ -116,7 +115,6 @@ class SjdMenu extends React.Component {
title={
<span style={padding}>
<div className={SjdMenuStyle.menuicon} style={defaultMenu == ele.id ? { width: ele.style.width, height: ele.style.height, backgroundImage: `url(${ele.activeurl})` } : { width: ele.style.width, height: ele.style.height, backgroundImage: `url(${ele.notactiveurl})` }} />
<Icon style={{ width: 0, minWidth: 'initial' }} />
<span style={fontSize}>{ele.name}</span>
</span>
}
......@@ -124,7 +122,6 @@ class SjdMenu extends React.Component {
{ele.subMenues.map(submenu => (
<Menu.Item key={submenu.id} style={menuItemStyle} onClick={() => this.selectedMenu(submenu.id, submenu.fatherId)}>
<div className={SjdMenuStyle.menuicon} style={defaultMenu == submenu.id ? { width: submenu.style.width, height: submenu.style.height, backgroundImage: `url(${submenu.activeurl})` } : { width: submenu.style.width, height: submenu.style.height, backgroundImage: `url(${submenu.notactiveurl})` }} />
<Icon style={{ width: 0, minWidth: 'initial' }} />
<span>{submenu.name}</span>
</Menu.Item>
))}
......
......@@ -37,6 +37,7 @@
vertical-align: sub;
text-align: center;
line-height: 1;
margin-right: 10px;
// background: url('@{images}spriteicon.png') no-repeat;
background-size: 100% 100%;
}
......
......@@ -125,7 +125,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -154,7 +154,7 @@ export default {
type: 'indexstaic/todoSchedule',
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -209,7 +209,7 @@ export default {
}
if (pathname === '/sjd/classmgt') {
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -220,7 +220,7 @@ export default {
}
if (pathname === '/erp/schoollist') {
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -231,7 +231,7 @@ export default {
}
if (pathname === '/erp/usersetting') {
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -247,7 +247,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -263,7 +263,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -279,7 +279,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -295,7 +295,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -316,7 +316,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -344,7 +344,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -360,7 +360,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -378,7 +378,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -411,7 +411,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -446,7 +446,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -470,7 +470,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -504,7 +504,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -538,7 +538,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -577,7 +577,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -622,7 +622,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -668,7 +668,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -690,7 +690,7 @@ export default {
const clockmgtactive = pathToRegexp('/sjd/clockmgt/:themetype/:classid/:themeid').exec(pathname);
if (clockmgtactive) {
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [
{
......@@ -739,7 +739,7 @@ export default {
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......@@ -762,7 +762,7 @@ export default {
},
});
dispatch({
type: 'webapp/updateState',
type: 'updateState',
payload: {
breadcrumbList: [{
path: pathname,
......
......@@ -55,7 +55,7 @@ class Institutions extends React.Component {
{schoolDetail.category && schoolDetail.category.length > 0 && categorys.map((ele) => {
const content = [];
if (schoolDetail.category.indexOf(ele.id) != -1) {
content.push(<div className={pageStyles.categoryitem}>{ele.name}</div>);
content.push(<div className={pageStyles.categoryitem} key={ele.id}>{ele.name}</div>);
}
return content;
})}
......
......@@ -134,7 +134,7 @@ class ClassMgtForm extends React.Component {
],
})(
<Select placeholder="请选择学员" style={{ width: 174 }} showSearch onChange={this.handleStudentChange}>
{allStudentList.map(ele => <Option value={ele.id}>{ele.name}</Option>)}
{allStudentList.map(ele => <Option key={ele.id} value={ele.id}>{ele.name}</Option>)}
</Select>,
)}
</FormItem>
......@@ -179,7 +179,7 @@ class ClassMgtForm extends React.Component {
},
],
})(<TextArea
autosize={{ minRows: 3, maxRows: 5 }}
autoSize={{ minRows: 3, maxRows: 5 }}
placeholder="请输入"
/>)}
</FormItem>
......
......@@ -87,6 +87,7 @@ class StoreMgt extends React.Component {
columns={columns}
pagination={false}
scroll={{ x: 'max-content' }}
rowKey="id"
footer={() => (
<div className="tablefooterbox">
<span className="tablefooterstatic">{recordListTotal}条数据</span>
......
......@@ -176,7 +176,7 @@ class CouponAddModal extends React.Component {
},
],
})(<TextArea
autosize={{ minRows: 3, maxRows: 5 }}
autoSize={{ minRows: 3, maxRows: 5 }}
placeholder="请输入其他说明"
/>)}
</FormItem>
......@@ -185,12 +185,12 @@ class CouponAddModal extends React.Component {
);
}
}
CouponAddModal.propTypes = {
isEdit: false,
};
CouponAddModal.defaultProps = {
isEdit: false,
};
// CouponAddModal.propTypes = {
// isEdit: false,
// };
// CouponAddModal.defaultProps = {
// isEdit: false,
// };
const ClassMgt = Form.create()(CouponAddModal);
......
......@@ -208,7 +208,7 @@ class GoodsAddModal extends React.Component {
<div className={pageStyle.smallImgBox}>
<Icon className={pageStyle.smallImgBoxClose} onClick={this.imgCancelUpdate} type="close" />
{editCouponInfo.banner && editCouponInfo.banner.map((img, i) => (
<div className={pageStyle.smallImgItem}>
<div className={pageStyle.smallImgItem} key={img}>
<div className={pageStyle.smallImgItembox}>
<img alt="" src={imagify(img)} />
<div className={pageStyle.imgdelandupdate}>
......@@ -305,7 +305,7 @@ class GoodsAddModal extends React.Component {
},
],
})(<TextArea
autosize={{ minRows: 3, maxRows: 5 }}
autoSize={{ minRows: 3, maxRows: 5 }}
placeholder="请输入其他说明"
/>)}
</FormItem>
......@@ -314,12 +314,12 @@ class GoodsAddModal extends React.Component {
);
}
}
GoodsAddModal.propTypes = {
isEdit: false,
};
GoodsAddModal.defaultProps = {
isEdit: false,
};
// GoodsAddModal.propTypes = {
// isEdit: false,
// };
// GoodsAddModal.defaultProps = {
// isEdit: false,
// };
function mapStateToProps(state) {
// eslint-disable-next-line no-empty-pattern
const {
......
......@@ -302,7 +302,7 @@ class StoreMgt extends React.Component {
<span>
{hasBtnPower('sjd/integralmanage', 'addGoods') &&
<a
href="javascript:;"
href="javascript:void(0)"
onClick={() => this.editCoupon(row)}
>
编辑
......@@ -311,7 +311,7 @@ class StoreMgt extends React.Component {
{hasBtnPower('sjd/integralmanage', 'del') && <Divider type="vertical" />}
{hasBtnPower('sjd/integralmanage', 'edit') &&
<a
href="javascript:;"
href="javascript:void(0)"
onClick={() => {
this.deleteItem(row);
}}
......@@ -334,6 +334,7 @@ class StoreMgt extends React.Component {
columns={columns}
scroll={{ x: 'max-content' }}
pagination={false}
rowKey="id"
/>
</div>
<Modal
......
......@@ -129,7 +129,7 @@ class Officialweb extends React.Component {
switch (ele.type) {
case 'schoolinfo':
renderDom = (
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox} ${index == moduleSelect ? pageStyle.moduleSelect : ''}`}
key={ele.type}
......@@ -158,7 +158,7 @@ class Officialweb extends React.Component {
break;
case 'banner':
renderDom = (
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox} ${index == moduleSelect ? pageStyle.moduleSelect : ''}`}
key={ele.type}
......@@ -187,7 +187,7 @@ class Officialweb extends React.Component {
break;
case 'course':
renderDom = (
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox} ${index == moduleSelect ? pageStyle.moduleSelect : ''}`}
key={ele.type}
......@@ -219,7 +219,7 @@ class Officialweb extends React.Component {
break;
case 'clocklist':
renderDom = (
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox} ${index == moduleSelect ? pageStyle.moduleSelect : ''}`}
key={ele.type}
......@@ -243,7 +243,7 @@ class Officialweb extends React.Component {
break;
case 'orgdesc':
renderDom = (
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox} ${index == moduleSelect ? pageStyle.moduleSelect : ''}`}
key={ele.type}
......
......@@ -105,7 +105,7 @@ class Officialweb extends React.Component {
switch (ele.type) {
case 'schoolinfo':
renderDom = (
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox}`}
key={ele.type}
......@@ -119,7 +119,7 @@ class Officialweb extends React.Component {
break;
case 'banner':
renderDom = (
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox}`}
key={ele.type}
......@@ -133,7 +133,7 @@ class Officialweb extends React.Component {
break;
case 'course':
renderDom = (ele.data.switch == 1 &&
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox}`}
key={ele.type}
......@@ -147,7 +147,7 @@ class Officialweb extends React.Component {
break;
case 'clocklist':
renderDom = (
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox}`}
key={ele.type}
......@@ -161,7 +161,7 @@ class Officialweb extends React.Component {
break;
case 'orgdesc':
renderDom = (
<div className={pageStyle.box}>
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox}`}
key={ele.type}
......
......@@ -17,7 +17,7 @@ function Banner(props) {
{banner.type == 'img' && banner.src.length > 1 &&
<div className={PageStyle.swiperbox}>
<Carousel autoplay>
{banner.src && banner.src.map(ele => <img className={PageStyle.videoPoster} src={imagify(ele)} alt="" />)}
{banner.src && banner.src.map(ele => <img className={PageStyle.videoPoster} key={ele} src={imagify(ele)} alt="" />)}
</Carousel>
</div>}
{banner.type == 'img' && banner.src.length == 1 &&
......
......@@ -139,7 +139,7 @@ class BannerEditor extends React.Component {
}
{bannerType == 2 && bannerImg.length > 0 &&
bannerImg.map((ele, index) => (
<div className={PageStyle.operateitembox}>
<div key={ele} className={PageStyle.operateitembox}>
<div className={PageStyle.imgoperatebox}>
{index == 0 && <div className={`${PageStyle.blockOperateItem} ${PageStyle.blockOperateItemGrey}`}><Icon className={PageStyle.blockOperateItemIcon} type="arrow-up" /></div>}
{index > 0 && <div className={PageStyle.blockOperateItem} onClick={() => this.movebannerimg(index, 'up')}><Icon className={PageStyle.blockOperateItemIcon} type="arrow-up" /></div>}
......
......@@ -96,7 +96,7 @@ class CourseEditorForm extends React.Component {
return (
<div className={`${PageStyle.SchoolInfoEditorcontainer} SchoolInfoEditorcontainer`}>
<div className={PageStyle.header}>体验课设置</div>
<Form className={PageStyle.FormBox} onSubmit={this.handleSubmit} hideRequiredMark={() => true}>
<Form className={PageStyle.FormBox} onSubmit={this.handleSubmit} hideRequiredMark>
<Form.Item label="状态" className={PageStyle.FormItemClass} colon={false} {...formItemLayout}>
{getFieldDecorator('switch', {
initialValue: course.switch,
......
......@@ -36,7 +36,7 @@ class Orgdesc extends React.Component {
</div>
<div className={PageStyle.ItemContainer}>
{orgdescs.length > 0 && orgdescs.map((ele, index) => (
<div className={`${PageStyle.ItemBox} ${PageStyle.OddBox}`}>
<div className={`${PageStyle.ItemBox} ${PageStyle.OddBox}`} key={ele.id}>
<div className={PageStyle.Item}>
{ele.type == 1 && <img src={imagify(ele.content[0])} className={PageStyle.descimg} alt="" />}
{ele.type == 2 && <img src={videoPoster(ele.content[0])} className={PageStyle.descimg} alt="" />}
......
......@@ -262,7 +262,7 @@ class OrgdescEditorForm extends React.Component {
<div className={PageStyle.smallImgBox}>
<Icon className={PageStyle.smallImgBoxClose} onClick={this.imgCancelUpdate} type="close" />
{ele.content.map((img, i) => (
<div className={PageStyle.smallImgItem}>
<div className={PageStyle.smallImgItem} key={img}>
<div className={PageStyle.smallImgItembox}>
<img alt="" src={imagify(img)} />
<div className={PageStyle.imgdelandupdate}>
......
......@@ -93,7 +93,7 @@ class SchoolInfoEditorForm extends React.Component {
<Form
className={PageStyle.FormBox}
onSubmit={this.handleSubmit}
hideRequiredMark={() => true}
hideRequiredMark
>
<Form.Item label="机构名" colon={false} className={PageStyle.FormItemClass} {...formItemLayout}>
{getFieldDecorator('title', {
......
......@@ -36,7 +36,7 @@ class StudentClock extends React.Component {
</div>
<div className={PageStyle.clockListBox}>
{clockList.list && clockList.list.length > 0 && clockList.list.map(ele => (
<div className={PageStyle.clockitem}>
<div className={PageStyle.clockitem} key={ele.id}>
<div className={PageStyle.clockiteminner}>
<div className={PageStyle.userinfo}>
<img src={imagify(ele.school_student.avatar)} className={PageStyle.avatar} alt="" />
......
......@@ -389,7 +389,7 @@ class SelectPlaceMap extends React.Component {
<Cascader
options={disData}
showSearch={this.filter}
changeOnSelect="true"
changeOnSelect
onChange={this.locationChange}
placeholder="请选择省市"
className={pageStyles.cityselect}
......@@ -414,7 +414,7 @@ class SelectPlaceMap extends React.Component {
{locationList.length > 0 &&
<div className={pageStyles.locationlistbox}>
{locationList.map((ele, index) => (
<div onClick={() => this.locationSelect(index)} className={`${pageStyles.locationitem} ${locationIndex == index ? pageStyles.locationitemselect : ''}`}>
<div key={ele.id} onClick={() => this.locationSelect(index)} className={`${pageStyles.locationitem} ${locationIndex == index ? pageStyles.locationitemselect : ''}`}>
<div className={pageStyles.locationiconbox}>
{index + 1}
</div>
......
......@@ -211,7 +211,7 @@ class SchoolAddForm extends React.Component {
required={false}
key={newIndex}
>
<Input placeholder="请输入联系电话" maxLength="20" value={k} onChange={e => this.mobileChange(e, newIndex)} />
<Input placeholder="请输入联系电话" maxLength={20} value={k} onChange={e => this.mobileChange(e, newIndex)} />
{mobile.length > 1 ? (
<Button className={pageStyles.delmobile} type="danger" onClick={() => this.delMobile(newIndex)}>删除</Button>
) : null}
......@@ -240,7 +240,7 @@ class SchoolAddForm extends React.Component {
message: '校区名称不能超过30个字',
},
],
})(<Input maxLength="30" placeholder="请输入校区名称" />)}
})(<Input maxLength={30} placeholder="请输入校区名称" />)}
</Form.Item>
</Col>
</Row>
......@@ -250,7 +250,7 @@ class SchoolAddForm extends React.Component {
{getFieldDecorator('category', {
})(
<div className={pageStyles.categotybox}>
{categorys.map(ele => <div className={`${pageStyles.categotyitem} ${selectcategorys.indexOf(ele.id) != -1 && pageStyles.categotyitemactive}`} onClick={() => this.categorySelect(ele)}>{ele.name}</div>)}
{categorys.map(ele => <div key={ele.id} className={`${pageStyles.categotyitem} ${selectcategorys.indexOf(ele.id) != -1 && pageStyles.categotyitemactive}`} onClick={() => this.categorySelect(ele)}>{ele.name}</div>)}
</div>)}
</Form.Item>
</Col>
......@@ -266,7 +266,7 @@ class SchoolAddForm extends React.Component {
message: '请输入联系人姓名',
},
],
})(<Input maxLength="20" placeholder="请输入联系人姓名" />)}
})(<Input maxLength={20} placeholder="请输入联系人姓名" />)}
</Form.Item>
</Col>
</Row>
......
......@@ -75,7 +75,7 @@ class ChooseClassModal extends React.Component {
})(
<Select className={pageStyle.selectitem} placeholder="全部课程" onChange={e => selectChange(e)}>
<Option value="">全部课程</Option>
{courseList.map(ele => <Option value={ele.id}>{ele.title}</Option>)}
{courseList.map(ele => <Option key={ele.id} value={ele.id}>{ele.title}</Option>)}
</Select>,
)}
</FormItem>
......@@ -89,7 +89,7 @@ class ChooseClassModal extends React.Component {
onChange={e => handleCheckClass(e)}
>
{ classList.map((item, index) =>
<div className={pageStyle.listwrap}> <Checkbox disabled={!item.can_cancel} value={item.id}>{item.title}</Checkbox></div>,
<div key={item.id} className={pageStyle.listwrap}> <Checkbox disabled={!item.can_cancel} value={item.id}>{item.title}</Checkbox></div>,
)}
</CheckboxGroup>,
......
......@@ -361,7 +361,7 @@ class ClassMgt extends React.Component {
},
{
title: '操作',
dataIndex: 'status',
// dataIndex: 'status',
render: (text, record) => {
return (
<div>
......@@ -393,7 +393,7 @@ class ClassMgt extends React.Component {
<div className={pageStyle.formitemlabel}>授课课程</div>
<Select className={pageStyle.selectitem} placeholder="请选择所属课程" value={searchteacherListQueryParams.course_id} onChange={e => this.searchParamsChange(e, 'Select', 'course_id')}>
<Option value="">全部课程</Option>
{courseList.map(ele => <Option value={ele.id}>{ele.title}</Option>)}
{courseList.map(ele => <Option key={ele.id} value={ele.id}>{ele.title}</Option>)}
</Select>
</Col>
<Col className={pageStyle.formitem} xs={{ span: 24 }} sm={{ span: 12 }} md={{ span: 12 }} lg={{ span: 5 }}>
......@@ -425,6 +425,7 @@ class ClassMgt extends React.Component {
columns={columns}
pagination={false}
scroll={{ x: 'max-content' }}
rowKey="id"
footer={() => (
<div className="tablefooterbox">
<span className="tablefooterstatic">{teacherListTotal}条数据</span>
......@@ -473,7 +474,7 @@ class ClassMgt extends React.Component {
>
<div className={pageStyle.invitationBox}>
{invitationTeacherList.map(ele => (
<div className={pageStyle.invitationitem}>
<div className={pageStyle.invitationitem} key={ele.id}>
<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>
......
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