Commit 2d266d4a by 前端

Merge branch 'kuangyq_fix_v2.0.0' into 'v2.0.0'

编辑修改

See merge request !88
2 parents 15872970 1d302eea
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
<el-input v-model="materialAddForm.materialName" :size="size" placeholder="请输入素材名称" maxlength="30"></el-input> <el-input v-model="materialAddForm.materialName" :size="size" placeholder="请输入素材名称" maxlength="30"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="素材类型:" prop="materialType"> <el-form-item label="素材类型:" prop="materialType">
<el-radio-group v-model="materialAddForm.materialType" @change="radioChange" :disabled="routeInfo.addOrEdit == 2"> <el-radio-group v-model="materialAddForm.materialType" @change="radioChange" :disabled="routeInfo.addOrEdit == 2 && routeInfo.status != 1">
<el-radio :label="1">PDF文件</el-radio> <el-radio :label="1">PDF文件</el-radio>
<!-- <el-radio :label="2">自定义链接</el-radio> --> <!-- <el-radio :label="2">自定义链接</el-radio> -->
<el-radio :label="3">图文</el-radio> <el-radio :label="3">图文</el-radio>
...@@ -27,8 +27,8 @@ ...@@ -27,8 +27,8 @@
<!-- 选择PDF --> <!-- 选择PDF -->
<div v-show="materialAddForm.materialType == 1"> <div v-show="materialAddForm.materialType == 1">
<div class="pdf-show"> <div class="pdf-show">
<input type="file" style="opacity: 0" accept=".pdf" @change="e => handlePdfChange(e)" /> <input type="file" style="opacity: 0" accept=".pdf" :disabled="routeInfo.addOrEdit == 2 && routeInfo.status != 1" @change="e => handlePdfChange(e)" />
<el-button icon="el-icon-plus" :size="size">选择文件</el-button> <el-button icon="el-icon-plus" :size="size" :disabled="routeInfo.addOrEdit == 2 && routeInfo.status != 1">选择文件</el-button>
</div> </div>
<div v-if="pdfUrl">{{ pdfUrl }}</div> <div v-if="pdfUrl">{{ pdfUrl }}</div>
</div> </div>
...@@ -244,8 +244,9 @@ export default { ...@@ -244,8 +244,9 @@ export default {
}, },
mounted() { mounted() {
this.routeInfo = this.$route.query this.routeInfo = this.$route.query
console.log(this.routeInfo)
this.routeInfo.addOrEdit != 1 ? this.getMaterialInfo() : '' this.routeInfo.addOrEdit != 1 ? this.getMaterialInfo() : ''
// this.routeInfo.addOrEdit != 1 ? this.forbidEdit() : '' this.routeInfo.addOrEdit != 1 ? (this.routeInfo.status != 1 ? this.forbidEdit() : '') : ''
this.title = this.titleObj[this.routeInfo.addOrEdit] this.title = this.titleObj[this.routeInfo.addOrEdit]
this.materialInsert() this.materialInsert()
this.getMaterialList() this.getMaterialList()
......
...@@ -68,7 +68,8 @@ export default { ...@@ -68,7 +68,8 @@ export default {
}) })
}, },
forbidEdit() { forbidEdit() {
this.editor.$textElem.attr('contenteditable', false) // this.editor.$textElem.attr('contenteditable', false)
this.editor.disable()
} }
} }
} }
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!