import React from 'react';
import './index.less';
import { Icon, Checkbox } from 'antd';
import Page from '@src/containers/Page';
import UserLayout from '../../../layouts/User';
import UserTable from '../../../components/UserTable';
import UserAction from '../../../components/UserAction';
import menu from '../index';
import Tabs from '../../../components/Tabs';
import Modal from '../../../components/Modal';
import Select from '../../../components/Select';
import GIcon from '../../../components/Icon';
const columns = [
{ key: '', title: '题型', fixSort: true },
{ key: '', title: '题目ID', fixSort: true },
{ key: '', title: '内容' },
{ key: '', title: '耗时', sort: true },
{ key: '', title: '错误率', sort: true },
{ key: '', title: '最近做题' },
{
key: '',
title: '',
render() {
return [, ];
},
},
];
const exportType = [
{ key: '1', title: '题目' },
{ key: '2', title: '官方解析' },
{ key: '3', title: '我的笔记' },
{ key: '4', title: '千行解析', auth: true },
{ key: '5', title: '题源联想', auth: true },
{ key: '6', title: '相关问答', auth: true },
];
export default class extends Page {
initState() {
return {
tab: '1',
filterMap: {},
sortMap: {},
data: [{}, {}],
selectList: [],
allChecked: false,
page: 1,
total: 1,
};
}
onChangeTab(tab) {
this.setState({ tab });
}
onFilter(value) {
this.setState({ filterMap: value });
}
onSort(value) {
this.setState({ sortMap: value });
}
onDataChange(page) {
this.setState({ page, allChecked: false, selectList: [] });
}
onAll(checked) {
if (checked) {
const { data = [] } = this.state;
const list = [];
data.forEach(item => {
list.push(item.key);
});
this.setState({ selectList: list, allChecked: true });
} else {
this.setState({ selectList: [], allChecked: false });
}
}
onAction() {}
onSelect(selectList) {
this.setState({ selectList });
}
renderView() {
const { config } = this.props;
return ;
}
renderTable() {
const { tab, filterMap = {}, sortMap = {}, selectList = [], data = [], allChecked, page, total } = this.state;
return (
this.onChangeTab(key)}
/>
this.onFilter(value)}
/>
2019-06-03 15:30 组卷50题,做对30题。移除正确题目
}
onAll={checked => this.onAll(checked)}
onAction={key => this.onAction(key)}
/>
this.onSelect(l)}
onSort={v => this.onSort(v)}
onChange={p => this.onDataChange(p)}
/>
{this.renderModal()}
);
}
renderModal() {
return [
{}}>
组卷功能
操作数量:10-50;
注意事项:可跨题型、不可跨学科。
导出功能
操作数量:1-100;
注意事项:“综合推理IR”暂时无法导出。
*您可点击
查阅以上信息。
,
{}}>
不可同时选中语文题和数学题,请重新选择。
,
{}} onCancel={() => {}}>
您共选择了 50 道题目,是否开始练习?
剔除已组卷练习 {' '}
次以上的错题
,
{}} onCancel={() => {}}>
当前选中的 50 道题即将被移出错题本,移出后无法恢复,是否继续?
,
{}}>
正在下载中,请不要关闭当前页面!
,
{}} onCancel={() => {}}>
当前共选中 50 道题,请确认需要导出的内容:
{exportType.map(item => {
return (
{item.title}
);
})}
,
{}} onCancel={() => {}}>
当前共选中 50 道题,请确认需要导出的内容:
{exportType
.filter(item => !item.auth)
.map(item => {
return (
{item.title}
);
})}
{exportType
.filter(item => item.auth)
.map(item => {
return (
{item.title}
);
})}
,
];
}
}