Commit a1fd0407 authored by jingnan's avatar jingnan 👀

三期入库明细新增列表接口参数修改为器材编码模糊查询

parent 5fa88e21
...@@ -33,6 +33,10 @@ export default { ...@@ -33,6 +33,10 @@ export default {
basicData: { basicData: {
type: Object, type: Object,
default: () => {} default: () => {}
},
parentTableData: {
type: Object,
default: () => {}
} }
}, },
data() { data() {
...@@ -71,9 +75,9 @@ export default { ...@@ -71,9 +75,9 @@ export default {
} }
if (this.basicData.materialType) { if (this.basicData.materialType) {
val.items.push({ val.items.push({
fieldName: 'inventory.jobResponse.jobOrder.extMaterial.resType2Id', fieldName: 'inventory.jobResponse.jobOrder.extMaterial.resType2.typeCode',
operator: 'EQ', operator: 'LIKE',
value: this.basicData.materialType value: this.parentTableData && this.parentTableData.materialType ? this.parentTableData.materialType.typeCode : this.basicData.materialType && this.basicData.materialType.includes('-') ? this.basicData.materialType.split('-')[1] + '%' : this.basicData.materialType
}) })
} }
val.items.push({ val.items.push({
......
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
v-for="(item,i) in materialTypeOptions" v-for="(item,i) in materialTypeOptions"
:key="i" :key="i"
:label="item.typeName" :label="item.typeName"
:value="item.id" :value="item.value"
/> />
</el-select> </el-select>
</div> </div>
...@@ -20,10 +20,21 @@ export default { ...@@ -20,10 +20,21 @@ export default {
name: 'MaterialType', name: 'MaterialType',
components: {}, components: {},
props: { props: {
form: {}, form: {
type: Object,
default: null
},
itemObj: { itemObj: {
type: Object, type: Object,
default: null default: null
},
typeKey: {
type: String,
default: ''
},
formAttrs: {
type: Object,
default: null
} }
}, },
data() { data() {
...@@ -67,7 +78,14 @@ export default { ...@@ -67,7 +78,14 @@ export default {
getMaterialType(val) { getMaterialType(val) {
this.isFirst = false this.isFirst = false
getParentData({ billTypeCode: val }).then(res => { getParentData({ billTypeCode: val }).then(res => {
this.materialTypeOptions = res.items.content || [] this.materialTypeOptions = res.items.content.map(item => {
if (this.formAttrs && this.formAttrs.layoutType === 'basicInfo_new_sanqiruku') {
item.value = `${item.id}-${item.typeName}`
} else {
item.value = item.id
}
return item
})
}) })
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment