Commit 5a48fc86 authored by 罗超's avatar 罗超

修改样式和bug

parent 8c62765e
...@@ -12,7 +12,7 @@ export default { ...@@ -12,7 +12,7 @@ export default {
<style> <style>
@import url('~assets/css/font.css'); @import url('~assets/css/font.css');
@import url('//at.alicdn.com/t/font_2077629_cata4y2l5e8.css'); @import url('//at.alicdn.com/t/font_2077629_6dh27k2xa4l.css');
html, html,
body, body,
......
...@@ -8,6 +8,80 @@ ...@@ -8,6 +8,80 @@
padding: 4px 0; padding: 4px 0;
cursor: default; cursor: default;
} }
.difficulty_Degree{
display: inline-block;
width: 70px;
height: 26px;
line-height: 26px;
color: #181E33;
font-size: 13px;
}
.selectBox {
display: inline-block;
vertical-align: top;
text-align: left;
position: relative;
cursor: pointer;
width: 75px;
line-height: 24px;
height: 24px;
background: #FFFFFF;
border: 1px solid #E1E1E5;
border-radius: 4px;
font-size: 12px;
color: #181E33;
}
.blue-border {
border: 1px solid #FFFFFF;
box-shadow: 0 0 7px 1px #75BAFF;
outline: none;
}
.addKnowledge{
display: inline-block;
width: 98px;
height: 28px;
border-radius: 4px;
border: 1px dashed #E1EAF4;
text-align: center;
line-height: 28px;
color: #91A0B5;
margin-right: 12px;
margin-bottom: 8px;
color:#CAD5E6;
cursor: pointer;
font-size:12px;
line-height: 24px;
}
.addKnowledge:hover {
opacity: 0.7;
}
.knowledge_List{
display: inline-block;
padding: 0 14px;
height: 28px;
border-radius: 4px;
border: 1px dashed #E1EAF4;
text-align: center;
line-height: 28px;
color: #91A0B5;
margin-right: 12px;
margin-bottom: 8px;
position: relative;
cursor: pointer;
}
.knowledge_List:hover {
color:rgba(139,146,166,0.7);
}
.knowledge_List:hover i{
display: block!important;
}
.knowledge_List i{
position: absolute;
font-size:15px;
display: none;
right:-8px;
top:-10px;
}
</style> </style>
<template> <template>
<q-dialog v-model="persistent" persistent content-class="bg-grey-1" transition-show="scale" transition-hide="scale"> <q-dialog v-model="persistent" persistent content-class="bg-grey-1" transition-show="scale" transition-hide="scale">
...@@ -80,21 +154,36 @@ ...@@ -80,21 +154,36 @@
</sharing-choose> </sharing-choose>
<br /> <br />
<div class="col-12"> <div class="col-12">
答案解析<UeEditor v-model="objOption.AnswerParse" :config="config" ref="AnswerParse"></UeEditor> <div style="margin-bottom:20px;">答案解析</div>
<UeEditor v-model="objOption.AnswerParse" :config="config" ref="AnswerParse"></UeEditor>
</div> </div>
<br /> <br />
<div class="col-12"> <div class="col-12">
<br /> <br />
<q-select filled stack-label option-value="Id" option-label="Name" v-model="objOption.DifficultyType" <span class="difficulty_Degree">难度</span>
<select v-model="objOption.DifficultyType" class="selectBox blue-border">
<template v-for="(cItem,cIndex) in questionDifficultyTypeList">
<option :key="cIndex" :label="cItem.Name" :value="cItem.Id">
</option>
</template>
</select>
<!-- <q-select filled stack-label option-value="Id" option-label="Name" v-model="objOption.DifficultyType"
ref="DifficultyType" :options="questionDifficultyTypeList" label="难易程度" :dense="false" ref="DifficultyType" :options="questionDifficultyTypeList" label="难易程度" :dense="false"
class="col-6 q-pr-lg q-pb-lg" emit-value map-options /> class="col-6 q-pr-lg q-pb-lg" emit-value map-options /> -->
</div> </div>
<div class="col-12"> <div class="col-12" style="margin-top:16px;">
知识点: <a style="cursor:pointer;color:blue;" @click="isShowPoint=true">选择知识点</a> <span class="difficulty_Degree">知识点: </span>
<div class="col"> <a class="addKnowledge" @click="isShowPoint=true">
<i class="iconfont icon-add" style="position:relative;top:1px;"></i>选择知识点
</a>
<span class="knowledge_List" v-for="(x, i) in choosePointArray" :key="i">
{{x.PointName}}
<i class="iconfont icon-shanchu1" @click="removePointTag(i)"></i>
</span>
<!-- <div class="col">
<q-chip v-for="(x, i) in choosePointArray" @remove="removePointTag(i)" :key="i" square color="red" <q-chip v-for="(x, i) in choosePointArray" @remove="removePointTag(i)" :key="i" square color="red"
class="q-ma-none q-mr-md" icon="bookmark" text-color="white" :label="x.PointName" removable /> class="q-ma-none q-mr-md" icon="bookmark" text-color="white" :label="x.PointName" removable />
</div> </div> -->
</div> </div>
</div> </div>
</q-card-section> </q-card-section>
...@@ -229,7 +318,7 @@ ...@@ -229,7 +318,7 @@
getPointList(obj) { getPointList(obj) {
if (obj && obj.length > 0) { if (obj && obj.length > 0) {
if (this.choosePointArray && this.choosePointArray.length > 0) { if (this.choosePointArray && this.choosePointArray.length > 0) {
this.choosePointArray.concat(obj); this.choosePointArray = this.choosePointArray.concat(obj);
} else { } else {
this.choosePointArray = obj; this.choosePointArray = obj;
} }
......
<template> <template>
<div class="questionpoint" style="z-index:99999"> <div class="questionpoint" style="z-index:99999">
<el-dialog class="questionpoint-dialog" style="width:1000px;height:800px;margin:0 auto;" title="知识点列表" <el-dialog class="questionpoint-dialog" style="width:1200px;margin:0 auto;" title="知识点列表"
:visible.sync="dialogVisible" @opened="dialogOpened" :close-on-click-modal="false"> :visible.sync="dialogVisible" @opened="dialogOpened" :close-on-click-modal="false">
<q-table :pagination="msg" :loading="loading" no-data-label="暂无相关数据" flat <q-table :pagination="msg" :loading="loading" no-data-label="暂无相关数据" flat
class="sticky-right-column-table sticky-column-table" separator="none" :data="data" :columns="columns" class="sticky-column-table" separator="none" :data="data" :columns="columns"
row-key="PointId" :selection="multiple?'multiple':'single'" :selected.sync="selectedArray"> row-key="PointId" :selection="multiple?'multiple':'single'" :selected.sync="selectedArray">
<template v-slot:top="props"> <template v-slot:top="props">
<q-input @input="resetSearch" clearable standout="bg-primary text-white" v-model="msg.PointName" label="关键字" <q-input @input="resetSearch" clearable style="width:50%;" standout="bg-primary text-white" v-model="msg.PointName" label="关键字"
maxlength="20" @clear="resetSearch" /> maxlength="20" @clear="resetSearch" />
<q-space /> <q-space />
<div class="page-option"> <div class="page-option">
...@@ -16,7 +16,7 @@ ...@@ -16,7 +16,7 @@
<q-banner v-if="IsShowPoint"> <q-banner v-if="IsShowPoint">
<div class="drop_NameDown" style="margin-top:20px;"> <div class="drop_NameDown" style="margin-top:20px;">
<q-input filled stack-label maxlength="100" v-model="setPointObj.PointName" :dense="false" <q-input filled stack-label maxlength="100" v-model="setPointObj.PointName" :dense="false"
class="col-12 q-pr-lg q-pb-lg" label="知识点名称" /> class="col-12 q-pb-lg" label="知识点名称" />
</div> </div>
<q-card-actions align="right" class="bg-white" style="margin-top:20px;"> <q-card-actions align="right" class="bg-white" style="margin-top:20px;">
<q-btn label="取消" flat color="grey-10" style="font-weight:400 !important" <q-btn label="取消" flat color="grey-10" style="font-weight:400 !important"
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
<div class="calenderDialog"> <div class="calenderDialog">
<div class="drop_NameDown" style="margin-top:20px;"> <div class="drop_NameDown" style="margin-top:20px;">
<q-input filled stack-label maxlength="100" v-model="setPointObj.PointName" :dense="false" <q-input filled stack-label maxlength="100" v-model="setPointObj.PointName" :dense="false"
class="col-12 q-pr-lg q-pb-lg" label="知识点名称" /> class="col-12 q-pb-lg" label="知识点名称" />
</div> </div>
<q-card-actions align="right" class="bg-white"> <q-card-actions align="right" class="bg-white">
<q-btn label="取消" flat color="grey-10" @click="isShowPointEdit=false" <q-btn label="取消" flat color="grey-10" @click="isShowPointEdit=false"
...@@ -59,7 +59,9 @@ ...@@ -59,7 +59,9 @@
</template> </template>
</q-table> </q-table>
<div style="margin-top:20px;text-align:right"> <div style="margin-top:20px;text-align:right">
<el-button size="small" type="primary" @click="SelectPoint">选定</el-button> <q-btn label="取消" flat color="grey-10" style="font-weight:400 !important"
@click="dialogVisible=false" />
<q-btn label="选定" color="accent q-px-md" style="font-weight:400 !important;margin-left:10px;padding:0;" @click="SelectPoint" />
</div> </div>
</el-dialog> </el-dialog>
</div> </div>
......
<style>
.singleQuestion{
width:100%;
}
.singleQuestion .InpDIV {
width: 765px;
height: 38px;
border-radius: 4px;
border: 1px solid #E1EAF4;
box-sizing: border-box;
-moz-box-sizing: border-box;
-webkit-box-sizing: border-box;
font-size: 14px;
padding: 0 10px;
line-height: 38px;
padding-left: 10px;
font-size: 14px;
text-overflow: ellipsis;
overflow: hidden;
white-space: nowrap;
}
.singleQuestion .delIcon{
color:#c3c3c3;
font-weight: bold;
display: none;
font-size:18px;
cursor: pointer;
}
.singleQuestion .delIcon:hover{
color:gray;
}
.singleQuestion table tr td{
vertical-align: top;
}
.singleQuestion table tr:hover .delIcon{
display: block!important;
}
.singleQuestion .addSingle{
cursor: pointer;
color:#3A8BFF;
font-size:13px;
height:40px;
}
.singleQuestion .addSingle:hover{
opacity: 0.7;
}
</style>
<!--单选题--> <!--单选题-->
<template> <template>
<div class="singleQuestion"> <div class="singleQuestion">
<table v-if="data&&data.length>0"> <table v-if="data&&data.length>0" style="width:100%;border-collapse:separate; border-spacing:0px 20px;">
<tr v-for="(item,index) in data"> <tr v-for="(item,index) in data">
<td> <td style="width:40px;text-align:center;">
<!-- <el-checkbox v-model="item.IsAnswer" @change="ChangeItem(item)">{{item.Name}}</el-checkbox> -->
<div class="Answer_List" @click="ChangeItem(item)" :class="{'Is_Answer':item.IsAnswer}"> <div class="Answer_List" @click="ChangeItem(item)" :class="{'Is_Answer':item.IsAnswer}">
{{item.Name}} {{item.Name}}
</div> </div>
</td> </td>
<td> <td>
<UeEditor v-model="item.Content" :config="config"></UeEditor> <div class="InpDIV" v-html="item.Content" v-if="commonIndex!=index" @click="changeEdit(index)"></div>
<UeEditor v-model="item.Content" v-else :config="config"></UeEditor>
</td> </td>
<td> <td style="width:40px;text-align:center;">
<a style="cursor:pointer;" @click="deleteOpion(index)">删除</a> <i class="iconfont icon-guanbi delIcon" @click="deleteOpion(index)"></i>
</td> </td>
</tr> </tr>
<tfoot> <tfoot>
<tr> <tr>
<td colspan="3"> <td colspan="3">
<a style="cursor:pointer;" @click="addOption()">添加选项</a> <a class="addSingle" @click="addOption()">
<i class="iconfont icon-add"></i>添加选项
</a>
</td> </td>
</tr> </tr>
</tfoot> </tfoot>
...@@ -48,14 +97,16 @@ ...@@ -48,14 +97,16 @@
data: this.questionData, data: this.questionData,
config: { config: {
initialFrameWidth: null, initialFrameWidth: null,
initialFrameHeight: 80, initialFrameHeight: 90,
}, },
optionTitleList: [], optionTitleList: [],
commonIndex:-1,
}; };
}, },
created() { created() {
this.initConfig(); this.initConfig();
console.log(this.data,'dataaa'); },
mounted(){
}, },
methods: { methods: {
initConfig() { initConfig() {
...@@ -106,6 +157,10 @@ ...@@ -106,6 +157,10 @@
item.IsAnswer = true; item.IsAnswer = true;
this.setOption.Answer=item.Name; this.setOption.Answer=item.Name;
}, },
//点击切换输入
changeEdit(index){
this.commonIndex=index;
}
}, },
mounted() { mounted() {
......
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