|
|
@@ -430,8 +430,16 @@ impl Platform for BitgetSpot {
|
|
|
Err(Error::new(ErrorKind::NotFound, "bitget_spot:该交易所方法未实现".to_string()))
|
|
|
}
|
|
|
|
|
|
- async fn wallet_transfers(&mut self, _coin: &str, _from: &str, _to: &str, _amount: Decimal) -> Result<String, Error> {
|
|
|
- Err(Error::new(ErrorKind::NotFound, "bitget_spot:该交易所方法未实现".to_string()))
|
|
|
+ async fn wallet_transfers(&mut self, coin: &str, from: &str, to: &str, amount: Decimal) -> Result<String, Error> {
|
|
|
+ let coin_format = coin.to_string().to_uppercase();
|
|
|
+ let res_data = self.request.wallet_transfer(from.to_string(), to.to_string(), amount.to_string(), coin_format.clone(), "".to_string(), "".to_string()).await;
|
|
|
+ if res_data.code == "200" {
|
|
|
+ let res_data_str = &res_data.data;
|
|
|
+ let result = res_data_str.clone();
|
|
|
+ Ok(result)
|
|
|
+ } else {
|
|
|
+ Err(Error::new(ErrorKind::Other, res_data.to_string()))
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
async fn command_order(&mut self, order_command: OrderCommand, trace_stack: TraceStack) {
|