Browse Source

买入平台币 现货时触发

JiahengHe 2 years ago
parent
commit
050c48f757
1 changed files with 6 additions and 0 deletions
  1. 6 0
      strategy/src/quant.rs

+ 6 - 0
strategy/src/quant.rs

@@ -1316,6 +1316,12 @@ impl Quant {
         self.local_cash = start_cash;
         self.local_cash = start_cash;
         self.local_coin = start_coin;
         self.local_coin = start_coin;
 
 
+        // 买入平台币
+        if self.exchange.contains("spot"){ // 现货
+            self.buy_token().await;
+        }
+
+
         // 清空挂单和仓位
         // 清空挂单和仓位
         self.check_position().await;
         self.check_position().await;
         /*
         /*