mirror of
https://gitlab.com/comunic/comunicapiv3
synced 2025-06-20 16:35:17 +00:00
Can authenticate admin with reset token
This commit is contained in:
18
src/api_data/admin/admin_auth_success.rs
Normal file
18
src/api_data/admin/admin_auth_success.rs
Normal file
@ -0,0 +1,18 @@
|
||||
//! # Admin authentication success
|
||||
//!
|
||||
//! Structure returned when an administrator successfully authenticate
|
||||
//!
|
||||
//! @author Pierre Hubert
|
||||
|
||||
use serde::Serialize;
|
||||
|
||||
#[derive(Serialize)]
|
||||
pub struct AdminAuthSuccess {
|
||||
token: String
|
||||
}
|
||||
|
||||
impl AdminAuthSuccess {
|
||||
pub fn new(t: String) -> Self {
|
||||
Self { token: t }
|
||||
}
|
||||
}
|
@ -2,4 +2,5 @@
|
||||
//!
|
||||
//! @author Pierre Hubert
|
||||
|
||||
pub mod admin_auth_options;
|
||||
pub mod admin_auth_options;
|
||||
pub mod admin_auth_success;
|
Reference in New Issue
Block a user