Skip to content

Commit

Permalink
added events for rewards module
Browse files Browse the repository at this point in the history
  • Loading branch information
faneaatiku committed Apr 18, 2024
1 parent ebb8ad6 commit f11f7a3
Show file tree
Hide file tree
Showing 15 changed files with 4,556 additions and 77 deletions.
10 changes: 0 additions & 10 deletions go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,6 @@ github.com/aymerick/douceur v0.2.0 h1:Mv+mAeH1Q+n9Fr+oyamOlAkUNPWPlA8PPGR0QAaYuP
github.com/aymerick/douceur v0.2.0/go.mod h1:wlT5vV2O3h55X9m7iVYN0TBM0NH/MmbLnd30/FjWUq4=
github.com/aymerick/raymond v2.0.3-0.20180322193309-b565731e1464+incompatible/go.mod h1:osfaiScAUVup+UC9Nfq76eWqDhXlp+4UYaA8uhTBO6g=
github.com/benbjohnson/clock v1.1.0 h1:Q92kusRqC1XV2MjkWETPvjJVqKetz1OzxZB7mHJLju8=
github.com/benbjohnson/clock v1.1.0/go.mod h1:J11/hYXuz8f4ySSvYwY0FKfm+ezbsZBKZxNJlLklBHA=
github.com/beorn7/perks v0.0.0-20180321164747-3a771d992973/go.mod h1:Dwedo/Wpr24TaqPxmxbtue+5NUziq4I4S80YR8gNf3Q=
github.com/beorn7/perks v1.0.0/go.mod h1:KWe93zE9D1o94FZ5RNwFwVgaQK1VOXiVxmqh+CedLV8=
github.com/beorn7/perks v1.0.1 h1:VlbKKnNfV8bJzeqoa4cOKqO6bYr3WgKZxO8Z16+hsOM=
Expand Down Expand Up @@ -262,7 +261,6 @@ github.com/containerd/continuity v0.3.0 h1:nisirsYROK15TAMVukJOUyGJjz4BNQJBVsNvA
github.com/coreos/etcd v3.3.10+incompatible/go.mod h1:uF7uidLiAD3TWHmW31ZFd/JWoc32PjwdhPthX9715RE=
github.com/coreos/go-etcd v2.0.0+incompatible/go.mod h1:Jez6KQU2B/sWsbdaef3ED8NzMklzPG4d5KIOhIy30Tk=
github.com/coreos/go-semver v0.2.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
github.com/coreos/go-semver v0.3.0/go.mod h1:nnelYz7RCh+5ahJtPPxZlU+153eP4D4r3EedlOD2RNk=
github.com/coreos/go-systemd v0.0.0-20180511133405-39ca1b05acc7/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4=
github.com/coreos/go-systemd/v22 v22.3.3-0.20220203105225-a9a7ef127534/go.mod h1:Y58oyj3AT4RCenI/lSvhwexgC+NSVTIJ3seZv2GcEnc=
github.com/coreos/pkg v0.0.0-20160727233714-3ac0863d7acf/go.mod h1:E3G3o1h8I7cfcXa63jLwjI0eiQQMgzzUDFVpN/nH/eA=
Expand All @@ -281,8 +279,6 @@ github.com/cosmos/gorocksdb v1.2.0 h1:d0l3jJG8M4hBouIZq0mDUHZ+zjOx044J3nGRskwTb4
github.com/cosmos/gorocksdb v1.2.0/go.mod h1:aaKvKItm514hKfNJpUJXnnOWeBnk2GL4+Qw9NHizILw=
github.com/cosmos/iavl v0.19.5 h1:rGA3hOrgNxgRM5wYcSCxgQBap7fW82WZgY78V9po/iY=
github.com/cosmos/iavl v0.19.5/go.mod h1:X9PKD3J0iFxdmgNLa7b2LYWdsGd90ToV5cAONApkEPw=
github.com/cosmos/ibc-go/v4 v4.5.1 h1:+P73X7aIikGAXBUJ9vP9rEbvdSuekt3KGXmAWCSYets=
github.com/cosmos/ibc-go/v4 v4.5.1/go.mod h1:2EOi40Bx/j6rJrtP1ui8k8yUAMpGybmL1EjakYqYv5U=
github.com/cosmos/ibc-go/v4 v4.6.0 h1:G7kiD4Zf8Wrxc8BXWIKuFnzI0W4wpvRPrl5HwdfTIsA=
github.com/cosmos/ibc-go/v4 v4.6.0/go.mod h1:ksiZHUypws0NVP50E3ea0ivVFO/bfS8q8yLg8yZ2ATQ=
github.com/cosmos/keyring v1.2.0 h1:8C1lBP9xhImmIabyXW4c3vFjjLiBdGCmfLUfeZlV1Yo=
Expand Down Expand Up @@ -496,15 +492,13 @@ github.com/golang/groupcache v0.0.0-20160516000752-02826c3e7903/go.mod h1:cIg4er
github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20210331224755-41bb18bfe9da/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A=
github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y=
github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw=
github.com/golang/mock v1.4.4/go.mod h1:l3mdAwkq5BuhzHwde/uurv3sEJeZMXNpwsxVWU71h+4=
github.com/golang/mock v1.6.0 h1:ErTB+efbowRARo13NNdxyJji2egdxLGQhRaY+DUumQc=
github.com/golang/mock v1.6.0/go.mod h1:p6yTPP+5HYm5mzsMV8JkE6ZKdX+/wYM6Hr+LicevLPs=
github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
github.com/golang/protobuf v1.3.0/go.mod h1:Qd/q+1AKNOZr9uGQzbzCmRO6sUih6GTPZv6a1/R87v0=
github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U=
Expand Down Expand Up @@ -654,7 +648,6 @@ github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brv
github.com/hashicorp/go-bexpr v0.1.10/go.mod h1:oxlubA2vC/gFVfX1A6JGp7ls7uCDlfJn732ehYYg+g0=
github.com/hashicorp/go-cleanhttp v0.5.0/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
github.com/hashicorp/go-cleanhttp v0.5.1/go.mod h1:JpRdi6/HCYpAwUzNwuwqhbovhLtngrth3wmdIIUrZ80=
github.com/hashicorp/go-cleanhttp v0.5.2/go.mod h1:kO/YDlP8L1346E6Sodw+PrpBSV4/SoxCXGY6BqNFT48=
github.com/hashicorp/go-immutable-radix v1.0.0/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
github.com/hashicorp/go-immutable-radix v1.3.1 h1:DKHmCUm2hRBK510BaiZlwvpD40f8bJFeZnpfm2KLowc=
github.com/hashicorp/go-immutable-radix v1.3.1/go.mod h1:0y9vanUI8NX6FsYoO3zeMjhV/C5i9g4Q3DwcSNZ4P60=
Expand All @@ -664,7 +657,6 @@ github.com/hashicorp/go-multierror v1.1.1 h1:H5DkEtf6CXdFp0N0Em5UCwQpXMWke8IA0+l
github.com/hashicorp/go-multierror v1.1.1/go.mod h1:iw975J/qwKPdAO1clOe2L8331t/9/fmwbPZ6JB6eMoM=
github.com/hashicorp/go-retryablehttp v0.5.3/go.mod h1:9B5zBasrRhHXnJnui7y6sL7es7NDiJgTc6Er0maI1Xs=
github.com/hashicorp/go-rootcerts v1.0.0/go.mod h1:K6zTfqpRlCUIjkwsN4Z+hiSfzSTQa6eBIzfwKfwNnHU=
github.com/hashicorp/go-rootcerts v1.0.2/go.mod h1:pqUvnprVnM5bf7AOirdbb01K4ccR319Vf4pU3K5EGc8=
github.com/hashicorp/go-sockaddr v1.0.0/go.mod h1:7Xibr9yA9JjQq1JpNB2Vw7kxv8xerXegt+ozgdvDeDU=
github.com/hashicorp/go-syslog v1.0.0/go.mod h1:qPfqrKkXGihmCqbJM2mZgkZGvKG1dFdvsLplgctolz4=
github.com/hashicorp/go-uuid v1.0.0/go.mod h1:6SBZvOh/SIDV7/2o3Jml5SYk/TvGqwFJ/bN7x4byOro=
Expand Down Expand Up @@ -1322,15 +1314,13 @@ go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
go.opencensus.io v0.22.5/go.mod h1:5pWMHQbX5EPX2/62yrJeAkowc+lfs/XD7Uxpq3pI6kk=
go.opencensus.io v0.23.0/go.mod h1:XItmlyltB5F7CS4xOC1DcqMoFqwtC6OG2xF7mCv7P7E=
go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE=
go.uber.org/atomic v1.5.0/go.mod h1:sABNBOSYdrvTF6hTgEIbc7YasKWGhgEQZyfxyTvoXHQ=
go.uber.org/atomic v1.7.0/go.mod h1:fEN4uk6kAWBTFdckzkM89CLk9XfWZrxpCo0nPH17wJc=
go.uber.org/atomic v1.10.0 h1:9qC72Qh0+3MqyJbAn8YU5xVq1frD8bn3JtD2oXtafVQ=
go.uber.org/atomic v1.10.0/go.mod h1:LUxbIzbOniOlMKjJjyPfpl4v+PKK2cNJn91OQbhoJI0=
go.uber.org/goleak v1.1.11 h1:wy28qYRKZgnJTxGxvye5/wgWr1EKjmUDGYox5mGlRlI=
go.uber.org/goleak v1.1.11/go.mod h1:cwTWslyiVhfpKIDGSZEM2HlOvcqm+tG4zioyIeLoqMQ=
go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0=
go.uber.org/multierr v1.3.0/go.mod h1:VgVr7evmIr6uPjLBxg28wmKNXyqE9akIJ5XnfpiKl+4=
go.uber.org/multierr v1.8.0 h1:dg6GjLku4EH+249NNmoIciG9N/jURbDG+pFlTkhzIC8=
Expand Down
64 changes: 64 additions & 0 deletions proto/rewards/events.proto
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,68 @@ import "gogoproto/gogo.proto";

