hangitbot/entity/src/stats.rs
2023-12-24 18:48:40 +08:00

29 lines
598 B
Rust

//! `SeaORM` Entity. Generated by sea-orm-codegen 0.12.4
use sea_orm::entity::prelude::*;
#[derive(Clone, Debug, PartialEq, DeriveEntityModel, Eq)]
#[sea_orm(table_name = "stats")]
pub struct Model {
/// internal ID
#[sea_orm(primary_key)]
pub id: i64,
/// group ID
#[sea_orm(indexed)]
pub group_id: i64,
/// name hanged
#[sea_orm(indexed)]
pub name: String,
/// count of hanged
#[sea_orm(default = 0)]
pub counts: i64,
}
#[derive(Copy, Clone, Debug, EnumIter, DeriveRelation)]
pub enum Relation {}
impl ActiveModelBehavior for ActiveModel {}