|
|
@@ -2,9 +2,11 @@
|
|
|
.input-with-select .el-select .el-input {
|
|
|
width: 110px;
|
|
|
}
|
|
|
+
|
|
|
.input-with-select .el-input-group__append {
|
|
|
background-color: #fff;
|
|
|
}
|
|
|
+
|
|
|
</style>
|
|
|
|
|
|
<template>
|
|
|
@@ -20,12 +22,15 @@
|
|
|
<el-breadcrumb-item>{{title}}</el-breadcrumb-item>
|
|
|
</el-breadcrumb>
|
|
|
<span style="float: right;">
|
|
|
- <el-button size="mini" type="primary" class="el-button--small" style="margin-left: 8px" @click="savesample">保存</el-button>
|
|
|
- <el-button size="mini" type="primary" class="el-button--small" style="margin-left: 8px" @click="goback">返回</el-button>
|
|
|
+ <el-button size="mini" type="primary" class="el-button--small" style="margin-left: 8px" @click="savesample">保存
|
|
|
+ </el-button>
|
|
|
+ <el-button size="mini" type="primary" class="el-button--small" style="margin-left: 8px" @click="goback">返回
|
|
|
+ </el-button>
|
|
|
</span>
|
|
|
</div>
|
|
|
|
|
|
- <el-form ref="samplemanageform" :rules="sampleformrule" :model="sampleform" label-width="130px" style="min-height: calc(100vh - 189px)">
|
|
|
+ <el-form ref="samplemanageform" :rules="sampleformrule" :model="sampleform" label-width="130px"
|
|
|
+ style="min-height: calc(100vh - 189px)">
|
|
|
<el-row>
|
|
|
<el-col :span="8">
|
|
|
<el-form-item label="样本条码" prop="BarCode">
|
|
|
@@ -34,9 +39,10 @@
|
|
|
</el-col>
|
|
|
<el-col :span="8">
|
|
|
<el-form-item label="样本类型" required prop="SampleTypestr">
|
|
|
- <el-select v-model="sampleform.SampleTypestr" clearable placeholder="请选择" style="width:100%" @change="choosetype"
|
|
|
- :disabled="disabledsampletype">
|
|
|
- <el-option v-for="item in sampletypelist" :label="item.label" :value="item.value" :key="item.value"></el-option>
|
|
|
+ <el-select v-model="sampleform.SampleTypestr" clearable placeholder="请选择" style="width:100%"
|
|
|
+ @change="choosetype" :disabled="disabledsampletype">
|
|
|
+ <el-option v-for="item in sampletypelist" :label="item.label" :value="item.value" :key="item.value">
|
|
|
+ </el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
@@ -47,15 +53,18 @@
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="8">
|
|
|
- <el-form-item label="组织器官" v-if="acc !='sBBo4' && acc != 'ssqOy'">
|
|
|
+ <el-form-item label="组织器官" v-if="acc !='sBBo4' && acc != 'ssqOy' && acc != 'saB4v'">
|
|
|
<el-cascader :options="organlist2" style="width:100%" :props="sampleorganprops" change-on-select
|
|
|
- :show-all-levels="false" v-model="selectedorgan" placeholder="请选择" @change="chooseorgange" :disabled="disabledsamplingorgan"></el-cascader>
|
|
|
+ :show-all-levels="false" v-model="selectedorgan" placeholder="请选择" @change="chooseorgange"
|
|
|
+ :disabled="disabledsamplingorgan"></el-cascader>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="8">
|
|
|
- <el-form-item label="取材部位" v-if="acc !='sBBo4' && acc != 'ssqOy'">
|
|
|
- <el-select v-model="sampleform.SamplingSite" placeholder="取材部位" clearable style="width:100%" :disabled="disabledsamplingsite">
|
|
|
- <el-option v-for="item in samplequcailist" :label="item.label" :value="item.value" :key="item.value"></el-option>
|
|
|
+ <el-form-item label="取材部位" v-if="acc !='sBBo4' && acc != 'ssqOy' && acc != 'saB4v'">
|
|
|
+ <el-select v-model="sampleform.SamplingSite" placeholder="取材部位" clearable style="width:100%"
|
|
|
+ :disabled="disabledsamplingsite">
|
|
|
+ <el-option v-for="item in samplequcailist" :label="item.label" :value="item.value" :key="item.value">
|
|
|
+ </el-option>
|
|
|
</el-select>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
@@ -87,9 +96,11 @@
|
|
|
<el-col :span="8">
|
|
|
<el-form-item label="有效日期">
|
|
|
<el-date-picker style="width: 70%" v-model="sampleform.ValidityDatedate" type="date" :clearable="false"
|
|
|
- :placeholder="sampleform.Isyongjiu ? '永久' : '请选择有效日期'" :disabled="disabledvaliditydate || sampleform.Isyongjiu">
|
|
|
+ :placeholder="sampleform.Isyongjiu ? '永久' : '请选择有效日期'"
|
|
|
+ :disabled="disabledvaliditydate || sampleform.Isyongjiu">
|
|
|
</el-date-picker>
|
|
|
- <el-checkbox v-model="sampleform.Isyongjiu" style="float:right" :disabled="diaabledyongjiu">永久</el-checkbox>
|
|
|
+ <el-checkbox v-model="sampleform.Isyongjiu" style="float:right" :disabled="diaabledyongjiu">永久
|
|
|
+ </el-checkbox>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="8">
|
|
|
@@ -98,24 +109,24 @@
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="8">
|
|
|
- <el-form-item label="样本来源" v-if="acc !='sBBo4' && acc != 'ssqOy'">
|
|
|
+ <el-form-item label="样本来源" v-if="acc !='sBBo4' && acc != 'ssqOy' && acc != 'saB4v'">
|
|
|
<el-input v-model="sampleform.SourceName" placeholder="样本来源" style="width:68%" disabled></el-input>
|
|
|
- <el-button type="primary" :disabled="disabledsourcebutton" style="width:30%" @click="dialogsamplesourceVisible = true"
|
|
|
- class="btnbox">选择</el-button>
|
|
|
+ <el-button type="primary" :disabled="disabledsourcebutton" style="width:30%"
|
|
|
+ @click="dialogsamplesourceVisible = true" class="btnbox">选择</el-button>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="8">
|
|
|
- <el-form-item label="样本来源" v-if="acc =='sBBo4'">
|
|
|
+ <el-form-item label="样本来源" v-if="acc =='sBBo4' || acc == 'saB4v'">
|
|
|
<el-input v-model="sampleform.SourceName" placeholder="样本来源" style="width:68%" disabled></el-input>
|
|
|
- <el-button type="primary" :disabled="disabledanimalbutton" style="width:30%" @click="animalSourceVisible = true"
|
|
|
- class="btnbox">选择</el-button>
|
|
|
+ <el-button type="primary" :disabled="disabledanimalbutton" style="width:30%"
|
|
|
+ @click="animalSourceVisible = true" class="btnbox">选择</el-button>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="8">
|
|
|
<el-form-item label="样本来源" v-if="acc =='ssqOy'">
|
|
|
<el-input v-model="sampleform.SourceName" placeholder="样本来源" style="width:68%" disabled></el-input>
|
|
|
- <el-button type="primary" :disabled="disabledanimalbutton" style="width:30%" @click="microSourceVisible = true"
|
|
|
- class="btnbox">选择</el-button>
|
|
|
+ <el-button type="primary" :disabled="disabledanimalbutton" style="width:30%"
|
|
|
+ @click="microSourceVisible = true" class="btnbox">选择</el-button>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
<el-col :span="16">
|
|
|
@@ -140,8 +151,8 @@
|
|
|
</el-col>
|
|
|
<el-col :span="8" v-if="acc =='sryms'">
|
|
|
<el-form-item label="所属分组">
|
|
|
- <el-select ref="refGroup" multiple filterable default-first-option v-model="GroupIdOption" placeholder="请选择"
|
|
|
- style="width: 100%">
|
|
|
+ <el-select ref="refGroup" multiple filterable default-first-option v-model="GroupIdOption"
|
|
|
+ placeholder="请选择" style="width: 100%">
|
|
|
<el-option v-for="item in groupList" :key="item.Key" :label="item.Value" :value="item.Id">
|
|
|
</el-option>
|
|
|
</el-select>
|
|
|
@@ -159,19 +170,21 @@
|
|
|
<el-input v-model="item.FieldDefault" v-if="item.FieldType === '1'" :placeholder="'请输入'+item.Name"
|
|
|
auto-complete="off"></el-input>
|
|
|
|
|
|
- <el-select v-model="item.FieldDefault" v-if="item.FieldType === '2'" clearable :placeholder="'请选择'+item.Name"
|
|
|
- style="width:100%">
|
|
|
- <el-option :label="v" :value="v" :key="v" v-for=" v in item.FieldContent.split(',')"></el-option>
|
|
|
+ <el-select v-model="item.FieldDefault" v-if="item.FieldType === '2'" clearable
|
|
|
+ :placeholder="'请选择'+item.Name" style="width:100%">
|
|
|
+ <el-option :label="v" :value="v" :key="v" v-for=" v in item.FieldContent.split(',')">
|
|
|
+ </el-option>
|
|
|
</el-select>
|
|
|
|
|
|
<el-input v-model="item.FieldDefault" v-if="item.FieldType === '3'" :placeholder="'请输入'+item.Name"
|
|
|
type="textarea" :rows=3 auto-complete="off"></el-input>
|
|
|
|
|
|
- <el-date-picker v-model="item.FieldDefault" v-if="item.FieldType === '4'" type="datetime" style="width:100%"
|
|
|
- placeholder="选择日期"></el-date-picker>
|
|
|
+ <el-date-picker v-model="item.FieldDefault" v-if="item.FieldType === '4'" type="datetime"
|
|
|
+ style="width:100%" placeholder="选择日期"></el-date-picker>
|
|
|
|
|
|
- <el-button plain v-model="item.FieldDefault" v-if="item.FieldType === '5'" type="primary" size="mini"
|
|
|
- class="el-button--small" style="margin-left: 8px" @click="getitem(item)">上传图片</el-button>
|
|
|
+ <el-button plain v-model="item.FieldDefault" v-if="item.FieldType === '5'" type="primary"
|
|
|
+ size="mini" class="el-button--small" style="margin-left: 8px" @click="getitem(item)">上传图片
|
|
|
+ </el-button>
|
|
|
</el-form-item>
|
|
|
</el-col>
|
|
|
</template>
|
|
|
@@ -232,8 +245,9 @@
|
|
|
</el-card>
|
|
|
|
|
|
<el-dialog :title="ImageTitle" width="80%" :visible.sync="imageDialog">
|
|
|
- <el-upload action="" :before-upload="beforeAvatarUpload" :on-preview="handlePictureCardPreview" :http-request="uploadrequest"
|
|
|
- :on-success="handleAvatarSuccess" :on-remove="handleRemove" :file-list="imagefilelist" list-type="picture">
|
|
|
+ <el-upload action="" :before-upload="beforeAvatarUpload" :on-preview="handlePictureCardPreview"
|
|
|
+ :http-request="uploadrequest" :on-success="handleAvatarSuccess" :on-remove="handleRemove"
|
|
|
+ :file-list="imagefilelist" list-type="picture">
|
|
|
<el-button size="small" type="primary">点击上传</el-button>
|
|
|
<div slot="tip" class="el-upload__tip">只能上传jpg/png文件</div>
|
|
|
</el-upload>
|
|
|
@@ -241,7 +255,8 @@
|
|
|
<el-dialog :visible.sync="dialogVisible">
|
|
|
<img width="100%" :src="dialogImageUrl" alt="">
|
|
|
</el-dialog>
|
|
|
- <choose-source-dialog @close="customsampsourceDialogCallback" :visible.sync="dialogsamplesourceVisible"></choose-source-dialog>
|
|
|
+ <choose-source-dialog @close="customsampsourceDialogCallback" :visible.sync="dialogsamplesourceVisible">
|
|
|
+ </choose-source-dialog>
|
|
|
<choose-animal-dialog @close="animalDialogCallback" :visible.sync="animalSourceVisible"></choose-animal-dialog>
|
|
|
<choose-micro-dialog @close="microDialogCallback" :visible.sync="microSourceVisible"></choose-micro-dialog>
|
|
|
</div>
|
|
|
@@ -787,10 +802,10 @@
|
|
|
}
|
|
|
_this.Tabs = _this.groupnameList[0]
|
|
|
_this.getSpecialkz(v)
|
|
|
- if(_this.acc =='sBBo4' || _this.acc == 'ssqOy'){
|
|
|
- let sampletypestr = _this.sampleform.SampleTypestr
|
|
|
- _this.getautobarcode(sampletypestr)
|
|
|
- }
|
|
|
+ // if(_this.acc =='sBBo4' || _this.acc == 'ssqOy' ){
|
|
|
+ let sampletypestr = _this.sampleform.SampleTypestr
|
|
|
+ _this.getautobarcode(sampletypestr)
|
|
|
+ // }
|
|
|
})
|
|
|
}
|
|
|
},
|
|
|
@@ -821,7 +836,8 @@
|
|
|
}
|
|
|
_this.sampleform.Unit = res.data.SampleType.Unit
|
|
|
if (_this.sampleform.code_default === 'true' && _this.sampleform.coderule_sampletype_flag === 1) {
|
|
|
- if (_this.sampleform.coderule_samplingorgan_flag !== 1 || (_this.sampleform.coderule_samplingorgan_flag ===
|
|
|
+ if (_this.sampleform.coderule_samplingorgan_flag !== 1 || (_this.sampleform
|
|
|
+ .coderule_samplingorgan_flag ===
|
|
|
1 && _this.selectedorgan.length > 0)) {
|
|
|
let sampletypestr = _this.sampleform.SampleTypestr
|
|
|
let sampleselectedorgan = ''
|
|
|
@@ -841,7 +857,7 @@
|
|
|
// response
|
|
|
_this.sampleform.code_lastnum = res.data.num
|
|
|
_this.sampleform.SampleCode = res.data.barcode
|
|
|
- console.log("==================",_this.sampleform.SampleCode)
|
|
|
+ console.log("==================", _this.sampleform.SampleCode)
|
|
|
})
|
|
|
},
|
|
|
getsametypetreelist() {
|
|
|
@@ -925,8 +941,9 @@
|
|
|
// 给扩展信息赋值
|
|
|
for (let i = 0; i < this.typetykzlist.length; i++) {
|
|
|
if (this.typetykzlist[i].FieldType == '4') {
|
|
|
- this.typetykzlist[i].FieldDefault = foo.eval('typetykzsampedit.' + this.typetykzlist[i].FieldName).substr(
|
|
|
- 0, 24)
|
|
|
+ this.typetykzlist[i].FieldDefault = foo.eval('typetykzsampedit.' + this.typetykzlist[i].FieldName)
|
|
|
+ .substr(
|
|
|
+ 0, 24)
|
|
|
} else {
|
|
|
this.typetykzlist[i].FieldDefault = foo.eval('typetykzsampedit.' + this.typetykzlist[i].FieldName)
|
|
|
}
|
|
|
@@ -986,7 +1003,7 @@
|
|
|
this.sampleform.SourceId = val.Id
|
|
|
this.sampleform.SourceName = val.Name
|
|
|
},
|
|
|
- microDialogCallback(val){
|
|
|
+ microDialogCallback(val) {
|
|
|
this.sampleform.SourceId = val.Id
|
|
|
this.sampleform.SourceName = val.Name
|
|
|
},
|