Branch_d40a2540 V2.3.2
yujialong 1 year ago
parent 5420b23e61
commit d40a254096
  1. 2
      src/layouts/header/index.vue
  2. 12
      src/pages/achievement/info/course.vue
  3. 6
      src/pages/achievement/info/project.vue
  4. 3
      src/pages/match/add/index.vue
  5. 1
      src/pages/match/add/set.vue
  6. 66
      src/pages/match/manage/matchArch.vue
  7. 2
      src/pages/product/list/index.vue
  8. 6
      src/pages/product/show/index.vue
  9. 61
      src/pages/screen/index.vue
  10. 11
      src/pages/station/preview/index.vue
  11. 2
      src/setting.js

@ -153,7 +153,7 @@ export default {
}, },
initSocket ({ id, account }) { initSocket ({ id, account }) {
// socket // socket
this.socket = new WebSocket(`${Setting.isTest ? 'ws' : 'wss'}://${Setting.isDev ? '192.168.31.51' : location.host}/nakadai/websocket/${id}/${account}`) this.socket = new WebSocket(`${Setting.isTest ? 'ws' : 'wss'}://${Setting.isDev ? '192.168.31.51:9100' : location.host}/nakadai/websocket/${id}/${account}`)
// this.socket = new WebSocket(`ws://121.37.12.51:9100/nakadai/websocket/${id}/${account}`) // this.socket = new WebSocket(`ws://121.37.12.51:9100/nakadai/websocket/${id}/${account}`)
// socket // socket
this.socket.onopen = this.open; this.socket.onopen = this.open;

@ -30,11 +30,11 @@
</div> </div>
<div class="item item3"> <div class="item item3">
<p class="name">实验最高分</p> <p class="name">实验最高分</p>
<p class="val">{{ maxScore }}</p> <p class="val">{{ maxScore || 0 }}</p>
</div> </div>
<div class="item item4"> <div class="item item4">
<p class="name">实验最低分</p> <p class="name">实验最低分</p>
<p class="val">{{ minScore }}</p> <p class="val">{{ minScore || 0 }}</p>
</div> </div>
</div> </div>
<div class="chart" <div class="chart"
@ -48,11 +48,11 @@
<div class="wrong"> <div class="wrong">
<div class="line"> <div class="line">
<span class="jud-name">错误率最高{{ max.projectName }}</span> <span class="jud-name">错误率最高{{ max.projectName }}</span>
<span>参加考试{{ max.numberOfParticipants }}&emsp;&emsp;{{ curTab == 1 ? `${max.itemErrorCount || ''}人做错,` : '' }}错误率{{ max.errorRate }}%</span> <span>参加考试{{ max.numberOfParticipants || 0 }}&emsp;&emsp;{{ curTab == 1 ? `${max.itemErrorCount || 0}人做错,` : '' }}错误率{{ max.errorRate || 0 }}%</span>
</div> </div>
<div class="line"> <div class="line">
<span class="jud-name">错误率最低{{ min.projectName }}</span> <span class="jud-name">错误率最低{{ min.projectName }}</span>
<span>参加考试{{ min.numberOfParticipants }}&emsp;&emsp;{{ curTab == 1 ? `${min.itemErrorCount || ''}人做错,` : '' }}错误率{{ min.errorRate }}%</span> <span>参加考试{{ min.numberOfParticipants || 0 }}&emsp;&emsp;{{ curTab == 1 ? `${min.itemErrorCount || 0}人做错,` : '' }}错误率{{ min.errorRate || 0 }}%</span>
</div> </div>
</div> </div>
<div class="chart" <div class="chart"
@ -346,11 +346,11 @@ export default {
this.peopleNum = stat.experimentalPopulation this.peopleNum = stat.experimentalPopulation
this.maxScore = stat.maxScore this.maxScore = stat.maxScore
this.minScore = stat.minScore this.minScore = stat.minScore
const err = per ? res.testErrorRateUnderProduct : res.projectErrorRateAnalysisUnderProduct const err = (per ? res.testErrorRateUnderProduct : res.projectErrorRateAnalysisUnderProduct) || []
err.forEach(e => { err.forEach(e => {
e.errorRate = (+e.errorRate).toFixed(2) e.errorRate = (+e.errorRate).toFixed(2)
}) })
this.errorAnalysis = err this.errorAnalysis = err || []
this.max = err[0] || {} this.max = err[0] || {}
this.min = err[err.length - 1] || {} this.min = err[err.length - 1] || {}
this.errorChart() this.errorChart()

@ -60,11 +60,11 @@
<div class="wrong"> <div class="wrong">
<div class="line"> <div class="line">
<span class="jud-name">错误率最高{{ max.judgmentName }}</span> <span class="jud-name">错误率最高{{ max.judgmentName }}</span>
<span>参加考试{{ permissions ? max.peopleNum : peopleNum }}&emsp;&emsp;{{ permissions ? `${max.errorTotal}人做错,` : '' }}错误率{{ max.errorRate }}%</span> <span>参加考试{{ permissions ? max.peopleNum : peopleNum }}&emsp;&emsp;{{ permissions ? `${max.errorTotal || 0}人做错,` : '' }}错误率{{ max.errorRate }}%</span>
</div> </div>
<div class="line"> <div class="line">
<span class="jud-name">错误率最低{{ min.judgmentName }}</span> <span class="jud-name">错误率最低{{ min.judgmentName }}</span>
<span>参加考试{{ permissions ? min.peopleNum : peopleNum }}&emsp;&emsp;{{ permissions ? `${min.errorTotal}人做错,` : '' }}错误率{{ min.errorRate }}%</span> <span>参加考试{{ permissions ? min.peopleNum : peopleNum }}&emsp;&emsp;{{ permissions ? `${min.errorTotal || 0}人做错,` : '' }}错误率{{ min.errorRate }}%</span>
</div> </div>
</div> </div>
<div class="chart" <div class="chart"
@ -365,7 +365,7 @@ export default {
this.peopleNum = res.peopleNum this.peopleNum = res.peopleNum
this.maxScore = res.maxScore this.maxScore = res.maxScore
this.minScore = res.minScore this.minScore = res.minScore
this.errorAnalysis = res.errorAnalysis this.errorAnalysis = res.errorAnalysis || {}
this.max = res.highestErrorRate || {} this.max = res.highestErrorRate || {}
this.min = res.minimumErrorRate || {} this.min = res.minimumErrorRate || {}
this.handlePage() this.handlePage()

@ -157,7 +157,7 @@ export default {
// , // ,
beforeRouteLeave (to, from, next) { beforeRouteLeave (to, from, next) {
const { updateTime } = this.$refs['step' + this.step] const { updateTime } = this.$refs['step' + this.step]
if (this.$refs['step' + this.step] && updateTime) { if (this.step < 4 && this.$refs['step' + this.step] && updateTime) {
this.$confirm(`您所更改的内容未更新,是否更新?`, '提示', { this.$confirm(`您所更改的内容未更新,是否更新?`, '提示', {
type: 'warning' type: 'warning'
}).then(() => { }).then(() => {
@ -275,6 +275,7 @@ export default {
back () { back () {
// //
const { updateTime } = this.$refs['step' + this.step] const { updateTime } = this.$refs['step' + this.step]
console.log("🚀 ~ file: index.vue:278 ~ back ~ updateTime:", updateTime)
if (this.step < 4 && this.$refs['step' + this.step] && updateTime) { if (this.step < 4 && this.$refs['step' + this.step] && updateTime) {
this.$confirm(`编辑的内容未保存,是否保存?`, '提示', { this.$confirm(`编辑的内容未保存,是否保存?`, '提示', {
type: 'warning' type: 'warning'

@ -228,6 +228,7 @@ export default {
toProject () { toProject () {
const { form, curStep } = this.$parent const { form, curStep } = this.$parent
form[curStep] = this.form form[curStep] = this.form
this.$parent.pass = 1
this.$store.commit('match/setCache', { this.$store.commit('match/setCache', {
form, form,
curStep curStep

@ -2,26 +2,52 @@
<!-- 报名人员 --> <!-- 报名人员 -->
<div class="page-content" <div class="page-content"
style="padding: 24px"> style="padding: 24px">
<el-collapse v-if="list.length" <el-table ref="table"
v-model="curStep"> :data="list"
<el-collapse-item v-for="(item, i) in list" class="table"
:key="i" stripe
:title="item.stageName" header-align="center"
:name="item.stageId"> row-key="stageId">
<div class="line"> <el-table-column type="index"
<span>比赛方式{{ item.methodName }}</span> width="60"
<span>比赛形式{{ item.competitionType ? '团队赛' : '个人赛' }}</span> label="序号"
<span>赛制{{ item.ruleName }}</span> align="center">
<span>状态{{ item.status }}</span> <template slot-scope="scope">
<span>竞赛起止时间{{ item.startTime + ' ~ ' + item.endTime }}</span> {{ scope.$index + 1 }}
<div> </template>
<el-button type="primary" </el-table-column>
@click="toRank(item, i)">排名</el-button> <el-table-column prop="methodName"
<el-button @click="toArch(item)">成绩管理</el-button> label="比赛方式"
</div> align="center"></el-table-column>
</div> <el-table-column prop="founderName"
</el-collapse-item> label="比赛形式"
</el-collapse> align="center">
<template slot-scope="scope">
{{ scope.row.competitionType ? '团队赛' : '个人赛' }}
</template>
</el-table-column>
<el-table-column prop="ruleName"
label="赛制"
align="center"></el-table-column>
<el-table-column prop="status"
label="状态"
align="center"></el-table-column>
<el-table-column label="竞赛起止时间"
align="center">
<template slot-scope="scope">
{{ scope.row.startTime + ' ~ ' + scope.row.endTime }}
</template>
</el-table-column>
<el-table-column label="操作"
align="center"
width="260">
<template slot-scope="scope">
<el-button type="primary"
@click="toRank(scope.row, scope.$index)">排名</el-button>
<el-button @click="toArch(scope.row)">成绩管理</el-button>
</template>
</el-table-column>
</el-table>
</div> </div>
</template> </template>

@ -356,7 +356,7 @@ export default {
el.innerHTML = e.productIntroduction el.innerHTML = e.productIntroduction
e.productIntroduction = el.innerText e.productIntroduction = el.innerText
const cid = e.classificationId const cid = e.classificationId
e.isCourse = (cid === 1 || cid === 2) && !e.isAssociatedProduct e.isCourse = (cid === 1 || cid === 2) && !e.isAssociatedProduct //
}) })
this.list = list ? list : [] this.list = list ? list : []
this.total = page.total this.total = page.total

@ -141,7 +141,7 @@
alt=""> alt="">
{{ section.name }} {{ section.name }}
</div> </div>
<i v-if="!form.goodsRes.logoOfOurSchool" <i v-if="!form.goodsRes.logoOfOurSchool && j"
class="icon el-icon-lock"></i> class="icon el-icon-lock"></i>
</div> </div>
</div> </div>
@ -310,7 +310,9 @@ export default {
}, },
// //
toPreview (i, j) { toPreview (i, j) {
this.form.goodsRes.logoOfOurSchool ? const bought = this.form.goodsRes.logoOfOurSchool
// ||
bought || (!bought && !j) ?
this.$router.push(`/station/preview?courseId=${this.form.mall.associatedProduct}&curriculumName=${this.form.mall.productName}&mallId=${this.id}&chapter=${i}&section=${j}&admin=1`) : this.$router.push(`/station/preview?courseId=${this.form.mall.associatedProduct}&curriculumName=${this.form.mall.productName}&mallId=${this.id}&chapter=${i}&section=${j}&admin=1`) :
this.toTrail() this.toTrail()
}, },

@ -718,11 +718,11 @@ export default {
}, },
{ {
color1: '#e71872', color1: '#e71872',
color2: 'rgba(243, 147, 189, 0.4)' color2: 'rgba(40, 147, 189, 0.4)'
}, },
{ {
color1: '#f9d437', color1: '#f9d437',
color2: 'rgba(255, 234, 144, 0.4)' color2: 'rgba(50, 234, 144, 0.4)'
}, },
{ {
color1: '#912892', color1: '#912892',
@ -730,11 +730,11 @@ export default {
}, },
{ {
color1: '#f21259', color1: '#f21259',
color2: 'rgba(213, 22, 11, 0.4)' color2: 'rgba(40, 176, 97, 0.4)'
}, },
{ {
color1: '#7343fe', color1: '#7343fe',
color2: 'rgba(243, 123, 2, 0.4)' color2: 'rgba(50, 240, 140, 0.4)'
}, },
{ {
color1: '#ea7321', color1: '#ea7321',
@ -746,8 +746,24 @@ export default {
}, },
{ {
color1: '#672313', color1: '#672313',
color2: 'rgba(156, 163, 2, 0.4)' color2: 'rgba(156, 40, 100, 0.4)'
} },
{
color1: '#0184d5',
color2: 'rgba(60, 132, 60, 0.4)'
},
{
color1: '#00d887',
color2: 'rgba(60, 42, 244, 0.4)'
},
{
color1: '#e71872',
color2: 'rgba(90, 147, 180, 0.4)'
},
{
color1: '#f9d437',
color2: 'rgba(150, 20, 144, 0.4)'
},
] ]
// //
const cousrseRes = await this.$post(this.api.listOfGoods, { const cousrseRes = await this.$post(this.api.listOfGoods, {
@ -758,22 +774,20 @@ export default {
hotTag: 1, hotTag: 1,
}) })
if (cousrseRes) { if (cousrseRes) {
const courseList = const courseList = cousrseRes.page.records
cousrseRes.page.records
const ids = courseList.map(e => e.mallId) const ids = courseList.map(e => e.mallId)
times.map(e => { times.map(e => {
e.mallId = ids e.mallId = ids
}) })
const courseData = {} const courseData = {}
courseList.map(e => {
// e.productName = e.productName.substring(0, 10)
courseData[e.productName] = []
})
this.$post(this.api.studentAssessSchievement, times).then(({ data }) => { this.$post(this.api.studentAssessSchievement, times).then(({ data }) => {
const times = [] const xData = data.map(e => e.time)
const len = xData.length
courseList.map(e => {
courseData[e.productName] = new Array(len).fill(0, 0)
})
const series = [] const series = []
data.map((e, i) => { data.map((e, i) => {
times.push(e.time)
e.assesScoreRespList.map(n => { e.assesScoreRespList.map(n => {
const item = courseList.find(j => j.mallId == n.mallId) const item = courseList.find(j => j.mallId == n.mallId)
if (item) { if (item) {
@ -790,7 +804,7 @@ export default {
series.push({ series.push({
name: i, name: i,
type: 'line', type: 'line',
smooth: true, // smooth: true,
symbol: 'circle', symbol: 'circle',
symbolSize: 5, symbolSize: 5,
lineStyle: { lineStyle: {
@ -799,23 +813,10 @@ export default {
width: 2 width: 2
} }
}, },
areaStyle: {
normal: {
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [{
offset: 0,
color: colors[index].color2
}, {
offset: 0.8,
color: colors[index].color2
}], false),
shadowColor: 'rgba(0, 0, 0, 0.1)',
}
},
itemStyle: { itemStyle: {
normal: { normal: {
color: colors[index].color1, color: colors[index].color1,
borderColor: 'rgba(221, 220, 107, .1)', borderWidth: 8
borderWidth: 12
} }
}, },
data: courseData[i] data: courseData[i]
@ -871,7 +872,7 @@ export default {
color: 'rgba(255,255,255,.2)' color: 'rgba(255,255,255,.2)'
} }
}, },
data: times data: xData
}, },
yAxis: [{ yAxis: [{
type: 'value', type: 'value',

@ -159,7 +159,7 @@
</template> </template>
<template v-if="active === 2"> <template v-if="active === 2">
<div class="page"> <div class="page">
<template v-if="showNoteAdd"> <template v-if="showNoteAdd || !notes.length">
<el-form class="form" <el-form class="form"
ref="form" ref="form"
label-width="120px" label-width="120px"
@ -179,7 +179,8 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
<div class="text-right"> <div class="text-right">
<el-button @click="showNoteAdd = false">取消</el-button> <el-button v-if="notes.length"
@click="showNoteAdd = false">取消</el-button>
<el-button type="primary" <el-button type="primary"
@click="submitNote">保存</el-button> @click="submitNote">保存</el-button>
</div> </div>
@ -638,13 +639,17 @@ export default {
// //
submitNote () { submitNote () {
const form = this.noteForm const form = this.noteForm
console.log(33, form, this.noteContent)
if (!form.noteName) return util.errorMsg('请输入笔记标题') if (!form.noteName) return util.errorMsg('请输入笔记标题')
if (!form.noteContent) return util.errorMsg('请输入笔记内容') if (!form.noteContent) return util.errorMsg('请输入笔记内容')
this.$post(this.api[form.noteId ? 'updateNote' : 'addNote'], form).then(res => { this.$post(this.api[form.noteId ? 'updateNote' : 'addNote'], form).then(res => {
this.getNote() this.getNote()
util.successMsg(form.noteId ? '修改成功' : '添加成功') util.successMsg(form.noteId ? '修改成功' : '添加成功')
this.showNoteAdd = false this.showNoteAdd = false
this.noteForm = {
cid: this.courseId,
noteContent: '',
noteName: '',
}
}).catch(res => { }) }).catch(res => { })
}, },
// //

@ -27,7 +27,7 @@ if (isPro) {
host = "http://121.37.12.51/"; // 中台测试服 host = "http://121.37.12.51/"; // 中台测试服
// host = 'https://www.occupationlab.com/' // 正式服 // host = 'https://www.occupationlab.com/' // 正式服
// host = "http://192.168.31.217:9000/"; // 榕 // host = "http://192.168.31.217:9000/"; // 榕
// host = 'http://192.168.31.51:9000/'; // 赓 host = 'http://192.168.31.51:9000/'; // 赓
} }
const Setting = { const Setting = {

Loading…
Cancel
Save