|
|
@@ -360,8 +360,9 @@ export default {
|
|
|
pass: true
|
|
|
}
|
|
|
});
|
|
|
- if (approveRes.data.code == '-1') {
|
|
|
- throw new Error(approveRes.data.msg || '审批失败');
|
|
|
+ const result = approveRes && approveRes.data;
|
|
|
+ if (!result || Number(result.code) !== 0) {
|
|
|
+ throw new Error((result && (result.message || result.msg)) || '审批失败');
|
|
|
}
|
|
|
await storageApi.outStorage(storageData);
|
|
|
this.$message.success(`出库成功!`);
|