1
This commit is contained in:
parent
2f25ad7ba0
commit
e6dd0478c8
@ -62,6 +62,36 @@ func (this *NftApi) Unlock(c *gin.Context) {
|
||||
f5.RspErr(c, 500, "nft not found")
|
||||
return
|
||||
}
|
||||
params := map[string]string{
|
||||
"c": "BcService",
|
||||
"a": "nftLock",
|
||||
"account_address": accountAddress,
|
||||
"net_id": ds.GetByName("net_id"),
|
||||
"nft_address": ds.GetByName("contract_address"),
|
||||
"to_address": reqJson.To,
|
||||
"token_ids": ds.GetByName("token_id"),
|
||||
}
|
||||
rspObj := &struct {
|
||||
ErrCode interface{} `json:"errcode"`
|
||||
ErrMsg string `json:"errmsg"`
|
||||
TransId string `json:"trans_id"`
|
||||
Params []string `json:"params"`
|
||||
}{
|
||||
Params: []string{},
|
||||
}
|
||||
f5.GetHttpCliMgr().SendGoStyleRequest(
|
||||
mt.Table.Web3SignCluster.RandElement().GetUrl(),
|
||||
params,
|
||||
func(rsp f5.HttpCliResponse) {
|
||||
if rsp.GetErr() != nil ||
|
||||
!rsp.JsonParseOk() {
|
||||
rspObj.ErrCode = 500
|
||||
rspObj.ErrMsg = "server internal error"
|
||||
c.JSON(200, rspObj)
|
||||
return
|
||||
}
|
||||
c.JSON(200, rspObj)
|
||||
})
|
||||
} else {
|
||||
f5.RspErr(c, 500, "nft not found")
|
||||
return
|
||||
|
Loading…
x
Reference in New Issue
Block a user