add:新增查询erp视图接口
This commit is contained in:
@@ -32,4 +32,20 @@ export function groupBag(data) {
|
||||
})
|
||||
}
|
||||
|
||||
export default { add, edit, del, groupBag }
|
||||
export function blurQueryMater(data) {
|
||||
return request({
|
||||
url: 'api/bagrecord/blurQueryMater',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export function blurPerson(data) {
|
||||
return request({
|
||||
url: 'api/bagrecord/blurPerson',
|
||||
method: 'post',
|
||||
data
|
||||
})
|
||||
}
|
||||
|
||||
export default { add, edit, del, groupBag, blurQueryMater, blurPerson }
|
||||
|
||||
@@ -25,9 +25,9 @@
|
||||
>
|
||||
<el-option
|
||||
v-for="item in materialList"
|
||||
:key="item.pcsn"
|
||||
:label="item.material_code"
|
||||
:value="item.material_code"
|
||||
:key="item.BATCH_SEQ"
|
||||
:label="item.ITEM_CODE"
|
||||
:value="item.ITEM_CODE"
|
||||
/>
|
||||
</el-select>
|
||||
</el-form-item>
|
||||
@@ -134,32 +134,29 @@ export default {
|
||||
},
|
||||
blurQueryMater(val) {
|
||||
// 根据单据号查询调用接口获取压制订单内信息
|
||||
const res = [
|
||||
{ 'pcsn': '111', 'material_code': 'XR13II-P-B-20' },
|
||||
{ 'pcsn': '23423', 'material_code': '001' },
|
||||
{ 'pcsn': '444', 'material_code': '002' },
|
||||
{ 'pcsn': '1215552', 'material_code': '003' }
|
||||
]
|
||||
|
||||
this.materialList = res
|
||||
crudBagrecord.blurQueryMater({ 'bill_code': val }).then(res => {
|
||||
this.materialList = res.data
|
||||
})
|
||||
},
|
||||
changePcsn(val) {
|
||||
this.materialList.forEach(item => {
|
||||
if (item.material_code === val) {
|
||||
this.form1.pcsn = item.pcsn
|
||||
if (item.ITEM_CODE === val) {
|
||||
this.form1.pcsn = item.BATCH_SEQ
|
||||
}
|
||||
})
|
||||
},
|
||||
blurPerson(val) {
|
||||
// 调用接口查询对应的人员信息
|
||||
|
||||
this.form1.return_person = val
|
||||
crudBagrecord.blurPerson({ 'return_code': val }).then(res => {
|
||||
this.form1.return_person = res.EMPEE_NAME
|
||||
})
|
||||
},
|
||||
groupBag() {
|
||||
crudBagrecord.groupBag(this.form1).then(res => {
|
||||
this.crud.notify('操作成功!', CRUD.NOTIFICATION_TYPE.SUCCESS)
|
||||
const LODOP = getLodop()
|
||||
const data = res.data
|
||||
debugger
|
||||
data.forEach(item => {
|
||||
debugger
|
||||
|
||||
|
||||
Reference in New Issue
Block a user