dev_2022-05-11
luoJunYong.123 3 years ago
commit fee316fe83
  1. 5
      src/pages/achievement/ass/index.vue
  2. 74
      src/pages/achievement/show/index.vue
  3. 4
      src/pages/achievement/vir/index.vue
  4. 2
      src/pages/assessment/list/index.vue
  5. 18
      src/pages/project/list/index.vue
  6. 20
      src/pages/system/list/staff.vue
  7. 1
      src/styles/common.scss

@ -196,7 +196,10 @@ export default {
type: "warning" type: "warning"
}) })
.then(() => { .then(() => {
this.$post(`${this.api.deleteReport}?reportId=${row.reportId}&recordId=${row.recordId}`).then(res => { let ids = this.multipleSelection.map(item => {
return item.reportId;
});
this.$post(`${this.api.deleteExperimentalReport}`,ids).then(res => {
util.successMsg("删除成功"); util.successMsg("删除成功");
this.getData(); this.getData();
}).catch(res => { }).catch(res => {

@ -54,35 +54,46 @@
<p class="meta-title">实验数据</p> <p class="meta-title">实验数据</p>
</div> </div>
<el-table :data="expData" class="table" stripe header-align="center"> <el-table :data="expData" class="table" stripe header-align="center">
<el-table-column type="index" width="100" label="序号" align="center"> <el-table-column type="index" width="50" label="序号" align="center">
<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="任务名称" align="center"> <el-table-column prop="judgmentName" width="150" label="任务名称" align="center">
</el-table-column> </el-table-column>
<el-table-column prop="userAnswer" label="考核点" align="center"> <el-table-column v-if='project' prop="userAnswer" label="考核点" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<div v-for="(item, index) in scope.row.lcRuleRecords"> <div v-for="(item, index) in scope.row.lcRuleRecords">
<span>{{index+1}}. </span>{{item.name}} <span>{{index+1}}. </span>{{item.name}}
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="userAnswer" label="学生答案" align="center"> <el-table-column prop="answer" label="参考答案" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<div v-if=' scope.row.lcRuleRecords'>
<div v-for="(item, index) in scope.row.lcRuleRecords"> <div v-for="(item, index) in scope.row.lcRuleRecords">
<span>{{index+1}}. </span>{{item.ruleAnswer}} <span>{{index+1}}. </span>{{item.ruleAnswer}}
</div> </div>
</div>
<div v-else v-html='scope.row.referenceAnswer'>
<!-- {{scope.row.referenceAnswer}}-->
</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="answer" label="参考答案" align="center"> <el-table-column prop="userAnswer" label="学生答案" align="center">
<template slot-scope="scope"> <template slot-scope="scope">
<div v-if=' scope.row.lcRuleRecords'>
<div v-for="(item, index) in scope.row.lcRuleRecords"> <div v-for="(item, index) in scope.row.lcRuleRecords">
<span>{{index+1}}. </span>{{item.ruleAnswer}} <span>{{index+1}}. </span>{{item.userAnswer}}
</div>
</div>
<div v-else v-html='scope.row.answer' style='white-space: pre-wrap'>
<!-- {{scope.row.answer}}-->
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column prop="score" label="得分" align="center">
<el-table-column prop="score" width="50" label="得分" align="center">
</el-table-column> </el-table-column>
</el-table> </el-table>
</div> </div>
@ -142,6 +153,7 @@ export default {
autograph: "1", autograph: "1",
pages: 1, pages: 1,
ipVisible: false, ipVisible: false,
project:false,
fileList: [{ name: "food.jpeg", url: "https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100" }, { fileList: [{ name: "food.jpeg", url: "https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100" }, {
name: "food2.jpeg", name: "food2.jpeg",
url: "https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100" url: "https://fuss10.elemecdn.com/3/63/4e7f3a15429bfda99bce42a18cdd1jpeg.jpeg?imageMogr2/thumbnail/360x360/format/webp/quality/100"
@ -160,6 +172,7 @@ export default {
]) ])
}, },
mounted() { mounted() {
this.getData(); this.getData();
}, },
methods: { methods: {
@ -173,6 +186,16 @@ export default {
let expData = res.userScores; let expData = res.userScores;
let form = this.form; let form = this.form;
let score = form.score; let score = form.score;
for(var i=0;i<expData.length;i++){
console.log(expData[i].referenceAnswer)
if (expData[i].referenceAnswer != undefined && expData[i].referenceAnswer){
console.log('123')
this.project = false
}else{
console.log('456')
this.project = true
}
}
if (expData) { if (expData) {
if (score) { if (score) {
expData.map(n => { expData.map(n => {
@ -183,7 +206,6 @@ export default {
}); });
form.score = score; form.score = score;
} }
this.expData = expData; this.expData = expData;
} }
this.infoData.push({ this.infoData.push({
@ -212,7 +234,16 @@ export default {
let expData = res.userScores; let expData = res.userScores;
let form = this.form; let form = this.form;
let score = form.score; let score = form.score;
for(var i=0;i<expData.length;i++){
console.log(expData[i].referenceAnswer)
if (expData[i].referenceAnswer != undefined && expData[i].referenceAnswer){
console.log('123')
this.project = false
}else{
console.log('456')
this.project = true
}
}
if (expData) { if (expData) {
if (score) { if (score) {
expData.map(n => { expData.map(n => {
@ -345,12 +376,11 @@ export default {
/deep/ .info-table { /deep/ .info-table {
margin-bottom: 40px; margin-bottom: 40px;
border: 0; border: 0;
th { th {
background-color: #fff !important; background-color: #fff !important;
.cell { .cell {
color: #444; color: #444;
line-height: 35px;
} }
} }
@ -385,11 +415,19 @@ export default {
background-color: #e1eaff !important; background-color: #e1eaff !important;
.cell { .cell {
line-height: 35px;
color: #555555; color: #555555;
} }
} }
} }
/deep/ pre, code, kbd, samp{
font-family: 'PingFang SC', "Helvetica Neue", Helvetica, "microsoft yahei", arial, STHeiTi, sans-serif;
word-wrap: break-word;
white-space: pre-wrap;
}
/deep/ pre{
white-space: pre-wrap;
}
/deep/ .cell { /deep/ .cell {
font-size: 12px; font-size: 12px;
} }
@ -455,4 +493,16 @@ export default {
padding-top: 20px; padding-top: 20px;
border-top: 1px dashed #ccc; border-top: 1px dashed #ccc;
} }
pre {
white-space: pre-wrap; /* css-3 */
white-space: -moz-pre-wrap; /* Mozilla, since 1999 */
white-space: pre-wrap; /* Opera 4-6 */
white-space: -o-pre-wrap; /* Opera 7 */
word-wrap: break-word; /* Internet Explorer 5.5+ */
word-break:break-all;
overflow:hidden;
font-size: 12px;
font-weight:400;
font-family:'PingFang SC', "Helvetica Neue", Helvetica, "microsoft yahei", arial, STHeiTi, sans-serif
}
</style> </style>

@ -152,7 +152,7 @@ export default {
this.$confirm("确定要删除吗?", "提示", { this.$confirm("确定要删除吗?", "提示", {
type: "warning" type: "warning"
}).then(() => { }).then(() => {
this.$post(this.api.deleteExperimentalReport, [row.projectId]).then(res => { this.$post(this.api.deleteExperimentalReport, [row.reportId]).then(res => {
util.successMsg("删除成功"); util.successMsg("删除成功");
this.getData(); this.getData();
}).catch(res => { }).catch(res => {
@ -166,7 +166,7 @@ export default {
type: "warning" type: "warning"
}).then(() => { }).then(() => {
let ids = this.multipleSelection.map(item => { let ids = this.multipleSelection.map(item => {
return item.projectId; return item.reportId;
}); });
this.$post(this.api.deleteExperimentalReport, ids).then(res => { this.$post(this.api.deleteExperimentalReport, ids).then(res => {
this.multipleSelection = []; this.multipleSelection = [];

@ -90,7 +90,7 @@
</template> </template>
</el-table-column> </el-table-column>
<el-table-column label="实验状态" align="center"> <el-table-column label="实验状态" align="center">
<template slot-scope="scope" v-if="scope.row.show"> <template slot-scope="scope">
<span> <span>
{{ status[scope.row.status] }} {{ status[scope.row.status] }}
</span> </span>

@ -90,15 +90,15 @@
<el-button v-if="scope.row.founder != 0" type="text" @click="edit(scope.row,'1',queryData.founder)">编辑</el-button> <el-button v-if="scope.row.founder != 0" type="text" @click="edit(scope.row,'1',queryData.founder)">编辑</el-button>
<el-button v-if="scope.row.founder != 0" type="text" @click="handleDelete(scope.row.projectId)">删除</el-button> <el-button v-if="scope.row.founder != 0" type="text" @click="handleDelete(scope.row.projectId)">删除</el-button>
<el-button v-if="auth('复制')" type="text" @click="copyData(scope.row.projectId)">复制</el-button> <el-button v-if="auth('复制')" type="text" @click="copyData(scope.row.projectId)">复制</el-button>
<!-- <el-switch--> <el-switch
<!-- v-if="auth('禁用')"--> v-if="auth('禁用')"
<!-- v-model="scope.row.isOpen"--> v-model="scope.row.isOpen"
<!-- :active-text="scope.row.isOpen ? '关闭' : '启用'"--> :active-text="scope.row.isOpen ? '关闭' : '启用'"
<!-- :active-value="0"--> :active-value="0"
<!-- :inactive-value="1"--> :inactive-value="1"
<!-- style="margin: 0 10px 0 10px"--> style="margin: 0 10px 0 10px"
<!-- @change="switchOff(scope.row)"--> @change="switchOff(scope.row)"
<!-- ></el-switch>--> ></el-switch>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>

@ -68,15 +68,18 @@
<el-form-item prop="workNumber" label="工号"> <el-form-item prop="workNumber" label="工号">
<el-input v-model.trim="teacherForm.workNumber" placeholder="请输入职工工号"></el-input> <el-input v-model.trim="teacherForm.workNumber" placeholder="请输入职工工号"></el-input>
</el-form-item> </el-form-item>
<template v-for="item in teacherForm.roleAndDeptList"> <el-form-item v-for="item in teacherForm.roleAndDeptList" :label="`${item.roleName}所属部门`" :rules="{
<el-form-item :label="`${item.roleName}所属部门`"> required: true, message: '请选择', trigger: 'change'
}">
<el-cascader <el-cascader
v-model="item.cascaderValue" v-model="item.cascaderValue"
:options="majorList" :options="majorList"
style="width: 100%" style="width: 100%"
></el-cascader> ></el-cascader>
</el-form-item> </el-form-item>
</template> <!-- <template v-for="item in teacherForm.roleAndDeptList">-->
<!-- -->
<!-- </template>-->
<el-form-item prop="phone" label="手机号"> <el-form-item prop="phone" label="手机号">
<el-input v-model.trim="teacherForm.phone" placeholder="请输入手机号" maxlength="11" @blur="phoneChange"></el-input> <el-input v-model.trim="teacherForm.phone" placeholder="请输入手机号" maxlength="11" @blur="phoneChange"></el-input>
@ -471,10 +474,15 @@ export default {
} }
}, },
roleRemove(value) { // roleRemove(value) { //
let index = this.teacherForm.roleAndDeptList.findIndex(i => i.roleName === value); let list = [];
if (index !== -1) { for(var i=0;i<this.teacherForm.roleAndDeptList.length;i++){
this.teacherForm.roleAndDeptList.splice(index, 1); if (this.teacherForm.roleAndDeptList[i].roleId == value){
}else{
list.push(this.teacherForm.roleAndDeptList[i])
}
} }
this.teacherForm.roleAndDeptList = list
}, },
async saveSure(teacherForm) { async saveSure(teacherForm) {
this.$refs[teacherForm].validate((valid) => { this.$refs[teacherForm].validate((valid) => {

@ -138,6 +138,7 @@
.cell { .cell {
font-size: 14px; font-size: 14px;
line-height: 35px;
} }
th { th {

Loading…
Cancel
Save