jira_api_v2/models/
issue_transition.rs

1/*
2 * The Jira Cloud platform REST API
3 *
4 * Jira Cloud platform REST API documentation
5 *
6 * The version of the OpenAPI document: 1001.0.0-SNAPSHOT
7 * Contact: ecosystem@atlassian.com
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// IssueTransition : Details of an issue transition.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct IssueTransition {
17    /// The ID of the issue transition. Required when specifying a transition to undertake.
18    #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
19    pub id: Option<String>,
20    /// The name of the issue transition.
21    #[serde(rename = "name", skip_serializing_if = "Option::is_none")]
22    pub name: Option<String>,
23    /// Details of the issue status after the transition.
24    #[serde(rename = "to", skip_serializing_if = "Option::is_none")]
25    pub to: Option<models::StatusDetails>,
26    /// Whether there is a screen associated with the issue transition.
27    #[serde(rename = "hasScreen", skip_serializing_if = "Option::is_none")]
28    pub has_screen: Option<bool>,
29    /// Whether the issue transition is global, that is, the transition is applied to issues regardless of their status.
30    #[serde(rename = "isGlobal", skip_serializing_if = "Option::is_none")]
31    pub is_global: Option<bool>,
32    /// Whether this is the initial issue transition for the workflow.
33    #[serde(rename = "isInitial", skip_serializing_if = "Option::is_none")]
34    pub is_initial: Option<bool>,
35    /// Whether the transition is available to be performed.
36    #[serde(rename = "isAvailable", skip_serializing_if = "Option::is_none")]
37    pub is_available: Option<bool>,
38    /// Whether the issue has to meet criteria before the issue transition is applied.
39    #[serde(rename = "isConditional", skip_serializing_if = "Option::is_none")]
40    pub is_conditional: Option<bool>,
41    /// Details of the fields associated with the issue transition screen. Use this information to populate `fields` and `update` in a transition request.
42    #[serde(rename = "fields", skip_serializing_if = "Option::is_none")]
43    pub fields: Option<std::collections::HashMap<String, models::FieldMetadata>>,
44    /// Expand options that include additional transition details in the response.
45    #[serde(rename = "expand", skip_serializing_if = "Option::is_none")]
46    pub expand: Option<String>,
47    #[serde(rename = "looped", skip_serializing_if = "Option::is_none")]
48    pub looped: Option<bool>,
49}
50
51impl IssueTransition {
52    /// Details of an issue transition.
53    pub fn new() -> IssueTransition {
54        IssueTransition {
55            id: None,
56            name: None,
57            to: None,
58            has_screen: None,
59            is_global: None,
60            is_initial: None,
61            is_available: None,
62            is_conditional: None,
63            fields: None,
64            expand: None,
65            looped: None,
66        }
67    }
68}
69