Administrator
7 days ago eb5e30f805f93f275f37fbe11cb1aefe6ccaa55e
src/main/java/com/xcong/excoin/modules/gateApi/GateGridTradeService.java
@@ -1356,11 +1356,11 @@
        String reason = "";
        if (hasLong && hasShort) {
            // 多空双边持仓:多均价 − 空均价 > span × step
            BigDecimal gap = longAvgPrice.subtract(shortAvgPrice);
            // 多空双边持仓:|多均价 − 空均价| > span × step
            BigDecimal gap = shortAvgPrice.subtract(longAvgPrice);
            if (gap.compareTo(threshold) >= 0) {
                shouldRestart = true;
                reason = StrUtil.format("双边跨度 多均价:{} − 空均价:{} = {} > {} (span:{}×step:{})",
                reason = StrUtil.format("双边跨度 |多均价:{} − 空均价:{}| = {} >= {} (span:{}×step:{})",
                        longAvgPrice, shortAvgPrice, gap, threshold, span, step);
            }
        } else if (hasLong) {