|
|
@@ -464,9 +464,7 @@ impl BitgetSpotRest {
|
|
|
"symbol":symbol,
|
|
|
"limit":limit,
|
|
|
});
|
|
|
- if id_less_than.len() > 0 {
|
|
|
- params.as_object_mut().unwrap().insert("idLessThan".parse().unwrap(), serde_json::Value::from(id_less_than));
|
|
|
- }
|
|
|
+
|
|
|
if start_time.len() > 0 {
|
|
|
params.as_object_mut().unwrap().insert("startTime".parse().unwrap(), serde_json::Value::from(start_time));
|
|
|
}
|
|
|
@@ -504,9 +502,11 @@ impl BitgetSpotRest {
|
|
|
}
|
|
|
//批量撤销计划委托
|
|
|
pub async fn cancel_plan_orders(&mut self, symbol_list: Vec<String>) -> ResponseData {
|
|
|
- let params = serde_json::json!({
|
|
|
- "symbolList":symbol_list
|
|
|
+ let mut params = serde_json::json!({
|
|
|
});
|
|
|
+ if symbol_list.len() > 0 {
|
|
|
+ params.as_object_mut().unwrap().insert("symbolList".parse().unwrap(), serde_json::Value::from(symbol_list));
|
|
|
+ }
|
|
|
let data = self.request("POST".to_string(),
|
|
|
"/api/v2".to_string(),
|
|
|
"/spot/trade/batch-cancel-plan-order".to_string(),
|