diff --git a/public/react/package.json b/public/react/package.json index f3565cf45..d2b6a23ea 100644 --- a/public/react/package.json +++ b/public/react/package.json @@ -6,7 +6,7 @@ "@flatten/array": "^1.1.7", "@icedesign/base": "^0.2.5", "@novnc/novnc": "^1.1.0", - "antd": "^3.20.1", + "antd": "^3.6.5", "array-flatten": "^2.1.2", "autoprefixer": "7.1.6", "axios": "^0.18.0", diff --git a/public/react/src/modules/courses/poll/PollNew.js b/public/react/src/modules/courses/poll/PollNew.js index 63143c59a..39a16e8a6 100644 --- a/public/react/src/modules/courses/poll/PollNew.js +++ b/public/react/src/modules/courses/poll/PollNew.js @@ -9,7 +9,7 @@ import '../css/Courses.css' import axios from 'axios' import moment from "../new/CoursesNew"; import Modals from "../../modals/Modals"; - +import Editingcomponent from "./components/Editingcomponent" const TextArea = Input.TextArea const RadioGroup = Radio.Group @@ -724,7 +724,7 @@ class PollNew extends Component { } //删除指定条目 - deleteadddom = (indexo) => { + Deleteadddom = (indexo) => { // console.log("deleteadddom 259") var arr = this.state.adddom; let newarr = [...arr]; @@ -739,7 +739,7 @@ class PollNew extends Component { } //保存并继续 //保存并继续,即提交本题的新建并继续创建一个相同的题(该新题处于编辑模式,题目和选项不要清空) - deleteadddomtwo = (indexo, object) => { + Deleteadddomtwo = (indexo, object) => { var thiss = this; this.setState({ q_countst: 1, @@ -1230,7 +1230,7 @@ class PollNew extends Component { //保存,即完成新建并退出本题编辑 // indexo 第几个数组 //object 单个数组数据 - deleteadddomthree = (indexo, object) => { + Deleteadddomthree = (indexo, object) => { // console.log("deleteadddom 349") var thiss = this; let arr = this.state.adddom; @@ -1648,7 +1648,7 @@ class PollNew extends Component { q_countst: 0, }) } - this.deleteadddom(indexo); + this.Deleteadddom(indexo); // console.log(indexo) } @@ -1814,7 +1814,7 @@ class PollNew extends Component { //删除编辑新增条目 //id 条目的唯一id //i 为要删除的子条目 - deleteentrys = (id, i, stirngname) => { + Deleteentrys = (id, i, stirngname) => { // console.log(id) // console.log(stirngname); var arrtwoy = this.state.adddom; @@ -1851,7 +1851,7 @@ class PollNew extends Component { // 新增选项 - ewoption = (id, object) => { + Ewoption = (id, object) => { // console.log("ewoption 440") // console.log("是否是新建题目还是编辑") // console.log(object.question.new) @@ -1913,7 +1913,7 @@ class PollNew extends Component { } //新增其他选项 - addanotheroption = (id) => { + Addanotheroption = (id) => { // console.log("addanotheroption 457") let arrtwo = this.state.adddom; let newarrtwo = [...arrtwo]; @@ -1989,7 +1989,10 @@ class PollNew extends Component { //e为获取组件对象 //i外层数组 //k为内层数组 - handleInputChanges = (e, i, k) => { + HandleInputChanges = (e, i, k) => { + console.log("handleInputChanges"+" "+e); + console.log("handleInputChanges"+" "+i); + console.log("handleInputChanges"+" "+k); // console.log("handleInputChanges 612") let value = e.target.value;//取到input的数据 @@ -2006,7 +2009,7 @@ class PollNew extends Component { } //标题输入监听 - handleInputTopic = (e, i) => { + HandleInputTopic = (e, i) => { // console.log("handleInputTopic 633") let value = e.target.value;//取到input的数据 @@ -2021,7 +2024,7 @@ class PollNew extends Component { } //最小值 - handleGradationGroupChangee = (value, index, max, length) => { + HandleGradationGroupChangee = (value, index, max, length) => { debugger var minbool = false; @@ -2058,7 +2061,7 @@ class PollNew extends Component { } //最大值 - handleGradationGroupChangeee = (value, index) => { + HandleGradationGroupChangeee = (value, index) => { let arr = this.state.adddom; for (var i = 0; i < arr.length; i++) { @@ -2151,7 +2154,7 @@ class PollNew extends Component { } //必答选项 - onCheckAllChange = (e, index) => { + OnCheckAllChange = (e, index) => { // console.log("onCheckAllChange"); // console.log(e.target.checked); // console.log(e.target.value); @@ -2479,8 +2482,9 @@ class PollNew extends Component { {/*自动生成修改好的获取到的*/} {/**************************************************************************/} {this.state.poll_questions === undefined ? "" : this.state.poll_questions.map((item, index) => { - // console.log('打印this.state.poll_questions') - // console.log(item.question) + console.log('打印this.state.poll_questions'); + console.log(this.state.poll_questions); + console.log(this.state.adddom); let resultDom; resultDom =

