주문 정보를 얻는 문제

저자:, 2021-11-23 22:14:46, 업데이트:

//383375074660855808 var order = exchanges[0].GetOrder ((383375074660855808)
로그:order.IdPrice: , order.Price, Amount: , order.Amount, DealAmount: , order.DealAmount, Status: , order.Status, Type: , order.Type) (웃음) var orders = exchanges[0].GetOrders (() Log (( 주문 1가 완료되지 않은 정보, ID:, orders[0].Id, Price:, orders[0].Price, Amount:, orders[0].Amount, DealAmount:, orders[0].DealAmount, type:, orders[0].Type 로그 () 오더 2가 완료되지 않은 정보, ID:, orders[1].Id, Price:, orders[1].Price, Amount:, orders[1]. DealAmount:, orders[1].DealAmount, type:, orders[1].Type) 는 , 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어, 명령어,

     exchanges[0].GetOrder可以返回信息
     Id: 383375074660855808 Price: 0 Amount: 1 DealAmount: 1 Status: 1 Type: 0
     exchanges[0].GetOrders()却返回错误
     TypeError: cannot read property 'Id' of undefined at main (__FILE__:129)
     
     请问这是什么原因啊?Id需要定义吗/xiexie

더 많은

/upload/asset/23c31a045d4345042eab9.jpg buyOrderId = openLong ((-1, amount) // 열리는 다중 포지션의 구매 -1은 시장 가격을 나타냅니다 buyOrderId = openLong ((-1, amount) // 열리는 다중 포지션의 구매 -1은 시장 가격을 나타냅니다 var orders = exchanges[0].GetOrders (() 로그 (("order=",order) 로그 (Log (("오더 1의 완료되지 않은 정보, ID:", orders[0].Id, "Price:", orders[0].Price, "Amount:", orders[0].Amount, "DealAmount:", orders[0].DealAmount, "type:", orders[0].Type) Log (("오더 2가 완료되지 않은 정보, ID:", orders[1].Id, "Price:", orders[1].Price, "Amount:", orders[1]. "DealAmount:", orders[1].DealAmount, "type:", orders[1].Type) 를 사용한다. -------------------- 오류 메시지는 위의 그림과 같습니다. 문제 코드는 여기, 계정에는 단자 A이 있고, id 앞에 있는 order는 A이 정의되어 있습니다. 기도

작은 꿈can't read property 'Id' of undefined at main (__FILE__: 129) 오프라인에서 정의되지 않은 것 129 행, 정책 코드를 확인합니다. Id라는 변수 이름 앞에 있는 변수가 정의되지 않습니다.

초목먼저 order를 확인합니다. 만약 null을 직접 사용할 수 없다면