拣货完成,回传库存信息到mes,数量为0

修改回库库存新增交易表bug
出库页面和功能整改
This commit is contained in:
zgf committed 2023-12-04 23:47:03 +08:00
1 parent 11ea24c544
commit aacf491051
4 files changed
+167 -78

No files matched your search

@@ -4,7 +4,7 @@
<el-row>
<el-col :span="4">
<el-form-item label="类型" prop="type">
<el-select v-model="type"
<el-select v-model="form.type"
placeholder="请选择类型"
style="width: 100%"
@@change="select"
@@ -109,11 +109,17 @@
select(data) {
this.form.code = "";
this.form.type = data;
this.invTable = [];
if (this.invTable.length == 0
&& this.form.type == "slbox"
&& this.form.code.startsWith("C")) {
this.showBack = true;
}
},
// 扫描料塔站台号
scanCode(data) {
var _this = this;
if (_this.type == "") {
if (_this.form.type == "") {
_this.$message({
message: "请先选择操作类型!",
type: "warning",
@@ -123,7 +129,7 @@
return;
}
let url = "";
if (_this.type == "uniqueCode") {
if (_this.form.type == "uniqueCode") {
url = "/shipment/ShipOut/ScanUniqueCode"
}
else{
@@ -132,7 +138,7 @@
$.ajax({
type: "post",
dataType: "json",
data: { code: _this.form.code },
data: { code: _this.form.code, type: _this.form.type },
url: url,
success: function (json) {
if (json.Code != 200) {
@@ -141,8 +147,9 @@
type: "warning",
duration: "10000",
});
_this.form.code = "";
} else {
if (_this.type == "uniqueCode") {
if (_this.form.type == "uniqueCode") {
_this.form.uniqueCode = json.Data.UniqueCode;
_this.form.materialCode = json.Data.MaterialCode;
_this.form.materialSpec = json.Data.MaterialSpec;
@@ -151,6 +158,11 @@
} else {
_this.showTable = true;
_this.invTable = json.Data;
if (_this.invTable.length == 0
&& _this.form.type == "slbox"
&& _this.form.code.startsWith("C")) {
_this.showBack = true;
}
}
}
},
@@ -166,7 +178,14 @@
// 拣货
onSubmit() {
var _this = this;
if (_this.form.uniqueCode == "") {
_this.$message({
message: "未选择出库明细!",
type: "warning",
duration: "10000",
});
return;
}
// 提交已绑定数据
$.ajax({
type: "post",
@@ -184,7 +203,9 @@
arr.splice(index, 1);
}
});
if (_this.invTable.length == 0 && _this.form.type == "slbox") {
if (_this.invTable.length == 0
&& _this.form.type == "slbox"
&& _this.form.code.startsWith("C")) {
_this.showBack = true;
}
_this.$refs['form'].resetFields();
@@ -209,7 +230,7 @@
back() {
var _this = this;
// 创建回库任务
if (_this.code == "") {
if (_this.form.code == "") {
_this.$message({
message: "箱号为空,不能创建回库任务!",
type: "error",