option go_package = "github.com/bze-alphateam/bze/x/rewards/types";

message StakingRewardCreateEvent {
string reward_id = 1;
string prize_amount = 2;
string prize_denom = 3;
string staking_denom = 4;
uint32 duration = 5;
uint64 min_stake = 6;
uint32 lock = 7;
}

message StakingRewardUpdateEvent {
string reward_id = 1;
uint32 duration = 2;
}

message StakingRewardClaimEvent {
string reward_id = 1;
string address = 2;
string amount = 3;
}

message StakingRewardJoinEvent {
string reward_id = 1;
string address = 2;
string amount = 3;
}

message StakingRewardExitEvent {
string reward_id = 1;
string address = 2;
}

message StakingRewardFinishEvent {
string reward_id = 1;
}

message StakingRewardDistributionEvent {
string reward_id = 1;
string amount = 2;
}

message TradingRewardCreateEvent {
string reward_id = 1;
string prize_amount = 2; //the amount paid as prize for each slot
string prize_denom = 3; //the denom paid as prize
uint32 duration = 4;
string market_id = 5;
uint32 slots = 6;
string creator = 7;
}

message TradingRewardExpireEvent {
string reward_id = 1;
}

message TradingRewardActivationEvent {
string reward_id = 1;
}

message TradingRewardDistributionEvent {
string reward_id = 1;
string prize_amount = 2;
string prize_denom = 3;
repeated string winners = 4;
}
92 changes: 46 additions & 46 deletions vue/src/store/generated/bze-alphateam/bze/bze.v1.rewards/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -407,6 +407,21 @@ export default {
},


