Skip to main content

artifacts/models/
account_status.rs

1use crate::models;
2use serde::{Deserialize, Serialize};
3
4#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
5#[cfg_attr(feature = "specta", derive(specta::Type))]
6#[derive(Default)]
7pub enum AccountStatus {
8    #[serde(rename = "standard")]
9    #[default]
10    Standard,
11    #[serde(rename = "founder")]
12    Founder,
13    #[serde(rename = "gold_founder")]
14    GoldFounder,
15    #[serde(rename = "vip_founder")]
16    VipFounder,
17    #[serde(rename = "goblin1")]
18    Goblin1,
19}
20
21impl std::fmt::Display for AccountStatus {
22    fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
23        match self {
24            Self::Standard => write!(f, "standard"),
25            Self::Founder => write!(f, "founder"),
26            Self::GoldFounder => write!(f, "gold_founder"),
27            Self::VipFounder => write!(f, "vip_founder"),
28            Self::Goblin1 => write!(f, "goblin1"),
29        }
30    }
31}