问题修改
This commit is contained in:
parent
85dab1ba7f
commit
0e72577081
|
|
@ -774,26 +774,9 @@ export default {
|
|||
async changeTag() {
|
||||
if (!this.queryCodeParams.maId) return;
|
||||
try {
|
||||
const response = await new Promise((resolve, reject)=>
|
||||
{
|
||||
uni.request({
|
||||
url: '/material/ma_machine/getHisByCode',
|
||||
method: 'GET',
|
||||
data: {maId: this.queryCodeParams.maId},
|
||||
success: resolve,
|
||||
fail: reject
|
||||
});
|
||||
}
|
||||
)
|
||||
;
|
||||
|
||||
if (response.data?.data && response.data.data.length > 0) {
|
||||
this.codeData = response.data.data[0];
|
||||
} else {
|
||||
uni.showToast({
|
||||
title: '获取编号信息失败',
|
||||
icon: 'none'
|
||||
});
|
||||
const response = await getDeviceListAPI({'maId': this.queryCodeParams.maId})
|
||||
if (response.data && response.data.length !== 0) {
|
||||
this.codeData = response.data[0]
|
||||
}
|
||||
} catch (error) {
|
||||
console.error("获取编号信息失败", error);
|
||||
|
|
|
|||
Loading…
Reference in New Issue