OSDN Git Service

feat(bcrp): add register action (#1904)
[bytom/bytom.git] / api / transact.go
index 947b47e..dd8b7f9 100644 (file)
@@ -8,12 +8,12 @@ import (
 
        log "github.com/sirupsen/logrus"
 
-       "github.com/bytom/account"
-       "github.com/bytom/blockchain/txbuilder"
-       "github.com/bytom/errors"
-       "github.com/bytom/net/http/reqid"
-       "github.com/bytom/protocol/bc"
-       "github.com/bytom/protocol/bc/types"
+       "github.com/bytom/bytom/account"
+       "github.com/bytom/bytom/blockchain/txbuilder"
+       "github.com/bytom/bytom/errors"
+       "github.com/bytom/bytom/net/http/reqid"
+       "github.com/bytom/bytom/protocol/bc"
+       "github.com/bytom/bytom/protocol/bc/types"
 )
 
 var (
@@ -27,6 +27,7 @@ func (a *API) actionDecoder(action string) (func([]byte) (txbuilder.Action, erro
                "control_program":              txbuilder.DecodeControlProgramAction,
                "issue":                        a.wallet.AssetReg.DecodeIssueAction,
                "retire":                       txbuilder.DecodeRetireAction,
+               "register_contract":            txbuilder.DecodeRegisterAction,
                "spend_account":                a.wallet.AccountMgr.DecodeSpendAction,
                "spend_account_unspent_output": a.wallet.AccountMgr.DecodeSpendUTXOAction,
        }