Commit 68c48c4e authored by 前端-钟卫鹏's avatar 前端-钟卫鹏

fix:处理仓位中获取仓位货品数量异常,处理采购询价下单删除商品运费变动异常和支付比例不为0的问题

parent b93d4c2d
......@@ -7,7 +7,7 @@ const { onFieldValueChange$ } = FormEffectHooks
export const useWarehouseSelect = (context: ISchemaFormActions) => {
onFieldValueChange$('warehouseId').subscribe(state => {
// 货品ID
const goodsId = context.getFieldValue('productId')
const goodsId = context.getFieldValue('goodsId')
const warehouseId = state.value
PublicApi.getWarehouseInventoryByItemNo({
warehouseId,
......
......@@ -79,6 +79,8 @@ export const MoneyTotalBox = registerVirtualBox('moneyTotalBox', props => {
setFreePrice(res.data)
}
})
} else {
setFreePrice(0)
}
}
}, [data])
......@@ -211,14 +213,14 @@ const PurchaseOrderDetail:React.FC<PurchaseOrderDetailProps> = (props) => {
}
// 校验是否选择支付渠道
let judgementByPay = params.paymentInformationResponses.map(item => {
if(item.channel && item.payWay){
if(item.channel && item.payWay && Number(item.payRatio)){
return true
} else {
return false
}
})
if(judgementByPay.includes(false)){
throw new Error('请选择支付方式或者支付渠道')
throw new Error('请正确填写支付信息')
}
// 校验采购数量
let judgementByCount = params.orderProductRequests.map(item => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment