|
@ -32,7 +32,7 @@ |
|
|
</view> |
|
|
</view> |
|
|
<view class="dec" style="font-weight: bold;"> |
|
|
<view class="dec" style="font-weight: bold;"> |
|
|
<view >补料数量:</view> |
|
|
<view >补料数量:</view> |
|
|
<view > <u-input v-model="item.srcMaterialCounts" type="number" placeholder="补料数量" border="true" clearable="true" style="width: 100px;" /> |
|
|
<view > <u-input v-model="item.srcMaterialCounts" type="number" placeholder="补料数量" border="true" clearable="true" style="width: 100px;" @update:modelValue="calculatePass(item,queryForm.planCount)" /> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
<view class="dec"> |
|
|
<view class="dec"> |
|
@ -112,6 +112,24 @@ |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
function calculatePass(item,planCount){ |
|
|
|
|
|
const count = item.repMaterialCounts * planCount |
|
|
|
|
|
if(item.srcMaterialCounts > count){ |
|
|
|
|
|
proxy.$modal.showToast('数量不能超过最大物料数') |
|
|
|
|
|
setTimeout(() => { |
|
|
|
|
|
item.srcMaterialCounts=count |
|
|
|
|
|
proxy.$modal.closeLoading() |
|
|
|
|
|
}, 500) |
|
|
|
|
|
} |
|
|
|
|
|
if(item.srcMaterialCounts <= 0 ){ |
|
|
|
|
|
proxy.$modal.showToast('数量必须大于0') |
|
|
|
|
|
setTimeout(() => { |
|
|
|
|
|
item.srcMaterialCounts=1 |
|
|
|
|
|
proxy.$modal.closeLoading() |
|
|
|
|
|
}, 500) |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
// 提交事件 |
|
|
// 提交事件 |
|
|
function handleSubmit(){ |
|
|
function handleSubmit(){ |
|
|
saveData.value.planDayCode = queryForm.value.planNoDay |
|
|
saveData.value.planDayCode = queryForm.value.planNoDay |
|
|