- add elm ConfirmOrder.
This commit is contained in:
@@ -122,3 +122,10 @@ func TestCallbackMsgPlayback(t *testing.T) {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func TestConfirmOrder(t *testing.T) {
|
||||
err := elmapi.ConfirmOrder("3023582487561731159")
|
||||
if err != nil {
|
||||
t.Fatalf("Error when accessing ConfirmOrdererror:%v", err)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -21,3 +21,11 @@ func (a *API) GetOrder(orderID string) (map[string]interface{}, error) {
|
||||
|
||||
return nil, err
|
||||
}
|
||||
|
||||
func (a *API) ConfirmOrder(orderID string) error {
|
||||
_, err := a.AccessAPI("eleme.order.confirmOrderLite", map[string]interface{}{
|
||||
"orderId": orderID,
|
||||
})
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user