dev_aliyun2
harry 5 years ago
parent e67b131f5c
commit 4c44e599a5

@ -1,50 +1,16 @@
export default Itembankstops;
import React, { Component } from "react"; import React, { Component } from "react";
import { Link, NavLink } from 'react-router-dom'; import { getImageUrl } from 'educoder';
import { WordsBtn, ActionBtn, SnackbarHOC, getImageUrl } from 'educoder';
import axios from 'axios'; import axios from 'axios';
import { import {
notification,
Spin,
Table,
Pagination,
Radio, Radio,
Checkbox,
Form, Form,
Input,
Select,
Cascader, Cascader,
Col, Row, InputNumber, DatePicker, AutoComplete, Button, Tag, Tooltip
} from "antd"; } from "antd";
import './../questioncss/questioncom.css'; import './../questioncss/questioncom.css';
import Newknledpots from './Newknledpots' import Newknledpots from './Newknledpots'
const InputGroup = Input.Group;
const { Option } = Select;
const queryString = require('query-string'); const queryString = require('query-string');
const options = [
{
value: '方向',
label: '方向',
children: [
{
value: '课程',
label: '课程',
},
],
},
{
value: 'jiangsu',
label: 'Jiangsu',
children: [
{
value: 'nanjing',
label: 'Nanjing',
},
],
},
];
//Comthetestpaperst试卷的 //Comthetestpaperst试卷的
class Itembankstop extends Component { class Itembankstop extends Component {
constructor(props) { constructor(props) {
@ -685,7 +651,6 @@ class Itembankstop extends Component {
` `
body{ body{
width: 100%!important; width: 100%!important;
overflow: hidden!important;
} }
.ant-form-item{ .ant-form-item{
margin-bottom: 0px !important; margin-bottom: 0px !important;
@ -738,6 +703,7 @@ class Itembankstop extends Component {
)( )(
<Cascader style={{ width: '270px' }} options={options} onChange={this.handleFormzhishidian} <Cascader style={{ width: '270px' }} options={options} onChange={this.handleFormzhishidian}
placeholder="请选择..." />
)} )}
</Form.Item> </Form.Item>
@ -750,51 +716,50 @@ class Itembankstop extends Component {
{getFieldDecorator("rbzsd" {getFieldDecorator("rbzsd"
)( )(
<div className="sortinxdirection"> <div className="sortinxdirection">
<Select style={{ width: '270px' }} value={undefined} onChange={this.handleFormkechen} <Select style={{ width: '270px' }} value={undefined} onChange={this.handleFormkechen}
placeholder="请选择..."> placeholder="请选择...">
{knowledgepoints2 && knowledgepoints2.map((object, index) => { {knowledgepoints2 && knowledgepoints2.map((object, index) => {
return ( return (
<Option key={object.id} value={object.id}>{object.name}</Option> <Option key={object.id} value={object.id}>{object.name}</Option>
) )
})} })}
</Select> </Select>
<img className=" ml22 zjzsdian xiaoshou" src={getImageUrl("images/educoder/zjzsd.png")} onClick={() => this.NewknTypedeldel(true)} /> <img className=" ml22 zjzsdian xiaoshou" src={getImageUrl("images/educoder/zjzsd.png")} onClick={() => this.NewknTypedeldel(true)} />
</div > </div>
) )}
} </Form.Item>
</Form.Item>
} }
{ {
this.state.Knowpoints === undefined || this.state.Knowpoints === null ? "" : this.state.Knowpoints === undefined || this.state.Knowpoints === null ? "" :
this.state.Knowpoints.length > 0 ? this.state.Knowpoints.length > 0 ?
<div className="sortinxdirection huanhan w100s mt15" style={{ <div className="sortinxdirection huanhan w100s mt15" style={{
minHeight: "33px", minHeight: "33px",
lineHeight: "28px", lineHeight: "28px",
}}> }}>
{this.state.Knowpoints === undefined ? "" : this.state.Knowpoints.map((object, index) => { {this.state.Knowpoints === undefined ? "" : this.state.Knowpoints.map((object, index) => {
return ( return (
<div key={index} className={index === 0 ? "mytags mb20" : "mytags"} style={{ <div key={index} className={index === 0 ? "mytags mb20" : "mytags"} style={{
position: "relative", position: "relative",
}}> }}>
<p className="w100s stestcen lh32">{object.name}</p> <p className="w100s stestcen lh32">{object.name}</p>
<img className=" ml7 zjzsdian xiaoshou icondowncolorssy" onClick={() => this.deletesobject(object, index)} src={getImageUrl("images/educoder/bzucha.png")} /> <img className=" ml7 zjzsdian xiaoshou icondowncolorssy" onClick={() => this.deletesobject(object, index)} src={getImageUrl("images/educoder/bzucha.png")} />
</div> </div>
) )
})} })}
</div> </div>
: :
"" ""
} }
@ -803,23 +768,24 @@ class Itembankstop extends Component {
label="题型" label="题型"
> >
{getFieldDecorator("rbtx", {getFieldDecorator("rbtx",
{initialValue: this.state.rbtx, {
rules: [{required: true, message: '请选择题型'}], initialValue: this.state.rbtx,
rules: [{ required: true, message: '请选择题型' }],
} }
)( )(
<Select style={{width: '270px'}} disabled={this.state.boolnews} onChange={this.handleFormtixing} <Select style={{ width: '270px' }} disabled={this.state.boolnews} onChange={this.handleFormtixing}
placeholder="请选择..."> placeholder="请选择...">
<Option value="PROGRAM">编程题</Option> <Option value="PROGRAM">编程题</Option>
<Option value="SINGLE">单选题</Option> <Option value="SINGLE">单选题</Option>
<Option value="MULTIPLE">多选题</Option> <Option value="MULTIPLE">多选题</Option>
<Option value="JUDGMENT">判断题</Option> <Option value="JUDGMENT">判断题</Option>
</Select> </Select>
)} )}
</Form.Item > </Form.Item>
<style> <style>
{ {
` `
.rbndclass .ant-radio-button-wrapper{ .rbndclass .ant-radio-button-wrapper{
width:106px !important; width:106px !important;
height:33px !important; height:33px !important;
@ -868,29 +834,30 @@ class Itembankstop extends Component {
} }
` `
} }
</style> </style>
<div className="rbndclass"> <div className="rbndclass">
<Form.Item label="难度"> <Form.Item label="难度">
{getFieldDecorator('rbnd', {getFieldDecorator('rbnd',
{ {
initialValue: this.state.rbnd, initialValue: this.state.rbnd,
rules: [{ required: true, message: '请选择难度' }], rules: [{ required: true, message: '请选择难度' }],
} }
)( )(
<Radio.Group onChange={this.handleFormLayoutChange}> <Radio.Group onChange={this.handleFormLayoutChange}>
<Radio.Button value="1">简单</Radio.Button> <Radio.Button value="1">简单</Radio.Button>
<Radio.Button value="2">适中</Radio.Button> <Radio.Button value="2">适中</Radio.Button>
<Radio.Button value="3">困难</Radio.Button> <Radio.Button value="3">困难</Radio.Button>
</Radio.Group>, </Radio.Group>,
)} )}
</Form.Item> </Form.Item>
</div> </div>
</Form > </Form>
<div className="h20"></div> <div className="h20"></div>
</div > </div>
) )
} }

Loading…
Cancel
Save