Commit 34ce7633 authored by baixian's avatar baixian

微官网

parent 371d834a
...@@ -11,13 +11,12 @@ ...@@ -11,13 +11,12 @@
<script src="js/console-polyfill.js"></script> <script src="js/console-polyfill.js"></script>
<![endif]--> <![endif]-->
<script charset="utf-8" src="https://map.qq.com/api/js?v=2.exp&key=XSZBZ-5LHCV-5I2P7-UQHPW-6456F-JBB3B"></script> <script charset="utf-8" src="https://map.qq.com/api/js?v=2.exp&key=XSZBZ-5LHCV-5I2P7-UQHPW-6456F-JBB3B"></script>
<script src="/js/ueeditor/ueditor.config.js?20200107" charset="utf-8"></script><script src="/js/ueeditor/ueditor.all.js?20200107" charset="utf-8"></script> <script src="/js/ueeditor/ueditor.config.js?20200107" charset="utf-8"></script><script src="/js/ueeditor/ueditor.all.js?20200107" charset="utf-8"></script>
<script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/console-polyfill.js?20200107" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/es6-shim.min.js?20200107" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/es5-shim.js?20200107" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/es5-sham.min.js?20200107" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/json3.min.js?20200107" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/html5shiv.min.js?20200107" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/js/polyfill.js?20200107" charset="utf-8"></script><script src="https://cdn.img.shangjiadao.cn/qingxiao/biz/lib/vendor.dll.js?20200107" charset="utf-8"></script> <script src="js/console-polyfill.js?20200107" charset="utf-8"></script><script src="js/es6-shim.min.js?20200107" charset="utf-8"></script><script src="js/es5-shim.js?20200107" charset="utf-8"></script><script src="js/es5-sham.min.js?20200107" charset="utf-8"></script><script src="js/json3.min.js?20200107" charset="utf-8"></script><script src="js/html5shiv.min.js?20200107" charset="utf-8"></script><script src="js/polyfill.js?20200107" charset="utf-8"></script><script src="lib/vendor.dll.js?20200107" charset="utf-8"></script>
</head> </head>
</head> </head>
<body> <body>
<div id="root"></div> <div id="root"></div>
<script type="text/javascript" src="/dist/main.31c1eb.js"></script></body> <script type="text/javascript" src="/dist/main.f651b7.js"></script></body>
</html> </html>
</html> \ No newline at end of file
...@@ -134,6 +134,7 @@ export default { ...@@ -134,6 +134,7 @@ export default {
subjectMixtureSave: `${dakaapi}member/website/subject_mixture/save`, subjectMixtureSave: `${dakaapi}member/website/subject_mixture/save`,
teacher: `${dakaapi}member/website/teachers`, teacher: `${dakaapi}member/website/teachers`,
teacherSave: `${dakaapi}member/website/teacher/save`, teacherSave: `${dakaapi}member/website/teacher/save`,
mixed_simple: `${dakaapi}member/subject/mixed_simple`,
}, },
schedule: `${dakaapi}member/erp/schedules`, schedule: `${dakaapi}member/erp/schedules`,
scheduleMgt: { scheduleMgt: {
......
...@@ -103,7 +103,6 @@ class CommonEditor extends React.Component { ...@@ -103,7 +103,6 @@ class CommonEditor extends React.Component {
commentParams, commentParams,
editorAdd, editorAdd,
} = this.props; } = this.props;
console.log(commentParams, 'commentParams');
return ( return (
<div className={pageStyle.container}> <div className={pageStyle.container}>
<div className={pageStyle.editor}> <div className={pageStyle.editor}>
......
This diff is collapsed.
...@@ -64,7 +64,6 @@ export default { ...@@ -64,7 +64,6 @@ export default {
signature, avatorUploader, files, uploaderLoading, uploadtype, orgIndex, imgIndex, orgType, action, signature, avatorUploader, files, uploaderLoading, uploadtype, orgIndex, imgIndex, orgType, action,
} = payload; } = payload;
const file = files.files ? files.files[0] : null; const file = files.files ? files.files[0] : null;
console.log(file, 'file');
uploaderLoading(); uploaderLoading();
const filename = `${signature.dir}${getRandomFilename(file.name)}`; const filename = `${signature.dir}${getRandomFilename(file.name)}`;
const params = { const params = {
......
...@@ -171,6 +171,9 @@ export default { ...@@ -171,6 +171,9 @@ export default {
}); });
} }
if (pathname === '/sjd/officialweb' || pathname === '/sjd/officialwebeditor') { if (pathname === '/sjd/officialweb' || pathname === '/sjd/officialwebeditor') {
dispatch({
type: 'officialweb/pageInit',
});
dispatch({ dispatch({
type: 'officialweb/queryinfo', type: 'officialweb/queryinfo',
payload: { payload: {
......
...@@ -31,7 +31,6 @@ class RichText extends React.Component { ...@@ -31,7 +31,6 @@ class RichText extends React.Component {
Authorization: `Bearer ${user.token}}`, Authorization: `Bearer ${user.token}}`,
}, },
}).then(response => response.json()); }).then(response => response.json());
console.log(res.data, 'access');
const { const {
accessid, accessid,
policy, policy,
...@@ -56,7 +55,6 @@ class RichText extends React.Component { ...@@ -56,7 +55,6 @@ class RichText extends React.Component {
body: formData2, body: formData2,
}).then(response => response.json()); }).then(response => response.json());
if (res2.status == 'ok') { if (res2.status == 'ok') {
console.log(res2, 'res21111111');
param.success({ param.success({
url: `${host}/${filename}`, url: `${host}/${filename}`,
meta: { meta: {
...@@ -73,7 +71,6 @@ class RichText extends React.Component { ...@@ -73,7 +71,6 @@ class RichText extends React.Component {
} }
handleChangeEditor = (editorState) => { handleChangeEditor = (editorState) => {
const { handleChangeEditor, index } = this.props; const { handleChangeEditor, index } = this.props;
console.log(editorState, 'editorState');
handleChangeEditor(editorState, index); handleChangeEditor(editorState, index);
} }
render() { render() {
...@@ -96,7 +93,6 @@ class RichText extends React.Component { ...@@ -96,7 +93,6 @@ class RichText extends React.Component {
'size', 'size',
'remove', 'remove',
]; ];
console.log(editorValue, 'editorValue');
const newValue = BraftEditor.createEditorState(editorValue); const newValue = BraftEditor.createEditorState(editorValue);
return ( return (
<div className={pageStyle.container}> <div className={pageStyle.container}>
......
This diff is collapsed.
...@@ -4,18 +4,16 @@ import { Icon, Button } from 'antd'; ...@@ -4,18 +4,16 @@ import { Icon, Button } from 'antd';
import pageStyle from './index.less'; import pageStyle from './index.less';
import { pageIn, hasBtnPower } from '../../utils/index'; import { pageIn, hasBtnPower } from '../../utils/index';
import SchoolInfo from './pagecomponent/SchoolInfo'; import SchoolInfo from './pagecomponent/SchoolInfo';
import SchoolInfoEditor from './pagecomponent/SchoolInfoEditor';
import Banner from './pagecomponent/Banner'; import Banner from './pagecomponent/Banner';
import BannerEditor from './pagecomponent/BannerEditor';
import Course from './pagecomponent/Course'; import Course from './pagecomponent/Course';
import CourseEditor from './pagecomponent/CourseEditor';
import Orgdesc from './pagecomponent/Orgdesc';
import OrgdescEditor from './pagecomponent/OrgdescEditor';
import StudentClock from './pagecomponent/StudentClock'; import StudentClock from './pagecomponent/StudentClock';
import BtnPermission from '../../components/BtnPermission'; import BtnPermission from '../../components/BtnPermission';
import AdCarousel from './pagecomponent/AdCarousel'; import AdCarousel from './pagecomponent/AdCarousel';
import ClassMoments from './pagecomponent/ClassMoments'; import ClassMoments from './pagecomponent/ClassMoments';
import SchoolIntro from './pagecomponent/SchoolIntro'; import SchoolIntro from './pagecomponent/SchoolIntro';
import OnlineClass from './pagecomponent/OnlineClass';
import TogetherClock from './pagecomponent/TogetherClock';
import Teacher from './pagecomponent/Teacher';
import Cropper from '../../components/Cropper'; import Cropper from '../../components/Cropper';
class Officialweb extends React.Component { class Officialweb extends React.Component {
componentDidMount() { // 挂载 componentDidMount() { // 挂载
...@@ -104,13 +102,13 @@ class Officialweb extends React.Component { ...@@ -104,13 +102,13 @@ class Officialweb extends React.Component {
return ( return (
<div className={pageStyle.container}> <div className={pageStyle.container}>
<div className={pageStyle.mobilecontainer}> <div className={pageStyle.mobilecontainer}>
{course.switch == 1 && {/* {course.switch == 1 && */}
<div className={pageStyle.floatcoursebox}> {/* <div className={pageStyle.floatcoursebox}> */}
<Course {/* <Course */}
course={course} {/* course={course} */}
/> {/* /> */}
</div> {/* </div> */}
} {/* } */}
{ {
newPageInfo.map((ele, index) => { newPageInfo.map((ele, index) => {
switch (ele.type) { switch (ele.type) {
...@@ -143,7 +141,7 @@ class Officialweb extends React.Component { ...@@ -143,7 +141,7 @@ class Officialweb extends React.Component {
); );
break; break;
case 'adCarousel': case 'adCarousel':
renderDom = ( renderDom = (schoolInfo.module_switch && schoolInfo.module_switch.adCarousel &&
<div className={pageStyle.box} key={ele.type}> <div className={pageStyle.box} key={ele.type}>
<div <div
className={`${pageStyle.ContentBox}`} className={`${pageStyle.ContentBox}`}
...@@ -157,23 +155,53 @@ class Officialweb extends React.Component { ...@@ -157,23 +155,53 @@ class Officialweb extends React.Component {
</div> </div>
); );
break; break;
case 'clocklist': case 'orgdesc':
renderDom = ( renderDom = (schoolInfo.module_switch && schoolInfo.module_switch.orgdesc &&
<div className={pageStyle.box} key={ele.type}> <div className={pageStyle.box} key={ele.type}>
<div <div
className={`${pageStyle.ContentBox}`} className={`${pageStyle.ContentBox}`}
key={ele.type} key={ele.type}
> >
<StudentClock <SchoolIntro
clockList={ele.data} data={ele.data}
schoolInfo={schoolInfo} schoolInfo={schoolInfo}
/> />
</div> </div>
</div> </div>
); );
break; break;
case 'teacher':
renderDom = (schoolInfo.module_switch && schoolInfo.module_switch.teacher &&
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox}`}
key={ele.type}
>
<Teacher
data={ele.data}
schoolInfo={schoolInfo}
/>
</div>
</div>
);
break;
case 'clocklist':
renderDom = (schoolInfo.module_switch && schoolInfo.module_switch.clocklist &&
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox}`}
key={ele.type}
>
<StudentClock
clockList={ele.data}
schoolInfo={schoolInfo}
/>
</div>
</div>
);
break;
case 'classmoments': case 'classmoments':
renderDom = ( renderDom = (schoolInfo.module_switch && schoolInfo.module_switch.classmoments &&
<div className={pageStyle.box} key={ele.type}> <div className={pageStyle.box} key={ele.type}>
<div <div
className={`${pageStyle.ContentBox}`} className={`${pageStyle.ContentBox}`}
...@@ -187,21 +215,36 @@ class Officialweb extends React.Component { ...@@ -187,21 +215,36 @@ class Officialweb extends React.Component {
</div> </div>
); );
break; break;
case 'orgdesc': case 'onlineclass':
renderDom = ( renderDom = (schoolInfo.module_switch && schoolInfo.module_switch.onlineclass &&
<div className={pageStyle.box} key={ele.type}> <div className={pageStyle.box} key={ele.type}>
<div <div
className={`${pageStyle.ContentBox}`} className={`${pageStyle.ContentBox}`}
key={ele.type} key={ele.type}
> >
<SchoolIntro <OnlineClass
data={ele.data} data={ele.data}
schoolInfo={schoolInfo} schoolInfo={schoolInfo}
/> />
</div>
</div> </div>
); </div>
break; );
break;
case 'togetherclock':
renderDom = (schoolInfo.module_switch && schoolInfo.module_switch.togetherclock &&
<div className={pageStyle.box} key={ele.type}>
<div
className={`${pageStyle.ContentBox}`}
key={ele.type}
>
<TogetherClock
data={ele.data}
schoolInfo={schoolInfo}
/>
</div>
</div>
);
break;
case 'course': case 'course':
renderDom = (ele.data.switch == 1 && renderDom = (ele.data.switch == 1 &&
<div className={pageStyle.box} key={ele.type}> <div className={pageStyle.box} key={ele.type}>
......
@import '../../less/variables.less'; @import '../../less/variables.less';
.container { .container {
background-color: #fff; background-color: #fff;
padding: 63px 0 750px 63px; padding: 63px 0 200px 63px;
display: flex; display: flex;
position: relative; position: relative;
overflow-y: hidden; overflow-y: hidden;
...@@ -93,12 +93,21 @@ ...@@ -93,12 +93,21 @@
border: none; border: none;
} }
.savebtnbox { .savebtnbox {
position: absolute; position: fixed;
right: 34px; bottom: 0;
top: 55px; background-color: #fff;
width: 200px; padding: 20px 20px 14px 20px;
display: flex; width: 100%;
justify-content: flex-end; box-shadow:1px -6px 6px 0px rgba(0, 0, 0, 0.04);
transition: 0.2s left;
transition: 0.1s width;
z-index: 20;
text-align: center;
:global {
.ant-popover {
position: fixed;
}
}
} }
.qrcodebox { .qrcodebox {
width: 200px; width: 200px;
......
...@@ -24,13 +24,15 @@ class adCarousel extends React.Component { ...@@ -24,13 +24,15 @@ class adCarousel extends React.Component {
}); });
} }
render() { render() {
const { data, schoolInfo } = this.props; const { data, schoolInfo, showStatus } = this.props;
console.log(schoolInfo, 'schoolInfo');
return ( return (
<div className={PageStyle.Bannercontainer}> <div className={PageStyle.Bannercontainer}>
<div className={PageStyle.switchWrap}> {
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.adCarousel} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'adCarousel')} /> showStatus &&
</div> <div className={PageStyle.switchWrap}>
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.adCarousel} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'adCarousel')} />
</div>
}
<div className={PageStyle.carouselWrap}> <div className={PageStyle.carouselWrap}>
{ {
data.length > 0 ? data.length > 0 ?
...@@ -40,7 +42,7 @@ class adCarousel extends React.Component { ...@@ -40,7 +42,7 @@ class adCarousel extends React.Component {
{ {
data.map((item, index) => { data.map((item, index) => {
return ( return (
<img className={PageStyle.img} src={imagify(item.cover)} alt="" /> <img key={item.id} className={PageStyle.img} src={imagify(item.cover)} alt="" />
); );
}) })
} }
......
...@@ -24,13 +24,15 @@ class ClassMoments extends React.Component { ...@@ -24,13 +24,15 @@ class ClassMoments extends React.Component {
}); });
} }
render() { render() {
const { data, schoolInfo } = this.props; const { data, schoolInfo, showStatus } = this.props;
console.log(data, 'datadatadatadata');
return ( return (
<div className={PageStyle.Bannercontainer}> <div className={PageStyle.Bannercontainer}>
<div className={PageStyle.switchWrap}> {
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.classmoments} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'classmoments')} /> showStatus &&
</div> <div className={PageStyle.switchWrap}>
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.classmoments} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'classmoments')} />
</div>
}
<div className={PageStyle.commonTitle}> <div className={PageStyle.commonTitle}>
<div>课堂瞬间</div> <div>课堂瞬间</div>
<div className={PageStyle.right}>更多<Icon type="right" /></div> <div className={PageStyle.right}>更多<Icon type="right" /></div>
......
...@@ -200,7 +200,7 @@ class ClassMomentsEditor extends React.Component { ...@@ -200,7 +200,7 @@ class ClassMomentsEditor extends React.Component {
switch (ele.type) { switch (ele.type) {
case 'img': case 'img':
return ( return (
<div className={PageStyle.imgItem} key={ele.type}> <div className={PageStyle.imgItem} key={ele.value}>
<img className={PageStyle.img} src={imagify(ele.value)} alt="图片" /> <img className={PageStyle.img} src={imagify(ele.value)} alt="图片" />
<div className={PageStyle.closeAdIcon} onClick={() => this.deleteClassMomentImg(index, i)}> <div className={PageStyle.closeAdIcon} onClick={() => this.deleteClassMomentImg(index, i)}>
<Icon type="close" /> <Icon type="close" />
......
...@@ -3,6 +3,7 @@ import { connect } from 'dva'; ...@@ -3,6 +3,7 @@ import { connect } from 'dva';
import { Carousel, Empty, Icon, Switch } from 'antd'; import { Carousel, Empty, Icon, Switch } from 'antd';
import PageStyle from './OnlineClass.less'; import PageStyle from './OnlineClass.less';
import { ossVideofy, imagify, videoPoster } from '../../../utils/index'; import { ossVideofy, imagify, videoPoster } from '../../../utils/index';
import Course from './Course';
class OnlineClass extends React.Component { class OnlineClass extends React.Component {
constructor(props) { constructor(props) {
super(props); super(props);
...@@ -24,12 +25,15 @@ class OnlineClass extends React.Component { ...@@ -24,12 +25,15 @@ class OnlineClass extends React.Component {
}); });
} }
render() { render() {
const { data, schoolInfo } = this.props; const { data, schoolInfo, showStatus } = this.props;
return ( return (
<div className={PageStyle.Bannercontainer}> <div className={PageStyle.Bannercontainer}>
<div className={PageStyle.switchWrap}> {
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.onlineclass} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'togetherclock')} /> showStatus &&
</div> <div className={PageStyle.switchWrap}>
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.onlineclass} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'onlineclass')} />
</div>
}
<div className={PageStyle.commonTitle}> <div className={PageStyle.commonTitle}>
<div>在线课堂</div> <div>在线课堂</div>
<div className={PageStyle.right}>更多<Icon type="right" /></div> <div className={PageStyle.right}>更多<Icon type="right" /></div>
......
...@@ -40,7 +40,6 @@ class OnlineClassEditor extends React.Component { ...@@ -40,7 +40,6 @@ class OnlineClassEditor extends React.Component {
onlineClassStatus, onlineClassStatus,
onlineClassTargetKeys, onlineClassTargetKeys,
} = this.props; } = this.props;
console.log(onlineClassTargetKeys, 'onlineClassTargetKeys');
return ( return (
<div className={`${PageStyle.SchoolInfoEditorcontainer} SchoolInfoEditorcontainer`}> <div className={`${PageStyle.SchoolInfoEditorcontainer} SchoolInfoEditorcontainer`}>
<div className={PageStyle.header}><span>在线课堂 </span><p>您可以从课堂列表中最多选择4个课程在微官网首页【在线课堂】展示</p></div> <div className={PageStyle.header}><span>在线课堂 </span><p>您可以从课堂列表中最多选择4个课程在微官网首页【在线课堂】展示</p></div>
...@@ -55,6 +54,7 @@ class OnlineClassEditor extends React.Component { ...@@ -55,6 +54,7 @@ class OnlineClassEditor extends React.Component {
rowKey={record => record.id} rowKey={record => record.id}
showSearch showSearch
lazy lazy
showSelectAll={false}
/> />
</div> </div>
</div> </div>
......
...@@ -5,7 +5,6 @@ import PageStyle from './SchoolInfo.less'; ...@@ -5,7 +5,6 @@ import PageStyle from './SchoolInfo.less';
const { Sider } = Layout; const { Sider } = Layout;
function SchoolInfo(props) { function SchoolInfo(props) {
const { schoolinfo } = props; const { schoolinfo } = props;
console.log(schoolinfo, 'schoolinfo');
return ( return (
<div className={PageStyle.SchoolInfocontainer}> <div className={PageStyle.SchoolInfocontainer}>
<div className={PageStyle.schoolinfo}> <div className={PageStyle.schoolinfo}>
...@@ -13,7 +12,7 @@ function SchoolInfo(props) { ...@@ -13,7 +12,7 @@ function SchoolInfo(props) {
<div className={PageStyle.name}>{schoolinfo.title || ''}</div> <div className={PageStyle.name}>{schoolinfo.title || ''}</div>
<div className={PageStyle.wantlearnstatic}> <div className={PageStyle.wantlearnstatic}>
{schoolinfo.tags && schoolinfo.tags.length > 0 && schoolinfo.tags.map((item, index) => { {schoolinfo.tags && schoolinfo.tags.length > 0 && schoolinfo.tags.map((item, index) => {
return (<span>{index < 4 && <Tag>{item}</Tag>} {index > 4 && '...'}</span>); return (<span key={item}>{index < 4 && <Tag>{item}</Tag>} {index > 4 && '...'}</span>);
})} })}
</div> </div>
</div> </div>
......
...@@ -142,7 +142,6 @@ class SchoolInfoEditorForm extends React.Component { ...@@ -142,7 +142,6 @@ class SchoolInfoEditorForm extends React.Component {
labelCol: { span: 6 }, labelCol: { span: 6 },
wrapperCol: { span: 18 }, wrapperCol: { span: 18 },
}; };
console.log(schoolTags, 'schoolTags');
return ( return (
<div className={`${PageStyle.SchoolInfoEditorcontainer} SchoolInfoEditorcontainer`}> <div className={`${PageStyle.SchoolInfoEditorcontainer} SchoolInfoEditorcontainer`}>
<div className={PageStyle.header}>机构信息</div> <div className={PageStyle.header}>机构信息</div>
......
...@@ -24,12 +24,15 @@ class SchoolIntro extends React.Component { ...@@ -24,12 +24,15 @@ class SchoolIntro extends React.Component {
}); });
} }
render() { render() {
const { data, schoolInfo } = this.props; const { data, schoolInfo, showStatus } = this.props;
return ( return (
<div className={PageStyle.Bannercontainer}> <div className={PageStyle.Bannercontainer}>
<div className={PageStyle.switchWrap}> {
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.orgdesc} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'orgdesc')} /> showStatus &&
</div> <div className={PageStyle.switchWrap}>
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.orgdesc} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'orgdesc')} />
</div>
}
<div className={PageStyle.commonTitle}> <div className={PageStyle.commonTitle}>
学校介绍 学校介绍
</div> </div>
...@@ -45,7 +48,7 @@ class SchoolIntro extends React.Component { ...@@ -45,7 +48,7 @@ class SchoolIntro extends React.Component {
{ {
data.map((item, index) => { data.map((item, index) => {
return ( return (
<div> <div key={item.id}>
{ {
item.type == 1 && <img className={PageStyle.img} src={imagify(item.content)} alt="" /> item.type == 1 && <img className={PageStyle.img} src={imagify(item.content)} alt="" />
} }
......
...@@ -187,7 +187,7 @@ class SchoolIntroEditor extends React.Component { ...@@ -187,7 +187,7 @@ class SchoolIntroEditor extends React.Component {
{ {
schoolIntro.length > 0 && schoolIntro.map((item, index) => { schoolIntro.length > 0 && schoolIntro.map((item, index) => {
return ( return (
<div className={PageStyle.formItem} key={item}> <div className={PageStyle.formItem} key={item.id}>
<div className={PageStyle.formLeft}> <div className={PageStyle.formLeft}>
{index == 0 && <div className={`${PageStyle.formItemIcon} ${PageStyle.formItemIconGray}`}><Icon className={PageStyle.itemIcon} type="arrow-up" /></div>} {index == 0 && <div className={`${PageStyle.formItemIcon} ${PageStyle.formItemIconGray}`}><Icon className={PageStyle.itemIcon} type="arrow-up" /></div>}
{ index > 0 && <div className={PageStyle.formItemIcon} onClick={() => this.moveSchoolIntroPlate(index, 'up')}><Icon className={PageStyle.itemIcon} type="arrow-up" /></div> } { index > 0 && <div className={PageStyle.formItemIcon} onClick={() => this.moveSchoolIntroPlate(index, 'up')}><Icon className={PageStyle.itemIcon} type="arrow-up" /></div> }
......
...@@ -34,6 +34,7 @@ class StudentClock extends React.Component { ...@@ -34,6 +34,7 @@ class StudentClock extends React.Component {
const { const {
menus, defaultMenu, collapsed, clockList, menus, defaultMenu, collapsed, clockList,
schoolInfo, schoolInfo,
showStatus,
} = this.props; } = this.props;
const menuItemStyle = { const menuItemStyle = {
fontSize: '16px', fontSize: '16px',
...@@ -45,9 +46,12 @@ class StudentClock extends React.Component { ...@@ -45,9 +46,12 @@ class StudentClock extends React.Component {
学生动态 学生动态
</div> </div>
</div> </div>
<div className={PageStyle.switchWrap}> {
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.clocklist} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'clocklist')} /> showStatus &&
</div> <div className={PageStyle.switchWrap}>
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.clocklist} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'clocklist')} />
</div>
}
<div className={PageStyle.clockListBox}> <div className={PageStyle.clockListBox}>
{clockList.list && clockList.list.length > 0 && clockList.list.map(ele => ( {clockList.list && clockList.list.length > 0 && clockList.list.map(ele => (
<div className={PageStyle.clockitem} key={ele.id}> <div className={PageStyle.clockitem} key={ele.id}>
......
...@@ -24,13 +24,16 @@ class Teacher extends React.Component { ...@@ -24,13 +24,16 @@ class Teacher extends React.Component {
}); });
} }
render() { render() {
const { data, schoolInfo } = this.props; const { data, schoolInfo, showStatus } = this.props;
console.log(data, 'data111'); console.log(data, 'data111');
return ( return (
<div className={PageStyle.Bannercontainer}> <div className={PageStyle.Bannercontainer}>
<div className={PageStyle.switchWrap}> {
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.teacher} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'teacher')} /> showStatus &&
</div> <div className={PageStyle.switchWrap}>
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.teacher} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'teacher')} />
</div>
}
<div className={PageStyle.commonTitle}> <div className={PageStyle.commonTitle}>
<div>名师风采</div> <div>名师风采</div>
<div className={PageStyle.right}>更多<Icon type="right" /></div> <div className={PageStyle.right}>更多<Icon type="right" /></div>
...@@ -41,7 +44,7 @@ class Teacher extends React.Component { ...@@ -41,7 +44,7 @@ class Teacher extends React.Component {
{ {
data.map((item, index) => { data.map((item, index) => {
return ( return (
<div className={PageStyle.commonItem}> <div className={PageStyle.commonItem} key={item.id}>
<div className={PageStyle.commonLeft}> <div className={PageStyle.commonLeft}>
<img src={imagify(item.avatar)} alt="" /> <img src={imagify(item.avatar)} alt="" />
</div> </div>
......
...@@ -24,13 +24,15 @@ class TogetherClock extends React.Component { ...@@ -24,13 +24,15 @@ class TogetherClock extends React.Component {
}); });
} }
render() { render() {
const { data, schoolInfo } = this.props; const { data, schoolInfo, showStatus } = this.props;
console.log(data, '一起来打卡');
return ( return (
<div className={PageStyle.Bannercontainer}> <div className={PageStyle.Bannercontainer}>
<div className={PageStyle.switchWrap}> {
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.togetherclock} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'togetherclock')} /> showStatus &&
</div> <div className={PageStyle.switchWrap}>
<Switch checked={schoolInfo.module_switch && schoolInfo.module_switch.togetherclock} checkedChildren="开" unCheckedChildren="关" onChange={e => this.handleChangeSwitch(e, 'togetherclock')} />
</div>
}
<div className={PageStyle.commonTitle}> <div className={PageStyle.commonTitle}>
<div>一起打卡</div> <div>一起打卡</div>
<div className={PageStyle.right}>更多<Icon type="right" /></div> <div className={PageStyle.right}>更多<Icon type="right" /></div>
......
import React from 'react'; import React from 'react';
import { connect } from 'dva'; import { connect } from 'dva';
import { Form, Layout, Transfer, Button, Icon, message, Modal, Popconfirm, Progress } from 'antd'; import { Form, Layout, Transfer, Button, Icon, message, Pagination, Popconfirm, Progress } from 'antd';
import { videoPoster, imagify, ossVideofy } from '../../../utils/index'; import { videoPoster, imagify, ossVideofy } from '../../../utils/index';
import PageStyle from './TogetherClockEditor.less'; import PageStyle from './TogetherClockEditor.less';
const FormItem = Form.Item; const FormItem = Form.Item;
...@@ -51,9 +51,10 @@ class TogetherClockEditor extends React.Component { ...@@ -51,9 +51,10 @@ class TogetherClockEditor extends React.Component {
onChange={this.handleChangeClock} onChange={this.handleChangeClock}
targetKeys={togetherClockTargetKeys} targetKeys={togetherClockTargetKeys}
render={item => item.title} render={item => item.title}
rowKey={record => record.subject_mixed_id} rowKey={record => record.id}
showSearch showSearch
lazy lazy
showSelectAll={false}
/> />
</div> </div>
</div> </div>
......
...@@ -187,3 +187,10 @@ export function teacherSave(params) { ...@@ -187,3 +187,10 @@ export function teacherSave(params) {
data, data,
}); });
} }
export function getMixedSimple(params) {
const data = qs.stringify(params);
return request({
url: `${api.officaialweb.mixed_simple}?${data}`,
method: 'GET',
});
}
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