Added a records function to client.
Some checks failed
Gitea Actions Demo / Explore-Gitea-Actions (push) Failing after 1s
Some checks failed
Gitea Actions Demo / Explore-Gitea-Actions (push) Failing after 1s
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
use super::{DocDef, FieldType, Query};
|
||||
use crate::{message::MessageAction, name::NameType};
|
||||
|
||||
#[derive(Clone, Debug)]
|
||||
pub enum UserAction {
|
||||
CreateDocument(DocDef),
|
||||
Query(Query),
|
||||
@@ -16,3 +18,12 @@ impl From<Query> for UserAction {
|
||||
Self::Query(value)
|
||||
}
|
||||
}
|
||||
|
||||
impl MessageAction for UserAction {
|
||||
fn doc_name(&self) -> &NameType {
|
||||
match self {
|
||||
Self::CreateDocument(data) => data.doc_name(),
|
||||
Self::Query(data) => data.doc_name(),
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user