wellbeinglib/jsonb/
location.rs

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
use serde::{Deserialize, Serialize};
use uuid::Uuid;
use crate::enums::accomodation_type::AccomodationType;

#[derive(Serialize, Deserialize, Debug, Clone, PartialEq)]
#[serde(rename_all = "camelCase")]
//отсюда убрать, в юзере добавить к адресам schedule и к типам адресов AccomodationType
pub struct Location {
    pub id : Uuid,
    pub location_type : AccomodationType,
    pub address : String,
    pub schedule : String,
    #[serde(skip_serializing_if = "Option::is_none")]
    pub comments : Option<String>
}