windmill-api 1.738.0

No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
Documentation
/*
 * Windmill API
 *
 * No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
 *
 * The version of the OpenAPI document: 1.738.0
 * Contact: contact@windmill.dev
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct MigrateLegacyDraftRequest {
    /// delete the legacy draft, or take ownership of it.
    #[serde(rename = "action")]
    pub action: Action,
}

impl MigrateLegacyDraftRequest {
    pub fn new(action: Action) -> MigrateLegacyDraftRequest {
        MigrateLegacyDraftRequest {
            action,
        }
    }
}
/// delete the legacy draft, or take ownership of it.
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Action {
    #[serde(rename = "delete")]
    Delete,
    #[serde(rename = "assign_to_self")]
    AssignToSelf,
}

impl Default for Action {
    fn default() -> Action {
        Self::Delete
    }
}