site is added
This commit is contained in:
parent
047455a888
commit
3e2df9d4a7
|
@ -1,2 +1,3 @@
|
||||||
pub mod identity;
|
pub mod identity;
|
||||||
pub mod member;
|
pub mod member;
|
||||||
|
pub mod site;
|
||||||
|
|
114
src/c2se/backend/site.rs
Normal file
114
src/c2se/backend/site.rs
Normal file
|
@ -0,0 +1,114 @@
|
||||||
|
use crate::protobuf::pagination;
|
||||||
|
use crate::protobuf::rpc;
|
||||||
|
|
||||||
|
const SUBJECT: &str = "bet.beteran.c2se.backend.site";
|
||||||
|
|
||||||
|
pub const SUBJECT_LIST_SITES: &str = const_format::concatcp!(SUBJECT, ".ListSites");
|
||||||
|
/// subject = bet.beteran.c2se.backend.site.ListSites
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct ListSitesRequest {
|
||||||
|
#[prost(message, optional, tag = "1")]
|
||||||
|
pub pagination: ::core::option::Option<pagination::Pagination>,
|
||||||
|
#[prost(message, repeated, tag = "2")]
|
||||||
|
pub searches: ::prost::alloc::vec::Vec<pagination::Search>,
|
||||||
|
#[prost(message, repeated, tag = "3")]
|
||||||
|
pub sorts: ::prost::alloc::vec::Vec<pagination::Sort>,
|
||||||
|
}
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct ListSitesResponse {
|
||||||
|
#[prost(message, optional, tag = "1")]
|
||||||
|
pub error: ::core::option::Option<rpc::Error>,
|
||||||
|
#[prost(message, optional, tag = "2")]
|
||||||
|
pub result: ::core::option::Option<list_sites_response::Result>,
|
||||||
|
}
|
||||||
|
|
||||||
|
/// Nested message and enum types in `ListSitesResponse`.
|
||||||
|
pub mod list_sites_response {
|
||||||
|
use crate::models::domain;
|
||||||
|
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct Result {
|
||||||
|
#[prost(message, repeated, tag = "1")]
|
||||||
|
pub sites: ::prost::alloc::vec::Vec<domain::Site>,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub const SUBJECT_CREATE_SITE: &str = const_format::concatcp!(SUBJECT, ".CreateSite");
|
||||||
|
/// subject = bet.beteran.c2se.backend.site.CreateSite
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct CreateSiteRequest {
|
||||||
|
#[prost(string, tag = "1")]
|
||||||
|
pub url: ::prost::alloc::string::String,
|
||||||
|
#[prost(bool, tag = "2")]
|
||||||
|
pub show: bool,
|
||||||
|
#[prost(bool, tag = "3")]
|
||||||
|
pub can_use: bool,
|
||||||
|
}
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct CreateSiteResponse {
|
||||||
|
#[prost(message, optional, tag = "1")]
|
||||||
|
pub error: ::core::option::Option<rpc::Error>,
|
||||||
|
#[prost(message, optional, tag = "2")]
|
||||||
|
pub result: ::core::option::Option<create_site_response::Result>,
|
||||||
|
}
|
||||||
|
/// Nested message and enum types in `CreateSiteResponse`.
|
||||||
|
pub mod create_site_response {
|
||||||
|
use crate::models::domain;
|
||||||
|
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct Result {
|
||||||
|
#[prost(message, optional, tag = "1")]
|
||||||
|
pub site: ::core::option::Option<domain::Site>,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub const SUBJECT_UPDATE_SITE: &str = const_format::concatcp!(SUBJECT, ".UpdateSite");
|
||||||
|
/// subject = bet.beteran.c2se.backend.site.UpdateSite
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct UpdateSiteRequest {
|
||||||
|
#[prost(string, tag = "1")]
|
||||||
|
pub id: ::prost::alloc::string::String,
|
||||||
|
#[prost(string, tag = "2")]
|
||||||
|
pub url: ::prost::alloc::string::String,
|
||||||
|
#[prost(bool, tag = "3")]
|
||||||
|
pub show: bool,
|
||||||
|
#[prost(bool, tag = "4")]
|
||||||
|
pub can_use: bool,
|
||||||
|
}
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct UpdateSiteResponse {
|
||||||
|
#[prost(message, optional, tag = "1")]
|
||||||
|
pub error: ::core::option::Option<rpc::Error>,
|
||||||
|
#[prost(message, optional, tag = "2")]
|
||||||
|
pub result: ::core::option::Option<update_site_response::Result>,
|
||||||
|
}
|
||||||
|
/// Nested message and enum types in `UpdateSiteResponse`.
|
||||||
|
pub mod update_site_response {
|
||||||
|
use crate::models::domain;
|
||||||
|
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct Result {
|
||||||
|
#[prost(message, optional, tag = "1")]
|
||||||
|
pub site: ::core::option::Option<domain::Site>,
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub const SUBJECT_DELETE_SITE: &str = const_format::concatcp!(SUBJECT, ".DeleteSite");
|
||||||
|
/// subject = bet.beteran.c2se.backend.site.DeleteSite
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct DeleteSiteRequest {
|
||||||
|
#[prost(string, tag = "1")]
|
||||||
|
pub id: ::prost::alloc::string::String,
|
||||||
|
}
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct DeleteSiteResponse {
|
||||||
|
#[prost(message, optional, tag = "1")]
|
||||||
|
pub error: ::core::option::Option<rpc::Error>,
|
||||||
|
#[prost(message, optional, tag = "2")]
|
||||||
|
pub result: ::core::option::Option<delete_site_response::Result>,
|
||||||
|
}
|
||||||
|
/// Nested message and enum types in `DeleteSiteResponse`.
|
||||||
|
pub mod delete_site_response {
|
||||||
|
#[derive(Clone, PartialEq, ::prost::Message)]
|
||||||
|
pub struct Result {}
|
||||||
|
}
|
Loading…
Reference in New Issue
Block a user