Browse Source

修复开单录单配送费不计算bug

dev
qb 1 month ago
parent
commit
8026fa1d85
  1. 10
      src/views/distribution/inventory/CreateOrder.vue
  2. 10
      src/views/waybill/CreateZeroOrder.vue

10
src/views/distribution/inventory/CreateOrder.vue

@ -2868,11 +2868,13 @@ const destinationWarehouseNameChange = val => {
* row -- 行数据
* onlyComputedTrunline -- 是否只计算干线的价格
*/
const handleComputed = (row: any, onlyComputedTrunline = false) => {
const handleComputed = (row: any, onlyComputedTrunline = false, chargeType = null) => {
const { template, trunkLine } = details.priceTemplate;
if (Boolean(isDisabled.value && template && trunkLine && !onlyComputedTrunline))
handleSpecialBrandPrice(row, trunkLine, template, !onlyComputedTrunline);
if (Boolean(isDisabled.value && template && trunkLine)) {
if (!chargeType && !onlyComputedTrunline)
handleSpecialBrandPrice(row, trunkLine, template, onlyComputedTrunline);
}
details.query.goodsCode = '-' + details.totalObj.totalCount;
@ -4592,7 +4594,7 @@ const handleAssignmentItemPrice = (value, isOnload = false, chargeType?: number
}
//
if (!isOnload) handleComputed(value, !isOnload);
if (!isOnload) handleComputed(value, isOnload, chargeType);
};
/**

10
src/views/waybill/CreateZeroOrder.vue

@ -2158,11 +2158,13 @@ const handleFindGoods = async (goodsName, item, isClearId = 0) => {
* row -- 行数据
* onlyComputedTrunline -- 是否只计算干线的价格
*/
const handleComputed = (row: any, onlyComputedTrunline = false) => {
const handleComputed = (row: any, onlyComputedTrunline = false, chargeType = null) => {
const { template, trunkLine } = details.priceTemplate;
if (Boolean(isDisabled.value && template && trunkLine && !onlyComputedTrunline))
handleSpecialBrandPrice(row, trunkLine, template, !onlyComputedTrunline);
if (Boolean(isDisabled.value && template && trunkLine)) {
if (!chargeType && !onlyComputedTrunline)
handleSpecialBrandPrice(row, trunkLine, template, onlyComputedTrunline);
}
details.query.goodsCode = '-' + details.totalObj.totalCount;
@ -3684,7 +3686,7 @@ const handleAssignmentItemPrice = (value, isOnload = false, chargeType?: number
}
//
if (!isOnload) handleComputed(value, !isOnload);
if (!isOnload) handleComputed(value, isOnload, chargeType);
};
/**

Loading…
Cancel
Save