package cli import ( "strconv" "colinear/x/colinearcore/types" "github.com/cosmos/cosmos-sdk/client" "github.com/cosmos/cosmos-sdk/client/flags" "github.com/spf13/cobra" ) var _ = strconv.Itoa(0) func CmdLockedFunds() *cobra.Command { cmd := &cobra.Command{ Use: "locked-funds [owner]", Short: "Query lockedFunds", Args: cobra.ExactArgs(1), RunE: func(cmd *cobra.Command, args []string) (err error) { reqOwner := args[0] clientCtx, err := client.GetClientTxContext(cmd) if err != nil { return err } queryClient := types.NewQueryClient(clientCtx) params := &types.QueryLockedFundsRequest{ Owner: reqOwner, } res, err := queryClient.LockedFunds(cmd.Context(), params) if err != nil { return err } return clientCtx.PrintProto(res) }, } flags.AddQueryFlagsToCmd(cmd) return cmd }