feat(indexer): add to modules and implement proto fields (#22544)
This commit is contained in:
@@ -8,10 +8,12 @@ import (
|
||||
gwruntime "github.com/grpc-ecosystem/grpc-gateway/runtime"
|
||||
"google.golang.org/grpc"
|
||||
|
||||
"cosmossdk.io/collections"
|
||||
"cosmossdk.io/core/appmodule"
|
||||
appmodulev2 "cosmossdk.io/core/appmodule/v2"
|
||||
"cosmossdk.io/core/registry"
|
||||
"cosmossdk.io/core/transaction"
|
||||
"cosmossdk.io/schema"
|
||||
|
||||
"github.com/cosmos/cosmos-sdk/client"
|
||||
"github.com/cosmos/cosmos-sdk/codec"
|
||||
@@ -198,3 +200,9 @@ func (AppModule) ProposalMsgsX(weights simsx.WeightSource, reg simsx.Registry) {
|
||||
func (am AppModule) RegisterStoreDecoder(sdr simtypes.StoreDecoderRegistry) {
|
||||
sdr[types.StoreKey] = simtypes.NewStoreDecoderFuncFromCollectionsSchema(am.accountKeeper.Schema)
|
||||
}
|
||||
|
||||
// ModuleCodec implements schema.HasModuleCodec.
|
||||
// It allows the indexer to decode the module's KVPairUpdate.
|
||||
func (am AppModule) ModuleCodec() (schema.ModuleCodec, error) {
|
||||
return am.accountKeeper.Schema.ModuleCodec(collections.IndexingOptions{})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user