Compare commits

..

No commits in common. 'master' and 'V3.0.0' have entirely different histories.

  1. 34
      src/components/TestPanel.vue
  2. 17
      src/components/tinymceConfig.js
  3. 15
      src/config/index.js
  4. 208
      src/views/Report.vue

@ -35,7 +35,7 @@
v-if="$parent.language === 'vscode' && !isSubmit && !competitionId">填写实验报告</el-button> v-if="$parent.language === 'vscode' && !isSubmit && !competitionId">填写实验报告</el-button>
<el-button @click="toReport" v-if="isSubmit && !competitionId">查看实验报告</el-button> <el-button @click="toReport" v-if="isSubmit && !competitionId">查看实验报告</el-button>
<el-button class="reload" @click="reloadConfirm" v-show="projectPermissions == 0">重新开始</el-button> <el-button class="reload" @click="reloadConfirm" v-show="projectPermissions == 0">重新开始</el-button>
<el-button type="primary" class="submit btn" :loading="submiting" @click="confirmSubmit" <el-button type="primary" class="submit btn" @click="confirmSubmit"
:disabled="isSubmit || !projectList.length">提交</el-button> :disabled="isSubmit || !projectList.length">提交</el-button>
</div> </div>
</el-header> </el-header>
@ -151,7 +151,7 @@
</el-container> </el-container>
</el-container> </el-container>
<div :class="['toggle-panel', { active: pannelVisible, ai: third }]"> <div :class="['toggle-panel', { active: pannelVisible, ai: isAI }]">
<!-- <div @click="togglePannel"> --> <!-- <div @click="togglePannel"> -->
<div> <div>
<i class="el-icon-rank drag-icon" id="drag"></i> <i class="el-icon-rank drag-icon" id="drag"></i>
@ -221,7 +221,7 @@ import Stomp from 'stompjs'
export default { export default {
data () { data () {
return { return {
third: Cookie.get('admin-third'), // iframe isAI: Cookie.get('admin-isAI') == 'true' ? true : false,
token: Cookie.get('admin-token'), token: Cookie.get('admin-token'),
systemId: Cookie.get('admin-systemId') || 1, systemId: Cookie.get('admin-systemId') || 1,
classId: Cookie.get('admin-classId'), classId: Cookie.get('admin-classId'),
@ -296,13 +296,11 @@ export default {
reportVisible: false, reportVisible: false,
tableHeight: 0, tableHeight: 0,
dragIds: ['panelHeader', 'aside', 'main', 'infoContainer'], dragIds: ['panelHeader', 'aside', 'main', 'infoContainer'],
confirmSubmiting: false,
submiting: false, submiting: false,
client: '', client: '',
accountId: '', accountId: '',
runCodeType: '', runCodeType: '',
finishVscodeItem: 0, finishVscodeItem: 0,
vscodeRunCodeNum: 0,
clientTopic: '', clientTopic: '',
}; };
}, },
@ -334,7 +332,7 @@ export default {
this.getAssList() this.getAssList()
} else { // } else { //
if (Cookie.get('doneProjectId')) { // id if (Cookie.get('doneProjectId')) { // id
if (!this.projectPermissions) this.projectId = +Cookie.get('doneProjectId') this.projectId = +Cookie.get('doneProjectId')
} else { } else {
// //
if (Cookie.get('admin-loaded')) { if (Cookie.get('admin-loaded')) {
@ -678,7 +676,7 @@ export default {
let href = location.origin let href = location.origin
if (this.$config.isTest) href += '/student' if (this.$config.isTest) href += '/student'
if (this.$config.isDev) href = `http://${location.hostname}:8082` if (this.$config.isDev) href = `http://${location.hostname}:8082`
href += `/#/record/trialReport?python=1&reportId=${reportId}` href += `/#/record/show?python=1&reportId=${reportId}`
// //
if (this.projectPermissions == 0) { if (this.projectPermissions == 0) {
href += `&curriculumId=${this.courseId}&projectId=${this.projectId}` href += `&curriculumId=${this.courseId}&projectId=${this.projectId}`
@ -751,7 +749,7 @@ export default {
this.$parent.workbench[i].codeId = data.codeId this.$parent.workbench[i].codeId = data.codeId
this.$parent.workbench[i].retResult = 1 this.$parent.workbench[i].retResult = 1
this.finishVscodeItem++ this.finishVscodeItem++
this.finishVscodeItem === this.vscodeRunCodeNum && this.submit() this.finishVscodeItem === this.$parent.workbench.length && this.submit()
}, },
emptyRunCode (data) { emptyRunCode (data) {
this.$parent.workbench[0].codeId = data.codeId this.$parent.workbench[0].codeId = data.codeId
@ -759,8 +757,8 @@ export default {
}, },
// //
confirmSubmit () { confirmSubmit () {
if (this.confirmSubmiting) return false if (this.submiting) return false
this.confirmSubmiting = true this.submiting = true
const isVscode = this.$parent.language === 'vscode' // vscode const isVscode = this.$parent.language === 'vscode' // vscode
const { taskList } = this const { taskList } = this
const pointList = this.$parent.workbench const pointList = this.$parent.workbench
@ -773,7 +771,6 @@ export default {
} else { } else {
if (!taskList.find(e => e.code || e.codeResult)) msg = '实验报告未填写,实验成绩为零,是否确认提交?' if (!taskList.find(e => e.code || e.codeResult)) msg = '实验报告未填写,实验成绩为零,是否确认提交?'
} }
this.vscodeRunCodeNum = 0
this.finishVscodeItem = 0 this.finishVscodeItem = 0
this.$confirm(msg, '提示', { this.$confirm(msg, '提示', {
confirmButtonText: '确定', confirmButtonText: '确定',
@ -786,7 +783,6 @@ export default {
if (isVscode) { if (isVscode) {
taskList.map(async (e, i) => { taskList.map(async (e, i) => {
if (e.code || e.codeResult) { if (e.code || e.codeResult) {
this.vscodeRunCodeNum++
this.runCodeType = 'vscodeRunCode' this.runCodeType = 'vscodeRunCode'
await this.$post(this.api.runPythonCode, { await this.$post(this.api.runPythonCode, {
assessmentId: this.assessmentId, assessmentId: this.assessmentId,
@ -799,7 +795,6 @@ export default {
type: 'vscode', type: 'vscode',
sort: i sort: i
}) })
this.$parent.workbench[i].finalCode = e.code
this.$parent.workbench[i].answer = e.codeResult this.$parent.workbench[i].answer = e.codeResult
} }
}) })
@ -816,20 +811,19 @@ export default {
projectId: this.projectId, projectId: this.projectId,
type: this.$parent.language type: this.$parent.language
}).then(res => { }).catch(err => { }).then(res => { }).catch(err => {
this.confirmSubmiting = false this.submiting = false
}) })
} else { } else {
this.submit() this.submit()
} }
} }
}).catch(() => { }).catch(() => {
this.confirmSubmiting = false this.submiting = false
}) })
}, },
// //
async submit () { async submit () {
if (this.isSubmit || this.submiting) return false if (this.isSubmit) return false
this.submiting = true
const pointList = this.$parent.workbench const pointList = this.$parent.workbench
const date = await this.getNow() const date = await this.getNow()
const { entryTime } = this const { entryTime } = this
@ -895,7 +889,7 @@ export default {
this.reportId = reportId this.reportId = reportId
this.$store.commit('setReportId', reportId) this.$store.commit('setReportId', reportId)
this.$store.commit('setTaskList', taskList) this.$store.commit('setTaskList', taskList)
this.confirmSubmiting = false this.editReport(reportId)
this.submiting = false this.submiting = false
// //
if (this.competitionId) { if (this.competitionId) {
@ -1118,7 +1112,7 @@ export default {
// //
connect () { connect () {
let ws = new WebSocket(`wss://python.occupationlab.com/ws`); let ws = new WebSocket(this.$config.isTest ? `ws://139.159.153.48:15674/ws` : `wss://python.occupationlab.com/ws`);
// let ws = new WebSocket(`wss://python.occupationlab.com/ws`); // let ws = new WebSocket(`wss://python.occupationlab.com/ws`);
this.client = Stomp.over(ws); this.client = Stomp.over(ws);
this.client.heartbeat.outgoing = 0 this.client.heartbeat.outgoing = 0
@ -1129,7 +1123,7 @@ export default {
passcode: this.$config.isTest ? 'huorantest2024' : 'huoran2024' passcode: this.$config.isTest ? 'huorantest2024' : 'huoran2024'
}; };
// //
this.client.connect(headers.login, headers.passcode, this.onConnected, this.$config.isTest ? `pytest` : 'pyhost') this.client.connect(headers.login, headers.passcode, this.onConnected, this.onFailed, 'pyhost');
}, },
onConnected () { onConnected () {
// //

@ -4,7 +4,7 @@ export default {
//skin:'oxide-dark', //skin:'oxide-dark',
language:'zh_CN', language:'zh_CN',
language_url: './styles/tinymce/langs/zh_CN.js', language_url: './styles/tinymce/langs/zh_CN.js',
plugins: 'print preview searchreplace autolink directionality visualblocks visualchars fullscreen image link media template codesample table charmap hr pagebreak nonbreaking anchor insertdatetime advlist lists wordcount imagetools textpattern help emoticons autoresize', plugins: 'print preview searchreplace autolink directionality visualblocks visualchars fullscreen image link media template codesample table charmap hr pagebreak nonbreaking anchor insertdatetime advlist lists wordcount imagetools textpattern help emoticons autosave autoresize',
toolbar: 'code undo redo restoredraft | cut copy pastetext | forecolor backcolor headings fontsize lineHeight bold italic underline strikethrough link anchor | alignleft aligncenter alignright alignjustify | \ toolbar: 'code undo redo restoredraft | cut copy pastetext | forecolor backcolor headings fontsize lineHeight bold italic underline strikethrough link anchor | alignleft aligncenter alignright alignjustify | \
styleselect fontselect fontsizeselect | bullist numlist | blockquote subscript superscript removeformat | \ styleselect fontselect fontsizeselect | bullist numlist | blockquote subscript superscript removeformat | \
table image media charmap emoticons hr pagebreak insertdatetime print preview | fullscreen | indent2em', table image media charmap emoticons hr pagebreak insertdatetime print preview | fullscreen | indent2em',
@ -212,8 +212,7 @@ export default {
}, },
//为内容模板插件提供预置模板 //为内容模板插件提供预置模板
templates: [ templates: [
{ { title: '个股分析报告', description: '', content: `
title: '个股分析报告', description: '', content: `
<div class="tiny-report"> <div class="tiny-report">
<h2>个股分析报告</h2> <h2>个股分析报告</h2>
<h6>1.引言</h6> <h6>1.引言</h6>
@ -272,8 +271,7 @@ export default {
` `
}, },
{ { title: '行业数据分析报告', description: '', content: `
title: '行业数据分析报告', description: '', content: `
<div class="tiny-report"> <div class="tiny-report">
<h2>行业数据分析报告</h2> <h2>行业数据分析报告</h2>
<h6>1.引言</h6> <h6>1.引言</h6>
@ -346,8 +344,7 @@ export default {
` `
}, },
{ { title: '宏观数据分析报告', description: '', content: `
title: '宏观数据分析报告', description: '', content: `
<div class="tiny-report"> <div class="tiny-report">
<h2>宏观数据分析报告</h2> <h2>宏观数据分析报告</h2>
<h6>1.引言</h6> <h6>1.引言</h6>
@ -406,8 +403,7 @@ export default {
` `
}, },
{ { title: '可视化报告', description: '', content: `
title: '可视化报告', description: '', content: `
<div class="tiny-report"> <div class="tiny-report">
<h2>可视化报告</h2> <h2>可视化报告</h2>
<h6>1.封面</h6> <h6>1.封面</h6>
@ -478,8 +474,7 @@ export default {
` `
}, },
{ { title: '数据分析报告', description: '', content: `
title: '数据分析报告', description: '', content: `
<div class="tiny-report"> <div class="tiny-report">
<h2>数据分析报告</h2> <h2>数据分析报告</h2>
<h6>1.引言</h6> <h6>1.引言</h6>

@ -2,25 +2,24 @@ import Cookie from 'js-cookie'
const url = location.host const url = location.host
const isDev = process.env.NODE_ENV === 'development' //是否本地 const isDev = process.env.NODE_ENV === 'development' //是否本地
const isTest = url.includes('118.31.167.228') //测试服 const isTest = url.includes('121.37.12.51') //测试服
const isHh = url.includes('10.196.131.73') //是否是河海版本 const isHh = url.includes('10.196.131.73') //是否是河海版本
const isPro = url.includes('occupationlab.com') //是否职站生产 const isPro = url.includes('occupationlab.com') //是否职站生产
const isZxy = url.includes('izhixinyun.com') //是否智信云 const isZxy = url.includes('izhixinyun.com') //是否智信云
let vscodeUrl = 'http://172.16.40.56:8088/' let vscodeUrl = 'http://10.60.32.77:8888'
let host = location.origin + '/' let host = location.origin + '/'
// let host = `https://izhixinyun.com/` // let host = `https://izhixinyun.com/`
let bankPath = `${location.origin}/systembank` // 银行系统 let bankPath = `${location.origin}/banksystem` // 银行系统
// 118.31.167.228 | 192.168.31.151 // 121.37.12.51 | 192.168.31.151
if (isDev) { if (isDev) {
host = 'http://192.168.31.217:9000/' host = 'http://192.168.31.217:9000/'
host = 'http://118.31.167.228/' host = 'http://121.37.12.217:9000/'
// host = 'https://izhixinyun.com/' // host = 'https://occupationlab.com/'
bankPath = `http://${location.hostname}:8093` bankPath = `http://${location.hostname}:8093`
} else if (isPro) { } else if (isPro) {
host = 'https://occupationlab.com/' host = 'https://occupationlab.com/'
bankPath = `https://www.huorantech.cn/systembank` bankPath = `https://www.huorantech.cn/banksystem`
vscodeUrl = 'https://vscode.occupationlab.com' vscodeUrl = 'https://vscode.occupationlab.com'
} else if (isZxy) { } else if (isZxy) {
vscodeUrl = 'https://vscode.izhixinyun.com' vscodeUrl = 'https://vscode.izhixinyun.com'

@ -2,112 +2,165 @@
<!-- 实验报告 --> <!-- 实验报告 -->
<div class="wrap"> <div class="wrap">
<breadcrumb data="返回实验/我的数据"></breadcrumb> <breadcrumb data="返回实验/我的数据"></breadcrumb>
<div class="content" :class="{ loading }" id="pdfDom"> <div class="content"
<div style="text-align: right" v-if="!loading"> :class="{loading}"
<el-button size="mini" @click="editReport"> id="pdfDom">
<div style="text-align: right"
v-if="!loading">
<el-button size="mini"
@click="editReport">
{{ editing ? "保存" : "编辑" }} {{ editing ? "保存" : "编辑" }}
</el-button> </el-button>
<el-button type="primary" size="mini" @click="exportPage">导出报告</el-button> <el-button type="primary"
size="mini"
@click="exportPage">导出报告</el-button>
</div> </div>
<h6 class="r-title">标准实验报告</h6> <h6 class="r-title">标准实验报告</h6>
<div class="info"> <div class="info">
<h6 class="l-title"> <h6 class="l-title">
<img src="@/assets/images/report1.png" alt=""> <img src="@/assets/images/report1.png"
alt="">
基本信息 基本信息
</h6> </h6>
<ul :class="['info-list', {edit: editing}]"> <ul :class="['info-list', {edit: editing}]">
<li> <li>
<label>学生姓名</label> <label>学生姓名</label>
<el-input v-if="editing" v-model="infoData.userName" disabled></el-input> <el-input v-if="editing"
v-model="infoData.userName"
disabled></el-input>
<span v-else>{{ infoData.userName }}</span> <span v-else>{{ infoData.userName }}</span>
</li> </li>
<li> <li>
<label>学生学号</label> <label>学生学号</label>
<el-input v-if="editing" v-model="infoData.workNumber" disabled></el-input> <el-input v-if="editing"
v-model="infoData.workNumber"
disabled></el-input>
<span v-else>{{ infoData.workNumber }}</span> <span v-else>{{ infoData.workNumber }}</span>
</li> </li>
<li> <li>
<label>实验时间</label> <label>实验时间</label>
<el-input v-if="editing" v-model="infoData.submitTime" disabled></el-input> <el-input v-if="editing"
v-model="infoData.submitTime"
disabled></el-input>
<span v-else>{{ infoData.submitTime }}</span> <span v-else>{{ infoData.submitTime }}</span>
</li> </li>
<li> <li>
<label>实验成绩</label> <label>实验成绩</label>
<el-input v-if="editing" v-model="infoData.score" disabled></el-input> <el-input v-if="editing"
<div v-else class="score-wrap"> v-model="infoData.score"
disabled></el-input>
<div v-else
class="score-wrap">
<em>{{ infoData.score }}</em> <em>{{ infoData.score }}</em>
<img src="@/assets/images/point.png" alt=""> <img src="@/assets/images/point.png"
alt="">
</div> </div>
</li> </li>
<li> <li>
<label>学生班级</label> <label>学生班级</label>
<el-input v-if="editing" v-model="infoData.className"></el-input> <el-input v-if="editing"
v-model="infoData.className"></el-input>
<span v-else>{{ infoData.className }}</span> <span v-else>{{ infoData.className }}</span>
</li> </li>
<li> <li>
<label>指导老师</label> <label>指导老师</label>
<el-input v-if="editing" v-model="infoData.instructor"></el-input> <el-input v-if="editing"
v-model="infoData.instructor"></el-input>
<span v-else>{{ infoData.instructor }}</span> <span v-else>{{ infoData.instructor }}</span>
</li> </li>
<li> <li>
<label>实验学时</label> <label>实验学时</label>
<el-input v-if="editing" v-model="infoData.period"></el-input> <el-input v-if="editing"
v-model="infoData.period"></el-input>
<span v-else>{{ infoData.period }}</span> <span v-else>{{ infoData.period }}</span>
</li> </li>
</ul> </ul>
<div class="m-b-20"> <div class="m-b-20">
<h6 class="l-title"> <h6 class="l-title">
<img src="@/assets/images/report2.png" alt=""> <img src="@/assets/images/report2.png"
alt="">
实验项目名称 实验项目名称
</h6> </h6>
<el-input v-if="editing" v-model="infoData.projectName" type="textarea"></el-input> <el-input v-if="editing"
<div v-else class="pre-wrap" v-html="infoData.projectName"></div> v-model="infoData.projectName"
type="textarea"></el-input>
<div v-else
class="pre-wrap"
v-html="infoData.projectName"></div>
</div> </div>
<div class="m-b-20"> <div class="m-b-20">
<h6 class="l-title"> <h6 class="l-title">
<img src="@/assets/images/report3.png" alt=""> <img src="@/assets/images/report3.png"
alt="">
实验目的 实验目的
</h6> </h6>
<quill v-if="editing" :border="true" v-model="infoData.purpose" :height="150" /> <quill v-if="editing"
<div v-else :class="['pre-wrap', { edit: editing }]" v-html="infoData.purpose"></div> :border="true"
v-model="infoData.purpose"
:height="150" />
<div v-else
:class="['pre-wrap', {edit: editing}]"
v-html="infoData.purpose"></div>
</div> </div>
<div class="m-b-20"> <div class="m-b-20">
<h6 class="l-title"> <h6 class="l-title">
<img src="@/assets/images/report4.png" alt=""> <img src="@/assets/images/report4.png"
alt="">
实验数据 实验数据
</h6> </h6>
<el-table :data="expData" class="table" border stripe header-align="center"> <el-table :data="expData"
<el-table-column type="index" label="序号" align="center" width="60"> class="table"
border
stripe
header-align="center">
<el-table-column type="index"
label="序号"
align="center"
width="60">
<template slot-scope="scope"> <template slot-scope="scope">
{{ scope.$index + 1 }} {{ scope.$index + 1 }}
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="judgmentName" label="判分点" width="200" align="center"></el-table-column> <el-table-column prop="judgmentName"
<el-table-column v-if='project' prop="judgmentName" label="考核点" align="center" width="150"> label="判分点"
width="200"
align="center"></el-table-column>
<el-table-column v-if='project'
prop="judgmentName"
label="考核点"
align="center"
width="150">
<template slot-scope="scope"> <template slot-scope="scope">
<div v-for="(item, index) in scope.row.lcRuleRecords" :key="index"> <div v-for="(item, index) in scope.row.lcRuleRecords"
:key="index">
<span> <span>
<span>{{index+1}}. </span>{{item.name}} <span>{{index+1}}. </span>{{item.name}}
</span> </span>
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="ruleAnswer" label="参考答案" style='word-wrap: break-word'> <el-table-column prop="ruleAnswer"
label="参考答案"
style='word-wrap: break-word'>
<template slot-scope="scope"> <template slot-scope="scope">
<div v-if='scope.row.lcRuleRecords'> <div v-if='scope.row.lcRuleRecords'>
<div v-for="(item, index) in scope.row.lcRuleRecords" :key="index"> <div v-for="(item, index) in scope.row.lcRuleRecords"
:key="index">
<span> <span>
<span>{{index+1}}. </span>{{item.ruleAnswer}} <span>{{index+1}}. </span>{{item.ruleAnswer}}
</span> </span>
</div> </div>
</div> </div>
<div v-else v-html="scope.row.referenceAnswer"></div> <div v-else
v-html="scope.row.referenceAnswer"></div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="userAnswer" label="学生答案"> <el-table-column prop="userAnswer"
label="学生答案">
<template slot-scope="scope"> <template slot-scope="scope">
<div v-if='scope.row.lcRuleRecords'> <div v-if='scope.row.lcRuleRecords'>
<div v-for="(item, index) in scope.row.lcRuleRecords" :key="index"> <div v-for="(item, index) in scope.row.lcRuleRecords"
:key="index">
<span v-if='item.userAnswer'> <span v-if='item.userAnswer'>
<span>{{index+1}}. </span>{{item.userAnswer}} <span>{{index+1}}. </span>{{item.userAnswer}}
</span> </span>
@ -116,30 +169,51 @@
</span> </span>
</div> </div>
</div> </div>
<div v-else class="pre-code">{{ scope.row.answer }}</div> <div v-else
v-html='scope.row.answer'
style='white-space: pre-wrap'></div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="runResult" label="学生运行结果" align="center"> <el-table-column prop="runResult"
label="学生运行结果"
align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<div class="m-b-20 pre-code">{{ scope.row.runResult }}</div> <div class="m-b-20"
v-html='scope.row.runResult'
style='white-space: pre-wrap'></div>
<template v-if="scope.row.runThePictureList"> <template v-if="scope.row.runThePictureList">
<img v-for="(img, i) in scope.row.runThePictureList" :key="i" width="200" class="result-pic" <img v-for="(img, i) in scope.row.runThePictureList"
:src="img" alt=""> :key="i"
width="200"
class="result-pic"
:src="img"
alt="">
</template> </template>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="quesScore" label="分值" width="80" align="center"></el-table-column> <el-table-column prop="quesScore"
<el-table-column prop="score" label="得分" width="80" align="center"></el-table-column> label="分值"
width="80"
align="center"></el-table-column>
<el-table-column prop="score"
label="得分"
width="80"
align="center"></el-table-column>
</el-table> </el-table>
</div> </div>
<div class="m-b-20"> <div class="m-b-20">
<h6 class="l-title"> <h6 class="l-title">
<img src="@/assets/images/report5.png" alt=""> <img src="@/assets/images/report5.png"
alt="">
实验总结与体会 实验总结与体会
</h6> </h6>
<Editor v-if="editing" api-key='rnk6zw9v267xqz7pf98twt1vmrvltmd436je7a642pckltda' v-model="infoData.summarize" <Editor v-if="editing"
api-key='rnk6zw9v267xqz7pf98twt1vmrvltmd436je7a642pckltda'
v-model="infoData.summarize"
:init="editorConfig" /> :init="editorConfig" />
<div v-show="!editing" class="pre-wrap" v-html="infoData.summarize"></div> <div v-show="!editing"
class="pre-wrap"
v-html="infoData.summarize"></div>
</div> </div>
</div> </div>
</div> </div>
@ -198,18 +272,17 @@ export default {
purpose: form.purpose, purpose: form.purpose,
summarize: form.summarize summarize: form.summarize
} }
let { data } = report const data = report.data
this.userScores = userScores
// data使 // data使
if (!data) { if (!data) {
this.userScores = userScores
this.handleList(userScores) this.handleList(userScores)
this.$post(this.api.editExperimentalData, { this.$post(this.api.editExperimentalData, {
reportId, reportId,
data: JSON.stringify(userScores) data: JSON.stringify(userScores)
}).then(res => { }).catch(err => { }) }).then(res => { }).catch(err => { })
} else { } else {
data = JSON.parse(data) this.handleList(userScores.find(e => e.lcRuleRecords) ? userScores : JSON.parse(data))
this.handleList(data)
} }
}).catch(res => { }) }).catch(res => { })
}, },
@ -286,19 +359,12 @@ export default {
<style lang="scss" scoped> <style lang="scss" scoped>
@import '/styles/css/editor.css'; @import '/styles/css/editor.css';
.m-b-20 { .m-b-20 {
margin-bottom: 20px; margin-bottom: 20px;
} }
.wrap { .wrap {
padding: 12px 300px 20px; padding: 12px 300px 20px;
} }
.pre-code {
white-space: pre-wrap;
}
code, code,
kbd, kbd,
samp { samp {
@ -307,18 +373,12 @@ samp {
word-wrap: break-word; word-wrap: break-word;
white-space: pre-wrap; white-space: pre-wrap;
} }
/deep/ pre { /deep/ pre {
white-space: pre-wrap; white-space: pre-wrap; /* css-3 */
/* css-3 */ white-space: -moz-pre-wrap; /* Mozilla, since 1999 */
white-space: -moz-pre-wrap; white-space: pre-wrap; /* Opera 4-6 */
/* Mozilla, since 1999 */ white-space: -o-pre-wrap; /* Opera 7 */
white-space: pre-wrap; word-wrap: break-word; /* Internet Explorer 5.5+ */
/* Opera 4-6 */
white-space: -o-pre-wrap;
/* Opera 7 */
word-wrap: break-word;
/* Internet Explorer 5.5+ */
word-break: break-all; word-break: break-all;
overflow: hidden; overflow: hidden;
font-size: 12px; font-size: 12px;
@ -326,27 +386,22 @@ samp {
font-family: 'PingFang SC', 'Helvetica Neue', Helvetica, 'microsoft yahei', font-family: 'PingFang SC', 'Helvetica Neue', Helvetica, 'microsoft yahei',
arial, STHeiTi, sans-serif; arial, STHeiTi, sans-serif;
} }
.content { .content {
padding: 16px 0; padding: 16px 0;
background: #fff; background: #fff;
&.loading { &.loading {
padding-top: 30px; padding-top: 30px;
} }
.r-title { .r-title {
margin-bottom: 40px; margin-bottom: 40px;
font-size: 24px; font-size: 24px;
text-align: center; text-align: center;
color: #333; color: #333;
} }
.info { .info {
padding: 20px 16px; padding: 20px 16px;
border: 1px solid #e1e6f2; border: 1px solid #e1e6f2;
} }
.l-title { .l-title {
display: flex; display: flex;
align-items: center; align-items: center;
@ -355,52 +410,43 @@ samp {
font-size: 14px; font-size: 14px;
color: #333; color: #333;
background-color: #f7f9fc; background-color: #f7f9fc;
img { img {
margin-right: 5px; margin-right: 5px;
} }
} }
.info-list { .info-list {
display: flex; display: flex;
flex-wrap: wrap; flex-wrap: wrap;
padding: 10px 0 0 20px; padding: 10px 0 0 20px;
li { li {
display: inline-flex; display: inline-flex;
width: 25%; width: 25%;
padding: 0 10px; padding: 0 10px;
margin-bottom: 34px; margin-bottom: 34px;
} }
&.edit { &.edit {
li { li {
align-items: center; align-items: center;
} }
} }
label { label {
font-size: 14px; font-size: 14px;
color: #333; color: #333;
white-space: nowrap; white-space: nowrap;
} }
span { span {
min-width: 150px; min-width: 150px;
padding: 0 10px 3px; padding: 0 10px 3px;
border-bottom: 1px solid #e1e6f2; border-bottom: 1px solid #e1e6f2;
} }
/deep/.el-input { /deep/.el-input {
width: 174px; width: 174px;
} }
} }
.score-wrap { .score-wrap {
position: relative; position: relative;
min-width: 150px; min-width: 150px;
border-bottom: 1px solid #e1e6f2; border-bottom: 1px solid #e1e6f2;
em { em {
position: absolute; position: absolute;
top: -12px; top: -12px;
@ -410,21 +456,18 @@ samp {
font-weight: 600; font-weight: 600;
color: #0b1d30; color: #0b1d30;
} }
img { img {
position: absolute; position: absolute;
bottom: -15px; bottom: -15px;
left: 0; left: 0;
} }
} }
/deep/.el-textarea .el-textarea__inner, /deep/.el-textarea .el-textarea__inner,
.pre-wrap { .pre-wrap {
min-height: 72px; min-height: 72px;
padding: 10px 16px; padding: 10px 16px;
font-size: 14px; font-size: 14px;
color: #333; color: #333;
&.edit { &.edit {
color: #abb3c6; color: #abb3c6;
border: 1px solid #cacfdb; border: 1px solid #cacfdb;
@ -432,27 +475,22 @@ samp {
background-color: #f6f7f9; background-color: #f6f7f9;
} }
} }
/deep/ .table th { /deep/ .table th {
background-color: #e1eaff !important; background-color: #e1eaff !important;
.cell { .cell {
line-height: 35px; line-height: 35px;
color: #555555; color: #555555;
} }
} }
} }
.result-pic { .result-pic {
margin: 10px 0; margin: 10px 0;
} }
@media (max-width: 1650px) { @media (max-width: 1650px) {
.wrap { .wrap {
padding: 12px 200px 20px; padding: 12px 200px 20px;
} }
} }
@media (max-width: 1430px) { @media (max-width: 1430px) {
.wrap { .wrap {
padding: 12px 100px 20px; padding: 12px 100px 20px;

Loading…
Cancel
Save