lodestone-parser/src/models/search/free_company.rs

35 lines
842 B
Rust
Raw Normal View History

2018-09-03 23:27:34 +00:00
use crate::models::GrandCompany;
use chrono::{DateTime, Utc};
use ffxiv_types::World;
2022-06-16 14:10:03 +00:00
#[cfg(feature = "with_serde")] use serde::{Deserialize, Serialize};
2018-09-03 23:27:34 +00:00
use url::Url;
#[derive(Debug)]
#[cfg_attr(feature = "with_serde", derive(Deserialize, Serialize))]
2018-09-03 23:27:34 +00:00
pub struct FreeCompanySearchItem {
#[cfg_attr(feature = "with_serde", serde(with = "crate::util::serde::u64_str"))]
2018-09-03 23:27:34 +00:00
pub id: u64,
pub name: String,
pub world: World,
pub crest: Vec<Url>,
pub grand_company: GrandCompany,
pub active_members: u16,
pub estate_built: bool,
pub formed: DateTime<Utc>,
pub active: Active,
pub recruitment: RecruitmentStatus,
}
ffxiv_enum!(Active {
2018-09-05 03:57:34 +00:00
Always => "always",
Weekdays => "weekdays",
Weekends => "weekends",
NotSpecified => "not specified",
2018-09-03 23:27:34 +00:00
});
ffxiv_enum!(RecruitmentStatus {
2018-09-05 03:57:34 +00:00
Open => "open",
Closed => "closed",
2018-09-03 23:27:34 +00:00
});