Browse Source

添加扫描提示,扫描成功和扫描失败

pda_nev
李俊城 8 months ago
parent
commit
f25a3eb375
  1. 8
      fe/PDA/api/index.js
  2. 24
      fe/PDA/common/basic.js
  3. 8
      fe/PDA/components/uni-combox/uni-combox.vue
  4. 2
      fe/PDA/mycomponents/common/comMessage.vue
  5. 7
      fe/PDA/mycomponents/wincom/winScanByPack.vue
  6. 6
      fe/PDA/mycomponents/wincom/winScanByProductCode.vue
  7. 5
      fe/PDA/mycomponents/wincom/winScanLocationCode.vue
  8. 10
      fe/PDA/pages/assemble/assembleTransfer.vue
  9. 8
      fe/PDA/pages/cotaing/coatingTransfer.vue
  10. 10
      fe/PDA/pages/injection/injectionTransfer.vue
  11. 20
      fe/PDA/pages/inventory/comTransfer.vue
  12. 12
      fe/PDA/pages/inventory/scrap.vue
  13. 12
      fe/PDA/pages/putaway/purchasePutaway.vue
  14. 7
      fe/PDA/pages/putaway/rapReceipt.vue
  15. 8
      fe/PDA/pages/putaway/semiPutaway.vue
  16. 7
      fe/PDA/pages/query/item.vue
  17. 7
      fe/PDA/pages/query/location.vue
  18. 7
      fe/PDA/pages/record/completeInventoryTransfer.vue
  19. 120
      fe/PDA/pages/record/productionReturn.vue
  20. 75
      fe/PDA/pages/record/productionReturnPack.vue
  21. 5
      fe/PDA/pages/request/coatingIssueRequest.vue
  22. 5
      fe/PDA/pages/request/injectionIssueRequest.vue
  23. 7
      fe/PDA/pages/request/injectionPlanRequest.vue
  24. 5
      fe/PDA/pages/request/kittingIssueRequest.vue
  25. 16
      fe/PDA/pages/request/thirdLocationRequest.vue
  26. 18
      fe/PDA/pages/return/productionReturnFg.vue
  27. 16
      fe/PDA/pages/return/productionReturnRaw.vue
  28. 10
      fe/PDA/pages/return/purchaseReturnRequest.vue
  29. 7
      fe/PDA/pages/return/purchaseReturn_detail.vue
  30. 8
      fe/PDA/pages/return/returnBeforPutaway.vue
  31. 8
      fe/PDA/pages/return/returnToWarehouse.vue
  32. 7
      fe/PDA/pages/spray/sprayCompleteReceive.vue
  33. 9
      fe/PDA/pages/store/deliverRaw.vue
  34. 9
      fe/PDA/pages/store/issueDirect.vue
  35. 7
      fe/PDA/pages/task/assembleIssueJob.vue
  36. 13
      fe/PDA/pages/task/assembleIssueJobDetail.vue
  37. 11
      fe/PDA/pages/task/assembleIssueJobDetailByQty.vue
  38. 7
      fe/PDA/pages/task/coatingIssuleJob.vue
  39. 23
      fe/PDA/pages/task/coatingIssuleJobDetail.vue
  40. 11
      fe/PDA/pages/task/coatingIssuleJobDetailByQty.vue
  41. 11
      fe/PDA/pages/task/countFg.vue
  42. 11
      fe/PDA/pages/task/countFgDetail.vue
  43. 11
      fe/PDA/pages/task/countRaw.vue
  44. 10
      fe/PDA/pages/task/countRawDetail.vue
  45. 11
      fe/PDA/pages/task/deliverBoard_detail.vue
  46. 8
      fe/PDA/pages/task/deliverJis_detail.vue
  47. 7
      fe/PDA/pages/task/injectionIssueJob.vue
  48. 15
      fe/PDA/pages/task/injectionIssueJobDetail.vue
  49. 11
      fe/PDA/pages/task/injectionIssueJobDetailByQty.vue
  50. 3
      fe/PDA/pages/task/kittingIssueJob.vue
  51. 13
      fe/PDA/pages/task/kittingIssueJobDetail.vue
  52. 11
      fe/PDA/pages/task/kittingIssueJobDetailByQty.vue
  53. 8
      fe/PDA/pages/task/receipt.vue
  54. 7
      fe/PDA/pages/task/receipt_detail.vue
  55. 7
      fe/PDA/pages/task/sparePartIssueJob.vue
  56. 14
      fe/PDA/pages/task/sparePartIssueJobDetail.vue
  57. 11
      fe/PDA/pages/task/sparePartIssueJobDetailByQty.vue
  58. 8
      fe/PDA/pages/task/thirdLocationJobDetail.vue
  59. 14
      fe/PDA/pages/task/unProducePickDetail.vue
  60. 10
      fe/PDA/pages/task/unProducePickWipDetail.vue
  61. 7
      fe/PDA/pages/task/unProduceReturnDetail.vue
  62. 9
      fe/PDA/pages/task/unProduceReturnWipDetail.vue
  63. BIN
      fe/PDA/static/video/scan_failed.mp3
  64. BIN
      fe/PDA/static/video/scan_success.mp3
  65. 2
      fe/PDA/uni_modules/wz-select-input/package.json
  66. 12
      fe/PDA/uni_modules/wz-select-popup/components/wz-select-popup/wz-list.vue
  67. 15
      fe/PDA/uni_modules/wz-select-popup/components/wz-select-popup/wz-select-popup.vue

8
fe/PDA/api/index.js

@ -2194,10 +2194,10 @@ export const getPoNumberByPackingCode = (toPackingCode) => promise(
}) })
//获取客户信息 //获取客户信息
export const getCustomerList = (id) => request( export const getCustomerList = (params) => request(
devUrl + "/api/pda/customer/get-all/", { // devUrl + "/api/pda/customer/get-list/", { //
data: {}, data: params,
method: "get" method: "post"
}); });

24
fe/PDA/common/basic.js

@ -401,6 +401,30 @@ export function scanErrorAudio() {
}); });
} }
export function scanSuccessAudio() {
var music = null;
music = uni.createInnerAudioContext(); //创建播放器对象
music.src = "../../static/video/scan_success.mp3";
music.volume = 1;
music.play(); //执行播放
music.onEnded(() => {
//播放结束
music = null;
});
}
export function scanFailedAudio() {
var music = null;
music = uni.createInnerAudioContext(); //创建播放器对象
music.src = "../../static/video/scan_failed.mp3";
music.volume = 1;
music.play(); //执行播放
music.onEnded(() => {
//播放结束
music = null;
});
}
export function newMessageAudio() { export function newMessageAudio() {
var music = null; var music = null;

8
fe/PDA/components/uni-combox/uni-combox.vue

@ -87,9 +87,10 @@
} }
}, },
filterCandidates() { filterCandidates() {
return this.candidates.filter((item) => { return this.candidates;
return item.toString().indexOf(this.inputVal) > -1 // return this.candidates.filter((item) => {
}) // return item.toString().indexOf(this.inputVal) > -1
// })
}, },
filterCandidatesLength() { filterCandidatesLength() {
return this.filterCandidates.length return this.filterCandidates.length
@ -173,6 +174,7 @@
font-size: 16px; font-size: 16px;
height: 22px; height: 22px;
line-height: 22px; line-height: 22px;
padding-left: 20rpx;
} }
.uni-combox__input-arrow { .uni-combox__input-arrow {

2
fe/PDA/mycomponents/common/comMessage.vue

@ -68,7 +68,7 @@
// //
showScanMessage(content) { showScanMessage(content) {
this.openMessage(content, 'scan'); this.openMessage(content, 'scan');
scanErrorAudio(); // // scanErrorAudio(); //
}, },
// //

7
fe/PDA/mycomponents/wincom/winScanByPack.vue

@ -32,6 +32,10 @@
getInventoryLabel getInventoryLabel
} from '@/api/index.js'; } from '@/api/index.js';
import {
scanFailedAudio
} from '@/common/basic.js';
export default { export default {
name: 'winScanByPack', name: 'winScanByPack',
components: { components: {
@ -85,10 +89,13 @@
uni.hideLoading(); uni.hideLoading();
this.callBack(); this.callBack();
} else { } else {
scanFailedAudio()
this.showMessage('标签【' + result.data.code + '】,在标签表中不存在') this.showMessage('标签【' + result.data.code + '】,在标签表中不存在')
uni.hideLoading(); uni.hideLoading();
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.showMessage(err.message) this.showMessage(err.message)
}); });

6
fe/PDA/mycomponents/wincom/winScanByProductCode.vue

@ -32,6 +32,10 @@
getitems, getitems,
getMesBarCode getMesBarCode
} from '@/api/index.js'; } from '@/api/index.js';
import {
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js';
export default { export default {
name: 'winScanByPack', name: 'winScanByPack',
@ -95,10 +99,12 @@
}; };
this.callBack(); this.callBack();
} else { } else {
scanFailedAudio()
this.losefocus(); this.losefocus();
this.showMessage('单件码【' + result.data.code + '】,不存在') this.showMessage('单件码【' + result.data.code + '】,不存在')
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.showMessage(err.message) this.showMessage(err.message)
}); });

5
fe/PDA/mycomponents/wincom/winScanLocationCode.vue