async sendMsgClaimStakingRewards({ rootGetters }, { value, fee = [], memo = '' }) {
try {
const txClient=await initTxClient(rootGetters)
const msg = await txClient.msgClaimStakingRewards(value)
const result = await txClient.signAndBroadcast([msg], {fee: { amount: fee,
gas: "200000" }, memo})
return result
} catch (e) {
if (e == MissingWalletError) {
throw new Error('TxClient:MsgClaimStakingRewards:Init Could not initialize signing client. Wallet is required.')
}else{
throw new Error('TxClient:MsgClaimStakingRewards:Send Could not broadcast Tx: '+ e.message)
}
}
},
async sendMsgCreateTradingReward({ rootGetters }, { value, fee = [], memo = '' }) {
try {
const txClient=await initTxClient(rootGetters)
Expand All @@ -422,33 +437,33 @@ export default {
}
}
},
async sendMsgExitStaking({ rootGetters }, { value, fee = [], memo = '' }) {
async sendMsgJoinStaking({ rootGetters }, { value, fee = [], memo = '' }) {
try {
const txClient=await initTxClient(rootGetters)
const msg = await txClient.msgExitStaking(value)
const msg = await txClient.msgJoinStaking(value)
const result = await txClient.signAndBroadcast([msg], {fee: { amount: fee,
gas: "200000" }, memo})
return result
} catch (e) {
if (e == MissingWalletError) {
throw new Error('TxClient:MsgExitStaking:Init Could not initialize signing client. Wallet is required.')
throw new Error('TxClient:MsgJoinStaking:Init Could not initialize signing client. Wallet is required.')
}else{
throw new Error('TxClient:MsgExitStaking:Send Could not broadcast Tx: '+ e.message)
throw new Error('TxClient:MsgJoinStaking:Send Could not broadcast Tx: '+ e.message)
}
}
},
async sendMsgClaimStakingRewards({ rootGetters }, { value, fee = [], memo = '' }) {
async sendMsgCreateStakingReward({ rootGetters }, { value, fee = [], memo = '' }) {
try {
const txClient=await initTxClient(rootGetters)
const msg = await txClient.msgClaimStakingRewards(value)
const msg = await txClient.msgCreateStakingReward(value)
const result = await txClient.signAndBroadcast([msg], {fee: { amount: fee,
gas: "200000" }, memo})
return result
} catch (e) {
if (e == MissingWalletError) {
throw new Error('TxClient:MsgClaimStakingRewards:Init Could not initialize signing client. Wallet is required.')
throw new Error('TxClient:MsgCreateStakingReward:Init Could not initialize signing client. Wallet is required.')
}else{
throw new Error('TxClient:MsgClaimStakingRewards:Send Could not broadcast Tx: '+ e.message)
throw new Error('TxClient:MsgCreateStakingReward:Send Could not broadcast Tx: '+ e.message)
}
}
},
Expand All @@ -467,37 +482,35 @@ export default {
}
}
},
async sendMsgJoinStaking({ rootGetters }, { value, fee = [], memo = '' }) {
async sendMsgExitStaking({ rootGetters }, { value, fee = [], memo = '' }) {
try {
const txClient=await initTxClient(rootGetters)
const msg = await txClient.msgJoinStaking(value)
const msg = await txClient.msgExitStaking(value)
const result = await txClient.signAndBroadcast([msg], {fee: { amount: fee,
gas: "200000" }, memo})
return result
} catch (e) {
if (e == MissingWalletError) {
throw new Error('TxClient:MsgJoinStaking:Init Could not initialize signing client. Wallet is required.')
throw new Error('TxClient:MsgExitStaking:Init Could not initialize signing client. Wallet is required.')
}else{
throw new Error('TxClient:MsgJoinStaking:Send Could not broadcast Tx: '+ e.message)
throw new Error('TxClient:MsgExitStaking:Send Could not broadcast Tx: '+ e.message)
}
}
},
async sendMsgCreateStakingReward({ rootGetters }, { value, fee = [], memo = '' }) {

async MsgClaimStakingRewards({ rootGetters }, { value }) {
try {
const txClient=await initTxClient(rootGetters)
const msg = await txClient.msgCreateStakingReward(value)
const result = await txClient.signAndBroadcast([msg], {fee: { amount: fee,
gas: "200000" }, memo})
return result
const msg = await txClient.msgClaimStakingRewards(value)
return msg
} catch (e) {
if (e == MissingWalletError) {
throw new Error('TxClient:MsgCreateStakingReward:Init Could not initialize signing client. Wallet is required.')
}else{
throw new Error('TxClient:MsgCreateStakingReward:Send Could not broadcast Tx: '+ e.message)
throw new Error('TxClient:MsgClaimStakingRewards:Init Could not initialize signing client. Wallet is required.')
} else{
throw new Error('TxClient:MsgClaimStakingRewards:Create Could not create message: ' + e.message)
}
}
},

async MsgCreateTradingReward({ rootGetters }, { value }) {
try {
const txClient=await initTxClient(rootGetters)
Expand All @@ -511,29 +524,29 @@ export default {
}
}
},
async MsgExitStaking({ rootGetters }, { value }) {
async MsgJoinStaking({ rootGetters }, { value }) {
try {
const txClient=await initTxClient(rootGetters)
const msg = await txClient.msgExitStaking(value)
const msg = await txClient.msgJoinStaking(value)
return msg
} catch (e) {
if (e == MissingWalletError) {
throw new Error('TxClient:MsgExitStaking:Init Could not initialize signing client. Wallet is required.')
throw new Error('TxClient:MsgJoinStaking:Init Could not initialize signing client. Wallet is required.')
} else{
throw new Error('TxClient:MsgExitStaking:Create Could not create message: ' + e.message)
throw new Error('TxClient:MsgJoinStaking:Create Could not create message: ' + e.message)
}
}
},
async MsgClaimStakingRewards({ rootGetters }, { value }) {
async MsgCreateStakingReward({ rootGetters }, { value }) {
try {
const txClient=await initTxClient(rootGetters)
const msg = await txClient.msgClaimStakingRewards(value)
const msg = await txClient.msgCreateStakingReward(value)
return msg
} catch (e) {
if (e == MissingWalletError) {
throw new Error('TxClient:MsgClaimStakingRewards:Init Could not initialize signing client. Wallet is required.')
throw new Error('TxClient:MsgCreateStakingReward:Init Could not initialize signing client. Wallet is required.')
} else{
throw new Error('TxClient:MsgClaimStakingRewards:Create Could not create message: ' + e.message)
throw new Error('TxClient:MsgCreateStakingReward:Create Could not create message: ' + e.message)
}
}
},
Expand All @@ -550,29 +563,16 @@ export default {
}
}
},
async MsgJoinStaking({ rootGetters }, { value }) {
try {
const txClient=await initTxClient(rootGetters)
const msg = await txClient.msgJoinStaking(value)
return msg
} catch (e) {
if (e == MissingWalletError) {
throw new Error('TxClient:MsgJoinStaking:Init Could not initialize signing client. Wallet is required.')
} else{
throw new Error('TxClient:MsgJoinStaking:Create Could not create message: ' + e.message)
}
}
},
async MsgCreateStakingReward({ rootGetters }, { value }) {
async MsgExitStaking({ rootGetters }, { value }) {
try {
const txClient=await initTxClient(rootGetters)
const msg = await txClient.msgCreateStakingReward(value)
const msg = await txClient.msgExitStaking(value)
return msg
} catch (e) {
if (e == MissingWalletError) {
throw new Error('TxClient:MsgCreateStakingReward:Init Could not initialize signing client. Wallet is required.')
throw new Error('TxClient:MsgExitStaking:Init Could not initialize signing client. Wallet is required.')
} else{
throw new Error('TxClient:MsgCreateStakingReward:Create Could not create message: ' + e.message)
throw new Error('TxClient:MsgExitStaking:Create Could not create message: ' + e.message)
}
}
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,21 +4,21 @@ import { StdFee } from "@cosmjs/launchpad";
import { SigningStargateClient } from "@cosmjs/stargate";
import { Registry, OfflineSigner, EncodeObject, DirectSecp256k1HdWallet } from "@cosmjs/proto-signing";
import { Api } from "./rest";
import { MsgCreateTradingReward } from "./types/rewards/tx";
import { MsgExitStaking } from "./types/rewards/tx";
import { MsgClaimStakingRewards } from "./types/rewards/tx";
import { MsgUpdateStakingReward } from "./types/rewards/tx";
import { MsgCreateTradingReward } from "./types/rewards/tx";
import { MsgJoinStaking } from "./types/rewards/tx";
import { MsgCreateStakingReward } from "./types/rewards/tx";
import { MsgUpdateStakingReward } from "./types/rewards/tx";
import { MsgExitStaking } from "./types/rewards/tx";


const types = [
["/bze.v1.rewards.MsgCreateTradingReward", MsgCreateTradingReward],
["/bze.v1.rewards.MsgExitStaking", MsgExitStaking],
["/bze.v1.rewards.MsgClaimStakingRewards", MsgClaimStakingRewards],
["/bze.v1.rewards.MsgUpdateStakingReward", MsgUpdateStakingReward],
["/bze.v1.rewards.MsgCreateTradingReward", MsgCreateTradingReward],
["/bze.v1.rewards.MsgJoinStaking", MsgJoinStaking],
["/bze.v1.rewards.MsgCreateStakingReward", MsgCreateStakingReward],
["/bze.v1.rewards.MsgUpdateStakingReward", MsgUpdateStakingReward],
["/bze.v1.rewards.MsgExitStaking", MsgExitStaking],

];
export const MissingWalletError = new Error("wallet is required");
Expand Down Expand Up @@ -51,12 +51,12 @@ const txClient = async (wallet: OfflineSigner, { addr: addr }: TxClientOptions =

return {
signAndBroadcast: (msgs: EncodeObject[], { fee, memo }: SignAndBroadcastOptions = {fee: defaultFee, memo: ""}) => client.signAndBroadcast(address, msgs, fee,memo),
msgCreateTradingReward: (data: MsgCreateTradingReward): EncodeObject => ({ typeUrl: "/bze.v1.rewards.MsgCreateTradingReward", value: MsgCreateTradingReward.fromPartial( data ) }),
msgExitStaking: (data: MsgExitStaking): EncodeObject => ({ typeUrl: "/bze.v1.rewards.MsgExitStaking", value: MsgExitStaking.fromPartial( data ) }),
msgClaimStakingRewards: (data: MsgClaimStakingRewards): EncodeObject => ({ typeUrl: "/bze.v1.rewards.MsgClaimStakingRewards", value: MsgClaimStakingRewards.fromPartial( data ) }),
msgUpdateStakingReward: (data: MsgUpdateStakingReward): EncodeObject => ({ typeUrl: "/bze.v1.rewards.MsgUpdateStakingReward", value: MsgUpdateStakingReward.fromPartial( data ) }),
msgCreateTradingReward: (data: MsgCreateTradingReward): EncodeObject => ({ typeUrl: "/bze.v1.rewards.MsgCreateTradingReward", value: MsgCreateTradingReward.fromPartial( data ) }),
msgJoinStaking: (data: MsgJoinStaking): EncodeObject => ({ typeUrl: "/bze.v1.rewards.MsgJoinStaking", value: MsgJoinStaking.fromPartial( data ) }),
msgCreateStakingReward: (data: MsgCreateStakingReward): EncodeObject => ({ typeUrl: "/bze.v1.rewards.MsgCreateStakingReward", value: MsgCreateStakingReward.fromPartial( data ) }),
msgUpdateStakingReward: (data: MsgUpdateStakingReward): EncodeObject => ({ typeUrl: "/bze.v1.rewards.MsgUpdateStakingReward", value: MsgUpdateStakingReward.fromPartial( data ) }),
msgExitStaking: (data: MsgExitStaking): EncodeObject => ({ typeUrl: "/bze.v1.rewards.MsgExitStaking", value: MsgExitStaking.fromPartial( data ) }),

};
};
Expand Down

0 comments on commit f11f7a3

Please sign in to comment.