feat(xumu): 添加远程耳标号查询功能
- 在 AppDeathManage 和 AppOutManage 组件中集成 AiEartagRemote 组件 - 实现耳标号远程查询和自动填充功能 -优化用户输入体验,提高数据准确性
This commit is contained in:
		| @@ -1,5 +1,6 @@ | ||||
| <script> | ||||
| import {mapState} from "vuex" | ||||
| import AiEartagRemote from "@project/xumu/components/AiEartagRemote.vue"; | ||||
|  | ||||
| const formImages = [ | ||||
|   {label: "身长测量照片", prop: "heightPic", rules: {required: true, message: '请上传 身长测量照片'}}, | ||||
| @@ -9,6 +10,7 @@ const formImages = [ | ||||
| ] | ||||
| export default { | ||||
|   name: "deathAdd", | ||||
|   components: {AiEartagRemote}, | ||||
|   props: { | ||||
|     instance: Function, | ||||
|     permissions: Function, | ||||
| @@ -71,7 +73,10 @@ export default { | ||||
|           } | ||||
|         }) | ||||
|       }) | ||||
|     } | ||||
|     }, | ||||
|     handlerAutocomplete(value) { | ||||
|       'biochipEarNumber|farmId|houseId|penId|electronicEarNumber|originalEarNumber|category|variety'.split("|").forEach(prop => this.$set(this.detail, prop, value[prop])) | ||||
|     }, | ||||
|   }, | ||||
|   created() { | ||||
|     this.getDetail(this.$route.query.id) | ||||
| @@ -84,7 +89,7 @@ export default { | ||||
|     <el-form size="small" label-width="120px" :model="detail" ref="detail"> | ||||
|       <ai-card title="基础信息"> | ||||
|         <div class="grid c-4"> | ||||
|           <ai-input class="row" v-model="detail.biochipEarNumber" placeholder="请输入耳标号按回车查询,或扫描耳标号" @input="getDetail"/> | ||||
|           <ai-eartag-remote :instance="instance" @enter="handlerAutocomplete" /> | ||||
|           <el-form-item label="生物芯片耳标号"> | ||||
|             <b v-text="detail.biochipEarNumber"/> | ||||
|           </el-form-item> | ||||
| @@ -100,7 +105,7 @@ export default { | ||||
|           <el-form-item label="电子耳标号" prop="electronicEarNumber"> | ||||
|             <b v-text="detail.electronicEarNumber"/> | ||||
|           </el-form-item> | ||||
|           <el-form-item label="原厂耳标号" prop="category"> | ||||
|           <el-form-item label="原厂耳标号" prop="originalEarNumber"> | ||||
|             <b v-text="detail.originalEarNumber"/> | ||||
|           </el-form-item> | ||||
|           <el-form-item label="类别" prop="category"> | ||||
|   | ||||
		Reference in New Issue
	
	Block a user