@ -22,6 +22,10 @@
import { import {
locations locations
} from '@/api/index.js'; } from '@/api/index.js';
import {
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js';
import winComScan from '@/mycomponents/wincom/winComScan.vue' import winComScan from '@/mycomponents/wincom/winComScan.vue'
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
export default { export default {
@ -79,6 +83,7 @@
this.locationInfo=res this.locationInfo=res
this.callBack() this.callBack()
} else { } else {
scanFailedAudio()
this.showMessage('未查找到库位【' + code + '】'); this.showMessage('未查找到库位【' + code + '】');
this.locationInfo=null this.locationInfo=null
} }

10
fe/PDA/pages/assemble/assembleTransfer.vue

@ -84,7 +84,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -196,6 +198,7 @@
}) })
if (datas.length > 0) { if (datas.length > 0) {
scanFailedAudio()
showConfirmMsg('物料【' + code + '】已经存在,是否要重新扫描?', confirm => { showConfirmMsg('物料【' + code + '】已经存在,是否要重新扫描?', confirm => {
if (confirm) { if (confirm) {
that.itemList.forEach((r, i) => { that.itemList.forEach((r, i) => {
@ -222,6 +225,7 @@
this.itemList.unshift(item); this.itemList.unshift(item);
this.$refs.scanPackPopup.closeScanPopup() this.$refs.scanPackPopup.closeScanPopup()
scanSuccessAudio()
} }
}, },
@ -258,18 +262,22 @@
if (res) { if (res) {
// //
if (res.type == 1 || res.type == 6 || res.type == 13) { if (res.type == 1 || res.type == 6 || res.type == 13) {
scanFailedAudio()
that.showMessage("目标库位不可以是待检、隔离、在途库位类型"); that.showMessage("目标库位不可以是待检、隔离、在途库位类型");
} else { } else {
scanSuccessAudio()
that.toLocationCode = code; that.toLocationCode = code;
that.toLocationErpCode = res.erpLocationCode; that.toLocationErpCode = res.erpLocationCode;
} }
} else { } else {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
that.showMessage('目标库位【' + code + '】不存在'); that.showMessage('目标库位【' + code + '】不存在');
this.$refs.location.clearLocation() this.$refs.location.clearLocation()
this.locationGotFocus = true; this.locationGotFocus = true;
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
this.locationGotFocus = true; this.locationGotFocus = true;
that.showMessage(err.message); that.showMessage(err.message);

8
fe/PDA/pages/cotaing/coatingTransfer.vue

@ -84,7 +84,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -259,18 +261,22 @@
if (res) { if (res) {
// //
if (res.type == 1 || res.type == 6 || res.type == 13) { if (res.type == 1 || res.type == 6 || res.type == 13) {
scanFailedAudio()
that.showMessage("目标库位不可以是待检、隔离、在途库位类型"); that.showMessage("目标库位不可以是待检、隔离、在途库位类型");
} else { } else {
scanSuccessAudio()
that.toLocationCode = code; that.toLocationCode = code;
that.toLocationErpCode = res.erpLocationCode; that.toLocationErpCode = res.erpLocationCode;
} }
} else { } else {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
that.showMessage('目标库位【' + code + '】不存在'); that.showMessage('目标库位【' + code + '】不存在');
this.$refs.location.clearLocation() this.$refs.location.clearLocation()
this.locationGotFocus = true; this.locationGotFocus = true;
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
this.locationGotFocus = true; this.locationGotFocus = true;
that.showMessage(err.message); that.showMessage(err.message);

10
fe/PDA/pages/injection/injectionTransfer.vue

@ -84,7 +84,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -197,6 +199,7 @@
}) })
if (datas.length > 0) { if (datas.length > 0) {
scanFailedAudio()
showConfirmMsg('物料【' + code + '】已经存在,是否要重新扫描?', confirm => { showConfirmMsg('物料【' + code + '】已经存在,是否要重新扫描?', confirm => {
if (confirm) { if (confirm) {
that.itemList.forEach((r, i) => { that.itemList.forEach((r, i) => {
@ -223,6 +226,7 @@
this.itemList.unshift(item); this.itemList.unshift(item);
this.$refs.scanPackPopup.closeScanPopup() this.$refs.scanPackPopup.closeScanPopup()
scanSuccessAudio()
} }
}, },
@ -259,12 +263,15 @@
if (res) { if (res) {
// //
if (res.type == 1 || res.type == 6 || res.type == 13) { if (res.type == 1 || res.type == 6 || res.type == 13) {
scanFailedAudio()
that.showMessage("目标库位不可以是待检、隔离、在途库位类型"); that.showMessage("目标库位不可以是待检、隔离、在途库位类型");
} else { } else {
scanSuccessAudio()
that.toLocationCode = code; that.toLocationCode = code;
that.toLocationErpCode = res.erpLocationCode; that.toLocationErpCode = res.erpLocationCode;
} }
} else { } else {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
that.showMessage('目标库位【' + code + '】不存在'); that.showMessage('目标库位【' + code + '】不存在');
this.$refs.location.clearLocation() this.$refs.location.clearLocation()
@ -272,6 +279,7 @@
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
this.locationGotFocus = true; this.locationGotFocus = true;
that.showMessage(err.message); that.showMessage(err.message);

20
fe/PDA/pages/inventory/comTransfer.vue

@ -45,7 +45,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -140,6 +142,7 @@
}) })
if (datas.length > 0) { if (datas.length > 0) {
scanFailedAudio()
showConfirmMsg('箱码【' + code + '】已经存在,是否要重新扫描?', confirm => { showConfirmMsg('箱码【' + code + '】已经存在,是否要重新扫描?', confirm => {
if (confirm) { if (confirm) {
that.itemList.forEach((r, i) => { that.itemList.forEach((r, i) => {
@ -173,18 +176,23 @@
.then(res => { .then(res => {
try { try {
if (res.totalCount === 0) { if (res.totalCount === 0) {
scanFailedAudio()
this.showMessage('箱码【' + packingCode + '】在【原料库、成品库、半成品库】未查询到库存信息'); this.showMessage('箱码【' + packingCode + '】在【原料库、成品库、半成品库】未查询到库存信息');
} else if (res.totalCount === 1) { } else if (res.totalCount === 1) {
scanSuccessAudio()
this.pushItem(res.items[0]); this.pushItem(res.items[0]);
} else { } else {
scanSuccessAudio()
this.$refs.balanceItems.openPopup(res.items); this.$refs.balanceItems.openPopup(res.items);
} }
} catch (e) { } catch (e) {
scanFailedAudio()
this.showMessage(e.message); this.showMessage(e.message);
} }
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showMessage(err.message); this.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });
@ -195,20 +203,24 @@
if (this.itemList.length == 0) { if (this.itemList.length == 0) {
this.locationErpCode = balanceItem.locationErpCode; this.locationErpCode = balanceItem.locationErpCode;
this.itemList.unshift(item); this.itemList.unshift(item);
scanSuccessAudio()
} else { } else {
if (this.transferType == 'Transfer_Inside') // if (this.transferType == 'Transfer_Inside') //
{ {
if (this.locationErpCode != balanceItem.locationErpCode) { if (this.locationErpCode != balanceItem.locationErpCode) {
scanFailedAudio()
this.showMessage('箱码【' + balanceItem.packingCode + '】的ERP储位【' + balanceItem.locationErpCode + this.showMessage('箱码【' + balanceItem.packingCode + '】的ERP储位【' + balanceItem.locationErpCode +
'】与默认的ERP储位[' + this '】与默认的ERP储位[' + this
.locationErpCode + .locationErpCode +
'】不是同一ERP储位,不可以进行储位内移库'); '】不是同一ERP储位,不可以进行储位内移库');
} else { } else {
this.itemList.unshift(item); this.itemList.unshift(item);
scanSuccessAudio()
} }
} else if (this.transferType == 'Transfer_Area') // } else if (this.transferType == 'Transfer_Area') //
{ {
this.itemList.unshift(item); this.itemList.unshift(item);
scanSuccessAudio()
} }
} }
}, },
@ -279,6 +291,7 @@
let that = this; let that = this;
locations(code).then(res => { locations(code).then(res => {
if (res == null) { if (res == null) {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
that.showMessage('目标库位【' + code + '】不存在'); that.showMessage('目标库位【' + code + '】不存在');
this.$refs.location.clearLocation() this.$refs.location.clearLocation()
@ -290,12 +303,14 @@
that.showMessage('目标库位的ERP储位【' + res.erpLocationCode + '】与【' + this that.showMessage('目标库位的ERP储位【' + res.erpLocationCode + '】与【' + this
.locationErpCode + .locationErpCode +
'】不是同一ERP储位,请重新扫描目标库位'); '】不是同一ERP储位,请重新扫描目标库位');
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
that.$refs.location.clearLocation(); that.$refs.location.clearLocation();
this.locationGotFocus = true; this.locationGotFocus = true;
} else { } else {
that.toLocationCode = code; that.toLocationCode = code;
that.toLocationErpCode = res.erpLocationCode; that.toLocationErpCode = res.erpLocationCode;
scanSuccessAudio()
} }
} else // } else //
@ -314,14 +329,17 @@
that.toLocationCode = '' that.toLocationCode = ''
that.$refs.location.clearLocation(); that.$refs.location.clearLocation();
this.locationGotFocus = true; this.locationGotFocus = true;
scanFailedAudio()
} else { } else {
that.toLocationCode = res.code; that.toLocationCode = res.code;
that.toLocationErpCode = res.erpLocationCode; that.toLocationErpCode = res.erpLocationCode;
scanSuccessAudio()
} }
} }
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
this.locationGotFocus = true; this.locationGotFocus = true;
that.showMessage(err.message); that.showMessage(err.message);

12
fe/PDA/pages/inventory/scrap.vue

@ -47,7 +47,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import VUE from 'vue' import VUE from 'vue'
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -130,6 +132,7 @@
}) })
if (items.length > 0) { if (items.length > 0) {
scanFailedAudio()
this.showRescanMessage('箱码【' + code + '】已经存在,是否要重新扫描?'); this.showRescanMessage('箱码【' + code + '】已经存在,是否要重新扫描?');
// showConfirmMsg('' + code + ',?', confirm => { // showConfirmMsg('' + code + ',?', confirm => {
// if (confirm) { // if (confirm) {
@ -179,6 +182,7 @@
}; };
getBalancesByFilter(params).then(res => { getBalancesByFilter(params).then(res => {
if (res.totalCount == 0) { if (res.totalCount == 0) {
scanFailedAudio()
this.showScanMessage('箱码【' + code + '】在【原料库】未查询到库存信息'); this.showScanMessage('箱码【' + code + '】在【原料库】未查询到库存信息');
} else if (res.totalCount == 1) { } else if (res.totalCount == 1) {
let balanceItem = res.items[0]; let balanceItem = res.items[0];
@ -186,11 +190,14 @@
let item = this.createItem(balanceItem); let item = this.createItem(balanceItem);
that.itemList.unshift(item) that.itemList.unshift(item)
that.scanPopupGetFocus(); that.scanPopupGetFocus();
scanSuccessAudio()
} else { } else {
scanSuccessAudio()
this.$refs.balanceItems.openPopup(res.items); this.$refs.balanceItems.openPopup(res.items);
} }
uni.hideLoading(); uni.hideLoading();
}).catch(ex => { }).catch(ex => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
that.showMessage(ex.message); that.showMessage(ex.message);
}); });
@ -267,15 +274,18 @@
let that = this; let that = this;
locations(code).then(res => { locations(code).then(res => {
if (res) { if (res) {
scanSuccessAudio()
that.toLocationCode = res.code; that.toLocationCode = res.code;
that.toLocationErpCode = res.erpLocationCode; that.toLocationErpCode = res.erpLocationCode;
} else { } else {
scanFailedAudio()
that.toLocationCode = ''; that.toLocationCode = '';
that.toLocationErpCode = ''; that.toLocationErpCode = '';
that.showMessage('目标库位不存在'); that.showMessage('目标库位不存在');
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocationCode = ''; that.toLocationCode = '';
that.toLocationErpCode = ''; that.toLocationErpCode = '';
that.showMessage(err.message); that.showMessage(err.message);

12
fe/PDA/pages/putaway/purchasePutaway.vue

@ -87,7 +87,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -240,6 +242,7 @@
let balanceRes = await getBalancesByFilterAsync(params); let balanceRes = await getBalancesByFilterAsync(params);
if (balanceRes.totalCount === 0) { if (balanceRes.totalCount === 0) {
scanFailedAudio()
that.showScanMessage('箱码【' + packingCode + '】在【待检库】未查询到库存状态为【合格】的库存信息'); that.showScanMessage('箱码【' + packingCode + '】在【待检库】未查询到库存状态为【合格】的库存信息');
} else if (balanceRes.totalCount === 1) { } else if (balanceRes.totalCount === 1) {
let balanceItem = balanceRes.items[0]; let balanceItem = balanceRes.items[0];
@ -268,6 +271,7 @@
//ERP //ERP
let purchaseDetail = await getPurchaseDetailNewAsync(balanceItem.itemCode, fromTopPackingCode); let purchaseDetail = await getPurchaseDetailNewAsync(balanceItem.itemCode, fromTopPackingCode);
if (purchaseDetail.error) { if (purchaseDetail.error) {
scanFailedAudio()
that.showScanMessage(purchaseDetail.error.message); that.showScanMessage(purchaseDetail.error.message);
} else { } else {
that.createBalanceItem(balanceItem, purchaseDetail); that.createBalanceItem(balanceItem, purchaseDetail);
@ -355,6 +359,7 @@
let newLabel = this.createLabel(balanceItem, purchaseDetail); let newLabel = this.createLabel(balanceItem, purchaseDetail);
this.addLabel(itemInfo, newLabel); this.addLabel(itemInfo, newLabel);
this.scanPopupGetFocus(); this.scanPopupGetFocus();
scanSuccessAudio()
}, },
createLabel(balanceItem, purchaseDetail) { createLabel(balanceItem, purchaseDetail) {
@ -472,25 +477,30 @@
let that = this; let that = this;
locations(code).then(res => { locations(code).then(res => {
if (res == null) { if (res == null) {
scanFailedAudio()
that.showMessage('目标库位【' + code + '】不存在'); that.showMessage('目标库位【' + code + '】不存在');
this.$refs.comCollapseLocation.clearLocation(); this.$refs.comCollapseLocation.clearLocation();
} else { } else {
if (res.type != 2) { if (res.type != 2) {
scanFailedAudio()
this.showMessage('目标库位必须是原材料库') this.showMessage('目标库位必须是原材料库')
this.$refs.comCollapseLocation.clearLocation(); this.$refs.comCollapseLocation.clearLocation();
} else { } else {
if (that.recommendErpLocationCode != res.erpLocationCode) { if (that.recommendErpLocationCode != res.erpLocationCode) {
scanFailedAudio()
that.showMessage('目标库位的ERP储位【' + res.erpLocationCode + '】与【' + this that.showMessage('目标库位的ERP储位【' + res.erpLocationCode + '】与【' + this
.recommendErpLocationCode + .recommendErpLocationCode +
'】不是同一ERP储位,请重新扫描'); '】不是同一ERP储位,请重新扫描');
this.$refs.comCollapseLocation.clearLocation(); this.$refs.comCollapseLocation.clearLocation();
} else { } else {
scanSuccessAudio()
this.location = res; this.location = res;
} }
} }
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.location = null; that.location = null;
that.showMessage(err.message); that.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();

7
fe/PDA/pages/putaway/rapReceipt.vue

@ -52,7 +52,9 @@
maxPageSize, maxPageSize,
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
export default { export default {
@ -241,8 +243,10 @@
.then(res => { .then(res => {
if (res != null) { if (res != null) {
if (res.type != 2) { if (res.type != 2) {
scanFailedAudio()
this.showMessage('目标库位必须是【原材料库】') this.showMessage('目标库位必须是【原材料库】')
} else { } else {
scanSuccessAudio()
this.location = res; this.location = res;
} }
} else { } else {
@ -251,6 +255,7 @@
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showMessage(err.message); this.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });

8
fe/PDA/pages/putaway/semiPutaway.vue

@ -60,7 +60,9 @@
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption, getRemoveOption,
getLocationTypeDesc getLocationTypeDesc,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -354,17 +356,21 @@
let that = this; let that = this;
locations(code).then(res => { locations(code).then(res => {
if (res == null) { if (res == null) {
scanFailedAudio()
that.showMessage('目标库位【' + code + '】不存在'); that.showMessage('目标库位【' + code + '】不存在');
that.$refs.comToLocation.clearLocation(); that.$refs.comToLocation.clearLocation();
} else { } else {
if (res.type != 3) { if (res.type != 3) {
scanFailedAudio()
this.showMessage('目标库位必须是【半成品库】') this.showMessage('目标库位必须是【半成品库】')
} else { } else {
scanSuccessAudio()
this.toLocation = res; this.toLocation = res;
} }
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
that.showMessage(err.message); that.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();

7
fe/PDA/pages/query/item.vue

@ -51,7 +51,9 @@
import { import {
getItemTypeStyle, getItemTypeStyle,
getItemStatusDesc, getItemStatusDesc,
goHome goHome,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comItem from '@/mycomponents/coms/query/comItem.vue' import comItem from '@/mycomponents/coms/query/comItem.vue'
import comSummary from '@/mycomponents/coms/query/comSummary.vue' import comSummary from '@/mycomponents/coms/query/comSummary.vue'
@ -160,16 +162,19 @@
setTimeout(() => { setTimeout(() => {
getitems(code).then((res) => { getitems(code).then((res) => {
if (res != null) { if (res != null) {
scanSuccessAudio()
this.closeScanPopup(); this.closeScanPopup();
this.itemCode = code; this.itemCode = code;
this.itemDetail = res; this.itemDetail = res;
this.getContentByTab(this.tabIndex) this.getContentByTab(this.tabIndex)
} else { } else {
scanFailedAudio()
this.showMessage('未查找到ERP料号【' + code + '】'); this.showMessage('未查找到ERP料号【' + code + '】');
this.itemCode = ""; this.itemCode = "";
} }
uni.hideLoading(); uni.hideLoading();
}).catch((err) => { }).catch((err) => {
scanFailedAudio()
this.showMessage(err.message); this.showMessage(err.message);
this.itemCode = ""; this.itemCode = "";
uni.hideLoading(); uni.hideLoading();

7
fe/PDA/pages/query/location.vue

@ -43,7 +43,9 @@
maxPageSize, maxPageSize,
goHome, goHome,
getInventoryTypeStyle, getInventoryTypeStyle,
getInventoryStatusDesc getInventoryStatusDesc,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comLocation from '@/mycomponents/coms/query/comLocation.vue' import comLocation from '@/mycomponents/coms/query/comLocation.vue'
@ -141,6 +143,7 @@
}); });
locations(code).then((res) => { locations(code).then((res) => {
if (res != null) { if (res != null) {
scanSuccessAudio()
this.closeScanPopup(); this.closeScanPopup();
this.locationCode = code; this.locationCode = code;
this.locationDetail = res this.locationDetail = res
@ -149,11 +152,13 @@
this.locationDetail.locationErpCode = res.erpLocationCode this.locationDetail.locationErpCode = res.erpLocationCode
this.getContentByTab(this.tabIndex); this.getContentByTab(this.tabIndex);
} else { } else {
scanFailedAudio()
this.showMessage('未查找到库位【' + code + '】'); this.showMessage('未查找到库位【' + code + '】');
this.locationCode = '' this.locationCode = ''
} }
uni.hideLoading(); uni.hideLoading();
}).catch((err) => { }).catch((err) => {
scanFailedAudio()
this.showMessage(err.message); this.showMessage(err.message);
this.locationCode = ''; this.locationCode = '';
uni.hideLoading(); uni.hideLoading();

7
fe/PDA/pages/record/completeInventoryTransfer.vue

@ -98,7 +98,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -301,16 +303,19 @@
let that = this; let that = this;
locations(code).then(res => { locations(code).then(res => {
if (res == null) { if (res == null) {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
that.showMessage('目标库位【' + code + '】不存在'); that.showMessage('目标库位【' + code + '】不存在');
this.$refs.location.clearLocation() this.$refs.location.clearLocation()
this.locationGotFocus = true; this.locationGotFocus = true;
} else { } else {
scanSuccessAudio()
that.toLocationCode = code; that.toLocationCode = code;
that.toLocationErpCode = res.erpLocationCode; that.toLocationErpCode = res.erpLocationCode;
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
this.locationGotFocus = true; this.locationGotFocus = true;
that.showMessage(err.message); that.showMessage(err.message);

120
fe/PDA/pages/record/productionReturn.vue

@ -1,8 +1,20 @@
<template> <template>
<page-meta root-font-size="18px"></page-meta> <page-meta root-font-size="18px"></page-meta>
<view class=""> <view class="" style="display: flex; flex-direction: column;">
<win-blank-view @goScan='openScanPopup' v-if="allDataList.length==0"></win-blank-view> <win-blank-view @goScan='openScanPopup' v-if="allDataList.length==0"></win-blank-view>
<scroll-view scroll-y class="scroll-detail" style="margin-top: 10rpx;padding-bottom:100px" >
<view class="uni-flex uni-row " style="align-items: center; justify-content: space-between;"
v-if="allDataList.length>0">
<view class="" style=" font-size: 35rpx; margin-left: 20rpx; font-weight: bold;">
退货客户 : {{customerCode}}
</view>
<view class="" style="margin-right: 20rpx; margin-top: 10rpx;">
<button type="primary" @click="seletCustomer" size="mini"> 选择客户 </button>
</view>
</view>
<scroll-view scroll-y class="scroll-detail" style="margin-top: 10rpx;padding-bottom:100px">
<view class="detail-list " v-for="(item, index) in allDataList" :key="index"> <view class="detail-list " v-for="(item, index) in allDataList" :key="index">
<view class="detail-content"> <view class="detail-content">
<view class="" style=""> <view class="" style="">
@ -64,6 +76,7 @@
</div> </div>
<win-scan-button @goScan='openScanPopup' v-if="allDataList.length>0"></win-scan-button> <win-scan-button @goScan='openScanPopup' v-if="allDataList.length>0"></win-scan-button>
<winScanByProductCode ref="scanPackPopup" title="单件码" @getScanResult='getScanResult'></winScanByProductCode> <winScanByProductCode ref="scanPackPopup" title="单件码" @getScanResult='getScanResult'></winScanByProductCode>
<wz-select-popup ref="wzSelectPopup" @select="selectCheckbox" title="选择客户" :isShowItem="false" />
<com-message ref="comMessage" @afterCloseScanMessage='closeScanMessage' @afterRescanMessage='afterRescan' <com-message ref="comMessage" @afterCloseScanMessage='closeScanMessage' @afterRescanMessage='afterRescan'
@afterCloseCommitMessage='closeCommitMessage'> @afterCloseCommitMessage='closeCommitMessage'>
</com-message> </com-message>
@ -76,12 +89,15 @@
getBalancesByFilterAsync, getBalancesByFilterAsync,
getWipListAsync, getWipListAsync,
customerReturnCommit, customerReturnCommit,
getCustomerList
} from '@/api/index.js'; } from '@/api/index.js';
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -119,7 +135,7 @@
return { return {
options: [], options: [],
currentItem: {}, currentItem: {},
toLocationInfo:{}, toLocationInfo: {},
toLocationCode: "", toLocationCode: "",
allCount: 0, allCount: 0,
allDataList: [], allDataList: [],
@ -128,6 +144,13 @@
old: { old: {
scrollTop: 0 scrollTop: 0
}, },
customerList: ['客户1', '客户2'],
customerCode: '',
userForm: {
names: [],
values: [],
origin: []
}
}; };
}, },
props: { props: {
@ -168,7 +191,7 @@
if (res) { if (res) {
this.allDataList.splice(index, 1); this.allDataList.splice(index, 1);
this.allCount = this.allDataList.length; this.allCount = this.allDataList.length;
var title =this.allCount>0?"客户退货单件码"+"("+this.allCount+")":"客户退货单件码" var title = this.allCount > 0 ? "客户退货单件码" + "(" + this.allCount + ")" : "客户退货单件码"
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
title: title title: title
}) })
@ -177,6 +200,47 @@
}) })
}, },
seletCustomer() {
this.$refs.wzSelectPopup.open({
mode: 'radio', //radio checkbox
// dataList:[], //dataList使proxyConfig
selected: this.userForm.values, //
proxyConfig: { //
reqFun: this.reqGetList, //,Promise.resolve([])
localPaging: false //
},
search: {
type: 'remote', //local | remote
},
fields: {
label: 'name',
value: 'code'
}
})
},
reqGetList(data) {
var params = {
condition: {
filters: [{
logic: "And",
column: "code",
action: "Like",
value: data.searchValue
}]
},
Sorting: "",
SkipCount: (data.pageIndex-1)*data.pageSize,
MaxResultCount: data.pageSize
}
return getCustomerList(params);
},
selectCheckbox(mode, resultData){
console.log(mode, resultData)
this.customerCode =resultData.code
},
getScanResult(result) { getScanResult(result) {
var filterItem = this.allDataList.filter(res => { var filterItem = this.allDataList.filter(res => {
if (res.itemCode == result.itemCode) { if (res.itemCode == result.itemCode) {
@ -200,7 +264,7 @@
this.allDataList.unshift(item) this.allDataList.unshift(item)
this.allCount = this.allDataList.length; this.allCount = this.allDataList.length;
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
title: "客户退货单件码"+"("+this.allCount+")" title: "客户退货单件码" + "(" + this.allCount + ")"
}) })
this.$forceUpdate(); this.$forceUpdate();
@ -216,15 +280,18 @@
locations(locationCode).then(res => { locations(locationCode).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res) { if (res) {
this.toLocationInfo =res; this.toLocationInfo = res;
this.toLocationCode = res.code this.toLocationCode = res.code
scanSuccessAudio()
} else { } else {
scanFailedAudio()
this.showMessage('目标库位【' + locationCode + '】不存在'); this.showMessage('目标库位【' + locationCode + '】不存在');
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.toLocationInfo={} this.toLocationInfo = {}
this.toLocationCode = "" this.toLocationCode = ""
this.showMessage(err.message); this.showMessage(err.message);
@ -245,9 +312,16 @@
this.showMessage('请扫描目标库位'); this.showMessage('请扫描目标库位');
return; return;
} }
var checkQtyItem =this.checkQty()
if(checkQtyItem!=undefined){ if (this.customerCode == "") {
this.showMessage("【"+checkQtyItem.itemCode+'】数量为0,退货数量必须大于0'); this.showMessage('请选择客户');
return;
}
var checkQtyItem = this.checkQty()
if (checkQtyItem != undefined) {
this.showMessage("【" + checkQtyItem.itemCode + '】数量为0,退货数量必须大于0');
return; return;
} }
@ -257,7 +331,7 @@
}); });
let params = this.setSubmitParam(); let params = this.setSubmitParam();
console.log( JSON.stringify(params) ) console.log(JSON.stringify(params))
customerReturnCommit(params) customerReturnCommit(params)
.then(res => { .then(res => {
uni.hideLoading(); uni.hideLoading();
@ -272,12 +346,12 @@
}); });
}, },
checkQty(){ checkQty() {
var isCheck =true; var isCheck = true;
var result =undefined var result = undefined
for (let item of this.allDataList) { for (let item of this.allDataList) {
if(item.qty==0){ if (item.qty == 0) {
result =item result = item
break break
} }
} }
@ -287,6 +361,7 @@
setSubmitParam() { setSubmitParam() {
let item = { let item = {
worker: localStorage.userName_CN == "" ? localStorage.userName : localStorage.userName_CN, worker: localStorage.userName_CN == "" ? localStorage.userName : localStorage.userName_CN,
customerCode: this.customerCode,
details: [] details: []
} }
this.allDataList.forEach(res => { this.allDataList.forEach(res => {
@ -297,10 +372,10 @@
uom: res.uom, uom: res.uom,
qty: res.qty, qty: res.qty,
stdPackQty: res.stdPackQty, stdPackQty: res.stdPackQty,
toLocationCode:this.toLocationCode, toLocationCode: this.toLocationCode,
toLocationArea:this.toLocationInfo.areaCode, toLocationArea: this.toLocationInfo.areaCode,
toLocationGroup:this.toLocationInfo.locationGroupCode, toLocationGroup: this.toLocationInfo.locationGroupCode,
toLocationErpCode:this.toLocationInfo.erpLocationCode toLocationErpCode: this.toLocationInfo.erpLocationCode
} }
item.details.push(detail) item.details.push(detail)
}) })
@ -404,10 +479,11 @@
clearInfo() { clearInfo() {
this.allDataList = []; this.allDataList = [];
this.toLocationInfo={} this.toLocationInfo = {}
this.toLocationCode = ""; this.toLocationCode = "";
this.allCount = 0; this.allCount = 0;
this.loadingType = "" this.loadingType = ""
this.customerCode = ""
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
title: "客户退货单件码" title: "客户退货单件码"
}) })

75
fe/PDA/pages/record/productionReturnPack.vue

@ -2,6 +2,15 @@
<page-meta root-font-size="18px"></page-meta> <page-meta root-font-size="18px"></page-meta>
<view class=""> <view class="">
<win-blank-view @goScan='openScanPopup' v-if="allDataList.length==0"></win-blank-view> <win-blank-view @goScan='openScanPopup' v-if="allDataList.length==0"></win-blank-view>
<view class="uni-flex uni-row " style="align-items: center; justify-content: space-between;"
v-if="allDataList.length>0">
<view class="" style=" font-size: 35rpx; margin-left: 20rpx; font-weight: bold;">
退货客户 : {{customerCode}}
</view>
<view class="" style="margin-right: 20rpx; margin-top: 10rpx;">
<button type="primary" @click="seletCustomer" size="mini"> 选择客户 </button>
</view>
</view>
<scroll-view scroll-y class="scroll-detail" style="margin-top: 10rpx;padding-bottom:100px"> <scroll-view scroll-y class="scroll-detail" style="margin-top: 10rpx;padding-bottom:100px">
<view class="detail-list " v-for="(item, index) in allDataList" :key="index"> <view class="detail-list " v-for="(item, index) in allDataList" :key="index">
<view class="detail-content"> <view class="detail-content">
@ -68,6 +77,7 @@
</div> </div>
<win-scan-button @goScan='openScanPopup' v-if="allDataList.length>0"></win-scan-button> <win-scan-button @goScan='openScanPopup' v-if="allDataList.length>0"></win-scan-button>
<win-scan-by-pack ref="scanPopup" @getScanResult='getScanResult'></win-scan-by-pack> <win-scan-by-pack ref="scanPopup" @getScanResult='getScanResult'></win-scan-by-pack>
<wz-select-popup ref="wzSelectPopup" @select="selectCheckbox" title="选择客户" :isShowItem="false" />
<com-message ref="comMessage" @afterCloseScanMessage='closeScanMessage' @afterRescanMessage='afterRescan' <com-message ref="comMessage" @afterCloseScanMessage='closeScanMessage' @afterRescanMessage='afterRescan'
@afterCloseCommitMessage='closeCommitMessage'> @afterCloseCommitMessage='closeCommitMessage'>
</com-message> </com-message>
@ -80,12 +90,15 @@
getBalancesByFilterAsync, getBalancesByFilterAsync,
getWipListAsync, getWipListAsync,
customerReturnCommit, customerReturnCommit,
getCustomerList
} from '@/api/index.js'; } from '@/api/index.js';
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -132,6 +145,12 @@
old: { old: {
scrollTop: 0 scrollTop: 0
}, },
customerCode: '',
userForm: {
names: [],
values: [],
origin: []
}
}; };
}, },
props: { props: {
@ -176,6 +195,46 @@
} }
}) })
}, },
seletCustomer() {
this.$refs.wzSelectPopup.open({
mode: 'radio', //radio checkbox
// dataList:[], //dataList使proxyConfig
selected: this.userForm.values, //
proxyConfig: { //
reqFun: this.reqGetList, //,Promise.resolve([])
localPaging: false //
},
search: {
type: 'remote', //local | remote
},
fields: {
label: 'name',
value: 'code'
}
})
},
reqGetList(data) {
var params = {
condition: {
filters: [{
logic: "And",
column: "code",
action: "Like",
value: data.searchValue
}]
},
Sorting: "",
SkipCount: (data.pageIndex-1)*data.pageSize,
MaxResultCount: data.pageSize
}
return getCustomerList(params);
},
selectCheckbox(mode, resultData){
console.log(mode, resultData)
this.customerCode =resultData.code
},
getScanResult(result) { getScanResult(result) {
var resultData = result.data var resultData = result.data
@ -185,6 +244,7 @@
} }
}) })
if (filterItem.length > 0) { if (filterItem.length > 0) {
scanFailedAudio()
this.showMessage("箱码【" + filterItem[0].packingCode + "】已经扫描") this.showMessage("箱码【" + filterItem[0].packingCode + "】已经扫描")
return; return;
} }
@ -207,6 +267,7 @@
}) })
this.$forceUpdate(); this.$forceUpdate();
scanSuccessAudio()
}, },
@ -221,15 +282,18 @@
uni.hideLoading(); uni.hideLoading();
if (res) { if (res) {
if (res.type == 2) { if (res.type == 2) {
scanSuccessAudio()
this.toLocationInfo = res; this.toLocationInfo = res;
this.toLocationCode = res.code this.toLocationCode = res.code
} else { } else {
scanFailedAudio()
this.toLocationInfo = {} this.toLocationInfo = {}
this.toLocationCode = "" this.toLocationCode = ""
this.$refs.comCollapseLocation.clearLocation(); this.$refs.comCollapseLocation.clearLocation();
this.showMessage('目标库位必须是原料库位类型'); this.showMessage('目标库位必须是原料库位类型');
} }
} else { } else {
scanFailedAudio()
this.toLocationInfo = {} this.toLocationInfo = {}
this.toLocationCode = "" this.toLocationCode = ""
this.showMessage('目标库位【' + locationCode + '】不存在'); this.showMessage('目标库位【' + locationCode + '】不存在');
@ -237,6 +301,7 @@
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.toLocationInfo = {} this.toLocationInfo = {}
this.toLocationCode = "" this.toLocationCode = ""
@ -260,6 +325,12 @@
this.showMessage('请扫描目标库位'); this.showMessage('请扫描目标库位');
return; return;
} }
if (this.customerCode == "") {
this.showMessage('请选择客户');
return;
}
var checkQtyItem = this.checkQty() var checkQtyItem = this.checkQty()
if (checkQtyItem != undefined) { if (checkQtyItem != undefined) {
this.showMessage("【" + checkQtyItem.itemCode + '】数量为0,退货数量必须大于0'); this.showMessage("【" + checkQtyItem.itemCode + '】数量为0,退货数量必须大于0');
@ -301,6 +372,7 @@
setSubmitParam() { setSubmitParam() {
let item = { let item = {
worker: localStorage.userName_CN == "" ? localStorage.userName : localStorage.userName_CN, worker: localStorage.userName_CN == "" ? localStorage.userName : localStorage.userName_CN,
customerCode: this.customerCode,
details: [] details: []
} }
this.allDataList.forEach(res => { this.allDataList.forEach(res => {
@ -427,6 +499,7 @@
this.toLocationCode = ""; this.toLocationCode = "";
this.allCount = 0; this.allCount = 0;
this.loadingType = "" this.loadingType = ""
this.customerCode=""
uni.setNavigationBarTitle({ uni.setNavigationBarTitle({
title: "客户退货箱码" title: "客户退货箱码"
}) })

5
fe/PDA/pages/request/coatingIssueRequest.vue

@ -101,7 +101,9 @@
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption, getRemoveOption,
getISODateTime getISODateTime,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -155,6 +157,7 @@
result.defaultHandleQty=result.qty result.defaultHandleQty=result.qty
this.itemList.push(result) this.itemList.push(result)
this.$forceUpdate() this.$forceUpdate()
scanSuccessAudio()
}, },

5
fe/PDA/pages/request/injectionIssueRequest.vue

@ -101,7 +101,9 @@
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption, getRemoveOption,
getISODateTime getISODateTime,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -155,6 +157,7 @@
result.defaultHandleQty=result.qty result.defaultHandleQty=result.qty
this.itemList.push(result) this.itemList.push(result)
this.$forceUpdate() this.$forceUpdate()
scanSuccessAudio()
}, },

7
fe/PDA/pages/request/injectionPlanRequest.vue

@ -75,7 +75,9 @@
dateFormat, dateFormat,
getContainerTypeName, getContainerTypeName,
showConfirmMsg, showConfirmMsg,
getISODateTime getISODateTime,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue' import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue'
@ -186,12 +188,15 @@
locations(locationCode).then(res => { locations(locationCode).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res) { if (res) {
scanSuccessAudio()
this.toLocationInfo = res this.toLocationInfo = res
} else { } else {
scanFailedAudio()
this.showMessage('目标库位【' + locationCode + '】不存在'); this.showMessage('目标库位【' + locationCode + '】不存在');
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.toLocationInfo = null this.toLocationInfo = null
this.showMessage(err.message); this.showMessage(err.message);

5
fe/PDA/pages/request/kittingIssueRequest.vue

@ -102,7 +102,9 @@
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption, getRemoveOption,
getISODateTime getISODateTime,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -156,6 +158,7 @@
result.defaultHandleQty = result.qty result.defaultHandleQty = result.qty
this.itemList.push(result) this.itemList.push(result)
this.$forceUpdate() this.$forceUpdate()
scanSuccessAudio()
}, },

16
fe/PDA/pages/request/thirdLocationRequest.vue

@ -98,7 +98,9 @@
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption, getRemoveOption,
getISODateTime getISODateTime,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -204,6 +206,7 @@
locations(code).then(res => { locations(code).then(res => {
uni.hideLoading(); uni.hideLoading();
if(res){ if(res){
scanSuccessAudio()
this.fromLocationCode = res.code; this.fromLocationCode = res.code;
this.fromLocationArea = res.areaCode; this.fromLocationArea = res.areaCode;
this.openPackLabel(); this.openPackLabel();
@ -217,10 +220,12 @@
// this.showMessage('' + code + ''); // this.showMessage('' + code + '');
// } // }
}else { }else {
scanFailedAudio()
this.showMessage('未查询到库位【' + code + '】'); this.showMessage('未查询到库位【' + code + '】');
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
this.fromLocationCode = ""; this.fromLocationCode = "";
this.fromLocationArea = ""; this.fromLocationArea = "";
uni.hideLoading(); uni.hideLoading();
@ -267,6 +272,7 @@
let balanceRes = await getBalancesByFilterAsync(balanceParam); let balanceRes = await getBalancesByFilterAsync(balanceParam);
if(balanceRes.totalCount==0){ if(balanceRes.totalCount==0){
scanFailedAudio()
this.showMessage("单件码【" + result.scanCode + "】在库位【"+this.fromLocationCode+"】没有库存") this.showMessage("单件码【" + result.scanCode + "】在库位【"+this.fromLocationCode+"】没有库存")
return; return;
} }
@ -277,6 +283,7 @@
} }
}) })
if (filterItem.length > 0) { if (filterItem.length > 0) {
scanFailedAudio()
this.showMessage("单件码【" + filterItem[0].itemCode + "】已经扫描") this.showMessage("单件码【" + filterItem[0].itemCode + "】已经扫描")
return; return;
} }
@ -300,6 +307,7 @@
this.updateTitle() this.updateTitle()
this.$refs.scanPackPopup.closeScanPopup() this.$refs.scanPackPopup.closeScanPopup()
this.$forceUpdate(); this.$forceUpdate();
scanSuccessAudio()
}, },
@ -313,22 +321,26 @@
uni.hideLoading(); uni.hideLoading();
if (res) { if (res) {
if(res.code==this.fromLocationCode){ if(res.code==this.fromLocationCode){
scanFailedAudio()
this.showMessage('目标库位【' + locationCode + "】不能与来源库位【"+this.fromLocationCode+"]一致"); this.showMessage('目标库位【' + locationCode + "】不能与来源库位【"+this.fromLocationCode+"]一致");
}else { }else {
if(res.type==14){ if(res.type==14){
scanSuccessAudio()
this.toLocationCode = res.code this.toLocationCode = res.code
this.toLocationArea =res.areaCode; this.toLocationArea =res.areaCode;
}else { }else {
scanFailedAudio()
this.showMessage('目标库位【' + locationCode + '】的库位类型不是三方库'); this.showMessage('目标库位【' + locationCode + '】的库位类型不是三方库');
} }
} }
} else { } else {
scanFailedAudio()
this.showMessage('目标库位【' + locationCode + '】不存在'); this.showMessage('目标库位【' + locationCode + '】不存在');
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.toLocationCode = "" this.toLocationCode = ""
this.toLocationArea ="" this.toLocationArea =""

18
fe/PDA/pages/return/productionReturnFg.vue

@ -100,7 +100,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -174,14 +176,18 @@
that.fromLocation = res; that.fromLocation = res;
this.openPackLabel(); this.openPackLabel();
this.closeScanFromLocationPopup(); this.closeScanFromLocationPopup();
scanSuccessAudio()
} else { } else {
scanFailedAudio()
that.showMessage('扫描的库位【' + code + '】不是【半成品库】或【线边库位】或【成品库位】'); that.showMessage('扫描的库位【' + code + '】不是【半成品库】或【线边库位】或【成品库位】');
} }
} else { } else {
scanFailedAudio()
that.showMessage('未查询到库位【' + code + '】'); that.showMessage('未查询到库位【' + code + '】');
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
that.showMessage(err.message); that.showMessage(err.message);
}); });
@ -231,6 +237,7 @@
}); });
if (item) { if (item) {
scanFailedAudio()
this.showMessage("物料[" + result.itemCode + "]已经扫描") this.showMessage("物料[" + result.itemCode + "]已经扫描")
} else { } else {
this.getLabel(result.itemCode); this.getLabel(result.itemCode);
@ -251,12 +258,14 @@
let balanceRes = await getRecommendBalanceByLocationAsync(balanceParams, itemCode, false); let balanceRes = await getRecommendBalanceByLocationAsync(balanceParams, itemCode, false);
// //
if (balanceRes.error) { if (balanceRes.error) {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.showMessage(balanceRes.error.message) this.showMessage(balanceRes.error.message)
return; return;
} }
if (balanceRes.length == 0) { if (balanceRes.length == 0) {
scanFailedAudio()
this.showScanMessage('零件【' + itemCode + '】在【' + this.fromLocation.code + this.showScanMessage('零件【' + itemCode + '】在【' + this.fromLocation.code +
'】库位没有库存信息,不可以退库'); '】库位没有库存信息,不可以退库');
} else { } else {
@ -274,7 +283,7 @@
labelList: [] labelList: []
}; };
this.addLabel(item); this.addLabel(item);
scanSuccessAudio()
} }
uni.hideLoading(); uni.hideLoading();
}, },
@ -317,6 +326,7 @@
getDefaultToLocation(locationCode) { getDefaultToLocation(locationCode) {
let that = this; let that = this;
if (locationCode == this.fromLocation.code) { if (locationCode == this.fromLocation.code) {
scanFailedAudio()
this.showMessage('来源库位【' + this.fromLocation.code + '】不能与目标库位【' + locationCode + '】相同'); this.showMessage('来源库位【' + this.fromLocation.code + '】不能与目标库位【' + locationCode + '】相同');
this.$refs.comCollapseLocation.clearLocation(); this.$refs.comCollapseLocation.clearLocation();
return; return;
@ -329,13 +339,16 @@
locations(locationCode).then(res => { locations(locationCode).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res == null) { if (res == null) {
scanFailedAudio()
that.showMessage('目标库位【' + locationCode + '】不存在'); that.showMessage('目标库位【' + locationCode + '】不存在');
} else { } else {
var locationType = res.type var locationType = res.type
// //
if (locationType == 1 || locationType == 6 || locationType == 13) { if (locationType == 1 || locationType == 6 || locationType == 13) {
scanFailedAudio()
that.showMessage('目标库位的库位类型不可以是【待检库】或【隔离库】或【在途】') that.showMessage('目标库位的库位类型不可以是【待检库】或【隔离库】或【在途】')
} else { } else {
scanSuccessAudio()
showConfirmMsg('是否要将所有未扫描目标库位的零件,指定目标库位【' + locationCode + '】', showConfirmMsg('是否要将所有未扫描目标库位的零件,指定目标库位【' + locationCode + '】',
confirm => { confirm => {
if (confirm) { if (confirm) {
@ -354,6 +367,7 @@
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocation = null; that.toLocation = null;
that.showMessage(err.message); that.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();

16
fe/PDA/pages/return/productionReturnRaw.vue

@ -92,7 +92,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -162,14 +164,18 @@
that.fromLocation = res; that.fromLocation = res;
this.openPackLabel(); this.openPackLabel();
this.closeScanFromLocationPopup(); this.closeScanFromLocationPopup();
scanSuccessAudio()
} else { } else {
scanFailedAudio()
that.showMessage('扫描的库位【' + code + '】不是【半成品库】或【线边库位】或【成品库位】'); that.showMessage('扫描的库位【' + code + '】不是【半成品库】或【线边库位】或【成品库位】');
} }
} else { } else {
scanFailedAudio()
that.showMessage('未查询到库位【' + code + '】'); that.showMessage('未查询到库位【' + code + '】');
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
that.showMessage(err.message); that.showMessage(err.message);
}); });
@ -227,6 +233,7 @@
} }
}) })
if (datas.length > 0) { if (datas.length > 0) {
scanFailedAudio()
this.showRescanMessage('箱码【' + code + '】已经存在,是否要重新扫描?'); this.showRescanMessage('箱码【' + code + '】已经存在,是否要重新扫描?');
// showConfirmMsg('' + code + ',?', confirm => { // showConfirmMsg('' + code + ',?', confirm => {
// if (confirm) { // if (confirm) {
@ -244,6 +251,7 @@
} }
} else { } else {
scanFailedAudio()
this.showMessage('请先扫描箱标签'); this.showMessage('请先扫描箱标签');
return; return;
} }
@ -280,6 +288,7 @@
let balanceRes = await getBalancesByFilterAsync(balanceParams); let balanceRes = await getBalancesByFilterAsync(balanceParams);
if (balanceRes.totalCount > 0) { if (balanceRes.totalCount > 0) {
scanFailedAudio()
let locationCode = balanceRes.items[0].locationCode; let locationCode = balanceRes.items[0].locationCode;
this.showScanMessage('箱码【' + that.currentLabel.packingCode + '】在【' + locationCode + this.showScanMessage('箱码【' + that.currentLabel.packingCode + '】在【' + locationCode +
'】库位已经有库存信息,请重新扫描箱码'); '】库位已经有库存信息,请重新扫描箱码');
@ -295,6 +304,7 @@
let wipRes = await getWipListAsync(params); let wipRes = await getWipListAsync(params);
if (wipRes.totalCount == 0) { if (wipRes.totalCount == 0) {
scanFailedAudio()
this.showScanMessage('零件【' + that.currentLabel.itemCode + '】在【' + this.fromLocation.code + this.showScanMessage('零件【' + that.currentLabel.itemCode + '】在【' + this.fromLocation.code +
'】库位没有库存信息,不可以退库'); '】库位没有库存信息,不可以退库');
} else { } else {
@ -321,6 +331,7 @@
// //
if (item.labelList.length == 0) { if (item.labelList.length == 0) {
if (this.currentLabel.qty > item.totalQty) { if (this.currentLabel.qty > item.totalQty) {
scanFailedAudio()
this.showScanMessage('标签数量【' + this.currentLabel.qty + this.showScanMessage('标签数量【' + this.currentLabel.qty +
'】大于零件的库存数量【' + item.totalQty + '】,不可以退库') '】大于零件的库存数量【' + item.totalQty + '】,不可以退库')
} else { } else {
@ -331,6 +342,7 @@
this.calcScanQty(item, 0) this.calcScanQty(item, 0)
item.labelList.unshift(this.currentLabel); item.labelList.unshift(this.currentLabel);
this.scanPopupGetFocus(); this.scanPopupGetFocus();
scanSuccessAudio()
} }
} else { } else {
let scanQty = 0; let scanQty = 0;
@ -338,12 +350,14 @@
scanQty += Number(r.qty) scanQty += Number(r.qty)
}) })
if (scanQty + this.currentLabel.qty > item.totalQty) { if (scanQty + this.currentLabel.qty > item.totalQty) {
scanFailedAudio()
this.showScanMessage('已扫描数量【' + scanQty + '】加标签数量【' + this.currentLabel.qty + this.showScanMessage('已扫描数量【' + scanQty + '】加标签数量【' + this.currentLabel.qty +
'】大于零件的库存数量【' + item.totalQty + '】,不可以退库') '】大于零件的库存数量【' + item.totalQty + '】,不可以退库')
} else { } else {
this.calcScanQty(item, scanQty) this.calcScanQty(item, scanQty)
item.labelList.unshift(this.currentLabel); item.labelList.unshift(this.currentLabel);
this.scanPopupGetFocus(); this.scanPopupGetFocus();
scanSuccessAudio()
} }
} }
}, },

10
fe/PDA/pages/return/purchaseReturnRequest.vue

@ -34,7 +34,9 @@
} from '@/api/index.js'; } from '@/api/index.js';
import { import {
navigateBack, navigateBack,
goHome goHome,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -95,8 +97,8 @@
}) })
if (items.length > 0) { if (items.length > 0) {
scanFailedAudio()
this.showMessage('箱码【' + code + '】已经存在,请扫描其他箱码.'); this.showMessage('箱码【' + code + '】已经存在,请扫描其他箱码.');
} else { } else {
this.getBalances() this.getBalances()
} }
@ -117,17 +119,21 @@
}; };
getBalancesByFilter(params).then(res => { getBalancesByFilter(params).then(res => {
if (res.totalCount == 0) { if (res.totalCount == 0) {
scanFailedAudio()
this.showScanMessage('箱码【' + code + '】在【原料库】未查询到库存信息'); this.showScanMessage('箱码【' + code + '】在【原料库】未查询到库存信息');
} else if (res.totalCount == 1) { } else if (res.totalCount == 1) {
let balanceItem = res.items[0]; let balanceItem = res.items[0];
let item = this.createItem(balanceItem); let item = this.createItem(balanceItem);
that.itemList.unshift(item) that.itemList.unshift(item)
that.scanPopupGetFocus(); that.scanPopupGetFocus();
scanSuccessAudio()
} else { } else {
scanSuccessAudio()
this.$refs.balanceItems.openPopup(res.items); this.$refs.balanceItems.openPopup(res.items);
} }
uni.hideLoading(); uni.hideLoading();
}).catch(ex => { }).catch(ex => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
that.showMessage(ex.message); that.showMessage(ex.message);
}); });

7
fe/PDA/pages/return/purchaseReturn_detail.vue

@ -51,7 +51,9 @@
showConfirmMsg, showConfirmMsg,
compareDesc, compareDesc,
goHome, goHome,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import { import {
getReturnReasonArray getReturnReasonArray
@ -214,14 +216,17 @@
}); });
if (datas.length === 0) { if (datas.length === 0) {
scanFailedAudio()
this.showMessage('在退货任务详情中,未找到箱码【' + code + '】'); this.showMessage('在退货任务详情中,未找到箱码【' + code + '】');
} else { } else {
if (datas.length === 1) { if (datas.length === 1) {
let data = datas[0]; let data = datas[0];
if (data.scaned) { if (data.scaned) {
scanFailedAudio()
this.showMessage('箱码【' + data.recommendPackingCode + '】已经扫描,请扫描下一箱'); this.showMessage('箱码【' + data.recommendPackingCode + '】已经扫描,请扫描下一箱');
} else { } else {
this.scanItem(data); this.scanItem(data);
scanSuccessAudio()
} }
} }
this.scanCount = this.detail.details.filter(r => r.scaned).length; this.scanCount = this.detail.details.filter(r => r.scaned).length;

8
fe/PDA/pages/return/returnBeforPutaway.vue

@ -37,7 +37,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
getRemoveOption, getRemoveOption,
goHome goHome,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import VUE from 'vue' import VUE from 'vue'
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -151,16 +153,20 @@
}; };
getBalancesByFilter(params).then(res => { getBalancesByFilter(params).then(res => {
if (res.totalCount == 0) { if (res.totalCount == 0) {
scanFailedAudio()
that.showScanMessage('箱码【' + code + '】在【隔离库】未查询到库存信息'); that.showScanMessage('箱码【' + code + '】在【隔离库】未查询到库存信息');
} else if (res.totalCount == 1) { } else if (res.totalCount == 1) {
res.items[0].poNumber = poNumber; res.items[0].poNumber = poNumber;
that.itemList.unshift(res.items[0]) that.itemList.unshift(res.items[0])
this.scanPopupGetFocus(); this.scanPopupGetFocus();
scanSuccessAudio()
} else { } else {
scanSuccessAudio()
this.$refs.balanceItems.openPopup(res.items); this.$refs.balanceItems.openPopup(res.items);
} }
uni.hideLoading(); uni.hideLoading();
}).catch(ex => { }).catch(ex => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
that.showScanMessage(ex.message); that.showScanMessage(ex.message);
}); });

8
fe/PDA/pages/return/returnToWarehouse.vue

@ -92,7 +92,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -371,10 +373,11 @@
}); });
locations(locationCode).then(res => { locations(locationCode).then(res => {
if (res == null) { if (res == null) {
scanFailedAudio()
that.showMessage('目标库位【' + locationCode + '】不存在'); that.showMessage('目标库位【' + locationCode + '】不存在');
} else { } else {
if (res.type == 2 || res.type == 3||res.type == 4 ||res.type == 6) { if (res.type == 2 || res.type == 3||res.type == 4 ||res.type == 6) {
scanSuccessAudio()
showConfirmMsg('是否要将所有未扫描目标库位的零件,指定目标库位【' + locationCode + '】', showConfirmMsg('是否要将所有未扫描目标库位的零件,指定目标库位【' + locationCode + '】',
confirm => { confirm => {
if (confirm) { if (confirm) {
@ -395,6 +398,7 @@
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocation = null; that.toLocation = null;
that.showMessage(err.message); that.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();

7
fe/PDA/pages/spray/sprayCompleteReceive.vue

@ -84,7 +84,9 @@
import { import {
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption getRemoveOption,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -241,16 +243,19 @@
let that = this; let that = this;
locations(code).then(res => { locations(code).then(res => {
if (res == null) { if (res == null) {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
that.showMessage('目标库位【' + code + '】不存在'); that.showMessage('目标库位【' + code + '】不存在');
this.$refs.location.clearLocation() this.$refs.location.clearLocation()
this.locationGotFocus = true; this.locationGotFocus = true;
} else { } else {
scanSuccessAudio()
that.toLocationCode = code; that.toLocationCode = code;
that.toLocationErpCode = res.erpLocationCode; that.toLocationErpCode = res.erpLocationCode;
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
this.locationGotFocus = true; this.locationGotFocus = true;
that.showMessage(err.message); that.showMessage(err.message);

9
fe/PDA/pages/store/deliverRaw.vue

@ -72,7 +72,9 @@
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption, getRemoveOption,
getISODateTime getISODateTime,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -212,20 +214,25 @@
.then(res => { .then(res => {
try { try {
if (res.totalCount === 0) { if (res.totalCount === 0) {
scanFailedAudio()
this.showScanMessage('箱码【' + result.data.packingCode + '】在【原料库】未查询到库存信息'); this.showScanMessage('箱码【' + result.data.packingCode + '】在【原料库】未查询到库存信息');
} else if (res.totalCount === 1) { } else if (res.totalCount === 1) {
let balanceItem = res.items[0]; let balanceItem = res.items[0];
this.createItem(balanceItem); this.createItem(balanceItem);
scanSuccessAudio()
} else { } else {
scanSuccessAudio()
this.$refs.balanceItems.openPopup(res.items); this.$refs.balanceItems.openPopup(res.items);
} }
} catch (e) { } catch (e) {
scanFailedAudio()
this.showScanMessage(e.message); this.showScanMessage(e.message);
} }
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showScanMessage(err.message); this.showScanMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });

9
fe/PDA/pages/store/issueDirect.vue

@ -78,7 +78,9 @@
showConfirmMsg, showConfirmMsg,
goHome, goHome,
getRemoveOption, getRemoveOption,
getISODateTime getISODateTime,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winBlankView from '@/mycomponents/wincom/winBlankView.vue' import winBlankView from '@/mycomponents/wincom/winBlankView.vue'
@ -389,16 +391,20 @@
let that = this; let that = this;
locations(code).then(res => { locations(code).then(res => {
if (res == null) { if (res == null) {
scanFailedAudio()
that.showMessage('目标库位【' + code + '】不存在'); that.showMessage('目标库位【' + code + '】不存在');
that.$refs.comToLocation.clearLocation(); that.$refs.comToLocation.clearLocation();
} else { } else {
if (res.type != 5) { if (res.type != 5) {
scanFailedAudio()
this.showMessage('目标库位必须是【线边库】') this.showMessage('目标库位必须是【线边库】')
} else { } else {
// this.toLocation = res; // this.toLocation = res;
if(res.erpLocationCode!=this.formlocationErpCode){ if(res.erpLocationCode!=this.formlocationErpCode){
scanFailedAudio()
this.showMessage('来源库位的ERP储位【'+this.formlocationErpCode+'】与目标库位ERP储位【'+res.erpLocationCode+'】不相等') this.showMessage('来源库位的ERP储位【'+this.formlocationErpCode+'】与目标库位ERP储位【'+res.erpLocationCode+'】不相等')
}else{ }else{
scanSuccessAudio()
this.toLocation = res; this.toLocation = res;
} }
@ -406,6 +412,7 @@
} }
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.toLocationCode = '' that.toLocationCode = ''
that.showMessage(err.message); that.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();

7
fe/PDA/pages/task/assembleIssueJob.vue

@ -29,7 +29,9 @@
import { import {
goHome, goHome,
getIssueJobState getIssueJobState,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue' import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue'
@ -152,12 +154,15 @@
getAssembleIssueJobByPackingCode(result.data.code).then(res=>{ getAssembleIssueJobByPackingCode(result.data.code).then(res=>{
uni.hideLoading(); uni.hideLoading();
if(res){ if(res){
scanSuccessAudio()
this.$refs.scanPopup.closeScanPopup(); this.$refs.scanPopup.closeScanPopup();
this.openDetail(res) this.openDetail(res)
}else { }else {
scanFailedAudio()
this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务"); this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务");
} }
}).catch(error=>{ }).catch(error=>{
scanSuccessAudio()
uni.hideLoading(); uni.hideLoading();
this.showMessage(error.message); this.showMessage(error.message);
}) })

13
fe/PDA/pages/task/assembleIssueJobDetail.vue

@ -185,7 +185,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -284,10 +286,12 @@
geToLocation(locationInfo) { geToLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
current.handledToLocationCode = locationInfo.code current.handledToLocationCode = locationInfo.code
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationArea = locationInfo.areaCode
current.handledToLocationGroup = locationInfo.locationGroupCode current.handledToLocationGroup = locationInfo.locationGroupCode
@ -379,13 +383,16 @@
var fromData = result.data; var fromData = result.data;
var data = this.details.filter(r => r.itemCode == result.data.itemCode) var data = this.details.filter(r => r.itemCode == result.data.itemCode)
if (data.length == 0) { if (data.length == 0) {
scanFailedAudio()
this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中") this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中")
return; return;
} }
if (this.jobStatus == 30) { if (this.jobStatus == 30) {
scanFailedAudio()
if (fromData.code == this.details[0].recommendFromPackingCode) { if (fromData.code == this.details[0].recommendFromPackingCode) {
this.showMessage("请先完成库移后在扫描箱码") this.showMessage("请先完成库移后在扫描箱码")
} else { } else {
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0] showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0]
.recommendFromPackingCode + .recommendFromPackingCode +
@ -408,6 +415,7 @@
var balancesItem = res.items[0]; var balancesItem = res.items[0];
var item = data[0]; var item = data[0];
if (balancesItem.lot == item.recommendToLot) { if (balancesItem.lot == item.recommendToLot) {
scanSuccessAudio()
item.handledToContainerCode = balancesItem.containerCode item.handledToContainerCode = balancesItem.containerCode
item.handledToPackingCode = balancesItem.packingCode item.handledToPackingCode = balancesItem.packingCode
item.handledToSupplierBatch = balancesItem.supplierBatch item.handledToSupplierBatch = balancesItem.supplierBatch
@ -431,6 +439,7 @@
item.handledFromLocationCode = balancesItem.locationCode item.handledFromLocationCode = balancesItem.locationCode
item.handleToPackingCodeLocationCode = balancesItem.locationCode item.handleToPackingCodeLocationCode = balancesItem.locationCode
} else { } else {
scanFailedAudio()
showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot + "]与推荐目标批次[" + item showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot + "]与推荐目标批次[" + item
.recommendToLot + "]不一致,是否继续发料", res => { .recommendToLot + "]不一致,是否继续发料", res => {
if (res) { if (res) {
@ -487,6 +496,7 @@
balances(params) balances(params)
.then(res => { .then(res => {
if (res.totalCount === 0) { if (res.totalCount === 0) {
scanFailedAudio()
this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息'); this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息');
} else { } else {
callback(res); callback(res);
@ -494,6 +504,7 @@
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showScanMessage(err.message); this.showScanMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });

11
fe/PDA/pages/task/assembleIssueJobDetailByQty.vue

@ -153,7 +153,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue' import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue'
@ -257,11 +259,12 @@
getFromLocation(locationInfo) { getFromLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendFromLocationCode) { if (locationInfo.code != current.recommendFromLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current
.recommendFromLocationCode + "]不一致,请重新扫描") .recommendFromLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
current.handledFromLocationCode = locationInfo.code current.handledFromLocationCode = locationInfo.code
current.handledFromLocationArea = locationInfo.locationArea current.handledFromLocationArea = locationInfo.locationArea
current.handledFromLocationGroup = locationInfo.locationGroup current.handledFromLocationGroup = locationInfo.locationGroup
@ -275,10 +278,12 @@
getToLocation(locationInfo) { getToLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
this.toLocationInfo = locationInfo this.toLocationInfo = locationInfo
current.handledToLocationCode = locationInfo.code current.handledToLocationCode = locationInfo.code
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationArea = locationInfo.areaCode
@ -384,9 +389,11 @@
}); });
if (item == undefined) { if (item == undefined) {
scanFailedAudio()
this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】'); this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】');
return; return;
} }
scanSuccessAudio()
this.singCode = result.itemCode this.singCode = result.itemCode
this.$refs.scanPackPopup.closeScanPopup(); this.$refs.scanPackPopup.closeScanPopup();

7
fe/PDA/pages/task/coatingIssuleJob.vue

@ -29,7 +29,9 @@
import { import {
goHome, goHome,
getIssueJobState getIssueJobState,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue' import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue'
@ -159,10 +161,13 @@
if(res){ if(res){
this.$refs.scanPopup.closeScanPopup(); this.$refs.scanPopup.closeScanPopup();
this.openDetail(res) this.openDetail(res)
scanSuccessAudio()
}else { }else {
scanFailedAudio()
this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务"); this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务");
} }
}).catch(error=>{ }).catch(error=>{
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.showMessage(error.message); this.showMessage(error.message);
}) })

23
fe/PDA/pages/task/coatingIssuleJobDetail.vue

@ -185,7 +185,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -286,14 +288,16 @@
geToLocation(locationInfo) { geToLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
current.handledToLocationCode = locationInfo.code scanSuccessAudio()
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationCode = locationInfo.code
current.handledToLocationGroup = locationInfo.locationGroupCode current.handledToLocationArea = locationInfo.areaCode
current.handledToLocationErpCode = locationInfo.erpLocationCode current.handledToLocationGroup = locationInfo.locationGroupCode
current.handledToLocationErpCode = locationInfo.erpLocationCode
}, },
// //
getDetail() { getDetail() {
@ -382,13 +386,16 @@
var fromData = result.data; var fromData = result.data;
var data = this.details.filter(r => r.itemCode == result.data.itemCode) var data = this.details.filter(r => r.itemCode == result.data.itemCode)
if (data.length == 0) { if (data.length == 0) {
scanFailedAudio()
this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中") this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中")
return; return;
} }
if (this.jobStatus == 30) { if (this.jobStatus == 30) {
if (fromData.code == this.details[0].recommendFromPackingCode) { if (fromData.code == this.details[0].recommendFromPackingCode) {
scanFailedAudio()
this.showMessage("请先完成库移后在扫描箱码") this.showMessage("请先完成库移后在扫描箱码")
} else { } else {
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0] showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0]
.recommendFromPackingCode + .recommendFromPackingCode +
@ -411,6 +418,7 @@
var balancesItem = res.items[0]; var balancesItem = res.items[0];
var item = data[0]; var item = data[0];
if (balancesItem.lot == item.recommendToLot) { if (balancesItem.lot == item.recommendToLot) {
scanSuccessAudio()
item.handledToContainerCode = balancesItem.containerCode item.handledToContainerCode = balancesItem.containerCode
item.handledToPackingCode = balancesItem.packingCode item.handledToPackingCode = balancesItem.packingCode
item.handledToSupplierBatch = balancesItem.supplierBatch item.handledToSupplierBatch = balancesItem.supplierBatch
@ -434,6 +442,7 @@
item.handledFromLocationCode = balancesItem.locationCode item.handledFromLocationCode = balancesItem.locationCode
item.handleToPackingCodeLocationCode = balancesItem.locationCode item.handleToPackingCodeLocationCode = balancesItem.locationCode
} else { } else {
scanFailedAudio()
showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot + "]与推荐目标批次[" + item showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot + "]与推荐目标批次[" + item
.recommendToLot + "]不一致,是否继续发料", res => { .recommendToLot + "]不一致,是否继续发料", res => {
if (res) { if (res) {
@ -490,6 +499,7 @@
balances(params) balances(params)
.then(res => { .then(res => {
if (res.totalCount === 0) { if (res.totalCount === 0) {
scanFailedAudio()
this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息'); this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息');
} else { } else {
callback(res); callback(res);
@ -497,6 +507,7 @@
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showScanMessage(err.message); this.showScanMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });
@ -504,6 +515,7 @@
getBalanceRemoveInAndOut(params) getBalanceRemoveInAndOut(params)
.then(res => { .then(res => {
if (res.totalCount === 0) { if (res.totalCount === 0) {
scanFailedAudio()
this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息'); this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息');
} else { } else {
callback(res); callback(res);
@ -511,6 +523,7 @@
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showScanMessage(err.message); this.showScanMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });

11
fe/PDA/pages/task/coatingIssuleJobDetailByQty.vue

@ -162,7 +162,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue' import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue'
@ -270,11 +272,12 @@
getFromLocation(locationInfo) { getFromLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendFromLocationCode) { if (locationInfo.code != current.recommendFromLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current
.recommendFromLocationCode + "]不一致,请重新扫描") .recommendFromLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
current.handledFromLocationCode = locationInfo.code current.handledFromLocationCode = locationInfo.code
current.handledFromLocationArea = locationInfo.locationArea current.handledFromLocationArea = locationInfo.locationArea
current.handledFromLocationGroup = locationInfo.locationGroup current.handledFromLocationGroup = locationInfo.locationGroup
@ -288,10 +291,12 @@
getToLocation(locationInfo) { getToLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
this.toLocationInfo = locationInfo this.toLocationInfo = locationInfo
current.handledToLocationCode = locationInfo.code current.handledToLocationCode = locationInfo.code
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationArea = locationInfo.areaCode
@ -397,9 +402,11 @@
}); });
if (item == undefined) { if (item == undefined) {
scanFailedAudio()
this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】'); this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】');
return; return;
} }
scanSuccessAudio()
this.singCode = result.itemCode this.singCode = result.itemCode
this.$refs.scanPackPopup.closeScanPopup(); this.$refs.scanPackPopup.closeScanPopup();

11
fe/PDA/pages/task/countFg.vue

@ -26,7 +26,9 @@
getJobStatuStyle, getJobStatuStyle,
getJobStatuDesc, getJobStatuDesc,
maxPageSize, maxPageSize,
goHome goHome,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue' import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue'
import comCount from '@/mycomponents/coms/task/comCount.vue'; import comCount from '@/mycomponents/coms/task/comCount.vue';
@ -198,11 +200,14 @@
getCountJobByNumber(code).then(res => { getCountJobByNumber(code).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res != null) { if (res != null) {
scanSuccessAudio()
that.openDetail(res); that.openDetail(res);
} else { } else {
scanFailedAudio()
that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务'); that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务');
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.showMessage(err.message); that.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });
@ -219,16 +224,20 @@
let jobRes = await getCountJobByLocationAsync(code); let jobRes = await getCountJobByLocationAsync(code);
if (jobRes.error == undefined) { if (jobRes.error == undefined) {
if (jobRes.totalCount == 0) { if (jobRes.totalCount == 0) {
scanFailedAudio()
that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务'); that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务');
} else if (jobRes.totalCount == 1) { } else if (jobRes.totalCount == 1) {
scanSuccessAudio()
this.openDetail(jobRes.items[0]); this.openDetail(jobRes.items[0]);
} else { } else {
this.openCountItems(jobRes.items); this.openCountItems(jobRes.items);
} }
} else { } else {
scanFailedAudio()
that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务'); that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务');
} }
} else { } else {
scanFailedAudio()
this.showMessage('未查找到库位【' + code + '】'); this.showMessage('未查找到库位【' + code + '】');
} }
uni.hideLoading(); uni.hideLoading();

11
fe/PDA/pages/task/countFgDetail.vue

@ -176,7 +176,9 @@
compare, compare,
getRemoveOption, getRemoveOption,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import { import {
@ -486,6 +488,7 @@
) )
if (itemScan.length > 0) { if (itemScan.length > 0) {
setTimeout(res => { setTimeout(res => {
scanFailedAudio()
showConfirmMsg("物料【" + itemCode + "】已经扫描,是否覆盖已经扫描的信息", res => { showConfirmMsg("物料【" + itemCode + "】已经扫描,是否覆盖已经扫描的信息", res => {
if (res) { if (res) {
this.setQty(itemScan[0], itemScan[0].inventoryQty, false); this.setQty(itemScan[0], itemScan[0].inventoryQty, false);
@ -501,10 +504,12 @@
if (items.length == 0) { if (items.length == 0) {
this.addNewDetail(result) this.addNewDetail(result)
} else if (items.length == 1) { } else if (items.length == 1) {
scanSuccessAudio()
var item = items[0]; var item = items[0];
item.isNew =true; item.isNew =true;
this.setQty(item, item.inventoryQty, true); this.setQty(item, item.inventoryQty, true);
} else { } else {
scanFailedAudio()
this.showMessage('盘点数量异常,箱码【' + packingCode + '】的出现多条数据'); this.showMessage('盘点数量异常,箱码【' + packingCode + '】的出现多条数据');
} }
@ -526,6 +531,7 @@
async addNewDetail(result) { async addNewDetail(result) {
if (this.location == null) { if (this.location == null) {
scanFailedAudio()
this.showMessage('未查找到库位信息,不可以添加为任务明细'); this.showMessage('未查找到库位信息,不可以添加为任务明细');
return; return;
} }
@ -533,6 +539,7 @@
let detail = this.creatDetail(result); let detail = this.creatDetail(result);
if (balanceItem == null || balanceItem == undefined) { if (balanceItem == null || balanceItem == undefined) {
setTimeout(res => { setTimeout(res => {
scanFailedAudio()
showConfirmMsg("扫描的物料["+result.code+"]在任务中不存在,是否要添加为任务明细?", async confirm => { showConfirmMsg("扫描的物料["+result.code+"]在任务中不存在,是否要添加为任务明细?", async confirm => {
if (confirm) { if (confirm) {
this.setDetailNoBalance(detail, result) this.setDetailNoBalance(detail, result)
@ -548,10 +555,12 @@
} else { } else {
if (balanceItem.locationCode != this.location.code) { if (balanceItem.locationCode != this.location.code) {
scanFailedAudio()
this.showMessage("物料【" + result.code + "】在库位【" + balanceItem.locationCode + "】不在库位【" + this.showMessage("物料【" + result.code + "】在库位【" + balanceItem.locationCode + "】不在库位【" +
this.location.code + "】不可以添加为任务明细"); this.location.code + "】不可以添加为任务明细");
} else { } else {
setTimeout(res => { setTimeout(res => {
scanFailedAudio()
showConfirmMsg("扫描的物料["+result.itemCode+"]在任务中不存在,是否要添加为任务明细?", async confirm => { showConfirmMsg("扫描的物料["+result.itemCode+"]在任务中不存在,是否要添加为任务明细?", async confirm => {
if (confirm) { if (confirm) {
this.setDetailByBalance(detail, balanceItem); this.setDetailByBalance(detail, balanceItem);

11
fe/PDA/pages/task/countRaw.vue

@ -26,7 +26,9 @@
getJobStatuStyle, getJobStatuStyle,
getJobStatuDesc, getJobStatuDesc,
maxPageSize, maxPageSize,
goHome goHome,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue' import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue'
import comCount from '@/mycomponents/coms/task/comCount.vue'; import comCount from '@/mycomponents/coms/task/comCount.vue';
@ -184,11 +186,14 @@
getCountJobByNumber(code).then(res => { getCountJobByNumber(code).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res != null) { if (res != null) {
scanSuccessAudio()
that.openDetail(res); that.openDetail(res);
} else { } else {
scanFailedAudio()
that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务'); that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务');
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.showMessage(err.message); that.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });
@ -205,16 +210,20 @@
let jobRes = await getCountJobByLocationAsync(code); let jobRes = await getCountJobByLocationAsync(code);
if (jobRes.error == undefined) { if (jobRes.error == undefined) {
if (jobRes.totalCount == 0) { if (jobRes.totalCount == 0) {
scanFailedAudio()
that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务'); that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务');
} else if (jobRes.totalCount == 1) { } else if (jobRes.totalCount == 1) {
scanSuccessAudio()
this.openDetail(jobRes.items[0]); this.openDetail(jobRes.items[0]);
} else { } else {
this.openCountItems(jobRes.items); this.openCountItems(jobRes.items);
} }
} else { } else {
scanFailedAudio()
that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务'); that.showMessage('未查找到' + type + '为【' + code + '】的盘点任务');
} }
} else { } else {
scanFailedAudio()
this.showMessage('未查找到库位【' + code + '】'); this.showMessage('未查找到库位【' + code + '】');
} }
uni.hideLoading(); uni.hideLoading();

10
fe/PDA/pages/task/countRawDetail.vue

@ -177,7 +177,9 @@
compare, compare,
getRemoveOption, getRemoveOption,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import { import {
@ -405,6 +407,7 @@
var itemScan = this.scanAllDetails.filter(r => var itemScan = this.scanAllDetails.filter(r =>
r.packingCode == packingCode && r.inventoryStage == this.datacontent.inventoryStage) r.packingCode == packingCode && r.inventoryStage == this.datacontent.inventoryStage)
if (itemScan.length > 0) { if (itemScan.length > 0) {
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg("箱码【" + packingCode + "】已经扫描,是否覆盖已经扫描的信息", res => { showConfirmMsg("箱码【" + packingCode + "】已经扫描,是否覆盖已经扫描的信息", res => {
if (res) { if (res) {
@ -426,7 +429,9 @@
var item = items[0]; var item = items[0];
item.isNew = true; item.isNew = true;
this.setQty(item, item.inventoryQty, true); this.setQty(item, item.inventoryQty, true);
scanSuccessAudio()
} else { } else {
scanFailedAudio()
this.showMessage('盘点数量异常,箱码【' + packingCode + '】的出现多条数据'); this.showMessage('盘点数量异常,箱码【' + packingCode + '】的出现多条数据');
} }
}, },
@ -440,6 +445,7 @@
let balanceItem = await this.getBalanceAsync(result); let balanceItem = await this.getBalanceAsync(result);
let detail = this.creatDetail(result); let detail = this.creatDetail(result);
if (balanceItem == null || balanceItem == undefined) { if (balanceItem == null || balanceItem == undefined) {
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg('扫描的库存在任务中不存在,是否要添加为任务明细?', async confirm => { showConfirmMsg('扫描的库存在任务中不存在,是否要添加为任务明细?', async confirm => {
if (confirm) { if (confirm) {
@ -456,9 +462,11 @@
} else { } else {
if (balanceItem.locationCode != this.location.code) { if (balanceItem.locationCode != this.location.code) {
scanFailedAudio()
this.showMessage("箱码【" + result.data.code + "】在库位【" + balanceItem.locationCode + "】不在库位【" + this.showMessage("箱码【" + result.data.code + "】在库位【" + balanceItem.locationCode + "】不在库位【" +
this.location.code + "】不可以添加为任务明细"); this.location.code + "】不可以添加为任务明细");
} else { } else {
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg('扫描的库存在任务中不存在,是否要添加为任务明细?', async confirm => { showConfirmMsg('扫描的库存在任务中不存在,是否要添加为任务明细?', async confirm => {
if (confirm) { if (confirm) {

11
fe/PDA/pages/task/deliverBoard_detail.vue

@ -100,7 +100,9 @@
getJobStatuDesc, getJobStatuDesc,
showConfirmMsg, showConfirmMsg,
goHome, goHome,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
import winMulitScan from '@/mycomponents/wincom/winMulitScan.vue' import winMulitScan from '@/mycomponents/wincom/winMulitScan.vue'
@ -220,10 +222,12 @@
}); });
if (item === undefined) { if (item === undefined) {
scanFailedAudio()
this.showMessage('在发货任务详情中,未找到箱码【' + code + '】'); this.showMessage('在发货任务详情中,未找到箱码【' + code + '】');
return; return;
} else { } else {
if (item.scaned) { if (item.scaned) {
scanFailedAudio()
this.showMessage('箱码【' + code + '】已经扫描,请扫描下一箱零件'); this.showMessage('箱码【' + code + '】已经扫描,请扫描下一箱零件');
return; return;
} }
@ -240,15 +244,20 @@
.then(res => { .then(res => {
try { try {
if (res.totalCount == 0) { if (res.totalCount == 0) {
scanFailedAudio()
this.showMessage('箱码【' + code + '】在【成品库】未查询到库存信息'); this.showMessage('箱码【' + code + '】在【成品库】未查询到库存信息');
} else if (res.totalCount == 1) { } else if (res.totalCount == 1) {
that.balancesItem = res.items[0]; that.balancesItem = res.items[0];
scanSuccessAudio()
this.createItem(item); this.createItem(item);
} else { } else {
scanSuccessAudio()
this.$refs.balanceItems.openPopup(res.items); this.$refs.balanceItems.openPopup(res.items);
} }
uni.hideLoading(); uni.hideLoading();
} catch (e) { } catch (e) {
uni.hideLoading();
scanFailedAudio()
this.showMessage(e.message) this.showMessage(e.message)
} }
}) })

8
fe/PDA/pages/task/deliverJis_detail.vue

@ -105,7 +105,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -244,15 +246,19 @@
// //
let item = this.details.find(r => r.recommendContainerCode == result.containerCode); let item = this.details.find(r => r.recommendContainerCode == result.containerCode);
if (item == undefined) { if (item == undefined) {
scanFailedAudio()
this.showMessage("器具码【" + result.containerCode + "】不在列表中") this.showMessage("器具码【" + result.containerCode + "】不在列表中")
} else { } else {
if (item.scaned) { if (item.scaned) {
scanFailedAudio()
this.showMessage("器具码【" + result.containerCode + "】已经扫描") this.showMessage("器具码【" + result.containerCode + "】已经扫描")
} else { } else {
if (this.allCount == this.scanCount) { if (this.allCount == this.scanCount) {
scanFailedAudio()
this.showMessage("零件已经全部扫描完成"); this.showMessage("零件已经全部扫描完成");
return; return;
} }
scanSuccessAudio()
item.containerCode = result.containerCode; item.containerCode = result.containerCode;
item.scaned = true; item.scaned = true;
item.handleQty = 10; item.handleQty = 10;

7
fe/PDA/pages/task/injectionIssueJob.vue

@ -29,7 +29,9 @@
import { import {
goHome, goHome,
getIssueJobState getIssueJobState,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue' import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue'
@ -152,12 +154,15 @@
getInjectionIssueJobByPackingCode(result.data.code).then(res=>{ getInjectionIssueJobByPackingCode(result.data.code).then(res=>{
uni.hideLoading(); uni.hideLoading();
if(res){ if(res){
scanSuccessAudio()
this.$refs.scanPopup.closeScanPopup(); this.$refs.scanPopup.closeScanPopup();
this.openDetail(res) this.openDetail(res)
}else { }else {
scanFailedAudio()
this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务"); this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务");
} }
}).catch(error=>{ }).catch(error=>{
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.showMessage(error.message); this.showMessage(error.message);
}) })

15
fe/PDA/pages/task/injectionIssueJobDetail.vue

@ -189,7 +189,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -288,10 +290,12 @@
geToLocation(locationInfo) { geToLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
current.handledToLocationCode = locationInfo.code current.handledToLocationCode = locationInfo.code
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationArea = locationInfo.areaCode
current.handledToLocationGroup = locationInfo.locationGroupCode current.handledToLocationGroup = locationInfo.locationGroupCode
@ -385,13 +389,16 @@
var fromData = result.data; var fromData = result.data;
var data = this.details.filter(r => r.itemCode == result.data.itemCode) var data = this.details.filter(r => r.itemCode == result.data.itemCode)
if (data.length == 0) { if (data.length == 0) {
scanFailedAudio()
this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中") this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中")
return; return;
} }
if (this.jobStatus == 30) { if (this.jobStatus == 30) {
if (fromData.code == this.details[0].recommendFromPackingCode) { if (fromData.code == this.details[0].recommendFromPackingCode) {
scanFailedAudio()
this.showMessage("请先完成库移后在扫描箱码") this.showMessage("请先完成库移后在扫描箱码")
} else { } else {
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0] showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0]
.recommendFromPackingCode + .recommendFromPackingCode +
@ -415,6 +422,7 @@
var balancesItem = res.items[0]; var balancesItem = res.items[0];
var item = data[0]; var item = data[0];
if (balancesItem.lot == item.recommendToLot) { if (balancesItem.lot == item.recommendToLot) {
scanSuccessAudio()
item.handledToContainerCode = balancesItem.containerCode item.handledToContainerCode = balancesItem.containerCode
item.handledToPackingCode = balancesItem.packingCode item.handledToPackingCode = balancesItem.packingCode
item.handledToSupplierBatch = balancesItem.supplierBatch item.handledToSupplierBatch = balancesItem.supplierBatch
@ -439,6 +447,7 @@
item.handleToPackingCodeLocationCode = balancesItem.locationCode item.handleToPackingCodeLocationCode = balancesItem.locationCode
} else { } else {
scanFailedAudio()
showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot + "]与推荐目标批次[" + item showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot + "]与推荐目标批次[" + item
.recommendToLot + "]不一致,是否继续发料", res => { .recommendToLot + "]不一致,是否继续发料", res => {
if (res) { if (res) {
@ -494,6 +503,7 @@
balances(params) balances(params)
.then(res => { .then(res => {
if (res.totalCount === 0) { if (res.totalCount === 0) {
scanFailedAudio()
this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息'); this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息');
} else { } else {
callback(res); callback(res);
@ -501,6 +511,7 @@
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showScanMessage(err.message); this.showScanMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });
@ -508,6 +519,7 @@
getBalanceRemoveInAndOut(params) getBalanceRemoveInAndOut(params)
.then(res => { .then(res => {
if (res.totalCount === 0) { if (res.totalCount === 0) {
scanFailedAudio()
this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息'); this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息');
} else { } else {
callback(res); callback(res);
@ -515,6 +527,7 @@
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showScanMessage(err.message); this.showScanMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });

11
fe/PDA/pages/task/injectionIssueJobDetailByQty.vue

@ -152,7 +152,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue' import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue'
@ -254,11 +256,12 @@
getFromLocation(locationInfo) { getFromLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendFromLocationCode) { if (locationInfo.code != current.recommendFromLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current
.recommendFromLocationCode + "]不一致,请重新扫描") .recommendFromLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
current.handledFromLocationCode = locationInfo.code current.handledFromLocationCode = locationInfo.code
current.handledFromLocationArea = locationInfo.locationArea current.handledFromLocationArea = locationInfo.locationArea
current.handledFromLocationGroup = locationInfo.locationGroup current.handledFromLocationGroup = locationInfo.locationGroup
@ -272,10 +275,12 @@
getToLocation(locationInfo) { getToLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
this.toLocationInfo = locationInfo this.toLocationInfo = locationInfo
current.handledToLocationCode = locationInfo.code current.handledToLocationCode = locationInfo.code
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationArea = locationInfo.areaCode
@ -380,9 +385,11 @@
}); });
if (item == undefined) { if (item == undefined) {
scanFailedAudio()
this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】'); this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】');
return; return;
} }
scanSuccessAudio()
this.singCode = result.itemCode this.singCode = result.itemCode
this.$refs.scanPackPopup.closeScanPopup(); this.$refs.scanPackPopup.closeScanPopup();

3
fe/PDA/pages/task/kittingIssueJob.vue

@ -153,12 +153,15 @@
getKitingIssueJobPackingCode(result.data.code).then(res=>{ getKitingIssueJobPackingCode(result.data.code).then(res=>{
uni.hideLoading(); uni.hideLoading();
if(res){ if(res){
scanSuccessAudio()
this.$refs.scanPopup.closeScanPopup(); this.$refs.scanPopup.closeScanPopup();
this.openDetail(res) this.openDetail(res)
}else { }else {
scanFailedAudio()
this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务"); this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务");
} }
}).catch(error=>{ }).catch(error=>{
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.showMessage(error.message); this.showMessage(error.message);
}) })

13
fe/PDA/pages/task/kittingIssueJobDetail.vue

@ -185,7 +185,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -285,10 +287,12 @@
geToLocation(locationInfo) { geToLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
current.handledToLocationCode = locationInfo.code current.handledToLocationCode = locationInfo.code
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationArea = locationInfo.areaCode
current.handledToLocationGroup = locationInfo.locationGroupCode current.handledToLocationGroup = locationInfo.locationGroupCode
@ -380,13 +384,16 @@
var fromData = result.data; var fromData = result.data;
var data = this.details.filter(r => r.itemCode == result.data.itemCode) var data = this.details.filter(r => r.itemCode == result.data.itemCode)
if (data.length == 0) { if (data.length == 0) {
scanFailedAudio()
this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中") this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中")
return; return;
} }
if (this.jobStatus == 30) { if (this.jobStatus == 30) {
if (fromData.code == this.details[0].recommendFromPackingCode) { if (fromData.code == this.details[0].recommendFromPackingCode) {
scanFailedAudio()
this.showMessage("请先完成库移后在扫描箱码") this.showMessage("请先完成库移后在扫描箱码")
} else { } else {
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0] showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0]
.recommendFromPackingCode + .recommendFromPackingCode +
@ -410,6 +417,7 @@
var balancesItem = res.items[0]; var balancesItem = res.items[0];
var item = data[0]; var item = data[0];
if (balancesItem.lot == item.recommendToLot) { if (balancesItem.lot == item.recommendToLot) {
scanSuccessAudio()
item.handledToContainerCode = balancesItem.containerCode item.handledToContainerCode = balancesItem.containerCode
item.handledToPackingCode = balancesItem.packingCode item.handledToPackingCode = balancesItem.packingCode
item.handledToSupplierBatch = balancesItem.supplierBatch item.handledToSupplierBatch = balancesItem.supplierBatch
@ -433,6 +441,7 @@
item.handledFromLocationCode =balancesItem.locationCode item.handledFromLocationCode =balancesItem.locationCode
item.handleToPackingCodeLocationCode = balancesItem.locationCode item.handleToPackingCodeLocationCode = balancesItem.locationCode
} else { } else {
scanFailedAudio()
showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot + showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot +
"]与推荐目标批次[" + item "]与推荐目标批次[" + item
.recommendToLot + "]不一致,是否继续发料", res => { .recommendToLot + "]不一致,是否继续发料", res => {
@ -491,6 +500,7 @@
balances(params) balances(params)
.then(res => { .then(res => {
if (res.totalCount === 0) { if (res.totalCount === 0) {
scanFailedAudio()
this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息'); this.showScanMessage('按箱码【' + result.data.code + '】未查询到库存信息');
} else { } else {
callback(res); callback(res);
@ -498,6 +508,7 @@
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showScanMessage(err.message); this.showScanMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });

11
fe/PDA/pages/task/kittingIssueJobDetailByQty.vue

@ -152,7 +152,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue' import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue'
@ -256,11 +258,12 @@
getFromLocation(locationInfo) { getFromLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendFromLocationCode) { if (locationInfo.code != current.recommendFromLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current
.recommendFromLocationCode + "]不一致,请重新扫描") .recommendFromLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
current.handledFromLocationCode = locationInfo.code current.handledFromLocationCode = locationInfo.code
current.handledFromLocationArea = locationInfo.locationArea current.handledFromLocationArea = locationInfo.locationArea
current.handledFromLocationGroup = locationInfo.locationGroup current.handledFromLocationGroup = locationInfo.locationGroup
@ -274,10 +277,12 @@
getToLocation(locationInfo) { getToLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
this.toLocationInfo = locationInfo this.toLocationInfo = locationInfo
current.handledToLocationCode = locationInfo.code current.handledToLocationCode = locationInfo.code
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationArea = locationInfo.areaCode
@ -383,9 +388,11 @@
}); });
if (item == undefined) { if (item == undefined) {
scanFailedAudio()
this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】'); this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】');
return; return;
} }
scanSuccessAudio()
this.singCode = result.itemCode this.singCode = result.itemCode
this.$refs.scanPackPopup.closeScanPopup(); this.$refs.scanPackPopup.closeScanPopup();

8
fe/PDA/pages/task/receipt.vue

@ -38,7 +38,9 @@
import { import {
getJobStatuStyle, getJobStatuStyle,
getJobStatuDesc, getJobStatuDesc,
goHome goHome,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue' import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue'
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
@ -233,13 +235,17 @@
getReceiptJobByAsnNumber(params).then(res => { getReceiptJobByAsnNumber(params).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res.totalCount == 0) { if (res.totalCount == 0) {
scanFailedAudio()
that.showMessage('未查找到' + type + '为【' + code + '】的收货任务'); that.showMessage('未查找到' + type + '为【' + code + '】的收货任务');
} else if (res.totalCount == 1) { } else if (res.totalCount == 1) {
scanSuccessAudio()
that.openDetail(res.items[0]); that.openDetail(res.items[0]);
} else { } else {
scanSuccessAudio()
this.showItemList(res.items); this.showItemList(res.items);
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
that.showMessage(err.message); that.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });

7
fe/PDA/pages/task/receipt_detail.vue

@ -102,7 +102,9 @@
getJobStatuDesc, getJobStatuDesc,
showConfirmMsg, showConfirmMsg,
compareDesc, compareDesc,
goHome goHome,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
@ -283,6 +285,7 @@
}); });
if (datas.length === 0) { if (datas.length === 0) {
scanFailedAudio()
this.showScanMessage('在收货任务详情中,未找到箱码【' + code + '】'); this.showScanMessage('在收货任务详情中,未找到箱码【' + code + '】');
} else { } else {
if (datas.length === 1) { if (datas.length === 1) {
@ -320,9 +323,11 @@
if (res != null) { if (res != null) {
this.afterPurchase(); this.afterPurchase();
} }
scanSuccessAudio()
this.scanPopupGetFocus(); this.scanPopupGetFocus();
uni.hideLoading(); uni.hideLoading();
}).catch(err => { }).catch(err => {
scanFailedAudio()
this.showMessage(err.message) this.showMessage(err.message)
uni.hideLoading(); uni.hideLoading();
}) })

7
fe/PDA/pages/task/sparePartIssueJob.vue

@ -29,7 +29,9 @@
import { import {
goHome, goHome,
getIssueJobState getIssueJobState,
scanSuccessAudio,
scanFailedAudio,
} from '@/common/basic.js'; } from '@/common/basic.js';
import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue' import winEmptyView from '@/mycomponents/wincom/winEmptyView.vue'
@ -151,12 +153,15 @@
getSparePartIssueJobByPackingCode(result.data.code).then(res=>{ getSparePartIssueJobByPackingCode(result.data.code).then(res=>{
uni.hideLoading(); uni.hideLoading();
if(res){ if(res){
scanSuccessAudio()
this.$refs.scanPopup.closeScanPopup(); this.$refs.scanPopup.closeScanPopup();
this.openDetail(res) this.openDetail(res)
}else { }else {
scanFailedAudio()
this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务"); this.showMessage("按箱码["+result.data.code+"]没有查找到发料任务");
} }
}).catch(error=>{ }).catch(error=>{
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.showMessage(error.message); this.showMessage(error.message);
}) })

14
fe/PDA/pages/task/sparePartIssueJobDetail.vue

@ -185,7 +185,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -283,10 +285,12 @@
geToLocationss(locationInfo) { geToLocationss(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage(" 扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
current.handledToLocationCode = locationInfo.code current.handledToLocationCode = locationInfo.code
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationArea = locationInfo.areaCode
current.handledToLocationGroup = locationInfo.locationGroupCode current.handledToLocationGroup = locationInfo.locationGroupCode
@ -298,15 +302,19 @@
locations(locationCode).then((res) => { locations(locationCode).then((res) => {
uni.hideLoading(); uni.hideLoading();
if (res) { if (res) {
scanSuccessAudio()
current.handledToLocationCode = res.code current.handledToLocationCode = res.code
current.handledToLocationArea = res.locationArea current.handledToLocationArea = res.locationArea
current.handledToLocationGroup = res.locationGroup current.handledToLocationGroup = res.locationGroup
current.handledToLocationErpCode = res.locationErpCode current.handledToLocationErpCode = res.locationErpCode
} else { } else {
scanFailedAudio()
this.showMessage('未查找到库位【' + locationCode + '】'); this.showMessage('未查找到库位【' + locationCode + '】');
} }
}).catch((err) => { }).catch((err) => {
scanFailedAudio()
uni.hideLoading();
this.showMessage(err.message); this.showMessage(err.message);
}) })
}, },
@ -397,13 +405,16 @@
var fromData = result.data; var fromData = result.data;
var data = this.details.filter(r => r.itemCode == result.data.itemCode) var data = this.details.filter(r => r.itemCode == result.data.itemCode)
if (data.length == 0) { if (data.length == 0) {
scanFailedAudio()
this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中") this.showMessage("扫描的箱码[" + fromData.code + "]的物品不在列表中")
return; return;
} }
if (this.jobStatus == 30) { if (this.jobStatus == 30) {
if (fromData.code == this.details[0].recommendFromPackingCode) { if (fromData.code == this.details[0].recommendFromPackingCode) {
scanFailedAudio()
this.showMessage("请先完成库移后在扫描箱码") this.showMessage("请先完成库移后在扫描箱码")
} else { } else {
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0] showConfirmMsg("扫描的箱码[" + fromData.code + "]与推荐的箱码[" + this.details[0]
.recommendFromPackingCode + .recommendFromPackingCode +
@ -451,6 +462,7 @@
item.handleToPackingCodeLocationCode = balancesItem.locationCode item.handleToPackingCodeLocationCode = balancesItem.locationCode
this.getToLocation(this.details[0].recommendToLocationCode) this.getToLocation(this.details[0].recommendToLocationCode)
} else { } else {
scanFailedAudio()
showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot + "]与推荐目标批次[" + item showConfirmMsg("箱码[" + fromData.code + "]的批次[" + balancesItem.lot + "]与推荐目标批次[" + item
.recommendToLot + "]不一致,是否继续发料", res => { .recommendToLot + "]不一致,是否继续发料", res => {
if (res) { if (res) {

11
fe/PDA/pages/task/sparePartIssueJobDetailByQty.vue

@ -153,7 +153,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue' import winScanButtonLeft from '@/mycomponents/wincom/winScanButtonLeft.vue'
@ -255,11 +257,12 @@
getFromLocation(locationInfo) { getFromLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendFromLocationCode) { if (locationInfo.code != current.recommendFromLocationCode) {
scanFailedAudio()
this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current this.showMessage(" 扫描来源库位[" + locationInfo.code + "]与推荐来源库位[" + current
.recommendFromLocationCode + "]不一致,请重新扫描") .recommendFromLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
current.handledFromLocationCode = locationInfo.code current.handledFromLocationCode = locationInfo.code
current.handledFromLocationArea = locationInfo.locationArea current.handledFromLocationArea = locationInfo.locationArea
current.handledFromLocationGroup = locationInfo.locationGroup current.handledFromLocationGroup = locationInfo.locationGroup
@ -273,10 +276,12 @@
getToLocation(locationInfo) { getToLocation(locationInfo) {
var current = this.details[0] var current = this.details[0]
if (locationInfo.code != current.recommendToLocationCode) { if (locationInfo.code != current.recommendToLocationCode) {
scanFailedAudio()
this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current this.showMessage("扫描目标库位[" + locationInfo.code + "]与推荐目标库位[" + current
.recommendToLocationCode + "]不一致,请重新扫描") .recommendToLocationCode + "]不一致,请重新扫描")
return; return;
} }
scanSuccessAudio()
this.toLocationInfo = locationInfo this.toLocationInfo = locationInfo
current.handledToLocationCode = locationInfo.code current.handledToLocationCode = locationInfo.code
current.handledToLocationArea = locationInfo.areaCode current.handledToLocationArea = locationInfo.areaCode
@ -381,9 +386,11 @@
}); });
if (item == undefined) { if (item == undefined) {
scanFailedAudio()
this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】'); this.showMessage('在任务详情中,未找到ERP料号【' + result.itemCode + '】');
return; return;
} }
scanSuccessAudio()
this.singCode = result.itemCode this.singCode = result.itemCode
this.$refs.scanPackPopup.closeScanPopup(); this.$refs.scanPackPopup.closeScanPopup();

8
fe/PDA/pages/task/thirdLocationJobDetail.vue

@ -120,7 +120,9 @@
showConfirmMsg, showConfirmMsg,
goHome, goHome,
navigateBack, navigateBack,
deepCopyData deepCopyData,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import { import {
calc calc
@ -217,6 +219,7 @@
// //
getDefaultToLocation(locationCode) { getDefaultToLocation(locationCode) {
if(this.details[0].toLocationCode!=locationCode){ if(this.details[0].toLocationCode!=locationCode){
scanFailedAudio()
this.showMessage("扫描库位["+locationCode+"]与目标库位["+this.details[0].toLocationCode+"]不一致"); this.showMessage("扫描库位["+locationCode+"]与目标库位["+this.details[0].toLocationCode+"]不一致");
this.$refs.comCollapseLocation.clearLocation() this.$refs.comCollapseLocation.clearLocation()
return; return;
@ -228,13 +231,16 @@
locations(locationCode).then(res => { locations(locationCode).then(res => {
uni.hideLoading(); uni.hideLoading();
if (res) { if (res) {
scanSuccessAudio()
this.toLocationInfo = res this.toLocationInfo = res
} else { } else {
scanFailedAudio()
this.$refs.comCollapseLocation.clearLocation() this.$refs.comCollapseLocation.clearLocation()
this.showMessage('目标库位【' + locationCode + '】不存在'); this.showMessage('目标库位【' + locationCode + '】不存在');
} }
}).catch(err => { }).catch(err => {
scanFailedAudio()
uni.hideLoading(); uni.hideLoading();
this.toLocationInfo = null this.toLocationInfo = null
this.$refs.comCollapseLocation.clearLocation() this.$refs.comCollapseLocation.clearLocation()

14
fe/PDA/pages/task/unProducePickDetail.vue

@ -124,7 +124,9 @@
goHome, goHome,
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime getCurrDateTime,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -265,6 +267,7 @@
let item = this.details.find(r => r.recommendPackingCode === result.data.packingCode && r let item = this.details.find(r => r.recommendPackingCode === result.data.packingCode && r
.scanPackingCode != result.data.packingCode); .scanPackingCode != result.data.packingCode);
if (item != undefined && item.scaned) { if (item != undefined && item.scaned) {
scanFailedAudio()
showConfirmMsg('扫描的箱码【' + result.data.packingCode + '】匹配到任务中的【' + item.scanPackingCode + showConfirmMsg('扫描的箱码【' + result.data.packingCode + '】匹配到任务中的【' + item.scanPackingCode +
'】箱,是否要重新匹配任务中的【' + item.scanPackingCode + '】箱?', '】箱,是否要重新匹配任务中的【' + item.scanPackingCode + '】箱?',
confirm => { confirm => {
@ -276,6 +279,7 @@
}) })
} else { } else {
if (this.allCount === this.scanCount) { if (this.allCount === this.scanCount) {
scanFailedAudio()
this.showMessage("零件已经全部扫描完成"); this.showMessage("零件已经全部扫描完成");
return; return;
} }
@ -295,6 +299,7 @@
r.scanLot === that.currentScanLebel.data.lot && r.scanLot === that.currentScanLebel.data.lot &&
r.scaned == true) r.scaned == true)
if (scanItem != undefined) { if (scanItem != undefined) {
scanFailedAudio()
this.showScanMessage('箱码【' + that.currentScanLebel.data.packingCode + '】已经扫描,请扫描下一箱零件'); this.showScanMessage('箱码【' + that.currentScanLebel.data.packingCode + '】已经扫描,请扫描下一箱零件');
} else { } else {
this.dyIssue(result, scaned); this.dyIssue(result, scaned);
@ -308,6 +313,7 @@
r.scaned === scaned r.scaned === scaned
}) })
if (itemCode == undefined) { if (itemCode == undefined) {
scanFailedAudio()
that.showScanMessage('所扫描的箱码【' + result.data.code + '】对应的物料【' + result.data.itemCode + '】不在任务中'); that.showScanMessage('所扫描的箱码【' + result.data.code + '】对应的物料【' + result.data.itemCode + '】不在任务中');
} else { } else {
//ERP //ERP
@ -327,6 +333,7 @@
if (itemCode2 == undefined) { if (itemCode2 == undefined) {
//ERP //ERP
console.log("ERP料号相同、箱码不相同、批次不相同") console.log("ERP料号相同、箱码不相同、批次不相同")
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg(itemCode.recommendPackingCode + '未执行先进先出或不是最先批次,是否继续?', confirm => { showConfirmMsg(itemCode.recommendPackingCode + '未执行先进先出或不是最先批次,是否继续?', confirm => {
if (confirm) { if (confirm) {
@ -357,6 +364,7 @@
if (itemCode3 == undefined) { if (itemCode3 == undefined) {
//ERP //ERP
console.log("ERP料号相同、箱码相同、批次不同") console.log("ERP料号相同、箱码相同、批次不同")
scanFailedAudio()
setTimeout(res => { setTimeout(res => {
showConfirmMsg(itemCode1.recommendPackingCode + '未执行先进先出或不是最先批次,是否继续?', showConfirmMsg(itemCode1.recommendPackingCode + '未执行先进先出或不是最先批次,是否继续?',
confirm => { confirm => {
@ -374,6 +382,7 @@
//ERP //ERP
that.currentItem = itemCode3; that.currentItem = itemCode3;
that.afterScanPackLabel(result); that.afterScanPackLabel(result);
} }
} }
} }
@ -414,15 +423,18 @@
getBalancesByFilter(params) getBalancesByFilter(params)
.then(res => { .then(res => {
if (res.totalCount === 0) { if (res.totalCount === 0) {
scanFailedAudio()
this.showScanMessage('按ERP料号【' + result.data.itemCode + '】箱码【' + result.data.code + '】批次【' + this.showScanMessage('按ERP料号【' + result.data.itemCode + '】箱码【' + result.data.code + '】批次【' +
result result
.data.lot + '】在【原料库】或【半成品库】或【成品库】未查询到库存信息'); .data.lot + '】在【原料库】或【半成品库】或【成品库】未查询到库存信息');
} else { } else {
scanSuccessAudio()
callback(res); callback(res);
} }
uni.hideLoading(); uni.hideLoading();
}) })
.catch(err => { .catch(err => {
scanFailedAudio()
this.showScanMessage(err.message); this.showScanMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}); });

10
fe/PDA/pages/task/unProducePickWipDetail.vue

@ -119,7 +119,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -223,10 +225,12 @@
getToLocation(locationInfo) { getToLocation(locationInfo) {
if (this.currentItem.recommendFromLocationCode != locationInfo.code) { if (this.currentItem.recommendFromLocationCode != locationInfo.code) {
scanFailedAudio()
this.showMessage("扫描库位[" + locationInfo.code + "]与推荐来源库位[" + this.currentItem this.showMessage("扫描库位[" + locationInfo.code + "]与推荐来源库位[" + this.currentItem
.recommendFromLocationCode + "]不一致") .recommendFromLocationCode + "]不一致")
return; return;
} }
scanSuccessAudio()
this.currentItem.handledFromLocationCode = locationInfo.code; this.currentItem.handledFromLocationCode = locationInfo.code;
this.currentItem.handledFromLocationArea = locationInfo.areaCode this.currentItem.handledFromLocationArea = locationInfo.areaCode
this.currentItem.handledFromLocationGroup = locationInfo.locationGroupCode this.currentItem.handledFromLocationGroup = locationInfo.locationGroupCode
@ -331,6 +335,7 @@
} }
this.getScanResult(result,false) this.getScanResult(result,false)
} else { } else {
scanFailedAudio()
this.showMessage('未查找到ERP料号【' + code + '】'); this.showMessage('未查找到ERP料号【' + code + '】');
} }
}).catch((err) => { }).catch((err) => {
@ -348,6 +353,7 @@
if (item == undefined) { if (item == undefined) {
if(isMesCode){ if(isMesCode){
scanFailedAudio()
this.showMessage('在任务详情中,单件码【' + result.scanCode + '】所对应的ERP料号与任务中的ERP料号不一致,请重新扫描'); this.showMessage('在任务详情中,单件码【' + result.scanCode + '】所对应的ERP料号与任务中的ERP料号不一致,请重新扫描');
}else { }else {
this.showMessage('在任务详情中,没有找到ERP料号[' + result.itemCode+"]的信息,请重新扫描"); this.showMessage('在任务详情中,没有找到ERP料号[' + result.itemCode+"]的信息,请重新扫描");
@ -357,12 +363,14 @@
} }
if (item.scaned) { if (item.scaned) {
if(isMesCode){ if(isMesCode){
scanFailedAudio()
this.showMessage('单件码[' + result.scanCode + "]已经扫描") this.showMessage('单件码[' + result.scanCode + "]已经扫描")
}else { }else {
this.showMessage('ERP料号[' + result.itemCode + "]已经扫描") this.showMessage('ERP料号[' + result.itemCode + "]已经扫描")
} }
} else { } else {
scanSuccessAudio()
item.scaned = true; item.scaned = true;
item.scanDate = new Date() item.scanDate = new Date()
this.details.sort(compareDesc('scanDate')); this.details.sort(compareDesc('scanDate'));

7
fe/PDA/pages/task/unProduceReturnDetail.vue

@ -122,7 +122,9 @@
goHome, goHome,
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime getCurrDateTime,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -264,6 +266,7 @@
.scanPackingCode != result.data.packingCode); .scanPackingCode != result.data.packingCode);
if (item != undefined && item.scaned) { if (item != undefined && item.scaned) {
scanFailedAudio()
showConfirmMsg('扫描的箱码【' + result.data.packingCode + '】匹配到任务中的【' + item.scanPackingCode + showConfirmMsg('扫描的箱码【' + result.data.packingCode + '】匹配到任务中的【' + item.scanPackingCode +
'】箱,是否要重新匹配任务中的【' + item.scanPackingCode + '】箱?', '】箱,是否要重新匹配任务中的【' + item.scanPackingCode + '】箱?',
confirm => { confirm => {
@ -275,6 +278,7 @@
}) })
} else { } else {
if (this.allCount === this.scanCount) { if (this.allCount === this.scanCount) {
scanFailedAudio()
this.showMessage("零件已经全部扫描完成"); this.showMessage("零件已经全部扫描完成");
return; return;
} }
@ -458,6 +462,7 @@
afterScanPackLabel(result) { afterScanPackLabel(result) {
this.setParams(this.currentItem, result) this.setParams(this.currentItem, result)
this.scanPopupGetFocus(); this.scanPopupGetFocus();
scanSuccessAudio()
}, },
// // // //

9
fe/PDA/pages/task/unProduceReturnWipDetail.vue

@ -119,7 +119,9 @@
compareDesc, compareDesc,
compareStr, compareStr,
getCurrDateTime, getCurrDateTime,
navigateBack navigateBack,
scanSuccessAudio,
scanFailedAudio
} from '@/common/basic.js'; } from '@/common/basic.js';
import comMessage from '@/mycomponents/common/comMessage.vue' import comMessage from '@/mycomponents/common/comMessage.vue'
import winScanButton from '@/mycomponents/wincom/winScanButton.vue' import winScanButton from '@/mycomponents/wincom/winScanButton.vue'
@ -329,9 +331,11 @@
} }
this.getScanResult(result,false) this.getScanResult(result,false)
} else { } else {
scanFailedAudio()
this.showMessage('未查找到ERP料号【' + code + '】'); this.showMessage('未查找到ERP料号【' + code + '】');
} }
}).catch((err) => { }).catch((err) => {
scanFailedAudio()
this.showMessage(err.message); this.showMessage(err.message);
uni.hideLoading(); uni.hideLoading();
}) })
@ -346,6 +350,7 @@
if (item == undefined) { if (item == undefined) {
if(isMesCode){ if(isMesCode){
scanFailedAudio()
this.showMessage('在任务详情中,单件码【' + result.scanCode + '】所对应的ERP料号与任务中的ERP料号不一致,请重新扫描'); this.showMessage('在任务详情中,单件码【' + result.scanCode + '】所对应的ERP料号与任务中的ERP料号不一致,请重新扫描');
}else { }else {
this.showMessage('在任务详情中,没有找到ERP料号[' + result.itemCode+"]的信息,请重新扫描"); this.showMessage('在任务详情中,没有找到ERP料号[' + result.itemCode+"]的信息,请重新扫描");
@ -355,12 +360,14 @@
} }
if (item.scaned) { if (item.scaned) {
if(isMesCode){ if(isMesCode){
scanFailedAudio()
this.showMessage('单件码[' + result.scanCode + "]已经扫描") this.showMessage('单件码[' + result.scanCode + "]已经扫描")
}else { }else {
this.showMessage('ERP料号[' + result.itemCode + "]已经扫描") this.showMessage('ERP料号[' + result.itemCode + "]已经扫描")
} }
} else { } else {
scanSuccessAudio()
item.scaned = true; item.scaned = true;
item.scanDate = new Date() item.scanDate = new Date()
this.details.sort(compareDesc('scanDate')); this.details.sort(compareDesc('scanDate'));

BIN
fe/PDA/static/video/scan_failed.mp3

Binary file not shown.

BIN
fe/PDA/static/video/scan_success.mp3

Binary file not shown.

2
fe/PDA/uni_modules/wz-select-input/package.json

@ -31,7 +31,7 @@
"npmurl": "" "npmurl": ""
}, },
"uni_modules": { "uni_modules": {
"dependencies": ["wz-select-popup"], "dependencies": ["wz-select-popup","wz-select-popup-customer"],
"encrypt": [], "encrypt": [],
"platforms": { "platforms": {
"cloud": { "cloud": {

12
fe/PDA/uni_modules/wz-select-popup/components/wz-select-popup/wz-list.vue

@ -8,12 +8,17 @@
</view> </view>
({{index+1}}) ({{index+1}})
<view class="uni-flex" style="flex-direction: column; font-size: 32rpx;"> <view v-if="isShowItem" class="uni-flex" style="flex-direction: column; font-size: 32rpx;">
<view class="list-item-text">ERP料号 : {{item.itemCode}}</view> <view class="list-item-text">ERP料号 : {{item.itemCode}}</view>
<view class="list-item-text">名称 : {{item.itemName}}</view> <view class="list-item-text">名称 : {{item.itemName}}</view>
<view class="list-item-text">描述 : {{item.itemDesc1}}</view> <view class="list-item-text">描述 : {{item.itemDesc1}}</view>
</view> </view>
<view v-else class="uni-flex" style="flex-direction: column; font-size: 32rpx;">
<view class="list-item-text">客户代码 : {{item.code}}</view>
<view class="list-item-text">客户名称 : {{item.name}}</view>
</view>
</view> </view>
<view class="loadmore" @click="$emit('loadmore')"> <view class="loadmore" @click="$emit('loadmore')">
<view v-if="page.loading == 'loading'" class="icon"> <view v-if="page.loading == 'loading'" class="icon">
@ -32,6 +37,11 @@
type: Array, type: Array,
default: () => [] default: () => []
}, },
isShowItem: {
type: Boolean,
default: true
},
isShowIcon: { isShowIcon: {
type: Boolean, type: Boolean,
default: true default: true

15
fe/PDA/uni_modules/wz-select-popup/components/wz-select-popup/wz-select-popup.vue

@ -16,7 +16,9 @@
<scroll-view class="popup-scroll-y" :scroll-top="scroll.newTop" scroll-y <scroll-view class="popup-scroll-y" :scroll-top="scroll.newTop" scroll-y
:style="{'--popup-scroll-height': scrollH}" @scrolltolower="scrolltolower" @scroll="viewScroll"> :style="{'--popup-scroll-height': scrollH}" @scrolltolower="scrolltolower" @scroll="viewScroll">
<wz-list :list="dataList" :fields="popConfig.fields" :page="pageStatus" @checkList="checkList" <wz-list :list="dataList" :fields="popConfig.fields" :page="pageStatus" @checkList="checkList"
@loadmore="scrolltolower" :isShowIcon="false" /> @loadmore="scrolltolower"
:isShowItem="isShowItem"
:isShowIcon="false" />
</scroll-view> </scroll-view>
<view v-if="popConfig.mode =='checkbox'" class="footer-button"> <view v-if="popConfig.mode =='checkbox'" class="footer-button">
<view class="button-item"> <view class="button-item">
@ -68,6 +70,12 @@
type: String, type: String,
default: '物料查询' default: '物料查询'
}, },
isShowItem: {
type: Boolean,
default: true
},
}, },
@ -239,6 +247,11 @@
this.handleSelected(list.items) this.handleSelected(list.items)
this.dataList = this.dataList.concat(list.items) this.dataList = this.dataList.concat(list.items)
}).catch(error=>{
uni.hideLoading()
uni.showToast({
title:"请求失败"
})
}) })
}, },
close() { close() {

Loading…
Cancel
Save