Commit afea53ae authored by baixian's avatar baixian

打卡完成

parent 2cea0f22
......@@ -18,5 +18,5 @@
</head>
<body>
<div id="root"></div>
<script type="text/javascript" src="/dist/main.78952e.js"></script></body>
<script type="text/javascript" src="/dist/main.88d533.js"></script></body>
</html>
\ No newline at end of file
......@@ -266,9 +266,10 @@ export default {
});
},
* getsubjectReviewTemplate({ payload }, { call, put, select }) {
const { themeId } = yield select(state => state.clockmgt);
const { themeId, themetype } = yield select(state => state.clockmgt);
const tempData = yield call(clockmgtajax.getsubjectReviewTemplate, {
subject_id: themeId,
subject_type: themetype,
});
if (tempData.code == 200) {
yield put({
......@@ -291,8 +292,10 @@ export default {
const {
classId, copyTempArr, tempsaveLoading, tempScoreArr, tabIndex, quicktempScoreArr,
singleClock,
themetype,
} = yield select(state => state.clockmgt);
const { type, callBack } = payload;
console.log(singleClock, 'singleClock');
const emptyIndex = copyTempArr.findIndex(ele => ele.title.trim() == '');
if (emptyIndex != -1) {
message.warn(`第${emptyIndex + 1}个模板名称不能为空`, 1);
......@@ -311,7 +314,8 @@ export default {
const saveData = yield call(clockmgtajax.saveSubjectReviewTemplate, {
class_id: classId,
templates: JSON.stringify(copyTempArr),
subject_id: singleClock.subject.id,
subject_id: singleClock.subject_type == 3 ? singleClock.unlock_mode_id : singleClock.subject_id,
subject_type: themetype,
});
setTimeout(loading);
if (saveData.code == 200) {
......
......@@ -365,6 +365,10 @@ export default {
message.error('请选择营销页!', 1);
return;
}
if (newParams.join_rule_type == 0) {
message.error('请选择参与打卡方式!', 1);
return;
}
if (newParams.join_rule_type == 4 && classes.length == 0) {
message.error('请选择班级!', 1);
return;
......
......@@ -779,6 +779,11 @@ export default {
}
const clockmgtactive = pathToRegexp('/sjd/clockmgt/:themetype/:themeid').exec(pathname);
if (clockmgtactive) {
dispatch({
type: 'clockmgt/pageInit',
payload: {
},
});
dispatch({
type: 'updateState',
payload: {
......
......@@ -592,10 +592,10 @@ class CalendarClockForm extends React.Component {
</FormItem>
<Divider />
<div className={pageStyle.title} >打卡营销页</div>
<FormItem {...formItemModalLineLayout} label="打卡营销页">
<FormItem {...formItemModalLineLayout} label="打卡营销页" style={{ marginBottom: 0 }}>
<span onClick={this.handleClickMarketing}>{themeAdInfo.title ? themeAdInfo.title : '请选择营销页'}<Icon type="right" /></span>
</FormItem>
<p>可在学生加入打卡前展示, 此功能可收集有意向学生的联系方式 <span>了解详情</span></p>
<p className={pageStyle.markeTip}>可在学生加入打卡前展示, 此功能可收集有意向学生的联系方式 <span>了解详情</span></p>
<div className={pageStyle.title}>更多设置 <span onClick={this.handleClickShow} className={pageStyle.pack}>{isShow ? '收起' : '展开'}</span></div>
<div className={isShow ? pageStyle.panpelBox : pageStyle.panpelhideBox}>
<div className={pageStyle.commonwrap}>
......
......@@ -358,3 +358,12 @@
z-index: 20;
text-align: center;
}
.markeTip {
font-size: 12px;
color: #555555;
margin-bottom: 20px;
&>span {
color: #1890ff;
cursor: pointer;
}
}
......@@ -193,6 +193,36 @@ class AddMarkeModal extends React.Component {
type: 'createmarke/updateState',
payload: {
addMarkeVisible: false,
markeParams: {
title: '',
name: '',
mobile: '',
img: '',
cover: 'https://cdn.img.shangjiadao.cn/qingxiao/daka/images/2c/sharemoretheme/newunlockbg.png',
content: [
{
title: '',
content: [{
type: 'text',
value: '1.全程陪伴练字教学,我们通过听课+作业+点评+群内解答等互动形式,提高学习效果' +
'\n' +
'2.国家级书法名师亲自授课,指导你快速学习正确的握笔姿势和练字方法' +
'\n' +
'3.从零基础讲起,适合小白快速入门,课程系统全面,有经验的学员也能得到进一步提高;' +
'\n' +
'4.我们的每一位同学都将得到一对一教师指导,每天督促学习,陪伴式成长' +
'适合人群\n' +
'(1)零基础练字学员\n' +
'(2)有一点基础,想提升的学员\n' +
'(3)节假日期间想快速练好字的学员',
},
{ type: 'img', value: 'https://cdn.img.shangjiadao.cn/qingxiao/daka/images/2b/themeeditorlock/title-1.png' },
{ type: 'text', value: '洛子帅, 书法练字训练营创始人,杭州阳关灿烂教育 \r\n 教学主管,专业书法教师,已帮助3000多人写好字。' },
{ type: 'img', value: 'https://cdn.img.shangjiadao.cn/qingxiao/daka/images/2b/themeeditorlock/shoubiao.png' },
],
},
],
},
},
});
}
......
......@@ -8,6 +8,7 @@
width: 375px;
height: 211px;
cursor: pointer;
background-color: #f0f0f0;
.defaultImg {
width: 100%;
height: 100%;
......
......@@ -585,7 +585,7 @@ class UnClockForm extends React.Component {
)}
<span className="ant-form-text"></span>
</FormItem>
<FormItem {...formItemModalLineLayout} label="打卡营销页">
<FormItem {...formItemModalLineLayout} label="打卡营销页" style={{ marginBottom: 0 }}>
<span onClick={this.handleClickMarketing}>{themeAdInfo.title ? themeAdInfo.title : '请选择营销页'}<Icon type="right" /></span>
</FormItem>
<FormItem {...formItemModaltypeLayout} label="参与打卡方式" style={{ marginBottom: 0 }}>
......
......@@ -492,10 +492,10 @@ class JobClockForm extends React.Component {
</div>
<Divider />
<div className={pageStyle.title} >打卡营销页</div>
<FormItem {...formItemModalLineLayout} label="打卡营销页">
<FormItem {...formItemModalLineLayout} label="打卡营销页" style={{ marginBottom: 0 }}>
<span onClick={this.handleClickMarketing}>{themeAdInfo.title ? themeAdInfo.title : '请选择营销页'}<Icon type="right" /></span>
</FormItem>
<p>可在学生加入打卡前展示, 此功能可收集有意向学生的联系方式 <span>了解详情</span></p>
<p className={pageStyle.markeTip}>可在学生加入打卡前展示, 此功能可收集有意向学生的联系方式 <span>了解详情</span></p>
<div className={pageStyle.title}>更多设置 <span onClick={this.handleClickShow} className={pageStyle.pack}>{isShow ? '收起' : '展开'}</span></div>
<div className={isShow ? pageStyle.panpelBox : pageStyle.panpelhideBox}>
<div className={pageStyle.commonwrap}>
......
......@@ -135,3 +135,12 @@
z-index: 20;
text-align: center;
}
.markeTip {
font-size: 12px;
color: #555555;
margin-bottom: 20px;
&>span {
color: #1890ff;
cursor: pointer;
}
}
......@@ -116,6 +116,7 @@ class LiveClass extends React.Component {
payload: {
params: {
subject_type: type,
page: 1,
},
},
});
......
......@@ -71,8 +71,9 @@ export function destoryShortWords(params) {
});
}
export function getsubjectReviewTemplate(params) {
const data = qs.stringify(params);
return request({
url: `${api.clockmgt.subjectReviewTemplate}?subject_id=${params.subject_id}`,
url: `${api.clockmgt.subjectReviewTemplate}?${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