This commit is contained in:
2025-11-05 20:46:47 +08:00
parent 75521c5102
commit 5712c8bbd2

View File

@@ -1175,12 +1175,12 @@ private String handleTF(String input) {
return warn;
}
// 验证2如果京粉实际价格不为空检查与付款金额是否一致
// 验证2如果京粉实际价格不为空检查与付款金额的差值是否大于等于100
if (order.getJingfenActualPrice() != null && order.getPaymentAmount() != null) {
double diff = Math.abs(order.getPaymentAmount() - order.getJingfenActualPrice());
// 如果金额不一致允许0.01的浮点数误差),则提示警告
if (diff > 0.01) {
String warn = "[炸弹] [炸弹] [炸弹] 录单警告!!! \n付款金额和实际金额不一致,请联系管理员录单\n" +
// 如果差额大于等于100,则提示警告
if (diff >= 100.0) {
String warn = "[炸弹] [炸弹] [炸弹] 录单警告!!! \n付款金额和实际金额相差" + String.format("%.2f", diff) + ",请联系管理员录单\n" +
"付款金额:" + order.getPaymentAmount() + "\n" +
"京粉实际价格:" + order.getJingfenActualPrice() + "\n" +
"差额:" + String.format("%.2f", diff);