|
@@ -298,10 +298,10 @@ impl Core {
|
|
|
|
|
|
|
|
// #[instrument(skip(self, data, trace_stack), level="TRACE")]
|
|
// #[instrument(skip(self, data, trace_stack), level="TRACE")]
|
|
|
pub async fn update_local_order(&mut self, data: OrderInfo, trace_stack: TraceStack) {
|
|
pub async fn update_local_order(&mut self, data: OrderInfo, trace_stack: TraceStack) {
|
|
|
- // if data.filled != Decimal::ZERO {
|
|
|
|
|
- // // info!("\n\n");
|
|
|
|
|
- // // info!("接收到订单信息①:{:?}", data);
|
|
|
|
|
- // }
|
|
|
|
|
|
|
+ if data.filled != Decimal::ZERO {
|
|
|
|
|
+ info!("\n\n");
|
|
|
|
|
+ info!("接收到订单信息①:{:?}", data);
|
|
|
|
|
+ }
|
|
|
/*
|
|
/*
|
|
|
更新订单
|
|
更新订单
|
|
|
首先直接复写本地订单
|
|
首先直接复写本地订单
|
|
@@ -367,7 +367,7 @@ impl Core {
|
|
|
let mut filled_order = data.clone();
|
|
let mut filled_order = data.clone();
|
|
|
filled_order.side = side.clone();
|
|
filled_order.side = side.clone();
|
|
|
|
|
|
|
|
- // info!("移除本地订单:{:?}, local_by_orders: {:?}", filled_order, self.local_position_by_orders);
|
|
|
|
|
|
|
+ info!("移除本地订单:{:?}, local_by_orders: {:?}", filled_order, self.local_position_by_orders);
|
|
|
// 如果是现货交易 还需要修改equity
|
|
// 如果是现货交易 还需要修改equity
|
|
|
if self.exchange.contains("spot") {
|
|
if self.exchange.contains("spot") {
|
|
|
// 现货必须考虑fee 买入fee单位为币 卖出fee单位为u
|
|
// 现货必须考虑fee 买入fee单位为币 卖出fee单位为u
|