notify: add missing doc-comment description for api enums

this is used as description in the api schema

Signed-off-by: Thomas Lamprecht <t.lamprecht@proxmox.com>
This commit is contained in:
Thomas Lamprecht 2024-10-22 14:49:10 +02:00
parent 331fa7a732
commit bd1133fcd2
5 changed files with 6 additions and 0 deletions

View File

@ -84,6 +84,7 @@ pub struct GotifyEndpoint {
#[api] #[api]
#[derive(Serialize, Deserialize)] #[derive(Serialize, Deserialize)]
#[serde(rename_all = "kebab-case")] #[serde(rename_all = "kebab-case")]
/// The set of properties that can be deleted from a gotify endpoint configuration.
pub enum DeleteableGotifyProperty { pub enum DeleteableGotifyProperty {
/// Delete `comment` /// Delete `comment`
Comment, Comment,

View File

@ -84,6 +84,7 @@ pub struct SendmailConfig {
#[api] #[api]
#[derive(Serialize, Deserialize)] #[derive(Serialize, Deserialize)]
#[serde(rename_all = "kebab-case")] #[serde(rename_all = "kebab-case")]
/// The set of properties that can be deleted from a sendmail endpoint configuration.
pub enum DeleteableSendmailProperty { pub enum DeleteableSendmailProperty {
/// Delete `author` /// Delete `author`
Author, Author,

View File

@ -115,6 +115,7 @@ pub struct SmtpConfig {
#[api] #[api]
#[derive(Serialize, Deserialize)] #[derive(Serialize, Deserialize)]
#[serde(rename_all = "kebab-case")] #[serde(rename_all = "kebab-case")]
/// The set of properties that can be deleted from a smtp endpoint configuration.
pub enum DeleteableSmtpProperty { pub enum DeleteableSmtpProperty {
/// Delete `author` /// Delete `author`
Author, Author,

View File

@ -138,6 +138,7 @@ impl FromStr for Severity {
#[api()] #[api()]
#[derive(Clone, Debug, Copy, Serialize, Deserialize, PartialEq, Eq, PartialOrd)] #[derive(Clone, Debug, Copy, Serialize, Deserialize, PartialEq, Eq, PartialOrd)]
#[serde(rename_all = "kebab-case")] #[serde(rename_all = "kebab-case")]
/// The origin of a notification configuration entry.
pub enum Origin { pub enum Origin {
/// User-created config entry /// User-created config entry
UserCreated, UserCreated,

View File

@ -19,6 +19,7 @@ pub const MATCHER_TYPENAME: &str = "matcher";
#[api] #[api]
#[derive(Debug, Serialize, Deserialize, Default, Clone, Copy)] #[derive(Debug, Serialize, Deserialize, Default, Clone, Copy)]
#[serde(rename_all = "kebab-case")] #[serde(rename_all = "kebab-case")]
/// The mode in which the results of matches are combined.
pub enum MatchModeOperator { pub enum MatchModeOperator {
/// All match statements have to match (AND) /// All match statements have to match (AND)
#[default] #[default]
@ -415,6 +416,7 @@ impl FromStr for CalendarMatcher {
#[api] #[api]
#[derive(Serialize, Deserialize)] #[derive(Serialize, Deserialize)]
#[serde(rename_all = "kebab-case")] #[serde(rename_all = "kebab-case")]
/// The set of matcher properties that can be deleted.
pub enum DeleteableMatcherProperty { pub enum DeleteableMatcherProperty {
/// Delete `comment` /// Delete `comment`
Comment, Comment,