Commit f57dae51 authored by 罗超's avatar 罗超
parents 7f0196be 34122328
This diff is collapsed.
...@@ -172,7 +172,6 @@ ...@@ -172,7 +172,6 @@
getQuestionList() { getQuestionList() {
this.loading = true; this.loading = true;
queryQuestionPageList(this.msg).then(res => { queryQuestionPageList(this.msg).then(res => {
console.log(res,'res');
this.loading = false; this.loading = false;
this.dataList = res.Data.PageData; this.dataList = res.Data.PageData;
this.pageCount = res.Data.PageCount; this.pageCount = res.Data.PageCount;
......
<template>
<q-dialog v-model="persistent" content-class="bg-grey-1" persistent transition-show="scale" transition-hide="scale">
<q-card style="width: 850px;max-width:900px;">
<q-card-section>
<div class="text-h6">题库信息</div>
</q-card-section>
<q-card-section class="q-pt-none scroll" style="max-height: 70vh">
<div class="page-search row items-center">
<div class="col row wrap q-mr-lg q-col-gutter-md">
<div class="col-12">
<q-input @input="research" clearable standout="bg-primary text-white" v-model="msg.BankName" label="关键字"
@clear="research" maxlength="20" />
</div>
</div>
</div>
<div class="page-content">
<q-table :pagination="msg" :loading="loading" no-data-label="暂无相关数据" flat
class="sticky-column-table sticky-right-column-table" separator="none" :data="dataList" :columns="columns"
row-key="BankId" selection="multiple" :selected.sync="selectedQuestionBank">
<template v-slot:top="props">
<div class="col-2 q-table__title">题库列表</div>
<q-space />
</template>
<template v-slot:body-cell-Title="props">
<td style="width:400px;">
<div @click="goDetail(props.row)" v-html="props.row.Title" class="quetion_Title">
</div>
</td>
</template>
<template v-slot:bottom>
<q-pagination class="full-width justify-end" v-model="msg.pageIndex" color="primary" :max="pageCount"
:input="true" @input="changePage" />
</template>
</q-table>
</div>
</q-card-section>
<q-separator />
<q-card-actions align="right" class="bg-white">
<q-btn label="取消" flat color="grey-10" style="font-weight:400 !important" @click="closeSaveForm" />
<q-btn label="确认选择" color="accent q-px-md" style="font-weight:400 !important" @click="sureQuestionBank" />
</q-card-actions>
</q-card>
</q-dialog>
</template>
<script>
import {
queryQuestionBankPage,
} from '../../api/question/question';
export default {
data() {
return {
persistent: true,
msg: {
pageIndex: 1,
pageSize: 12,
rowsPerPage: 12,
BankName: ''
},
pageCount: 0, //总页数
loading: false, //表格加载进度条
columns: [{
name: 'RowNum',
label: '编号',
field: 'RowNum',
align: 'left'
},
{
name: 'BankNo',
label: '题库序号',
field: 'BankNo',
align: 'left',
},
{
name: 'BankName',
label: '题库名称',
field: 'BankName',
align: 'left',
},
{
name: 'CreateByName',
label: '创建人',
field: 'CreateByName',
align: 'left'
},
{
name: 'QuestionCount',
label: '题量',
field: 'QuestionCount',
align: 'left'
},
],
dataList: [], //数据列表
selectedQuestionBank: [], //选择的题库
}
},
mounted() {
this.getQuestionBankPage();
},
methods: {
//获取题库分页列表
getQuestionBankPage() {
queryQuestionBankPage(this.msg).then(res => {
if (res.Code == 1) {
this.dataList = res.Data.PageData;
this.pageCount = res.Data.PageCount;
}
})
},
//翻页
changePage(val) {
this.msg.pageIndex = val;
this.getQuestionBankPage()
},
research() {
this.msg.pageIndex = 1;
this.getQuestionBankPage();
},
//关闭弹窗
closeSaveForm() {
this.$emit('close')
this.persistent = false
},
//确认选择
sureQuestionBank() {
this.persistent = false;
var tempArray = [];
if (this.selectedQuestionBank && this.selectedQuestionBank.length > 0) {
this.selectedQuestionBank.forEach(item => {
tempArray.push({
BankId: item.BankId,
BankName: item.BankName,
})
})
}
this.$emit('success', tempArray);
},
},
}
</script>
This diff is collapsed.
...@@ -56,6 +56,37 @@ ...@@ -56,6 +56,37 @@
{{addMsg.Content}} {{addMsg.Content}}
</div> </div>
</div> </div>
<div style="display: flex;align-items: flex-start;margin-top: 15px;" v-for="(item,index) in MediumModel" :key="index">
<i class="el-icon-user" style="margin-right:20px;font-size: 40px;color: #1890ff;"></i>
<div v-if="item.Type==2" style="width: 1px; flex:1;">
<q-img :src="item.ImageModel.ImagePath"
style="width: 70%;">
</q-img>
</div>
<div v-if="item.Type==3" style="width: 1px; flex:1;padding: 10px 15px; border: 1px solid #eee; border-radius: 4px; background: #fff;">
<div>{{item.ImgTextModel.Title}}</div>
<div style="display: flex;align-items: flex-start;justify-content: space-between;">
<div style="width: 1px;flex:1">
{{item.ImgTextModel.Description}}
</div>
<q-img :src="item.ImgTextModel.ImgPath"
style="width: 80px;height: 80px;margin-left: 10px;">
</q-img>
</div>
</div>
<div v-if="item.Type==6" style="width: 70%;padding: 10px 15px; border: 1px solid #eee; border-radius: 4px; background: #fff;">
<div>{{item.AppletModel.Title}}</div>
<q-img :src="item.AppletModel.ImagePath"
style="width: 100%;">
</q-img>
</div>
</div>
</div> </div>
</div> </div>
<div class="box_r"> <div class="box_r">
...@@ -87,8 +118,9 @@ ...@@ -87,8 +118,9 @@
<div v-if="MediumModel.length>0"> <div v-if="MediumModel.length>0">
<div class="row items-center" v-for="(x,y) in MediumModel" :key="y"> <div class="row items-center" v-for="(x,y) in MediumModel" :key="y">
<i class="el-icon-link"></i> <i class="el-icon-link"></i>
<span style="margin-left: 10px;cursor: pointer;" @click="selectimg">{{Selectobj.name}}</span> <span style="margin-left: 10px;cursor: pointer;" >{{getType(x,'title')}}</span>
<i style="margin-left: 10px;cursor: pointer" class="el-icon-close" @click="Selectobj={}"></i> <i style="margin-left: 10px;cursor: pointer" class="el-icon-close"
@click="deleteModel(y)"></i>
</div> </div>
</div> </div>
...@@ -108,7 +140,8 @@ ...@@ -108,7 +140,8 @@
</el-form-item> </el-form-item>
</el-form> </el-form>
<q-card-actions align="left" class="bg-white" style="margin-top: 15px;"> <q-card-actions align="left" class="bg-white" style="margin-top: 15px;">
<q-btn color="accent" class="q-mr-md" label="保存" @click="savemove()" style="width: 100px;" :loading="loading"/> <q-btn color="accent" class="q-mr-md" label="保存" @click="savemove()" style="width: 100px;"
:loading="loading" />
<q-btn class="q-mr-md" label="返回" @click="goblck()" style="width: 60px;" /> <q-btn class="q-mr-md" label="返回" @click="goblck()" style="width: 60px;" />
</q-card-actions> </q-card-actions>
</div> </div>
...@@ -139,14 +172,13 @@ ...@@ -139,14 +172,13 @@
</div> </div>
</el-dialog> </el-dialog>
<!-- 图片 --> <!-- 图片 -->
<selectMaterial v-if="isshowselectMaterial" :materialType="materialType" :saveobj='Selectobj' :classifyList='classifyList' <selectMaterial v-if="isshowselectMaterial" :materialType="materialType" :classifyList='classifyList'
@close="getclose()" @success='getsuccess'> @close="getclose()" @success='getsuccess'>
</selectMaterial> </selectMaterial>
<!-- 图文 --> <!-- 图文 -->
<imagetextform v-if="isshowimagetext" :saveobj='Selectobj' @close="gettwclose()" @success='gettwsuccess'> <imagetextform v-if="isshowimagetext" @close="gettwclose()" @success='gettwsuccess' :classifyList='classifyList'></imagetextform>
</imagetextform>
<!-- 小程序 --> <!-- 小程序 -->
<appletform v-if="isshowapplet" :saveobj='Selectobj' @close="getxcxclose()" @success='getxcxsuccess'> <appletform v-if="isshowapplet" @close="getxcxclose()" @success='getxcxsuccess' :classifyList='classifyList'>
</appletform> </appletform>
</div> </div>
</template> </template>
...@@ -179,7 +211,7 @@ ...@@ -179,7 +211,7 @@
outerVisible: false,//选择人员弹窗 outerVisible: false,//选择人员弹窗
filterText: '',//人员选择 帅选 filterText: '',//人员选择 帅选
memberList: [],// memberList: [],//
allmemberList:[], allmemberList: [],
showMember: [], showMember: [],
membertype: '1', membertype: '1',
ryList: [], ryList: [],
...@@ -198,9 +230,8 @@ ...@@ -198,9 +230,8 @@
isshowselectMaterial: false, isshowselectMaterial: false,
isshowimagetext: false, isshowimagetext: false,
isshowapplet: false, isshowapplet: false,
Selectobj: {},//选中对象 MediumModel: [],//已选的添加内容
MediumModel:[], classifyList: [],
classifyList:[],
} }
}, },
created() { created() {
...@@ -219,7 +250,7 @@ ...@@ -219,7 +250,7 @@
queryEmployee({}).then(res => { queryEmployee({}).then(res => {
if (res.Code == 1) { if (res.Code == 1) {
this.memberList = res.Data; this.memberList = res.Data;
this.allmemberList = JSON.parse(JSON.stringify(res.Data)) ; this.allmemberList = JSON.parse(JSON.stringify(res.Data));
} }
}).catch(() => { }).catch(() => {
...@@ -258,7 +289,7 @@ ...@@ -258,7 +289,7 @@
if (!value) return true; if (!value) return true;
return data.DepartmentName.indexOf(value) !== -1; return data.DepartmentName.indexOf(value) !== -1;
}, },
getmemlist(){ getmemlist() {
if (this.filterText === '') { if (this.filterText === '') {
this.memberList = JSON.parse(JSON.stringify(this.allmemberList)) this.memberList = JSON.parse(JSON.stringify(this.allmemberList))
} else { } else {
...@@ -285,9 +316,34 @@ ...@@ -285,9 +316,34 @@
}, },
getsuccess(data) {//选择数据回来 getsuccess(data) {//选择数据回来
this.Selectobj = data this.ISidentical(data)
this.isshowselectMaterial = false this.isshowselectMaterial = false
}, },
ISidentical(data){//返回来的数据进行判断再添加
if(this.MediumModel.length>0){
let isyes = false
this.MediumModel.map(x=>{
if(x.Id== data.Id){
isyes = true;
return
}
})
if(isyes==false){
this.MediumModel.push(data)
}else{
this.$q.notify({
type: 'negative',
message: `重复选择、请您重新选择!`,
position: 'top'
})
return
}
}else{
this.MediumModel = [];
this.MediumModel.push(data)
}
},
selecttextimg() {//图文 selecttextimg() {//图文
this.isshowimagetext = true; this.isshowimagetext = true;
...@@ -299,7 +355,7 @@ ...@@ -299,7 +355,7 @@
this.isshowimagetext = false; this.isshowimagetext = false;
}, },
gettwsuccess(data) {//图文返回成功 gettwsuccess(data) {//图文返回成功
this.Selectobj = data this.ISidentical(data)
this.isshowimagetext = false this.isshowimagetext = false
}, },
...@@ -314,8 +370,8 @@ ...@@ -314,8 +370,8 @@
getxcxclose() {//小程序 关闭 getxcxclose() {//小程序 关闭
this.isshowapplet = false; this.isshowapplet = false;
}, },
getxcxsuccess() {//小程序 关闭 getxcxsuccess(data) {//小程序 关闭
this.Selectobj = data this.ISidentical(data)
this.isshowapplet = false this.isshowapplet = false
}, },
savemove() {//保存 savemove() {//保存
...@@ -336,6 +392,16 @@ ...@@ -336,6 +392,16 @@
return return
} }
} }
this.addMsg.MediumIds == ''
if(this.MediumModel && this.MediumModel.length>0){
let ids=[]
this.MediumModel.forEach(x=>{
ids.push(x.Id)
})
this.addMsg.MediumIds = ids.join(',')
}
if (this.addMsg.MediumIds == '') { if (this.addMsg.MediumIds == '') {
this.addMsg.Type = 1; this.addMsg.Type = 1;
if (this.addMsg.Content == '') { if (this.addMsg.Content == '') {
...@@ -367,6 +433,29 @@ ...@@ -367,6 +433,29 @@
goblck() {//返回上一个页面 goblck() {//返回上一个页面
this.$router.go(-1);//返回上一层 this.$router.go(-1);//返回上一层
}, },
getType(row, name) {
let title = ''
let content = ''
if (row.Type == 2) {
title = row.ImageModel.ImageName
content = row.ImageModel.ImagePath
} else if (row.Type == 3) {
title = row.ImgTextModel.Title
content = row.ImgTextModel.ImgPath
} else if (row.Type == 6) {
title = row.AppletModel.Title
content = row.AppletModel.ImagePath
}
if (name == 'title') {
return title
} else if (name == 'content') {
return content
}
},
deleteModel(index){
this.MediumModel.splice(index,1)
}
} }
......
...@@ -161,7 +161,7 @@ ...@@ -161,7 +161,7 @@
getWeChatWelcomesPageList(this.msg).then(res => { getWeChatWelcomesPageList(this.msg).then(res => {
this.loading = false this.loading = false
this.data = res.Data.PageData; this.data = res.Data.PageData;
this.pageCount = res.Data.Count this.pageCount = res.Data.PageCount
this.data.forEach(x => { this.data.forEach(x => {
x.UserIdName = '' x.UserIdName = ''
x.UserIdList.map((j, i) => { x.UserIdList.map((j, i) => {
......
<!--组卷-->
<style>
.examCreate {
margin-left: 100px;
}
</style>
<template>
<div class="examCreate">
<br />
组卷题库(*): {{ShowBankName}} <a style="cursor:pointer;color:blue" @click="showQuestionBank">选择题库</a> <br />
<q-btn color="accent" size="sm" @click="postMsg.GenerateType==1" class="q-mr-md" label="智能组卷"  />
<q-btn color="accent" size="sm" @click="postMsg.GenerateType==2,setExamPaper" class="q-mr-md" label="手动组卷"  /> <br /> <br />
<template v-if="postMsg.GenerateType==1">
</template>
<template v-if="postMsg.GenerateType==2">
</template>
<questionbankForm v-if="isShowQuestionBank"  @close="closeQuestionBankForm"  @success="getBankData">
</questionbankForm>
</div>
</template>
<script>
import questionbankForm from '../../components/exam/questionbank-form'
import {
queryQuestionTypeList,
queryDifficultyType,
queryQuestionCategory,
queryQuestionLevelType
} from '../../api/question/question'
import {
savePaperInfo,
} from '../../api/teacher/index';
export default {
components: {
questionbankForm
},
meta: {
title: "组卷"
},
data() {
return {
isShowQuestionBank: false, //是否显示题库列表
postMsg: {
PaperId: 0, //试卷编号
PaperName: "新建试卷", //试卷名称
QuestionBandIds: "", //题库编号【多个逗号分割】
DifficultyType: 1, //难易程度
GenerateType: 0, //组卷类型(1-智能组卷,2-手动组卷,3-智能导入)
},
ShowBankName: "", //显示题库名称
}
},
created() {
},
mounted() {
},
methods: {
//显示题库
showQuestionBank() {
this.isShowQuestionBank = true;
},
//关闭题库
closeQuestionBankForm() {
this.isShowQuestionBank = false;
},
//获取选择的题库
getBankData(bankArray) {
this.isShowQuestionBank = false;
var qBankIds = "";
var sBankName = "";
if (bankArray && bankArray.length > 0) {
bankArray.forEach(item => {
qBankIds += "," + item.BankId;
sBankName += "," + item.BankName;
});
}
if (qBankIds.substr(0, 1) == ',') {
qBankIds = qBankIds.substr(1);
}
if (sBankName.substr(0, 1) == ',') {
sBankName = sBankName.substr(1);
}
this.postMsg.QuestionBandIds = qBankIds;
this.ShowBankName = sBankName;
},
//保存试卷信息
setExamPaper() {
savePaperInfo(this.postMsg).then(res => {
});
}
}
}
</script>
...@@ -82,7 +82,7 @@ ...@@ -82,7 +82,7 @@
width: 328px; width: 328px;
} }
.List-ul li{ .List-ul li {
display: block; display: block;
padding-left: 25px; padding-left: 25px;
line-height: 33px; line-height: 33px;
...@@ -93,7 +93,7 @@ ...@@ -93,7 +93,7 @@
text-decoration: none; text-decoration: none;
min-width: 250px; min-width: 250px;
overflow: hidden; overflow: hidden;
padding-right:20px; padding-right: 20px;
white-space: nowrap; white-space: nowrap;
text-overflow: ellipsis text-overflow: ellipsis
} }
...@@ -119,6 +119,7 @@ ...@@ -119,6 +119,7 @@
justify-content: space-between; justify-content: space-between;
align-items: center; align-items: center;
} }
.List-bt { .List-bt {
width: 318px; width: 318px;
height: 27px; height: 27px;
...@@ -127,34 +128,40 @@ ...@@ -127,34 +128,40 @@
line-height: 27px; line-height: 27px;
padding-left: 10px; padding-left: 10px;
} }
.List-ul li:hover{
.List-ul li:hover {
background: #a6a6a6; background: #a6a6a6;
color: #333; color: #333;
} }
.left-btn-list{
padding:5px 10px; .left-btn-list {
padding: 5px 10px;
display: inline-block; display: inline-block;
color: #555; color: #555;
border-radius: 3px; border-radius: 3px;
font-size:14px; font-size: 14px;
border:1px solid #999; border: 1px solid #999;
margin-right:10px; margin-right: 10px;
cursor: pointer; cursor: pointer;
} }
#btn1{
background: #26a69a!important; #btn1 {
background: #26a69a !important;
} }
.difficulty_Degree{
.difficulty_Degree {
display: inline-block; display: inline-block;
width:80px; width: 80px;
text-align: right; text-align: right;
line-height: 56px; line-height: 56px;
} }
.commonDalei{
.commonDalei {
display: flex; display: flex;
align-content: center; align-content: center;
margin-bottom:20px; margin-bottom: 20px;
} }
</style> </style>
<template> <template>
<div class="examPaper"> <div class="examPaper">
...@@ -164,8 +171,8 @@ ...@@ -164,8 +171,8 @@
<q-input filled label="标题" v-model="DataObj.PaperName" /> <q-input filled label="标题" v-model="DataObj.PaperName" />
</div> </div>
<div style="width:20%;"> <div style="width:20%;">
<q-select filled option-value="Id" option-label="Name" :options="easyList" emit-value map-options label="难度" <q-select filled option-value="Id" option-label="Name" :options="questionDifficultyTypeList" emit-value
use-input clearable v-model="DataObj.DifficultyType" /> map-options label="难度" use-input clearable v-model="DataObj.DifficultyType" />
</div> </div>
</div> </div>
<div style="width:20%;text-align:right;"> <div style="width:20%;text-align:right;">
...@@ -200,13 +207,10 @@ ...@@ -200,13 +207,10 @@
</div> </div>
<div class="Exam-right f1"> <div class="Exam-right f1">
<div class="Left-btn"> <div class="Left-btn">
          <div>           <div>
<!-- <template v-for="(fItem,fIndex) in firstTypeList">
<span class="left-btn-list" :key="fIndex" @click="onItemClick(fItem)">{{fItem.Name}}</span>
</template> -->
<template v-for="(fItem,fIndex) in firstTypeList"> <template v-for="(fItem,fIndex) in firstTypeList">
<q-btn :key="fIndex" color="accent" :id="commonIndex==fIndex?'btn1':''" size="sm" :label="fItem.Name" style="margin-left:5px;" <q-btn :key="fIndex" color="accent" :id="commonIndex==fIndex?'btn1':''" size="sm" :label="fItem.Name"
@click="onItemClick(fItem,fIndex)" /> style="margin-left:5px;" @click="onItemClick(fItem,fIndex)" />
</template> </template>
<q-btn-dropdown color="accent" size="sm" label="更多" style="margin-left:5px;"> <q-btn-dropdown color="accent" size="sm" label="更多" style="margin-left:5px;">
<q-list> <q-list>
...@@ -219,9 +223,10 @@ ...@@ -219,9 +223,10 @@
</q-list> </q-list>
</q-btn-dropdown> </q-btn-dropdown>
</div> </div>
          <div>           <div>
            <q-btn color="accent" size="sm" @click="isShowQuestion=true" class="q-mr-md" label="题库选题" />             
          </div> <q-btn color="accent" size="sm" @click="isShowQuestion=true" class="q-mr-md" label="题库选题"  />
          </div>
</div> </div>
<div class="row wrap" v-if="ChooseItem" style="padding:20px;"> <div class="row wrap" v-if="ChooseItem" style="padding:20px;">
<div class="edit_stem"> <div class="edit_stem">
...@@ -282,19 +287,19 @@ ...@@ -282,19 +287,19 @@
<div class="col-12 commonDalei" style="margin-top:20px;"> <div class="col-12 commonDalei" style="margin-top:20px;">
<span class="difficulty_Degree">难度:</span> <span class="difficulty_Degree">难度:</span>
<q-select filled option-value="Id" size="sm" style="display:inline-block;width:300px;" option-label="Name" <q-select filled option-value="Id" size="sm" style="display:inline-block;width:300px;" option-label="Name"
v-model="ChooseItem.DifficultyType" :options="questionDifficultyTypeList" emit-value map-options/> v-model="ChooseItem.DifficultyType" :options="questionDifficultyTypeList" emit-value map-options />
</div> </div>
<div class="col-12 commonDalei"> <div class="col-12 commonDalei">
<br /> <br />
<span class="difficulty_Degree">所属大类:</span> <span class="difficulty_Degree">所属大类:</span>
<q-select filled option-value="Id" size="sm" style="display:inline-block;width:300px;" option-label="Name" <q-select filled option-value="Id" size="sm" style="display:inline-block;width:300px;" option-label="Name"
v-model="ChooseItem.Category" :options="questionCategoryList" emit-value map-options/> v-model="ChooseItem.Category" :options="questionCategoryList" emit-value map-options />
</div> </div>
<div class="col-12 commonDalei"> <div class="col-12 commonDalei">
<br /> <br />
<span class="difficulty_Degree">考级程度:</span> <span class="difficulty_Degree">考级程度:</span>
<q-select filled option-value="Id" size="sm" style="display:inline-block;width:300px;" option-label="Name" <q-select filled option-value="Id" size="sm" style="display:inline-block;width:300px;" option-label="Name"
v-model="ChooseItem.LevelType" :options="questionLevalTypeList" emit-value map-options/> v-model="ChooseItem.LevelType" :options="questionLevalTypeList" emit-value map-options />
</div> </div>
<div class="col-12"> <div class="col-12">
<span class="difficulty_Degree">知识点:</span> <span class="difficulty_Degree">知识点:</span>
...@@ -328,7 +333,7 @@ ...@@ -328,7 +333,7 @@
import cloze from '../../components/questiontype/cloze' import cloze from '../../components/questiontype/cloze'
import readingComprehensio from '../../components/questiontype/reading-comprehensio' import readingComprehensio from '../../components/questiontype/reading-comprehensio'
import sharingChoose from '../../components/questiontype/sharing-choose' import sharingChoose from '../../components/questiontype/sharing-choose'
import questionForm from '../../components/exam/question-form' import questionForm from '../../components/exam/question-form'
import { import {
GetPaper, GetPaper,
savePaperInfo, savePaperInfo,
...@@ -365,16 +370,6 @@ ...@@ -365,16 +370,6 @@
initialFrameWidth: null, initialFrameWidth: null,
initialFrameHeight: 80, initialFrameHeight: 80,
}, },
easyList: [{
Id: 1,
Name: '难'
}, {
Id: 2,
Name: '中'
}, {
Id: 3,
Name: '易'
}],
msg: { msg: {
PaperId: 0 PaperId: 0
}, },
...@@ -388,8 +383,8 @@ ...@@ -388,8 +383,8 @@
choosePointArray: [], //选择知识点 choosePointArray: [], //选择知识点
firstTypeList: [], //第一类题型 firstTypeList: [], //第一类题型
secondTypeList: [], //第二类题型 secondTypeList: [], //第二类题型
isShowQuestion:false, isShowQuestion: false,
commonIndex:-1 commonIndex: -1
} }
}, },
created() { created() {
...@@ -418,7 +413,7 @@ ...@@ -418,7 +413,7 @@
}); });
}, },
//题型点击 //题型点击
onItemClick(item,index) { onItemClick(item, index) {
// this.AnswerList = []; // this.AnswerList = [];
// this.questionObj = item; // this.questionObj = item;
// this.objOption.QuestionTypeId = item.QId; // this.objOption.QuestionTypeId = item.QId;
...@@ -428,7 +423,7 @@ ...@@ -428,7 +423,7 @@
// if (obj) { // if (obj) {
// this.objOption.QuestionContent = JSON.stringify(obj); // this.objOption.QuestionContent = JSON.stringify(obj);
// } // }
this.commonIndex=index this.commonIndex = index
}, },
//获取问题大类 //获取问题大类
getQuestionCategory() { getQuestionCategory() {
...@@ -470,10 +465,10 @@ ...@@ -470,10 +465,10 @@
console.log("res", res); console.log("res", res);
}) })
}, },
closeQuestForm(){ closeQuestForm() {
this.isShowQuestion = false; this.isShowQuestion = false;
}, },
refreshPage(){ refreshPage() {
} }
} }
......
...@@ -30,10 +30,7 @@ ...@@ -30,10 +30,7 @@
<div class="page-body"> <div class="page-body">
<div class="page-search row items-center"> <div class="page-search row items-center">
<div class="col row wrap q-mr-lg q-col-gutter-md"> <div class="col row wrap q-mr-lg q-col-gutter-md">
<!-- <div class="col-3">
<q-select @input="getList" standout="bg-primary text-white" option-value="Id" option-label="Name"
v-model="msg.tikuName" :options="tikuList" emit-value map-options label="所属题库" />
</div> -->
<div class="col-3"> <div class="col-3">
<q-input @change="getList" clearable filled v-model="msg.PaperName" @clear="getList" maxlength="20" <q-input @change="getList" clearable filled v-model="msg.PaperName" @clear="getList" maxlength="20"
label="输入试卷名称、组卷人查找" /> label="输入试卷名称、组卷人查找" />
...@@ -47,7 +44,8 @@ ...@@ -47,7 +44,8 @@
<template v-slot:top="props"> <template v-slot:top="props">
<div class="col-2 q-table__title">试卷管理</div> <div class="col-2 q-table__title">试卷管理</div>
<q-space /> <q-space />
<q-btn color="accent" size="sm" class="q-mr-md" label="组卷" /> <q-btn color="accent" size="sm" class="q-mr-md" label="新增文件夹" @click="CreatePaper()" />
<q-btn color="accent" size="sm" class="q-mr-md" label="新增试卷" @click="CreatePaper()" />
</template> </template>
<template v-slot:bottom> <template v-slot:bottom>
<q-pagination class="full-width justify-end" v-model="msg.pageIndex" color="primary" :max="pageCount" <q-pagination class="full-width justify-end" v-model="msg.pageIndex" color="primary" :max="pageCount"
...@@ -139,6 +137,11 @@ ...@@ -139,6 +137,11 @@
this.getList(); this.getList();
}, },
methods: { methods: {
//创建试卷
CreatePaper() {
this.OpenNewUrl('/exam/examCreate', {
})
},
//翻页 //翻页
changePage(val) { changePage(val) {
this.msg.pageIndex = val; this.msg.pageIndex = val;
...@@ -162,13 +165,14 @@ ...@@ -162,13 +165,14 @@
}, },
//点击编辑 跳转 //点击编辑 跳转
goExameEdit(item) { goExameEdit(item) {
console.log("item",item); console.log("item", item);
this.OpenNewUrl('/exam/examEdit', { this.OpenNewUrl('/exam/examEdit', {
Id: item.PaperId Id: item.PaperId
}) })
} }
} }
} }
</script> </script>
<style lang="sass"> <style lang="sass">
@import url('~assets/css/table.sass') @import url('~assets/css/table.sass')
......
<style> <style>
</style> </style>
<template> <template>
<div class="page-body"> <div class="page-body">
<q-tabs style="margin-bottom:20px;" v-model="tabCheck" narrow-indicator dense align="left" class="text-primary"> <q-tabs
<q-tab :ripple="false" v-for="(qitem,qindex) in tabList" :name="qitem.name" :label="qitem.label" :key="qindex" /> style="margin-bottom: 20px"
v-model="tabCheck"
narrow-indicator
dense
align="left"
class="text-primary"
>
<q-tab
:ripple="false"
v-for="(qitem, qindex) in tabList"
:name="qitem.name"
:label="qitem.label"
:key="qindex"
/>
</q-tabs> </q-tabs>
<div> <div>
<template v-if="tabCheck=='1'"> <template v-if="tabCheck == '1'">
<!--退课流程--> <!--退课流程-->
<backclassflow-form></backclassflow-form> <backclassflow-form></backclassflow-form>
</template> </template>
<template v-if="tabCheck=='2'"> <template v-if="tabCheck == '2'">
<!--调课流程--> <!--调课流程-->
<changeclassflow-form></changeclassflow-form> <changeclassflow-form></changeclassflow-form>
</template> </template>
<template v-if="tabCheck=='3'"> <template v-if="tabCheck == '3'">
<!--停课流程--> <!--停课流程-->
<stopclassflow-form></stopclassflow-form> <stopclassflow-form></stopclassflow-form>
</template> </template>
<template v-if="tabCheck=='4'"> <template v-if="tabCheck == '4'">
<!-- 转班流程 --> <!-- 转班流程 -->
<transfer-form></transfer-form> <transfer-form></transfer-form>
</template> </template>
<template v-if="tabCheck=='5'"> <template v-if="tabCheck == '5'">
<!-- 临时上课邀请流程 --> <!-- 临时上课邀请流程 -->
<temporaryClass-form></temporaryClass-form> <temporaryClass-form></temporaryClass-form>
</template> </template>
<template v-if="tabCheck=='6'"> <template v-if="tabCheck == '6'">
<!-- 分拆 --> <!-- 分拆 -->
<separate-form></separate-form> <separate-form></separate-form>
</template> </template>
<template v-if="tabCheck == '7'">
<!-- 请假流程 -->
<leave-form></leave-form>
</template>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import backclassflowForm from '../../components/flow/backclassflow-form'; import backclassflowForm from "../../components/flow/backclassflow-form";
import changeclassflowForm from '../../components/flow/changeclassflow-form'; import changeclassflowForm from "../../components/flow/changeclassflow-form";
import stopclassflowForm from '../../components/flow/stopclassflow-form'; import stopclassflowForm from "../../components/flow/stopclassflow-form";
import transferForm from '../../components/flow/transfer-form'; import transferForm from "../../components/flow/transfer-form";
import temporaryClassForm from '../../components/flow/temporaryClass-form'; import temporaryClassForm from "../../components/flow/temporaryClass-form";
import separateForm from '../../components/flow/separate-form' import separateForm from "../../components/flow/separate-form";
export default { import leaveForm from "../../components/flow/leave-form";
export default {
meta: { meta: {
title: "流程设置" title: "流程设置",
}, },
components: { components: {
backclassflowForm, backclassflowForm,
...@@ -51,11 +68,13 @@ ...@@ -51,11 +68,13 @@
stopclassflowForm, stopclassflowForm,
transferForm, transferForm,
temporaryClassForm, temporaryClassForm,
separateForm separateForm,
leaveForm,
}, },
data() { data() {
return { return {
tabList: [{ tabList: [
{
name: "1", name: "1",
label: "退课流程", label: "退课流程",
}, },
...@@ -69,27 +88,26 @@ ...@@ -69,27 +88,26 @@
}, },
{ {
name: "4", name: "4",
label: "转班流程" label: "转班流程",
}, },
{ {
name: "5", name: "5",
label: "临时上课邀请流程" label: "临时上课邀请流程",
}, },
{ {
name: "6", name: "6",
label: "分拆" label: "分拆",
} },
// {
// name: "7",
// label: "请假流程",
// },
], ],
tabCheck: '1', tabCheck: "1",
} };
}, },
created() {}, created() {},
mounted() { mounted() {},
methods: {},
}, };
methods: {
}
}
</script> </script>
...@@ -1048,6 +1048,11 @@ const routes = [{ ...@@ -1048,6 +1048,11 @@ const routes = [{
component: () => component: () =>
import("pages/exam/examEdit") import("pages/exam/examEdit")
}, },
{
path: "/exam/examCreate", //考试组卷
component: () =>
import("pages/exam/examCreate")
},
{ {
path: "/teacher/testdatabase", //题库查询 path: "/teacher/testdatabase", //题库查询
component: () => component: () =>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment