nautobot_openapi/models/
circuit_request.rs1#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
14pub struct CircuitRequest {
15 #[serde(rename = "id", skip_serializing_if = "Option::is_none")]
16 pub id: Option<uuid::Uuid>,
17 #[serde(rename = "cid")]
18 pub cid: String,
19 #[serde(
20 rename = "install_date",
21 default,
22 with = "::serde_with::rust::double_option",
23 skip_serializing_if = "Option::is_none"
24 )]
25 pub install_date: Option<Option<String>>,
26 #[serde(
27 rename = "commit_rate",
28 default,
29 with = "::serde_with::rust::double_option",
30 skip_serializing_if = "Option::is_none"
31 )]
32 pub commit_rate: Option<Option<i32>>,
33 #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
34 pub description: Option<String>,
35 #[serde(rename = "comments", skip_serializing_if = "Option::is_none")]
36 pub comments: Option<String>,
37 #[serde(rename = "status")]
38 pub status: Box<crate::models::ApprovalWorkflowStageResponseApprovalWorkflowStage>,
39 #[serde(rename = "provider")]
40 pub provider: Box<crate::models::ApprovalWorkflowStageResponseApprovalWorkflowStage>,
41 #[serde(rename = "circuit_type")]
42 pub circuit_type: Box<crate::models::ApprovalWorkflowStageResponseApprovalWorkflowStage>,
43 #[serde(
44 rename = "tenant",
45 default,
46 with = "::serde_with::rust::double_option",
47 skip_serializing_if = "Option::is_none"
48 )]
49 pub tenant: Option<Option<Box<crate::models::ApprovalWorkflowUser>>>,
50 #[serde(rename = "tags", skip_serializing_if = "Option::is_none")]
51 pub tags: Option<Vec<crate::models::ApprovalWorkflowStageResponseApprovalWorkflowStage>>,
52 #[serde(rename = "custom_fields", skip_serializing_if = "Option::is_none")]
53 pub custom_fields: Option<::std::collections::HashMap<String, serde_json::Value>>,
54 #[serde(rename = "relationships", skip_serializing_if = "Option::is_none")]
55 pub relationships: Option<
56 ::std::collections::HashMap<
57 String,
58 crate::models::ApprovalWorkflowDefinitionRequestRelationshipsValue,
59 >,
60 >,
61}
62
63impl CircuitRequest {
64 pub fn new(
66 cid: String,
67 status: crate::models::ApprovalWorkflowStageResponseApprovalWorkflowStage,
68 provider: crate::models::ApprovalWorkflowStageResponseApprovalWorkflowStage,
69 circuit_type: crate::models::ApprovalWorkflowStageResponseApprovalWorkflowStage,
70 ) -> CircuitRequest {
71 CircuitRequest {
72 id: None,
73 cid,
74 install_date: None,
75 commit_rate: None,
76 description: None,
77 comments: None,
78 status: Box::new(status),
79 provider: Box::new(provider),
80 circuit_type: Box::new(circuit_type),
81 tenant: None,
82 tags: None,
83 custom_fields: None,
84 relationships: None,
85 }
86 }
87}