chromesetting
杨树明 5 years ago
commit 8650416be1

@ -235,7 +235,7 @@ class EditTab extends React.Component {
['image', 'formula'], // 数学公式、图片、视频 ['image', 'formula'], // 数学公式、图片、视频
['clean'], // 清除格式 ['clean'], // 清除格式
]; ];
return ( return (
<div className={'editor_area'} id="textCase"> <div className={'editor_area'} id="textCase">
<Form className={'editor_form'}> <Form className={'editor_form'}>
@ -309,15 +309,15 @@ class EditTab extends React.Component {
colon={ false } colon={ false }
> >
<div style={{ marginTop: '15px'}}> <div style={{ marginTop: '15px'}}>
<QuillForEditor <QuillForEditor
style={{ height: '200px', 'overflowY': 'auto' }} style={{ height: '200px', 'overflowY': 'auto' }}
placeholder="请输入描述信息" placeholder="请输入描述信息"
onContentChange={handleContentChange} onContentChange={handleContentChange}
options={quillConfig} options={quillConfig}
value={ojForm.description} value={ojForm.description}
/> />
</div> </div>
</FormItem> </FormItem>
{/* <FormItem {/* <FormItem
@ -331,7 +331,7 @@ class EditTab extends React.Component {
{getOptions('openOrNot')} {getOptions('openOrNot')}
</Select> </Select>
</FormItem> */} </FormItem> */}
</Form> </Form>
{/* 添加测试用例 */} {/* 添加测试用例 */}

@ -149,6 +149,8 @@ class TPMBanner extends Component {
} }
} }
} }

@ -145,6 +145,8 @@ class Challengesjupyter extends Component {
}, 600) }, 600)
}); });
setTimeout(this.getjianjiesize(), 1000);

@ -87,7 +87,7 @@ export const getUserProgramDetail = (identifier, type) => {
type: types.SAVE_USE_TEST_CASE_VALUE, type: types.SAVE_USE_TEST_CASE_VALUE,
payload: data.test_case || {} payload: data.test_case || {}
}); });
// 代码是否更新 // 代码是否更新
let _modify_code = false; let _modify_code = false;
if (data.hack) { if (data.hack) {
_modify_code = data.hack.modify_code; _modify_code = data.hack.modify_code;
@ -178,7 +178,7 @@ export const codeEvaluate = (dispatch, identifier, type, time_limit) => {
let count = 1; let count = 1;
/** /**
* @param {*} excuteTime 执行时间 * @param {*} excuteTime 执行时间
* @param {*} finalTime 总时间 * @param {*} finalTime 总时间
* @param {*} count 执行次数 * @param {*} count 执行次数
* @param {*} timer 定时器 * @param {*} timer 定时器
*/ */
@ -190,7 +190,7 @@ export const codeEvaluate = (dispatch, identifier, type, time_limit) => {
if (+status === 0 || (excuteTime / 1000) > (finalTime + 1)) { if (+status === 0 || (excuteTime / 1000) > (finalTime + 1)) {
clearInterval(timer); // 清除定时器 clearInterval(timer); // 清除定时器
timer = null; timer = null;
let returnData = null; let returnData = null;
if (status === 1) { // 结果没有返回 if (status === 1) { // 结果没有返回
returnData = { returnData = {
error_line: -1, error_line: -1,
@ -208,8 +208,8 @@ export const codeEvaluate = (dispatch, identifier, type, time_limit) => {
// 返回评测结果 // 返回评测结果
dispatch({ dispatch({
type: types.COMMIT_RECORD_DETAIL, type: types.COMMIT_RECORD_DETAIL,
payload: returnData payload: returnData
}); });
if (!type || type === 'debug') { if (!type || type === 'debug') {
dispatch({ // 改变 loading 值 dispatch({ // 改变 loading 值
type: types.LOADING_STATUS, type: types.LOADING_STATUS,
@ -261,13 +261,13 @@ export const codeEvaluate = (dispatch, identifier, type, time_limit) => {
/** /**
* @description 调试代码 * @description 调试代码
* @param {*} identifier * @param {*} identifier
* @param {*} inputValue 输入值: 自定义 | 系统返回的 * @param {*} inputValue 输入值: 自定义 | 系统返回的
* @param {*} type 测评类型 debug | submit * @param {*} type 测评类型 debug | submit
*/ */
export const debuggerCode = (identifier,value, type) => { export const debuggerCode = (identifier,value, type) => {
return (dispatch, getState) => { return (dispatch, getState) => {
// 调用之前 先保存 code // 调用之前 先保存 code
// TODO // TODO
// console.log(identifier, value); // console.log(identifier, value);
const {hack: {time_limit = 0}} = getState().ojForUserReducer; const {hack: {time_limit = 0}} = getState().ojForUserReducer;

@ -136,4 +136,4 @@ export async function fetchUploadImage (file) {
export async function fetchUploadImageUrl (id) { export async function fetchUploadImageUrl (id) {
const url = `/attachments/${id}`; const url = `/attachments/${id}`;
return axios.get(url); return axios.get(url);
} }

Loading…
Cancel
Save