status-go/protocol/communities/token/community_token.go
Mykhailo Prakhov db9adb631f
feat: share requests to join and revealed addresses with privileged roles (#3951)
- share requests to join with new privileged roles during reevaluating member role
- share requests to join with new members, joined the community as TOKEN_MASTER, ADMIN
- share requests to join revealed addresses to ADMINS and TOKEN_MASTERS
- refactor common test functionality to make them more predictable
- removed unused CommunityToken protobuf
2023-09-20 10:37:46 +02:00

42 lines
1.4 KiB
Go

package token
import (
"github.com/status-im/status-go/protocol/protobuf"
"github.com/status-im/status-go/services/wallet/bigint"
)
type DeployState uint8
const (
Failed DeployState = iota
InProgress
Deployed
)
type PrivilegesLevel uint8
const (
OwnerLevel PrivilegesLevel = iota
MasterLevel
CommunityLevel
)
type CommunityToken struct {
TokenType protobuf.CommunityTokenType `json:"tokenType"`
CommunityID string `json:"communityId"`
Address string `json:"address"`
Name string `json:"name"`
Symbol string `json:"symbol"`
Description string `json:"description"`
Supply *bigint.BigInt `json:"supply"`
InfiniteSupply bool `json:"infiniteSupply"`
Transferable bool `json:"transferable"`
RemoteSelfDestruct bool `json:"remoteSelfDestruct"`
ChainID int `json:"chainId"`
DeployState DeployState `json:"deployState"`
Base64Image string `json:"image"`
Decimals int `json:"decimals"`
Deployer string `json:"deployer"`
PrivilegesLevel PrivilegesLevel `json:"privilegesLevel"`
}