change: Rename UserId
to IdCol
and make it private
Signed-off-by: Awiteb <a@4rs.nl>
This commit is contained in:
parent
0274444434
commit
f0383296de
5 changed files with 8 additions and 8 deletions
|
@ -31,8 +31,8 @@ use crate::prelude::*;
|
|||
#[sea_orm(table_name = "incoming_chat")]
|
||||
pub struct Model {
|
||||
#[sea_orm(primary_key)]
|
||||
pub id: UserId,
|
||||
pub recipient_id: UserId,
|
||||
pub id: IdCol,
|
||||
pub recipient_id: IdCol,
|
||||
/// Public key of the sender
|
||||
pub sender: PublicKey,
|
||||
/// The timestamp of the request, when it was received
|
||||
|
|
|
@ -31,8 +31,8 @@ use crate::prelude::*;
|
|||
#[sea_orm(table_name = "out_chat_requests")]
|
||||
pub struct Model {
|
||||
#[sea_orm(primary_key)]
|
||||
pub id: UserId,
|
||||
pub sender_id: UserId,
|
||||
pub id: IdCol,
|
||||
pub sender_id: IdCol,
|
||||
/// Public key of the recipient
|
||||
pub recipient: PublicKey,
|
||||
/// The timestamp of the request, when it was sent
|
||||
|
|
|
@ -38,7 +38,7 @@ pub use sea_orm::{
|
|||
};
|
||||
|
||||
/// User ID type
|
||||
pub type UserId = i64;
|
||||
pub(crate) type IdCol = i64;
|
||||
|
||||
pub use super::incoming_chat::{
|
||||
ActiveModel as IncomingChatActiveModel,
|
||||
|
|
|
@ -31,7 +31,7 @@ use crate::prelude::*;
|
|||
#[sea_orm(table_name = "users")]
|
||||
pub struct Model {
|
||||
#[sea_orm(primary_key)]
|
||||
pub id: UserId,
|
||||
pub id: IdCol,
|
||||
pub public_key: PublicKey,
|
||||
pub last_logout: chrono::DateTime<Utc>,
|
||||
pub is_admin: bool,
|
||||
|
|
|
@ -40,8 +40,8 @@ pub enum AccessStatus {
|
|||
#[sea_orm(table_name = "users_status")]
|
||||
pub struct Model {
|
||||
#[sea_orm(primary_key)]
|
||||
pub id: UserId,
|
||||
pub user_id: UserId,
|
||||
pub id: IdCol,
|
||||
pub user_id: IdCol,
|
||||
pub target: PublicKey,
|
||||
pub status: AccessStatus,
|
||||
pub updated_at: chrono::DateTime<Utc>,
|
||||
|
|
Loading…
Reference in a new issue