yujialong 8 months ago
parent 46186012d5
commit f98551590c
  1. 2
      src/components/TestPanel.vue
  2. 12
      src/components/codemirror.vue
  3. 2
      src/views/Home.vue
  4. 1
      src/views/Report.vue

@ -1240,7 +1240,7 @@ export default {
responseCallback: function (frame) {
const data = JSON.parse(frame.body)
console.log("接收信息:", data, typeof data);
console.log("接收信息:", data, typeof data, newmain, newmain.$emit);
if (typeof data === 'object') {
newmain.$emit('setPid', '')
if (this.runCodeType) {

@ -325,7 +325,7 @@ import config from '@/config'
import { saveAs } from 'file-saver'
const CANCEL_TOKEN = axios.CancelToken // input
export default {
props: ['judgmentId', 'code', 'finalCode', 'codeId', 'projectId', 'systemId', 'retResult', 'modelIsShow', 'photoUrl', 'answer'],
props: ['judgmentId', 'code', 'finalCode', 'codeId', 'projectId', 'systemId', 'retResult', 'modelIsShow', 'photoUrl', 'answer', 'curTab', 'index'],
data () {
return {
token: Cookie.get('admin-token'),
@ -653,7 +653,8 @@ export default {
bcId: this.judgmentId,
cid: this.courseId,
projectId: this.projectId,
type: 0
type: 0,
sort: this.index
}, {
headers: {
token: this.token
@ -698,6 +699,7 @@ export default {
this.$emit('update:retResult', data.retResult) //
},
runCodeCb2 (data) {
if (data.sort != this.index) return false
//
if (data) {
const photo = data.photoUrl
@ -778,7 +780,8 @@ export default {
bcId,
cid,
projectId,
type: 0
type: 0,
sort: this.index
}).then(res => {
this.$emit('update:finalCode', code)
}).catch(err => {
@ -802,7 +805,8 @@ export default {
bcId,
cid,
projectId,
type: 0
type: 0,
sort: this.index
}).then(res => {
this.$emit('update:finalCode', code)
}).catch(res => {

@ -66,6 +66,8 @@
:answer.sync="item.answer"
:retResult.sync="item.retResult"
:photoUrl.sync="item.photoUrl"
:index="i"
:curTab.sync="curTab"
:modelIsShow.sync="modelIsShow"
@cache="leavePage"></codemirror>
<iframe v-else

@ -306,6 +306,7 @@ export default {
if (item) {
if (item.runThePictureList) e.runThePictureList = item.runThePictureList
if (item.runResult) e.runResult = item.runResult
if (item.answer) e.answer = item.answer
}
})
}

Loading…
Cancel
Save