Initial version of pools
This commit is contained in:
parent
fe7edb93ad
commit
2b6b1f30f4
21 changed files with 577 additions and 36 deletions
|
|
@ -15,10 +15,18 @@ pub struct Model {
|
|||
|
||||
#[derive(Copy, Clone, Debug, EnumIter, DeriveRelation)]
|
||||
pub enum Relation {
|
||||
#[sea_orm(has_many = "super::samey_pool::Entity")]
|
||||
SameyPool,
|
||||
#[sea_orm(has_many = "super::samey_post::Entity")]
|
||||
SameyPost,
|
||||
}
|
||||
|
||||
impl Related<super::samey_pool::Entity> for Entity {
|
||||
fn to() -> RelationDef {
|
||||
Relation::SameyPool.def()
|
||||
}
|
||||
}
|
||||
|
||||
impl Related<super::samey_post::Entity> for Entity {
|
||||
fn to() -> RelationDef {
|
||||
Relation::SameyPost.def()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue