|
@@ -3,7 +3,7 @@
|
|
|
<crumbs :title="title" :param="$route.params" linkTo="BaseField"></crumbs>
|
|
|
<div class="contents">
|
|
|
<div class="content">
|
|
|
- <el-form ref="form" :label-position="labelPosition" label-width="118px" :model="form" :rules="rules">
|
|
|
+ <el-form ref="form" :label-position="labelPosition" label-width="125px" :model="form" :rules="rules">
|
|
|
<el-form-item label="所属医院:" prop="hospitalId">
|
|
|
<el-select v-model="form.hospitalId"
|
|
|
placeholder="请选择"
|
|
@@ -57,10 +57,11 @@
|
|
|
|
|
|
</el-form-item>
|
|
|
<el-form-item>
|
|
|
- <el-checkbox v-model="form.addLine" :true-label="Number(1)" :false-label="Number(0)">换行</el-checkbox>
|
|
|
+ <el-checkbox v-model="form.monoLine" :true-label="Number(1)" :false-label="Number(0)">独占一行</el-checkbox>
|
|
|
+ <el-checkbox v-model="form.addLine" :true-label="Number(1)" :false-label="Number(0)">内容换行</el-checkbox>
|
|
|
<el-checkbox v-model="form.position" :true-label="Number(1)" :false-label="Number(0)">靠右显示</el-checkbox>
|
|
|
<el-checkbox v-model="form.bold" :true-label="Number(1)" :false-label="Number(0)">内容加粗</el-checkbox>
|
|
|
- <el-checkbox v-model="form.retract" :true-label="Number(1)" :false-label="Number(0)">缩进</el-checkbox>
|
|
|
+ <el-checkbox v-model="form.retract" :true-label="Number(1)" :false-label="Number(0)">内容缩进</el-checkbox>
|
|
|
</el-form-item>
|
|
|
<el-button class="disclButn" size="small" type="primary" :disabled = 'saveDisable' @click="comfirn('form')">确定</el-button>
|
|
|
</el-form>
|
|
@@ -78,7 +79,7 @@
|
|
|
list:[],
|
|
|
labelPosition:'left',
|
|
|
isFirst:true,
|
|
|
- title:'字段映射维护-添加映射字段',
|
|
|
+ title:'字段映射维护-添加字段映射',
|
|
|
casesEIds:'',
|
|
|
form:{
|
|
|
tagType:1, //固定
|
|
@@ -87,6 +88,7 @@
|
|
|
name:'',
|
|
|
val:'',
|
|
|
tagName:'',
|
|
|
+ monoLine:0,
|
|
|
addLine:0,
|
|
|
bold:0,
|
|
|
position:0,
|
|
@@ -110,9 +112,11 @@
|
|
|
},
|
|
|
created(){
|
|
|
this.getAllTypes();
|
|
|
- let info = this.$route.params.info;
|
|
|
+ let {isCopy,info} = this.$route.params;
|
|
|
+ this.copy=isCopy;
|
|
|
if(info){
|
|
|
const infoCopy = Object.assign({},info);
|
|
|
+ isCopy?infoCopy.id="":"";
|
|
|
// infoCopy.casesEntryIds?this.casesEIds = infoCopy.casesEntryIds.split(","):'';
|
|
|
let tmpArr = [],tmpArr1 = []
|
|
|
for(let i = 0;i < infoCopy.quesCasesEntryDTOList.length;i++){
|
|
@@ -122,12 +126,12 @@
|
|
|
id:infoCopy.quesCasesEntryDTOList[i].casesEntryId,
|
|
|
casesEntryId:infoCopy.quesCasesEntryDTOList[i].casesEntryId
|
|
|
}
|
|
|
- tmpArr.push(infoCopy.quesCasesEntryDTOList[i].casesEntryId)
|
|
|
+ tmpArr.push(""+infoCopy.quesCasesEntryDTOList[i].casesEntryId)
|
|
|
tmpArr1.push(obj)
|
|
|
}
|
|
|
infoCopy.quesCasesEntryDTOList?this.casesEIds = tmpArr:'';
|
|
|
infoCopy.quesCasesEntryVOList = [...tmpArr1];
|
|
|
- this.title='字段映射维护-修改映射字段';
|
|
|
+ this.title=isCopy?"字段映射维护-复制字段映射":'字段映射维护-修改字段映射';
|
|
|
this.form = infoCopy;
|
|
|
this.getQcFlawList(tmpArr1);
|
|
|
}else{
|
|
@@ -138,6 +142,7 @@
|
|
|
this.form.hospitalId = hospitalId
|
|
|
this.form.modeId = modeId
|
|
|
this.form.tagName = qcSelecttModuleNme
|
|
|
+ this.getQcFlawList()
|
|
|
}
|
|
|
},
|
|
|
watch:{
|
|
@@ -159,6 +164,9 @@
|
|
|
localStorage.setItem("qcSelectHospital",val);
|
|
|
|
|
|
this.getQcFlawList()
|
|
|
+ this.form.modeId=""
|
|
|
+ this.form.quesCasesEntryDTOList =[]
|
|
|
+ this.casesEIds=[]
|
|
|
},
|
|
|
changeModule(val){
|
|
|
localStorage.setItem("qcSelectModule",val);
|
|
@@ -166,6 +174,8 @@
|
|
|
this.form.tagName = qcSelecttModuleNme
|
|
|
localStorage.setItem("qcSelectModuleName",qcSelecttModuleNme);
|
|
|
this.getQcFlawList()
|
|
|
+ this.form.quesCasesEntryDTOList =[]
|
|
|
+ this.casesEIds=[]
|
|
|
},
|
|
|
getQcFlawList(val){
|
|
|
const { hospitalId, modeId } = this.form
|
|
@@ -176,7 +186,23 @@
|
|
|
api.getQcFlawList(param).then((res)=>{
|
|
|
if(res.data.code==="0") {
|
|
|
const data = res.data.data;
|
|
|
+ this.flawList = []
|
|
|
this.flawList = data.records;
|
|
|
+ let info = this.$route.params.info;
|
|
|
+ if(info){
|
|
|
+ const infoCopy = Object.assign({},this.form);
|
|
|
+
|
|
|
+
|
|
|
+ for(let i = 0;i < infoCopy.quesCasesEntryDTOList.length;i++){
|
|
|
+ let obj = {
|
|
|
+ name:infoCopy.quesCasesEntryDTOList[i].casesEntryName,
|
|
|
+ casesEntryName:infoCopy.quesCasesEntryDTOList[i].casesEntryName,
|
|
|
+ id:infoCopy.quesCasesEntryDTOList[i].casesEntryId,
|
|
|
+ casesEntryId:infoCopy.quesCasesEntryDTOList[i].casesEntryId
|
|
|
+ }
|
|
|
+ this.flawList.unshift(obj)
|
|
|
+ }
|
|
|
+ }
|
|
|
}else{
|
|
|
this.warning("获取缺陷条目失败");
|
|
|
}
|
|
@@ -224,11 +250,11 @@
|
|
|
this.warning("取值字段【】含有非法字符")
|
|
|
return;
|
|
|
}
|
|
|
-
|
|
|
- if(this.id){//修改
|
|
|
- const param = Object.assign({},this.form,{id:this.id});
|
|
|
+
|
|
|
+ if(this.form.id){//修改
|
|
|
+ const param = Object.assign({},this.form);
|
|
|
this.saveDisable = true; //提交保存按钮不可点击,返回结果时才可点击,防止频繁发送请求
|
|
|
- api.addFieldMatch(param).then((res)=>{
|
|
|
+ api.addFieldMatch({questionWrapper:param}).then((res)=>{
|
|
|
if(res.data.code==0){
|
|
|
this.$message({
|
|
|
message:"修改成功",
|
|
@@ -289,6 +315,9 @@
|
|
|
color: #545455;
|
|
|
min-width: 980px;
|
|
|
position: relative;
|
|
|
+ .el-checkbox{
|
|
|
+ display: inline-block;
|
|
|
+ }
|
|
|
}
|
|
|
.el-form-item{
|
|
|
width: 600px;
|