Skip to content
Clone
b453d5d
18 lines 618 B Rust
use sea_orm::entity::prelude::*;
use uuid::Uuid;
#[sea_orm::model]
#[derive(Clone, Debug, PartialEq, Eq, DeriveEntityModel)]
#[sea_orm(table_name = "space_invite_groups")]
pub struct Model {
#[sea_orm(primary_key, auto_increment = false)]
pub invite_id: Uuid,
#[sea_orm(primary_key, auto_increment = false)]
pub group_id: Uuid,
#[sea_orm(belongs_to, from = "invite_id", to = "id")]
pub invite: BelongsTo<super::space_invite::Entity>,
#[sea_orm(belongs_to, from = "group_id", to = "id")]
pub group: BelongsTo<super::space_groups::Entity>,
}
impl ActiveModelBehavior for ActiveModel {}