Compare commits
2 Commits
9b6e02810a
...
356e6438e0
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
356e6438e0 | ||
|
|
5fe82a68ef |
@@ -49,7 +49,7 @@ export default {
|
||||
return id && this.instance.post("/api/insurance/apply/getInfo", null, {params: {id}}).then(res => {
|
||||
if (res?.data) {
|
||||
const detail = res.data
|
||||
detail.detailList = detail.weightList || []
|
||||
detail.detailList = detail.detailList || []
|
||||
let {farmPicture: picture = "{}"} = detail
|
||||
picture = JSON.parse(picture)
|
||||
return this.detail = {...detail, ...picture}
|
||||
|
||||
@@ -56,7 +56,7 @@ export default {
|
||||
return id && this.instance.post("/api/breed/treatment/getInfo", null, {params: {biochipEarNumber: id}}).then(res => {
|
||||
if (res?.data) {
|
||||
const detail = res.data
|
||||
detail.detailList = detail.immunityList || []
|
||||
detail.detailList = detail.treatmentList || []
|
||||
return this.detail = {...detail}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -14,9 +14,9 @@ export default {
|
||||
methods: {
|
||||
getText(biochipEarNumber) {
|
||||
this.info = {}
|
||||
return this.instance.post("/api/breed/earTag/page", null, { params: { biochipEarNumber } }).then(res => {
|
||||
if (res?.data) {
|
||||
this.info = res.data
|
||||
return this.instance.post("/api/breed/earTag/page", null, {params: {biochipEarNumber, pageSize: 10, pageNum: 1}}).then(res => {
|
||||
if (res?.data?.records) {
|
||||
this.info = res.data.records[0]
|
||||
this.$emit('enter', this.info)
|
||||
}
|
||||
})
|
||||
@@ -27,7 +27,7 @@ export default {
|
||||
|
||||
<template>
|
||||
<section class="AiEartagRemote">
|
||||
<ai-input v-model="value" placeholder="请输入耳标号按回车查询,或扫描耳标号" @keyup.enter.native="getText(value)" />
|
||||
<ai-input v-model="value" placeholder="请输入耳标号按回车查询,或扫描耳标号" @keyup.enter.native="getText(value)"/>
|
||||
</section>
|
||||
|
||||
</template>
|
||||
|
||||
Reference in New Issue
Block a user