|
@@ -18,7 +18,7 @@
|
|
|
</el-form-item>
|
|
|
<el-form-item label="内容类型:" prop="position" label-width="160px">
|
|
|
<el-checkbox-group v-model="data.position">
|
|
|
- <el-checkbox v-for="it in positions" :key="it.key" :label="it.key">{{it.name}}</el-checkbox>
|
|
|
+ <el-checkbox v-for="it in positions" :key="it.val" :label="it.val">{{it.name}}</el-checkbox>
|
|
|
</el-checkbox-group>
|
|
|
</el-form-item>
|
|
|
<el-form-item label="内容" prop="content" label-width="160px" ref="editor">
|
|
@@ -191,7 +191,7 @@ export default {
|
|
|
filterHiddenPosition() {
|
|
|
const pos = this.data.position;
|
|
|
const pArr = this.positions.map(it => {
|
|
|
- return it.key;
|
|
|
+ return it.val;
|
|
|
});
|
|
|
const pStr = pArr.join(',');
|
|
|
const arr = pos.filter(it => {
|
|
@@ -210,47 +210,7 @@ export default {
|
|
|
return arr.includes(it.val);
|
|
|
});
|
|
|
}
|
|
|
- // let positions = config.contentTypes;
|
|
|
- // if (this.showType == 1) {
|
|
|
- // // 诊断
|
|
|
- // this.positions = positions.filter(item => item.key !== 2);
|
|
|
- // } else if (
|
|
|
- // this.showType == 3 ||
|
|
|
- // this.showType == 4 ||
|
|
|
- // this.showType == 5 ||
|
|
|
- // this.showType == 6
|
|
|
- // ) {
|
|
|
- // // 检验/检查
|
|
|
- // this.positions = positions.filter(item => {
|
|
|
- // return item.key <= 2;
|
|
|
- // });
|
|
|
- // } else if (
|
|
|
- // this.showType == 2 ||
|
|
|
- // this.showType == 7 ||
|
|
|
- // this.showType == 8 ||
|
|
|
- // this.showType == 9 ||
|
|
|
- // this.showType == 10
|
|
|
- // ) {
|
|
|
- // // 药品/手术
|
|
|
- // this.positions = positions.filter(item => item.key === 1);
|
|
|
- // } else {
|
|
|
- // this.positions = positions;
|
|
|
- // }
|
|
|
}
|
|
|
-
|
|
|
- /*emitVal(){
|
|
|
- let data = this.form;
|
|
|
- let pst=this.form.position;
|
|
|
- const content = this.form.content.replace(config.imgHost,'{imageUrlPrefix}');
|
|
|
- const text = this.$refs.quillEditor;console.log(text)
|
|
|
- pst = typeof pst=='string'?pst:pst.join(',');
|
|
|
- data = Object.assign({},data,{
|
|
|
- position:this.form.position?pst:'',
|
|
|
- orderNo:this.index,
|
|
|
- text:'',
|
|
|
- content:content});
|
|
|
- this.$emit("change",this.index,data);
|
|
|
- }*/
|
|
|
}
|
|
|
};
|
|
|
</script>
|