|
@@ -10,7 +10,7 @@
|
|
<el-button type="primary" @click="getSplitLogList">查找</el-button>
|
|
<el-button type="primary" @click="getSplitLogList">查找</el-button>
|
|
</el-col>
|
|
</el-col>
|
|
<el-col :span="4">
|
|
<el-col :span="4">
|
|
- <el-button type="primary" @click="add">新增</el-button>
|
|
|
|
|
|
+ <!-- <el-button type="primary" @click="add">新增</el-button> -->
|
|
</el-col>
|
|
</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
</header>
|
|
</header>
|
|
@@ -30,10 +30,11 @@
|
|
<el-table-column prop="splitBatchNo" label="分割批次"></el-table-column>
|
|
<el-table-column prop="splitBatchNo" label="分割批次"></el-table-column>
|
|
<el-table-column label="操作" width="150">
|
|
<el-table-column label="操作" width="150">
|
|
<template slot-scope="scope">
|
|
<template slot-scope="scope">
|
|
- <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
|
|
|
|
- <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
|
|
|
|
|
|
+ <!-- <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button> -->
|
|
|
|
+ <el-button @click="weigh(scope.row)" type="text" size="small">称重</el-button>
|
|
|
|
+ <!-- <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
|
|
<el-button slot="reference" type="text" size="small">删除</el-button>
|
|
<el-button slot="reference" type="text" size="small">删除</el-button>
|
|
- </el-popconfirm>
|
|
|
|
|
|
+ </el-popconfirm>-->
|
|
</template>
|
|
</template>
|
|
</el-table-column>
|
|
</el-table-column>
|
|
</el-table>
|
|
</el-table>
|
|
@@ -83,6 +84,22 @@
|
|
</el-col>
|
|
</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
|
|
+
|
|
|
|
+ <el-dialog title="称重" :visible.sync="isShowWeigh" width="40%">
|
|
|
|
+ <el-row type="flex">
|
|
|
|
+ <el-col :span="20">
|
|
|
|
+ <el-form ref="Weigh" :model="formData_1" :rules="rules" label-width="140px">
|
|
|
|
+ <el-form-item label="重量">
|
|
|
|
+ <el-input v-model="formData_1.weight"></el-input>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ <el-form-item>
|
|
|
|
+ <el-button @click="isShow=false">取 消</el-button>
|
|
|
|
+ <el-button type="primary" @click="submitForm_1('Weigh')">保 存</el-button>
|
|
|
|
+ </el-form-item>
|
|
|
|
+ </el-form>
|
|
|
|
+ </el-col>
|
|
|
|
+ </el-row>
|
|
|
|
+ </el-dialog>
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
|
|
|
|
@@ -91,7 +108,8 @@ import {
|
|
reqSplitLogList,
|
|
reqSplitLogList,
|
|
reqAddSplitLog,
|
|
reqAddSplitLog,
|
|
reqUpdateSplitLog,
|
|
reqUpdateSplitLog,
|
|
- reqDelSplitLog
|
|
|
|
|
|
+ reqDelSplitLog,
|
|
|
|
+ reqWeight
|
|
} from "@/api/productManagement.js";
|
|
} from "@/api/productManagement.js";
|
|
|
|
|
|
const pageSize = 10;
|
|
const pageSize = 10;
|
|
@@ -106,6 +124,7 @@ export default {
|
|
tableData: [],
|
|
tableData: [],
|
|
totalPages: 0,
|
|
totalPages: 0,
|
|
isShow: false,
|
|
isShow: false,
|
|
|
|
+ isShowWeigh: false,
|
|
formData: {
|
|
formData: {
|
|
productUniqueNo: "",
|
|
productUniqueNo: "",
|
|
productName: "带骨羊前腿",
|
|
productName: "带骨羊前腿",
|
|
@@ -113,6 +132,10 @@ export default {
|
|
weight: "35",
|
|
weight: "35",
|
|
splitBatchNo: "1548"
|
|
splitBatchNo: "1548"
|
|
},
|
|
},
|
|
|
|
+ formData_1: {
|
|
|
|
+ productUniqueNo: "",
|
|
|
|
+ weight: ""
|
|
|
|
+ },
|
|
isAdd: false,
|
|
isAdd: false,
|
|
rules
|
|
rules
|
|
};
|
|
};
|
|
@@ -163,6 +186,21 @@ export default {
|
|
}
|
|
}
|
|
});
|
|
});
|
|
},
|
|
},
|
|
|
|
+ submitForm_1(formName) {
|
|
|
|
+ this.$refs[formName].validate(valid => {
|
|
|
|
+ if (valid) {
|
|
|
|
+ reqWeight(this.formData_1).then(res => {
|
|
|
|
+ if (res.errCode) {
|
|
|
|
+ this.$message.error(res.errMsg);
|
|
|
|
+ } else {
|
|
|
|
+ this.$message.success("成功");
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ } else {
|
|
|
|
+ return false;
|
|
|
|
+ }
|
|
|
|
+ });
|
|
|
|
+ },
|
|
// 分割登记列表
|
|
// 分割登记列表
|
|
getSplitLogList() {
|
|
getSplitLogList() {
|
|
reqSplitLogList({
|
|
reqSplitLogList({
|
|
@@ -182,6 +220,11 @@ export default {
|
|
this.isShow = true;
|
|
this.isShow = true;
|
|
this.isAdd = true;
|
|
this.isAdd = true;
|
|
},
|
|
},
|
|
|
|
+ weigh(row) {
|
|
|
|
+ console.log(row);
|
|
|
|
+ this.formData_1.productUniqueNo = row.productUniqueNo;
|
|
|
|
+ this.isShowWeigh = true;
|
|
|
|
+ },
|
|
edit(row) {
|
|
edit(row) {
|
|
this.formData = row;
|
|
this.formData = row;
|
|
this.isShow = true;
|
|
this.isShow = true;
|