|
@@ -222,7 +222,7 @@
|
|
|
<template slot-scope="{ row, $index }">
|
|
|
<el-form :model="row" :rules="getRules2($index)" :ref="`boxFormRef${$index}`" :inline="true" style="margin-top: 20px;">
|
|
|
<el-form-item prop="oldActualBoxNum">
|
|
|
- <el-input v-model.number="row.oldActualBoxNum" size="mini" @input="iptChange"></el-input>
|
|
|
+ <el-input v-model="row.oldActualBoxNum" v-allow-decimal size="mini" @input="iptChange"></el-input>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
</template>
|
|
@@ -231,7 +231,7 @@
|
|
|
<template slot-scope="{ row, $index }">
|
|
|
<el-form :model="row" :rules="getRules1($index)" :ref="`weightFormRef${$index}`" :inline="true" style="margin-top: 20px;">
|
|
|
<el-form-item prop="oldActualWeight">
|
|
|
- <el-input v-model.number="row.oldActualWeight" size="mini" @input="iptChange"></el-input>
|
|
|
+ <el-input v-model="row.oldActualWeight" v-allow-decimal size="mini" @input="iptChange"></el-input>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
</template>
|
|
@@ -244,10 +244,10 @@
|
|
|
</el-table-column>
|
|
|
</el-table>
|
|
|
<pagination
|
|
|
- v-show="total > 0"
|
|
|
- :total="total"
|
|
|
- :page.sync="queryParams.pageNum"
|
|
|
- :limit.sync="queryParams.pageSize"
|
|
|
+ v-show="cktotal > 0"
|
|
|
+ :total="cktotal"
|
|
|
+ :page.sync="queryParams.ckpageNum"
|
|
|
+ :limit.sync="queryParams.ckpageSize"
|
|
|
@pagination="handleEditCkDo"
|
|
|
/>
|
|
|
</el-dialog>
|
|
@@ -273,6 +273,22 @@ export default {
|
|
|
props: [],
|
|
|
dicts: ["billing_type", "document_type"],
|
|
|
components: {FormList},
|
|
|
+ directives: {
|
|
|
+ 'allow-decimal': {
|
|
|
+ bind(el) {
|
|
|
+ el.addEventListener('input', () => {
|
|
|
+ let value = el.value;
|
|
|
+ // 允许数字和最多一个小数点
|
|
|
+ if (value.includes('.')) {
|
|
|
+ const parts = value.split('.');
|
|
|
+ el.value = parts[0] + '.' + parts.slice(1).join('');
|
|
|
+ } else {
|
|
|
+ el.value = value.replace(/[^0-9]/g, '');
|
|
|
+ }
|
|
|
+ });
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
data() {
|
|
|
// 校验箱数的自定义校验逻辑 rule:当前校验规则对象,value:当前字段值,callback 回调函数,用于通知校验结果。
|
|
|
// const validateOldActualWeight = (rule, value, callback) => {
|
|
@@ -316,8 +332,11 @@ export default {
|
|
|
// { validator: validateOldActualBoxNum, trigger: 'blur' } // 自定义校验规则
|
|
|
// ]
|
|
|
// },
|
|
|
+ cktotal:0,
|
|
|
tableData: [],
|
|
|
queryParams:{
|
|
|
+ ckpageNum:1,
|
|
|
+ ckpageSize:10,
|
|
|
pageNum: 1, // 第几页
|
|
|
pageSize: 10, // 每页大小
|
|
|
},
|
|
@@ -451,7 +470,7 @@ export default {
|
|
|
//查询老库存列表信息
|
|
|
let res1 = await queryTheOldInventoryDeliveryList(row);
|
|
|
//打开老库存列表弹窗
|
|
|
- this.total=res1.total;
|
|
|
+ this.cktotal=res1.total;
|
|
|
this.tableData=res1.rows;
|
|
|
this.dckOpen=true;
|
|
|
// 初始化表单引用数组
|
|
@@ -521,7 +540,7 @@ export default {
|
|
|
}else {
|
|
|
this.$message.error(this.$t('oldOutStock.message.outStockFailed'));
|
|
|
}
|
|
|
- this.dckOpen=false;
|
|
|
+ // this.dckOpen=false;
|
|
|
}
|
|
|
},
|
|
|
iptChange(value) {
|