dev_aliyun2
杨树林 5 years ago committed by harry
parent 7467cc0455
commit 330caed864

@ -79,7 +79,9 @@ class Paperreview_single extends Component {
itemsnamesy = objectsingle && objectsingle.program_attr && objectsingle.program_attr.description; itemsnamesy = objectsingle && objectsingle.program_attr && objectsingle.program_attr.description;
} }
var fenshul=(objectsingle.score+"分"); var fenshul=(objectsingle.score+"分");
const options = [
'bold', // 加粗
]
return ( return (
<div key={indexxy} <div key={indexxy}
className={"w100s borderwdswuh mb20 pd20 "} className={"w100s borderwdswuh mb20 pd20 "}
@ -162,6 +164,7 @@ class Paperreview_single extends Component {
"" ""
: :
<QuillForEditor <QuillForEditor
options={options}
readOnly={true} readOnly={true}
value={itemssname} value={itemssname}
/> />

@ -160,20 +160,23 @@ class Listjihe extends Component {
try { try {
analysisnames = JSON.parse(items && items.analysis); analysisnames = JSON.parse(items && items.analysis);
} catch (e) { }catch (e) {
analysisnames = items && items.analysis; analysisnames=items&&items.analysis;
} }
console.log(items.name); // console.log(items.name);
console.log(itemsnamesy); // console.log(itemsnamesy);
//
console.log(analysisnames); // console.log(analysisnames);
return ( const options = [
<div key={keindex} 'bold', // 加粗
className={chakanjiexiboolindex === keindex ? "w100s borderwds283 pd20 mb20 listjihecolors" : "w100s borderwds pd20 mb20 listjihecolors"}> ]
{/*顶部*/} return (
<style> <div key={keindex}
{ className={chakanjiexiboolindex === keindex ? "w100s borderwds283 pd20 mb20 listjihecolors" : "w100s borderwds pd20 mb20 listjihecolors"}>
` .markdown-body .ql-editor{ {/*顶部*/}
<style>
{
` .markdown-body .ql-editor{
padding-left: 0px !important; padding-left: 0px !important;
padding-top: 0px !important; padding-top: 0px !important;
} }
@ -193,64 +196,65 @@ class Listjihe extends Component {
this.props.listjihe this.props.listjihe
}. }.
</div> </div>
{ {
items.item_type === "PROGRAM" ? items.item_type==="PROGRAM"?
<a href={`/problems/${items.program_attr.identifier}/edit`}> <a href={`/problems/${items.program_attr.identifier}/edit`}>
<div className="ml10 w100s " style={{ wordBreak: "break-word" }} dangerouslySetInnerHTML={{ __html: markdownToHTML(items && items.name).replace(/▁/g, "▁▁▁") }}></div> <div className="ml10 w100s " style={{wordBreak: "break-word"}} dangerouslySetInnerHTML={{__html: markdownToHTML(items&&items.name).replace(/▁/g, "▁▁▁")}}></div>
</a> </a>
: :
<div className="ml10 w100s markdown-body" style={{ wordBreak: "break-word" }}> <div className="ml10 w100s markdown-body" style={{wordBreak: "break-word"}}>
{items === undefined || items === null || items === "" ? "" : { items===undefined||items===null||items===""?"":
items.name === undefined || items.name === null || items.name === "" ? items.name === undefined || items.name === null || items.name === "" ?
"" ""
: :
items.name.length > 0 ? items.name.length>0?
itemssname === null || itemssname === undefined ? "" : itemssname===null|| itemssname===undefined?"":
<QuillForEditor <QuillForEditor
readOnly={true} options={options}
value={itemssname} readOnly={true}
/> value={itemssname}
: "" />
} :""
</div> }
} </div>
}
</div> </div>
{/*内容*/} {/*内容*/}
<div className="w100s sortinxdirection "> <div className="w100s sortinxdirection ">
{items.item_type === "JUDGMENT" ? {items.item_type === "JUDGMENT" ?
<p className="w100s listjihetixingstitsp sortinxdirection "> <p className="w100s listjihetixingstitsp sortinxdirection ">
{ {
items === undefined || items === null ? "" : items.choices.map((object, index) => { items === undefined || items === null ? "" : items.choices.map((object, index) => {
return ( return (
<p className={index === 1 ? "sortinxdirection ml10" : "sortinxdirection "}> <p className={index === 1 ? "sortinxdirection ml10" : "sortinxdirection "}>
<Radio disabled={true} > <Radio disabled={true} >
{object.choice_text} {object.choice_text}
</Radio> </Radio>
</p> </p>
) )
}) })
} }
</p> : </p> :
items.item_type === "PROGRAM" ? items.item_type === "PROGRAM" ?
<p className="w100s listjihetixingstitssy sortinxdirection "> <p className="w100s listjihetixingstitssy sortinxdirection ">
<p id={"itemsnamesyid"} className={"sortinxdirection mt15"}> <p id={"itemsnamesyid"} className={"sortinxdirection mt15"}>
{ {
items && items.program_attr && items.program_attr.description ? items&&items.program_attr&&items.program_attr.description?
<p className="programquill" style={{ wordBreak: "break-word" }} <p className="programquill" style={{wordBreak: "break-word"}}
> >
{ {
itemsnamesy === null || itemsnamesy === undefined ? itemsnamesy===null || itemsnamesy===undefined?
"" ""
: :
<QuillForEditor <QuillForEditor
readOnly={true} readOnly={true}
value={itemsnamesy} value={itemsnamesy}
/> />
} }
</p> </p>
: "" :""
} }

@ -77,6 +77,9 @@ class Paperlibraryseeid_items extends Component {
} catch (e) { } catch (e) {
itemsnamesy = objectsingle && objectsingle.program_attr && objectsingle.program_attr.description; itemsnamesy = objectsingle && objectsingle.program_attr && objectsingle.program_attr.description;
} }
const options = [
'bold', // 加粗
]
return ( return (
<div key={indexxy} <div key={indexxy}
className={"w100s borderwdswuh mb20 pd20 "} className={"w100s borderwdswuh mb20 pd20 "}
@ -159,6 +162,7 @@ class Paperlibraryseeid_items extends Component {
"" ""
: :
<QuillForEditor <QuillForEditor
options={options}
readOnly={true} readOnly={true}
value={itemssname} value={itemssname}
/> />

Loading…
Cancel
Save