|
@@ -11,7 +11,7 @@
|
|
|
<el-form-item class="addDiagName" label="选择添加疾病名称:" >
|
|
|
<input class="searchInput" @focus="focuInput" type="text" v-model = "searchDiagVal">
|
|
|
<span class="searchName" @click="searchDiag">搜索</span>
|
|
|
- <ul class="itemList diagList" ref="diagList">
|
|
|
+ <ul v-if="showDiagList&&diagList.length > 0" class="itemList diagList" ref="diagList">
|
|
|
<li
|
|
|
v-for="item in diagList"
|
|
|
class="diagItem ellipsis"
|
|
@@ -48,22 +48,55 @@
|
|
|
</td>
|
|
|
<td class="FeatureNumber" >
|
|
|
<el-tooltip :disabled="!item.verifyCode&&!item.codeNull&&!item.codeError" class="item" effect="dark" :content="item.verifyCode||item.codeNull||item.codeError" placement="top">
|
|
|
- <input class="groupInput" :class="{borderRed:item.verifyCode||item.codeNull, colorRed: item.codeError}" :title="item.code" type="text" v-model.trim="item.code" @input="handleInp(index,$event,'FeatureNumber')" @click="clickItem(index,'FeatureNumber')">
|
|
|
+ <el-input class="groupTextarea"
|
|
|
+ type="textarea"
|
|
|
+ :autosize="{ minRows: 1}"
|
|
|
+ :class="{borderRed:item.verifyCode||item.codeNull, colorRed: item.codeError}"
|
|
|
+ :title="item.code"
|
|
|
+ v-model.trim="item.code"
|
|
|
+ @input="handleInp(index,$event,'FeatureNumber')"
|
|
|
+ @focus="clickItem(index,'FeatureNumber')">
|
|
|
+ </el-input>
|
|
|
</el-tooltip>
|
|
|
</td>
|
|
|
<td class="FeatureStand" >
|
|
|
<el-tooltip :disabled="!item.verifyStandard&&!item.standardNull" class="item" effect="dark" :content="item.verifyStandard||item.standardNull" placement="top">
|
|
|
- <input class="groupInput" :class="{borderRed:item.verifyStandard||item.standardNull}" :title="item.standard" type="text" v-model.trim="item.standard" @input="handleInp(index,$event,'FeatureStand')" @click="clickItem(index,'FeatureStand')">
|
|
|
+ <el-input class="groupTextarea"
|
|
|
+ type="textarea"
|
|
|
+ :autosize="{ minRows: 1}"
|
|
|
+ :class="{borderRed:item.verifyStandard||item.standardNull}"
|
|
|
+ :title="item.standard"
|
|
|
+ v-model.trim="item.standard"
|
|
|
+ @input="handleInp(index,$event,'FeatureStand')"
|
|
|
+ @focus="clickItem(index,'FeatureStand')">
|
|
|
+ </el-input>
|
|
|
</el-tooltip>
|
|
|
</td>
|
|
|
<td class="FeatureRelate">
|
|
|
<el-tooltip :disabled="!item.verifyRelation&&!item.relationNull" class="item" effect="dark" :content="item.verifyRelation||item.relationNull" placement="top">
|
|
|
- <input class="groupInput" :class="{borderRed:item.verifyRelation|| item.relationNull}" :title="item.relation" type="text" v-model.trim="item.relation" @input="handleInp(index,$event,'FeatureRelate',item.type)" @click="clickItem(index,'FeatureRelate')">
|
|
|
+ <el-input class="groupTextarea"
|
|
|
+ type="textarea"
|
|
|
+ :autosize="{ minRows: 1}"
|
|
|
+ :class="{borderRed:item.verifyRelation|| item.relationNull}"
|
|
|
+ :title="item.relation"
|
|
|
+ v-model.trim="item.relation"
|
|
|
+ @input="handleInp(index,$event,'FeatureRelate',item.type)"
|
|
|
+ @focus="clickItem(index,'FeatureRelate')">
|
|
|
+ </el-input>
|
|
|
</el-tooltip>
|
|
|
</td>
|
|
|
<td class="FeatureResult">
|
|
|
<el-tooltip :disabled="!item.verifyResult" class="item" effect="dark" :content="item.verifyResult" placement="top">
|
|
|
- <input :readonly="item.type!=3" class="groupInput" :class="{borderRed:item.verifyResult, inpDisabled:item.type!=3}" :title="item.result" type="text" v-model.trim="item.result" @input="handleInp(index,$event,'FeatureResult')" @click="clickItem(index,'FeatureResult')">
|
|
|
+ <el-input class="groupTextarea"
|
|
|
+ type="textarea"
|
|
|
+ :autosize="{ minRows: 1}"
|
|
|
+ :readonly="item.type!=3"
|
|
|
+ :class="{borderRed:item.verifyResult, inpDisabled:item.type!=3}"
|
|
|
+ :title="item.result"
|
|
|
+ v-model.trim="item.result"
|
|
|
+ @input="handleInp(index,$event,'FeatureResult')"
|
|
|
+ @focus="clickItem(index,'FeatureResult')">
|
|
|
+ </el-input>
|
|
|
</el-tooltip>
|
|
|
</td>
|
|
|
<td class="FeatureOpera">
|
|
@@ -90,7 +123,16 @@
|
|
|
</td>
|
|
|
<td class="FormulaNumber">
|
|
|
<el-tooltip :disabled="!item.verifyFormula" class="item" effect="dark" :content="item.verifyFormula" placement="top">
|
|
|
- <input class="groupInput" :readonly="!item.type" :class="{borderRed:item.verifyFormula,inpDisabled:!item.type}" :title="item.formula" type="text" v-model.trim="item.formula" @input="handleInp(index,$event,'FormulaNumber',item.type)" @click="clickItem(index,'FormulaNumber')">
|
|
|
+ <el-input class="groupTextarea"
|
|
|
+ type="textarea"
|
|
|
+ :readonly="!item.type"
|
|
|
+ :autosize="{ minRows: 1}"
|
|
|
+ :class="{borderRed:item.verifyFormula,inpDisabled:!item.type}"
|
|
|
+ :title="item.formula"
|
|
|
+ v-model.trim="item.formula"
|
|
|
+ @input="handleInp(index,$event,'FormulaNumber')"
|
|
|
+ @focus="clickItem(index,'FormulaNumber')">
|
|
|
+ </el-input>
|
|
|
</el-tooltip>
|
|
|
</td>
|
|
|
<td class="FeatureOpera">
|
|
@@ -173,7 +215,8 @@
|
|
|
saveDisable: false ,
|
|
|
hasQuestion: 1, //是否有问题词
|
|
|
disNameExist: true, //诊断名称是否存在
|
|
|
- isReady:false
|
|
|
+ isReady:false,
|
|
|
+ showDiagList: false
|
|
|
}
|
|
|
},
|
|
|
created(){
|
|
@@ -222,7 +265,6 @@
|
|
|
},
|
|
|
close() {
|
|
|
this.diagList = [];
|
|
|
- if(this.diagList.length>0){this.$refs['diagList'].style.display = 'none';}
|
|
|
},
|
|
|
back(){
|
|
|
this.$router.go(-1);
|
|
@@ -238,19 +280,17 @@
|
|
|
api.diagBaseIndex(param).then((res)=>{
|
|
|
if(res.data.code === '0') {
|
|
|
this.diagList = res.data.data
|
|
|
- if(this.diagList.length>0) {this.$refs['diagList'].style.display = 'block'}
|
|
|
+ this.showDiagList = true
|
|
|
}
|
|
|
})
|
|
|
},
|
|
|
selectDiag(item) {
|
|
|
this.disName = item.name
|
|
|
- this.$refs['diagList'].style.display='none'
|
|
|
this.searchDiagVal = ''
|
|
|
this.diagList=[]
|
|
|
},
|
|
|
focuInput() {
|
|
|
- this.$refs['diagList'].style.display='none'
|
|
|
-
|
|
|
+ this.showDiagList = false
|
|
|
},
|
|
|
addItem(index, type) {
|
|
|
if(type == 1) {
|
|
@@ -543,23 +583,28 @@
|
|
|
})
|
|
|
},
|
|
|
handleInp(index,e,type,itemType){ //分组不能输入负数
|
|
|
- const value = e.target.value;
|
|
|
- console.log(type,itemType)
|
|
|
+ const value = e;
|
|
|
if(type === 'FeatureNumber') { //序号只能输入数字和.
|
|
|
- this.disFeatureList[index].code = value.replace(/[^\d.]/g,'')
|
|
|
- } else if(type==='FeatureStand') { //关联词不能输入顿号
|
|
|
- this.disFeatureList[index].standard = value.replace(/、/g,'')
|
|
|
+ this.$nextTick(() => {
|
|
|
+ this.disFeatureList[index].code = value.replace(/[^\d.]/g,'')
|
|
|
+ })
|
|
|
+ } else if(type==='FeatureStand') { //标准词不能输入顿号
|
|
|
+ this.$nextTick(() => {
|
|
|
+ this.disFeatureList[index].standard = value.replace(/、/g,'')
|
|
|
+ })
|
|
|
+ // this.disFeatureList[index].standard = value.replace(/、/g,'')
|
|
|
} else if ( type === 'FormulaNumber') {
|
|
|
- //计算公式确诊只能输入以下内容: 任、一、二、三、四、五、六、七、八、九、十、拟、诊、0-9、/、.、(、)、(、)
|
|
|
- if(itemType == 91) {
|
|
|
- this.disFormulaList[index].formula = value.replace(/[^\u4EFB\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D\u5341\u62df\u8bca0-9\/\.+\(\)\(\)]/g,'').replace(/[\(]/g, '(').replace(/[\)]/g, ')').replace(/' '/g, '')
|
|
|
- } else { //计算公式其他只能输入以下内容: 任、一、二、三、四、五、六、七、八、九、十、0-9、/、.、(、)、(、)
|
|
|
+ //计算公式只能输入以下内容: 任、一、二、三、四、五、六、七、八、九、十、0-9、/、.、(、)、(、)
|
|
|
+ this.$nextTick(() => {
|
|
|
this.disFormulaList[index].formula = value.replace(/[^\u4EFB\u4E00\u4E8C\u4E09\u56DB\u4E94\u516D\u4E03\u516B\u4E5D\u53410-9\/\.+\(\)\(\)]/g,'').replace(/[\(]/g, '(').replace(/[\)]/g, ')').replace(/' '/g, '')
|
|
|
-
|
|
|
- }
|
|
|
+ })
|
|
|
+
|
|
|
+
|
|
|
} else if ( type === 'FeatureRelate') {
|
|
|
if(itemType == 3) {
|
|
|
- this.disFeatureList[index].relation = value.replace(/、/g,'')
|
|
|
+ this.$nextTick(() => {
|
|
|
+ this.disFeatureList[index].relation = value.replace(/、/g,'')
|
|
|
+ })
|
|
|
}
|
|
|
}
|
|
|
// const item = this.selectedIndexList[index].indexDesc;
|
|
@@ -648,7 +693,6 @@
|
|
|
}
|
|
|
.itemList {
|
|
|
position: absolute;
|
|
|
- display: none;
|
|
|
background: #fff;
|
|
|
width: 162px;
|
|
|
max-height: 150px;
|
|
@@ -691,7 +735,6 @@
|
|
|
margin-bottom: 20px;
|
|
|
tr {
|
|
|
td {
|
|
|
- padding: 5px 10px;
|
|
|
border: 1px solid #a9a9a9;
|
|
|
text-align: center;
|
|
|
}
|
|
@@ -701,6 +744,14 @@
|
|
|
text-align: left;
|
|
|
padding-left: 30px;
|
|
|
}
|
|
|
+ /deep/.el-textarea__inner {
|
|
|
+ width: 100%;
|
|
|
+ line-height: 20px;
|
|
|
+ resize:none;
|
|
|
+ border: none;
|
|
|
+ border-radius: 0;
|
|
|
+ text-align: center;
|
|
|
+ }
|
|
|
}
|
|
|
.selectedContent {
|
|
|
width: 25%;
|
|
@@ -714,10 +765,14 @@
|
|
|
}
|
|
|
.groupInput {
|
|
|
text-align: center;
|
|
|
- height: 28px;
|
|
|
color: #606266;
|
|
|
width: 80%;
|
|
|
}
|
|
|
+ .groupTextarea {
|
|
|
+ text-align: center;
|
|
|
+ color: #606266;
|
|
|
+ width: 100%;
|
|
|
+ }
|
|
|
.btn {
|
|
|
position: absolute;
|
|
|
background-color: #fff;
|
|
@@ -745,6 +800,7 @@
|
|
|
}
|
|
|
.borderRed {
|
|
|
border: 3px solid red ;
|
|
|
+ box-sizing: border-box;
|
|
|
}
|
|
|
.colorRed {
|
|
|
color: red;
|
|
@@ -754,6 +810,7 @@
|
|
|
}
|
|
|
.FeatureType {
|
|
|
width: 7%;
|
|
|
+ padding: 0 5px;
|
|
|
}
|
|
|
.FeatureNumber {
|
|
|
width: 8%;
|
|
@@ -775,6 +832,7 @@
|
|
|
}
|
|
|
.FormulaType{
|
|
|
width: 7%;
|
|
|
+ padding: 0 5px;
|
|
|
}
|
|
|
.FormulaNumber{
|
|
|
width: 78%;
|
|
@@ -811,13 +869,17 @@
|
|
|
margin: 0 0 10px 0;
|
|
|
}
|
|
|
.inpDisabled{
|
|
|
- background: #ECECEC;
|
|
|
- color: #AAAAAA;
|
|
|
- border: none;
|
|
|
- cursor: not-allowed;
|
|
|
+ textarea {
|
|
|
+ background: #ECECEC;
|
|
|
+ color: #AAAAAA;
|
|
|
+ border: none;
|
|
|
+ cursor: not-allowed;
|
|
|
+ height: 100%;
|
|
|
+ }
|
|
|
+
|
|
|
}
|
|
|
.inpTips {
|
|
|
- font-size: 13px;
|
|
|
+ font-size: 14px;
|
|
|
color: red;
|
|
|
margin-bottom: 10px;
|
|
|
}
|