Commit 82fbf73a authored by youjie's avatar youjie

问卷 样式调整

parent da25d061
......@@ -22,25 +22,25 @@
</div>
</template>
</q-field>
<q-input filled stack-label maxlength="20" :dense="false" v-model="objOption.Sort"
<q-input filled stack-label maxlength="20" :dense="false" v-model="objOption.Sort"
class="col-6 q-pr-lg q-pb-lg" label="排序" :rules="[val => !!val || '请输入排序']" />
</div>
<template v-if="objOption.SurveyType==2||objOption.SurveyType==3">
增加选项
<q-btn round dense flat icon="add" @click="addSurveyOptions" />
<div v-for="(sItem,sIndex) in objOption.SurveyOptionsList" :key="sIndex">
<div class="row wrap">
<q-input filled class="col-6 q-pr-lg q-pb-lg" v-model="sItem.OptionsName" :label="`选项${sIndex+1}`" :dense="false">
</q-input>
<q-input filled stack-label :dense="false" v-model="sItem.Sort"
class="col-4 q-pr-lg q-pb-lg" label="排序" :rules="[val => !!val || '请输入排序']">
<template v-slot:append>
<q-btn round dense flat icon="delete" @click="delSurveyOptions(sIndex)" />
</template>
</q-input>
</div>
<div class="q-pb-xs">
增加选项
<q-btn round dense flat icon="add" @click="addSurveyOptions" />
</div>
<div v-for="(sItem,sIndex) in objOption.SurveyOptionsList" :key="sIndex">
<div class="row wrap">
<q-input filled class="col-10 q-pr-lg q-pb-lg" v-model="sItem.OptionsName" :label="`选项${sIndex+1}`" :dense="false"></q-input>
<q-input filled stack-label :dense="false" v-model="sItem.Sort"
class="col-2 q-pr-lg q-pb-lg" label="排序" :rules="[val => !!val || '请输入排序']">
<template v-slot:append>
<q-btn round dense flat icon="delete" @click="delSurveyOptions(sIndex)" />
</template>
</q-input>
</div>
</div>
</template>
</q-card-section>
......@@ -110,7 +110,7 @@
item.Sort=index+1;
});
},
//获取类型列表
getSurveyTypeEnumList() {
querySurveyTypeEnumList({}).then(res => {
......@@ -173,6 +173,6 @@
}
},
}
</script>
\ No newline at end of file
</script>
<template>
<div class="page-body" style="width: auto;height:150%;">
<div class="page-content">
<div class="col-2 q-table__title" style="text-align:center;">老师上课质量调查问卷</div>
......@@ -11,26 +11,26 @@
<div class="row wrap">
<div class="col-12">
<q-select
filled
v-model="addMsg.TeacherId"
use-input
:dense="false"
ref="Teacher_Id"
label="您选择评价的老师:"
option-value="TId" option-label="TeacherName"
:options="TeacherList"
@filter="filterFnTeacher"
class="col-6 q-pb-lg"
emit-value map-options >
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">
No results
</q-item-section>
</q-item>
</template>
</q-select>
</div>
filled
v-model="addMsg.TeacherId"
use-input
:dense="false"
ref="Teacher_Id"
label="您选择评价的老师:"
option-value="TId" option-label="TeacherName"
:options="TeacherList"
@filter="filterFnTeacher"
class="col-6 q-pb-lg"
emit-value map-options>
<template v-slot:no-option>
<q-item>
<q-item-section class="text-grey">
No results
</q-item-section>
</q-item>
</template>
</q-select>
</div>
</div>
<template v-if="data&&data.length>0">
<div v-for="(item,index) in data" >
......@@ -44,49 +44,47 @@
<span class="ratestyle" v-if="item.ScoreNum==3">感觉一般</span>
<span class="ratestyle" v-if="item.ScoreNum==2">不满意</span>
<span class="ratestyle" v-if="item.ScoreNum==1">非常不满意</span>
</template>
</template>
<template v-if="item.SurveyType === 2">
<div class="q-gutter-sm" >
<q-list>
<div v-for="(radio, rIndex) in item.SurveyOptionsList"><q-radio :key="rIndex" v-model="item.ScoreNum" :label="radio.OptionsName" :val="radio.ID" /></div>
</q-list>
</div>
</template>
<template v-if="item.SurveyType === 3">
<div class="q-gutter-sm" >
<q-list>
<div v-for="(radio, rIndex) in item.SurveyOptionsList" ><q-checkbox :key="rIndex" v-model="item.CheckInfo" :val="radio.ID" :label="radio.OptionsName" /></div>
</q-list>
</div>
</template>
<template v-if="item.SurveyType === 2">
<div class="q-gutter-sm" >
<q-list>
<q-radio v-for="(radio, rIndex) in item.SurveyOptionsList" :key="rIndex" v-model="item.ScoreNum" :label="radio.OptionsName" :val="radio.ID" />
</q-list>
</div>
</template>
<template v-if="item.SurveyType === 3">
<div class="q-gutter-sm" >
<q-list>
<q-checkbox v-for="(radio, rIndex) in item.SurveyOptionsList" :key="rIndex" v-model="item.CheckInfo" :val="radio.ID" :label="radio.OptionsName" />
</q-list>
</div>
</template>
<template v-if="item.SurveyType === 4">
<q-input type="textarea" :rows="2" :placeholder="$t('fnc.qsrneirong')" v-model="item.TextContent" style="margin-bottom:15px;">
</q-input>
<template v-if="item.SurveyType === 4">
<q-input type="textarea" :rows="2" :placeholder="$t('fnc.qsrneirong')" v-model="item.TextContent" style="margin-bottom:15px;">
</q-input>
</template>
</div>
</template>
</div>
</div>
</div>
</template>
<q-card-actions align="right" class="bg-white">
<q-card-actions align="center" class="bg-white q-pt-lg">
<q-btn label="取消" flat color="grey-10" style="font-weight:400 !important" />
<q-btn label="立即提交" color="accent q-px-md" style="font-weight:400 !important"
<q-btn label="立即提交" color="accent q-px-md" style="font-weight:400 !important"
@click="setSurveyStudent" />
</q-card-actions>
</div>
<div v-else>
<div class="row wrap" style="margin:10px 0px;text-align:center; ">
<div class="row wrap" style="margin:20px 0px;text-align:center; ">
<div class="col-12">亲爱的{{addMsg.StuName}}同学,感谢您对任课老师{{addMsg.TeacherName}}的评价。</div>
</div>
</div>
</div>
</div>
</template>
......@@ -103,7 +101,7 @@
title: "老师上课质量调查问卷"
},
components: {
},
data() {
return {
......@@ -114,8 +112,8 @@
msg: {
RB_Group_Id:0,
},
TeacherList: [], //关联教师下拉数据
AllTeacherList: [], //关联教师下拉数据
TeacherList: [], //关联教师下拉数据
AllTeacherList: [], //关联教师下拉数据
addMsg: {
TeacherId:0,
StuName:"",
......@@ -136,7 +134,7 @@
if(this.$route.query&&this.$route.query.StuName){
this.addMsg.StuName = decodeURIComponent(this.$route.query.StuName)
}
this.GetTeacherList();
this.getSurveyShowList();
},
......@@ -210,9 +208,9 @@
// showTips+=1;
// }
// }
this.addMsg.SurveyList.push(nowInfo);
});
});
if (showTips> 0) {
return;
}
......@@ -237,7 +235,7 @@
getTeacherListByGroupId(this.msg).then(res => {
if (res.Code == 1) {
this.TeacherList = res.Data;
var obj = {
TeacherName: '请选择',
TId: 0
......@@ -285,5 +283,5 @@
</style>
<style lang="sass">
@import url('~assets/css/table.sass')
</style>
\ No newline at end of file
</style>
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