@@ -2512,7 +2516,7 @@ class PollNew extends Component { onClick={() => this.addMytopic(item.question.question_type, this.state.pollid, index + 1, true, item.question.id)}> - this.adddomedit(item)}> this.adddomedit(item)}> : this.adddomedit(item)}> @@ -2522,165 +2526,388 @@ class PollNew extends Component {

{item.question.question_title}

{/*
{item.question.question_title}
*/} {item.question.question_type === 1 ? - ( +
+ {item.question.answers === undefined ? "" : item.question.answers.map((items, i) => { return (
- {/*
{items.answer_text}
*/} - {/*
{items.answer_text}
*/} {items.answer_text}
) })} -
) + + {/*单选题*/} +
+ {this.state.adddom === undefined ? "" : item.question.question_type === 1&&this.state.adddom.map((itemo, indexo) => { + let arrid = itemo.question.id; + let resultDomtwo; + resultDomtwo = +
+ {itemo.question.question_type === 1 ? "单选题" : itemo.question.question_type === 2 ? "多选题" : "主观题"} + this.OnCheckAllChange(e, indexo)} + className="lineh-40" + style={{"marginLeft": "20px"}}>必答 + + + + + {itemo.question.answers === undefined ? "" : itemo.question.answers.map((itemt, indext) => { + return ( +
+ {itemt.answer_text === undefined ? ( +
) : itemt.answer_text === "其他" ? ( +

+ 其它 + + + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Deleteentrys(arrid, indext, true)}> + : ""} +

) : (

+ 选项 + + + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Deleteentrys(arrid, indext, false)}> + : ""} +

)} +
+ ) + })} + +
+ {itemo.question.question_type === 1 ? ( +
+
+ {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Ewoption(itemo.question.id, itemo)}>新增选项 + + : ""} + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + + (this.state.newoption === false ? + this.Addanotheroption(itemo.question.id)}>新增其他选项 + : "") + : ""} + + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+
+ + + ) + + + : itemo.question.question_type === 2 ? ( + //////////////////////////////////////////// 可选 +
+
+
+ 可选 +
+ {/*可选最小*/} + + + ~ + {/*可选最大*/} + + + (学生答题时,系统对其选择的选项个数进行限制,--表示不限制) +
+ +
+
+
+ ) + + : (
) + + } +
+
+ {itemo.question.question_type === 2 ? + ( + this.state.polls_status === undefined || this.state.polls_status === 1 ? +
+ +
this.Ewoption(itemo.question.id, itemo)}>新增选项 + + { + this.state.newoption === false ? this.Addanotheroption(itemo.question.id)}>新增其他选项 : "" + } + +
+ + + + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+ + + : +
+ + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+ ) + + : itemo.question.question_type === 3 ? +
+ + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+ : + ""} + + +
+
+ + + return ( +
+ {resultDomtwo} +
+ ) + })} + +
+ +
: item.question.question_type === 2 ? - ( +
+ {item.question.answers === undefined ? "" : item.question.answers.map((items, i) => { return (
{items.answer_text} - - {/*{items.answer_text}*/}
) })} -
) - : item.question.question_type === 3 ? (
) : (
)} -
- - return ( -
- {resultDom} -
- ) - })} - {/**************************************************************************/} - {/*编辑用的新增用的*/} - {/**************************************************************************/} - - {this.state.adddom === undefined ? "" : this.state.adddom.map((itemo, indexo) => { - // console.log('打印this.state.adddom') - // console.log(this.state.adddom); - let arrid = itemo.question.id; - let resultDomtwo; - resultDomtwo = -
+ + {/*多选题*/} +
+ {this.state.adddom === undefined ? "" : item.question.question_type === 2&&this.state.adddom.map((itemo, indexo) => { + let arrid = itemo.question.id; + let resultDomtwo; + resultDomtwo = +
{itemo.question.question_type === 1 ? "单选题" : itemo.question.question_type === 2 ? "多选题" : "主观题"} this.onCheckAllChange(e, indexo)} + onChange={(e) => this.OnCheckAllChange(e, indexo)} className="lineh-40" style={{"marginLeft": "20px"}}>必答 - - - {itemo.question.answers === undefined ? "" : itemo.question.answers.map((itemt, indext) => { - return ( -
- {itemt.answer_text === undefined ? ( -
) : itemt.answer_text === "其他" ? ( -

+ + + {itemo.question.answers === undefined ? "" : itemo.question.answers.map((itemt, indext) => { + return ( +

+ {itemt.answer_text === undefined ? ( +
) : itemt.answer_text === "其他" ? ( +

其它 - - {polls_status === undefined || polls_status === 1 ? - this.deleteentrys(arrid, indext, true)}> - : ""} -

) : (

+ + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Deleteentrys(arrid, indext, true)}> + : ""} +

) : (

选项 - - {polls_status === undefined || polls_status === 1 ? - this.deleteentrys(arrid, indext, false)}> - : ""} -

)} -
- ) - })} - -
- {itemo.question.question_type === 1 ? ( -
-
- {polls_status === undefined || polls_status === 1 ? - this.ewoption(itemo.question.id, itemo)}>新增选项 - - : ""} - {polls_status === undefined || polls_status === 1 ? - - (newoption === false ? - this.addanotheroption(itemo.question.id)}>新增其他选项 - : "") - : ""} - + + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Deleteentrys(arrid, indext, false)}> + : ""} +

)} +
+ ) + })} + +
+ {itemo.question.question_type === 1 ? ( +
+
+ {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Ewoption(itemo.question.id, itemo)}>新增选项 + + : ""} + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + + (this.state.newoption === false ? + this.Addanotheroption(itemo.question.id)}>新增其他选项 + : "") + : ""} + this.deleteadddom(indexo)}>取消 + onClick={() => this.Deleteadddom(indexo)}>取消 this.deleteadddomthree(indexo, itemo)}>保存 + onClick={() => this.Deleteadddomthree(indexo, itemo)}>保存 this.deleteadddomtwo(indexo, itemo)}>保存并继续 + onClick={() => this.Deleteadddomtwo(indexo, itemo)}>保存并继续 -
-
+
+
- ) + ) - : itemo.question.question_type === 2 ? ( - //////////////////////////////////////////// 可选 -
-
-
+ : itemo.question.question_type === 2 ? ( + //////////////////////////////////////////// 可选 +
+
+
可选 -
- {/*可选最小*/} - - - ~ - {/*可选最大*/} - - - (学生答题时,系统对其选择的选项个数进行限制,--表示不限制) -
+ } + + + ~ + {/*可选最大*/} + + + (学生答题时,系统对其选择的选项个数进行限制,--表示不限制) +
+ +
+
+
+ ) + + : (
) + + } +
+
+ {itemo.question.question_type === 2 ? + ( + this.state.polls_status === undefined || this.state.polls_status === 1 ? +
+ +
this.Ewoption(itemo.question.id, itemo)}>新增选项 + + { + this.state.newoption === false ? this.Addanotheroption(itemo.question.id)}>新增其他选项 : "" + } + +
+ + + + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+ + + : +
+ + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+ ) + + : itemo.question.question_type === 3 ? +
+ + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+ : + ""} +
-
- ) - : (
) - } -
-
- {itemo.question.question_type === 2 ? - ( - polls_status === undefined || polls_status === 1 ? -
+ return ( +
+ {resultDomtwo} +
+ ) + })} +
+
-
this.ewoption(itemo.question.id, itemo)}>新增选项 + : item.question.question_type === 3 ? + // 主观题 + (
+ {this.state.adddom === undefined ? "" : item.question.question_type === 3&&this.state.adddom.map((itemo, indexo) => { + let arrid = itemo.question.id; + let resultDomtwo; + resultDomtwo = +
+ {itemo.question.question_type === 1 ? "单选题" : itemo.question.question_type === 2 ? "多选题" : "主观题"} + this.OnCheckAllChange(e, indexo)} + className="lineh-40" + style={{"marginLeft": "20px"}}>必答 + - { - newoption === false ? this.addanotheroption(itemo.question.id)}>新增其他选项 : "" - } + + + {itemo.question.answers === undefined ? "" : itemo.question.answers.map((itemt, indext) => { + return ( +
+ {itemt.answer_text === undefined ? ( +
) : itemt.answer_text === "其他" ? ( +

+ 其它 -

+ + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Deleteentrys(arrid, indext, true)}> + : ""} +

) : (

+ 选项 + + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Deleteentrys(arrid, indext, false)}> + : ""} +

)} +
+ ) + })} + +
+ {itemo.question.question_type === 1 ? ( +
+
+ {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Ewoption(itemo.question.id, itemo)}>新增选项 + + : ""} + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + + (this.state.newoption === false ? + this.Addanotheroption(itemo.question.id)}>新增其他选项 + : "") + : ""} + + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+
- + + ) + + + : itemo.question.question_type === 2 ? ( + //////////////////////////////////////////// 可选 +
+
+
+ 可选 +
+ {/*可选最小*/} + + + ~ + {/*可选最大*/} + + + (学生答题时,系统对其选择的选项个数进行限制,--表示不限制) +
+ +
+
+
+ ) + + : (
) + + } +
+
+ {itemo.question.question_type === 2 ? + ( + this.state.polls_status === undefined || this.state.polls_status === 1 ? +
+ +
this.Ewoption(itemo.question.id, itemo)}>新增选项 + + { + this.state.newoption === false ? this.Addanotheroption(itemo.question.id)}>新增其他选项 : "" + } + +
+ + + this.deleteadddom(indexo)}>取消 + onClick={() => this.Deleteadddom(indexo)}>取消 this.deleteadddomthree(indexo, itemo)}>保存 + onClick={() => this.Deleteadddomthree(indexo, itemo)}>保存 this.deleteadddomtwo(indexo, itemo)}>保存并继续 + onClick={() => this.Deleteadddomtwo(indexo, itemo)}>保存并继续 -
+
- : -
+ : +
this.deleteadddom(indexo)}>取消 + onClick={() => this.Deleteadddom(indexo)}>取消 this.deleteadddomthree(indexo, itemo)}>保存 + onClick={() => this.Deleteadddomthree(indexo, itemo)}>保存 this.deleteadddomtwo(indexo, itemo)}>保存并继续 + onClick={() => this.Deleteadddomtwo(indexo, itemo)}>保存并继续 -
- ) +
+ ) - : itemo.question.question_type === 3 ? -
+ : itemo.question.question_type === 3 ? +
this.deleteadddom(indexo)}>取消 + onClick={() => this.Deleteadddom(indexo)}>取消 this.deleteadddomthree(indexo, itemo)}>保存 + onClick={() => this.Deleteadddomthree(indexo, itemo)}>保存 this.deleteadddomtwo(indexo, itemo)}>保存并继续 + onClick={() => this.Deleteadddomtwo(indexo, itemo)}>保存并继续 -
- : - ""} +
+ : + ""} -
-
+
+
+ + return ( +
+ {resultDomtwo} +
+ ) + })} +
) : (
)} +
return (
- {resultDomtwo} + {resultDom}
) })} - {/**************************************************************************/} + +
{polls_status === undefined || polls_status === 1 ?
{ @@ -2820,24 +3298,24 @@ class PollNew extends Component { className="iconfont icon-tianjiafangda font-15 mr10">主观题
- : "" :
-
- this.addmysingles()}>单选题 - this.addmydoubles()}>多选题 - this.addmymainsint()}>主观题 -
+
+ this.addmysingles()}>单选题 + this.addmydoubles()}>多选题 + this.addmymainsint()}>主观题 +
} :
} + { this.props.match.params.news === "new" ? (this.state.Newedit === false ? diff --git a/public/react/src/modules/courses/poll/components/Editingcomponent.js b/public/react/src/modules/courses/poll/components/Editingcomponent.js new file mode 100644 index 000000000..5a27a42e2 --- /dev/null +++ b/public/react/src/modules/courses/poll/components/Editingcomponent.js @@ -0,0 +1,332 @@ +import React, {Component} from "react"; +import '../pollStyle.css' +import {Input, Tooltip, Checkbox, Radio, Select} from 'antd' +import {WordsBtn, ActionBtn} from 'educoder' +const TextArea = Input.TextArea +const RadioGroup = Radio.Group +const CheckboxGroup = Checkbox.Group +class Editingcomponent extends Component { + + constructor(props) { + super(props); + this.state = { + adddom:this.props.adddom, + Newedit:this.props.Newedit, + } + } + componentWillReceiveProps(nextProps) { + const { adddom } = this.state + const newdata = nextProps.adddom.toString() + if (adddom.toString() !== newdata) { + this.setState({ + adddom: nextProps.adddom, + }) + } + } + // componentWillReceiveProps(nextProps) { + // // console.log("46"); + // // console.log(nextProps); + // // console.log(this.props); + // if (nextProps.adddom != this.props.adddom) { + // // console.log("50"); + // // console.log(nextProps.user); + // if (nextProps.adddom !== undefined) { + // // console.log("53"); + // // console.log(nextProps.user); + // this.setState({ + // adddom: nextProps.adddom, + // }) + // } + // + // + // } + // } + + OnCheckAllChange =(e, indexo)=>{ + this.props.OnCheckAllChange(e, indexo); + } + + HandleInputTopic = (e, indexo)=>{ + this.props.HandleInputTopic(e, indexo); + + } + + Deleteentrys=(id, i, stirngname)=>{ + this.props.Deleteentrys(id, i, stirngname); + } + + HandleInputChanges=(e, i, k)=>{ + console.log("handleInputChanges"+" "+e); + console.log("handleInputChanges"+" "+i); + console.log("handleInputChanges"+" "+k); + + this.props.HandleInputChanges(e, i, k); + } + + Ewoption = (id, object) => { + this.props.Ewoption(id, object) + } + + Addanotheroption = (id) => { + this.props.Addanotheroption(id); + } + Deleteadddom = (indexo) => { + this.props.Deleteadddom(indexo); + } + Deleteadddomthree= (indexo, object)=>{ + this.props.Deleteadddomthree(indexo, object); + } + Deleteadddomtwo =(indexo, object)=>{ + this.props.Deleteadddomtwo(indexo, object); + } + HandleGradationGroupChangee = (value, index, max, length) => { + this.props.HandleGradationGroupChangee(value, index, max, length); + } + HandleGradationGroupChangeee= (value, index) => { + this.props.HandleGradationGroupChangeee(value, index); + } + + render() { + return ( +
+ {this.state.adddom === undefined ? "" : this.state.adddom.map((itemo, indexo) => { + let arrid = itemo.question.id; + let resultDomtwo; + resultDomtwo = +
+ {itemo.question.question_type === 1 ? "单选题" : itemo.question.question_type === 2 ? "多选题" : "主观题"} + this.OnCheckAllChange(e, indexo)} + className="lineh-40" + style={{"marginLeft": "20px"}}>必答 + + + + + {itemo.question.answers === undefined ? "" : itemo.question.answers.map((itemt, indext) => { + return ( +
+ {itemt.answer_text === undefined ? ( +
) : itemt.answer_text === "其他" ? ( +

+ 其它 + + + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Deleteentrys(arrid, indext, true)}> + : ""} +

) : (

+ 选项 + + + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Deleteentrys(arrid, indext, false)}> + : ""} +

)} +
+ ) + })} + +
+ {itemo.question.question_type === 1 ? ( +
+
+ {this.state.polls_status === undefined || this.state.polls_status === 1 ? + this.Ewoption(itemo.question.id, itemo)}>新增选项 + + : ""} + {this.state.polls_status === undefined || this.state.polls_status === 1 ? + + (this.state.newoption === false ? + this.Addanotheroption(itemo.question.id)}>新增其他选项 + : "") + : ""} + + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+
+ + + ) + + + : itemo.question.question_type === 2 ? ( + //////////////////////////////////////////// 可选 +
+
+
+ 可选 +
+ {/*可选最小*/} + + + ~ + {/*可选最大*/} + + + (学生答题时,系统对其选择的选项个数进行限制,--表示不限制) +
+ +
+
+
+ ) + + : (
) + + } +
+
+ {itemo.question.question_type === 2 ? + ( + this.state.polls_status === undefined || this.state.polls_status === 1 ? +
+ +
this.Ewoption(itemo.question.id, itemo)}>新增选项 + + { + this.state.newoption === false ? this.Addanotheroption(itemo.question.id)}>新增其他选项 : "" + } + +
+ + + + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+ + + : +
+ + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+ ) + + : itemo.question.question_type === 3 ? +
+ + this.Deleteadddom(indexo)}>取消 + this.Deleteadddomthree(indexo, itemo)}>保存 + this.Deleteadddomtwo(indexo, itemo)}>保存并继续 + +
+ : + ""} + + +
+
+ + + return ( +
+ {resultDomtwo} +
+ ) + })} +
+ ) + + } +} +export default (Editingcomponent); diff --git a/public/react/src/modules/courses/poll/pollStyle.css b/public/react/src/modules/courses/poll/pollStyle.css index ffe13eb10..27a88b95e 100644 --- a/public/react/src/modules/courses/poll/pollStyle.css +++ b/public/react/src/modules/courses/poll/pollStyle.css @@ -1,342 +1,345 @@ -/* 单选或多选 */ -.ant-form{ - color:#05101A; -} -.ant-radio-disabled + span,.ant-checkbox-disabled + span{ - color: #666!important; - cursor: default -} -.ant-radio-wrapper { - color: #666!important; -} -.ant-checkbox-wrapper + .ant-checkbox-wrapper{ - margin-left: 0px!important; -} -/* 下拉 */ -.ant-select-selection,.ant-select-selection-selected-value{ - min-height: 40px; - min-line-height: 40px; -} - -/* 选答 */ -.chooseAnswer{ - display: inline-block; - width: 68px; - text-align: center; - height: 24px; - line-height: 24px; - background: #EDEDED; - color: #666; - margin-left: 10px; - border-radius: 12px; -} - -.problemShow{ - padding:30px; - border-bottom: 1px solid #eee; -} -.problemShow:last-child{ - border-bottom: none; -} - -/* 问卷详情 */ -/* 答题列表 */ -.unlimit{ - height: 24px; - line-height: 24px; - padding:0px 10px; - border-radius: 12px; - cursor: pointer; - border:1px solid #cdcdcd; - color:#666; -} -.unlimit.active{ - background-color: #4CACFF; - border:1px solid #4CACFF; - color: #fff; -} -.edu-table thead th,.edu-table tbody tr:last-child td{ - border-bottom: none!important; -} -.edu-table tbody tr:hover td{ - background-color: #fff!important; -} -/* 统计结果 */ -.countList p.countHeader{ - background-color: #f8f8f8; - color: #666; - height: 38px; - font-size: 16px; - justify-content: center; - align-items: center; - display: -webkit-flex; -} -.countList p.countHeader ul{ - width: 100%; - padding:0px 30px -} -.countList p.countHeader span,.countList div.countBody span{ - float: left; -} -.countList div.countBody{ - margin:0px 30px; - border-bottom:1px solid #EBEBEB; - padding:12px 0px; -} -.countList div.countBody:last-child{ - border-bottom: none; -} -.countList p.countHeader span:nth-child(1),.countList div.countBody span:nth-child(1){ - width: 50%; - text-align: left; -} -.countList p.countHeader span:nth-child(2),.countList div.countBody span:nth-child(2){ - width:15%; - text-align: center; -} -.countList p.countHeader span:nth-child(3),.countList div.countBody span:nth-child(3){ - width:35%; - text-align: left; -} -.percentForm{ - width: 340px; - height: 11px; - background: #F5F5F5; - border-radius: 6px; - position: relative; - margin-top: 7px; -} -.percentValue{ - position: absolute; - top:0px; - left: 0px; - height: 11px; - background: #29BD8B; - border-radius: 6px; -} -.answerTxt{ - max-height: 500px; - background-color: #F2F9FF; - width: 100%; - margin-top: 10px; - padding:10px; - box-sizing: border-box; - color: #4c4c4c; -} -.otherTxt{ - border:none!important; - border-bottom: 1px solid #eee!important; - background: transparent!important; - flex:1; - height: 20px!important; - line-height: 20px!important; -} -.otherTxt.ant-input:hover,.otherTxt.ant-input:focus{ - border:none!important; - border-bottom: 1px solid #eee!important; - background: #F8F8F8!important; -} - -/* 必答 */ -.mustAnswer{ - padding:0px 10px; - border-radius: 15px; - height: 22px; - line-height: 22px; - background: #eaeaea; - color: #999; - font-size: 14px; -} -/* 问卷内容 */ -.previewList{ - border-bottom: 1px solid #ebebeb; -} -.previewList:last-child{ - border-bottom:none; -} -.textLine{ - flex: 1; - height:22px; - border-bottom: 1px solid #ebebeb; -} -.answerList{ - box-sizing: border-box; - width: 100%; - margin-bottom: 20px; -} -.answerList li{ - padding:10px 30px; - box-sizing: border-box; - line-height:20px; - width: 100%; -} -.answerList li:hover{ - background: #F8F8F8; -} -textarea:read-only{ - background: #f3f3f3; -} -.ant-calendar-picker-input{ - height: 40px; -} - -/* 问卷答题 */ -.questionsNo{ - position: relative; - padding: 30px; - border-bottom: 1px solid #ebebeb; -} -.questionsfixed{ - position: fixed; - padding: 30px; - z-index: 12; - top: 60px; - width: 1200px; - background: #fff; -} -.answered,.unanswer,.answerTure,.answerFalse,.answerHalf{ - position: relative; -} -.answered::after{ - position: absolute; - right:35px; - top:4px; - width: 12px; - height: 12px; - border-radius: 50%; - background: #CBCBCB; - content: ""; -} -.unanswer::after{ - position: absolute; - right:35px; - top:4px; - width: 12px; - height: 12px; - border-radius: 50%; - background: #fff; - content: ""; - border:1px solid rgba(203,203,203,1); -} -.answerTure::after{ - position: absolute; - right:35px; - top:4px; - width: 20px; - height: 10px; - border-radius: 5px; - background: #29BD8B; - content: ""; -} -.answerFalse::after{ - position: absolute; - right:35px; - top:4px; - width: 20px; - height: 10px; - border-radius: 5px; - background: #FF3756; - content: ""; -} -.color-red{color: #FF3756!important} -.answerHalf::after{ - position: absolute; - left:-25px; - top:4px; - width: 20px; - height: 10px; - border-radius: 5px; - background: #FF6800; - content: ""; -} -.leaderNav,.leaderMainNav{ - margin-top: 20px; -} -.leaderNav a,.leaderMainNav a{ - display: block; - float: left; - margin-right: 10px; - border-radius: 50%; - border:1px solid #CBCBCB; - height: 40px; - line-height: 40px; - width: 40px; - text-align: center; - color: #999999; - cursor: pointer; - margin-bottom: 5px; -} -.leaderMainNav a{ - background: #FF3756; - color: #fff; - border:1px solid #FF3756; -} -.leaderNav a.acted{ - background:rgba(203,203,203,1); - color: #fff; -} -.leaderMainNav a.acted{ - background-color: #29BD8B; - color: #fff; - border:1px solid #29BD8B; -} -.leaderMainNav a.half{ - background-color: #FF6800; - color: #fff; - border:1px solid #FF6800; -} - -/* 问卷设置 */ -.pollForm .ant-form-item-control{ - line-height: 20px; -} -.pollForm.ant-form-item{ - margin-bottom: 0px -} -.setInfo .ant-select-selection__rendered{ - line-height: 40px; -} - -/* 下拉搜索框 */ -.ant-select-dropdown-menu .ant-select-dropdown-menu-item{ - padding:5px 15px; -} -.ant-select-dropdown.ant-select-dropdown--multiple .ant-select-dropdown-menu-item .ant-select-selected-icon{ - right: 15px; -} - -.noticeTip{ - border:1px solid #FF0000; - border-radius: 5px; -} - -/* 试卷 */ -.setScoreInput{ - width: 60px!important;height: 30px!important;box-sizing: border-box; - text-align: center!important; - background: #F8F8F8; - color:#666; -} -.setScoreInput:focus{ - background: #fff; - color:#FF6800 -} -.standardAnswer p{ - line-height: 20px!important; -} -/* 倒计时 */ -.remainingTime li{ - float: left; - width: 40px; - line-height: 40px; - background-color: #111C24; - color: #fff; - border-radius: 4px; - text-align: center -} -.remainingTime span{ - float: left; - width: 20px; - line-height: 40px; - text-align: center; -} +/* 单选或多选 */ +.ant-form{ + color:#05101A; +} +.ant-radio-disabled + span,.ant-checkbox-disabled + span{ + color: #666!important; + cursor: default +} +.ant-radio-wrapper { + color: #666!important; +} +.ant-checkbox-wrapper + .ant-checkbox-wrapper{ + margin-left: 0px!important; +} +/* 下拉 */ +.ant-select-selection,.ant-select-selection-selected-value{ + min-height: 40px; + min-line-height: 40px; +} + +/* 选答 */ +.chooseAnswer{ + display: inline-block; + width: 68px; + text-align: center; + height: 24px; + line-height: 24px; + background: #EDEDED; + color: #666; + margin-left: 10px; + border-radius: 12px; +} + +.problemShow{ + padding:30px; + border-bottom: 1px solid #eee; +} +.problemShow:last-child{ + border-bottom: none; +} + +/* 问卷详情 */ +/* 答题列表 */ +.unlimit{ + height: 24px; + line-height: 24px; + padding:0px 10px; + border-radius: 12px; + cursor: pointer; + border:1px solid #cdcdcd; + color:#666; +} +.unlimit.active{ + background-color: #4CACFF; + border:1px solid #4CACFF; + color: #fff; +} +.edu-table thead th,.edu-table tbody tr:last-child td{ + border-bottom: none!important; +} +.edu-table tbody tr:hover td{ + background-color: #fff!important; +} +/* 统计结果 */ +.countList p.countHeader{ + background-color: #f8f8f8; + color: #666; + height: 38px; + font-size: 16px; + justify-content: center; + align-items: center; + display: -webkit-flex; +} +.countList p.countHeader ul{ + width: 100%; + padding:0px 30px +} +.countList p.countHeader span,.countList div.countBody span{ + float: left; +} +.countList div.countBody{ + margin:0px 30px; + border-bottom:1px solid #EBEBEB; + padding:12px 0px; +} +.countList div.countBody:last-child{ + border-bottom: none; +} +.countList p.countHeader span:nth-child(1),.countList div.countBody span:nth-child(1){ + width: 50%; + text-align: left; +} +.countList p.countHeader span:nth-child(2),.countList div.countBody span:nth-child(2){ + width:15%; + text-align: center; +} +.countList p.countHeader span:nth-child(3),.countList div.countBody span:nth-child(3){ + width:35%; + text-align: left; +} +.percentForm{ + width: 340px; + height: 11px; + background: #F5F5F5; + border-radius: 6px; + position: relative; + margin-top: 7px; +} +.percentValue{ + position: absolute; + top:0px; + left: 0px; + height: 11px; + background: #29BD8B; + border-radius: 6px; +} +.answerTxt{ + max-height: 500px; + background-color: #F2F9FF; + width: 100%; + margin-top: 10px; + padding:10px; + box-sizing: border-box; + color: #4c4c4c; +} +.otherTxt{ + border:none!important; + border-bottom: 1px solid #eee!important; + background: transparent!important; + flex:1; + height: 20px!important; + line-height: 20px!important; +} +.otherTxt.ant-input:hover,.otherTxt.ant-input:focus{ + border:none!important; + border-bottom: 1px solid #eee!important; + background: #F8F8F8!important; +} + +/* 必答 */ +.mustAnswer{ + padding:0px 10px; + border-radius: 15px; + height: 22px; + line-height: 22px; + background: #eaeaea; + color: #999; + font-size: 14px; +} +/* 问卷内容 */ +.previewList{ + border-bottom: 1px solid #ebebeb; +} +.previewList:last-child{ + border-bottom:none; +} +.textLine{ + flex: 1; + height:22px; + border-bottom: 1px solid #ebebeb; +} +.answerList{ + box-sizing: border-box; + width: 100%; + margin-bottom: 20px; +} +.answerList li{ + padding:10px 30px; + box-sizing: border-box; + line-height:20px; + width: 100%; +} +.answerList li:hover{ + background: #F8F8F8; +} +textarea:read-only{ + background: #f3f3f3; +} +.ant-calendar-picker-input{ + height: 40px; +} + +/* 问卷答题 */ +.questionsNo{ + position: relative; + padding: 30px; + border-bottom: 1px solid #ebebeb; +} +.questionsfixed{ + position: fixed; + padding: 30px; + z-index: 12; + top: 60px; + width: 1200px; + background: #fff; +} +.answered,.unanswer,.answerTure,.answerFalse,.answerHalf{ + position: relative; +} +.answered::after{ + position: absolute; + right:35px; + top:4px; + width: 12px; + height: 12px; + border-radius: 50%; + background: #CBCBCB; + content: ""; +} +.unanswer::after{ + position: absolute; + right:35px; + top:4px; + width: 12px; + height: 12px; + border-radius: 50%; + background: #fff; + content: ""; + border:1px solid rgba(203,203,203,1); +} +.answerTure::after{ + position: absolute; + right:35px; + top:4px; + width: 20px; + height: 10px; + border-radius: 5px; + background: #29BD8B; + content: ""; +} +.answerFalse::after{ + position: absolute; + right:35px; + top:4px; + width: 20px; + height: 10px; + border-radius: 5px; + background: #FF3756; + content: ""; +} +.color-red{color: #FF3756!important} +.answerHalf::after{ + position: absolute; + left:-25px; + top:4px; + width: 20px; + height: 10px; + border-radius: 5px; + background: #FF6800; + content: ""; +} +.leaderNav,.leaderMainNav{ + margin-top: 20px; +} +.leaderNav a,.leaderMainNav a{ + display: block; + float: left; + margin-right: 10px; + border-radius: 50%; + border:1px solid #CBCBCB; + height: 40px; + line-height: 40px; + width: 40px; + text-align: center; + color: #999999; + cursor: pointer; + margin-bottom: 5px; +} +.leaderMainNav a{ + background: #FF3756; + color: #fff; + border:1px solid #FF3756; +} +.leaderNav a.acted{ + background:rgba(203,203,203,1); + color: #fff; +} +.leaderMainNav a.acted{ + background-color: #29BD8B; + color: #fff; + border:1px solid #29BD8B; +} +.leaderMainNav a.half{ + background-color: #FF6800; + color: #fff; + border:1px solid #FF6800; +} + +/* 问卷设置 */ +.pollForm .ant-form-item-control{ + line-height: 20px; +} +.pollForm.ant-form-item{ + margin-bottom: 0px +} +.setInfo .ant-select-selection__rendered{ + line-height: 40px; +} + +/* 下拉搜索框 */ +.ant-select-dropdown-menu .ant-select-dropdown-menu-item{ + padding:5px 15px; +} +.ant-select-dropdown.ant-select-dropdown--multiple .ant-select-dropdown-menu-item .ant-select-selected-icon{ + right: 15px; +} + +.noticeTip{ + border:1px solid #FF0000; + border-radius: 5px; +} + +/* 试卷 */ +.setScoreInput{ + width: 60px!important;height: 30px!important;box-sizing: border-box; + text-align: center!important; + background: #F8F8F8; + color:#666; +} +.setScoreInput:focus{ + background: #fff; + color:#FF6800 +} +.standardAnswer p{ + line-height: 20px!important; +} +/* 倒计时 */ +.remainingTime li{ + float: left; + width: 40px; + line-height: 40px; + background-color: #111C24; + color: #fff; + border-radius: 4px; + text-align: center +} +.remainingTime span{ + float: left; + width: 20px; + line-height: 40px; + text-align: center; +} +.myyslwidth { + min-width:1200px +} \ No newline at end of file