This commit is contained in:
van
2026-05-17 14:40:23 +08:00
parent 17ec7fa131
commit 0a3a9c46f6

View File

@@ -69,18 +69,18 @@ public class JDOrderProfitServiceImpl implements IJDOrderProfitService {
return;
}
if ("F".equals(mark) || mark.startsWith("F-")) {
if (!sellingLocked) {
fillSellingPriceFromConfig(order);
}
if (!profitLocked) {
computeProfitForF(order);
}
return;
// 其余分销标记:与 F / F-* / PDD / H / … 共用同一利润公式(含额外成本);须有售价渠道 + 售价才自动算出利润,否则清空
if (!sellingLocked) {
fillSellingPriceFromConfig(order);
}
if (!profitLocked) {
order.setProfit(null);
String type = order.getSellingPriceType();
Double sp = order.getSellingPrice();
if (type != null && !type.trim().isEmpty() && sp != null) {
computeProfitForF(order);
} else {
order.setProfit(null);
}
}
}