|
@@ -346,7 +346,7 @@ impl Platform for CoinexSwap {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
if res_data.code == 200 {
|
|
if res_data.code == 200 {
|
|
|
- info!("order_detail {}", res_data.data);
|
|
|
|
|
|
|
+ // info!("order_detail {}", res_data.data);
|
|
|
if res_data.data.is_array() {
|
|
if res_data.data.is_array() {
|
|
|
let res_data_json = res_data.data.as_array().unwrap();
|
|
let res_data_json = res_data.data.as_array().unwrap();
|
|
|
if res_data_json.len() == 0 { // 已取消或已成交
|
|
if res_data_json.len() == 0 { // 已取消或已成交
|
|
@@ -373,12 +373,11 @@ impl Platform for CoinexSwap {
|
|
|
result.id = order_id.to_string();
|
|
result.id = order_id.to_string();
|
|
|
Ok(result)
|
|
Ok(result)
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
} else if res_data.code == -1 && res_data.message.contains("3103:order not exists") { // 未成交已取消的订单会报不存在
|
|
} else if res_data.code == -1 && res_data.message.contains("3103:order not exists") { // 未成交已取消的订单会报不存在
|
|
|
let mut order = Order::new();
|
|
let mut order = Order::new();
|
|
|
order.id = order_id.to_string();
|
|
order.id = order_id.to_string();
|
|
|
order.custom_id = custom_id.to_string();
|
|
order.custom_id = custom_id.to_string();
|
|
|
- order.status = "NULL".to_string();
|
|
|
|
|
|
|
+ order.status = "REMOVE".to_string();
|
|
|
Ok(order)
|
|
Ok(order)
|
|
|
} else {
|
|
} else {
|
|
|
Err(Error::new(ErrorKind::Other, res_data.to_string()))
|
|
Err(Error::new(ErrorKind::Other, res_data.to_string()))
|