1#[doc = "The value of the attribute."]
3#[derive(Default, Debug, Clone, PartialEq)]
4pub enum InventoryItemCharacteristicValue {
5 String(super::super::types::String),
6 Integer(super::super::types::Integer),
7 Decimal(super::super::types::Decimal),
8 Boolean(super::super::types::Boolean),
9 Url(super::super::types::Url),
10 DateTime(super::super::types::DateTime),
11 Quantity(Box<super::super::types::Quantity>),
12 Range(Box<super::super::types::Range>),
13 Ratio(Box<super::super::types::Ratio>),
14 Annotation(Box<super::super::types::Annotation>),
15 Address(Box<super::super::types::Address>),
16 Duration(Box<super::super::types::Duration>),
17 CodeableConcept(Box<super::super::types::CodeableConcept>),
18 #[default]
19 Invalid,
20}
21#[doc = "The item name(s) - the brand name, or common name, functional name, generic name."]
22#[derive(Debug, Clone, PartialEq)]
23pub struct InventoryItemName {
24 #[doc = "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces."]
25 pub r#id: Option<std::string::String>,
26 #[doc = "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
27 pub r#extension: Vec<super::super::types::Extension>,
28 #[doc = "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
29 pub r#modifier_extension: Vec<super::super::types::Extension>,
30 #[doc = "The type of name e.g. 'brand-name', 'functional-name', 'common-name'."]
31 pub r#name_type: Box<super::super::types::Coding>,
32 #[doc = "The language that the item name is expressed in."]
33 pub r#language: super::super::types::Code,
34 #[doc = "The name or designation that the item is given."]
35 pub r#name: super::super::types::String,
36}
37#[allow(clippy::derivable_impls)]
38impl Default for InventoryItemName {
39 fn default() -> Self {
40 Self {
41 r#id: Default::default(),
42 r#extension: Default::default(),
43 r#modifier_extension: Default::default(),
44 r#name_type: Box::new(super::super::types::Coding {
45 id: Some("$invalid".to_string()),
46 ..Default::default()
47 }),
48 r#language: super::super::types::Code {
49 id: Some("$invalid".to_string()),
50 ..Default::default()
51 },
52 r#name: super::super::types::String {
53 id: Some("$invalid".to_string()),
54 ..Default::default()
55 },
56 }
57 }
58}
59#[doc = "Organization(s) responsible for the product."]
60#[derive(Debug, Clone, PartialEq)]
61pub struct InventoryItemResponsibleOrganization {
62 #[doc = "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces."]
63 pub r#id: Option<std::string::String>,
64 #[doc = "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
65 pub r#extension: Vec<super::super::types::Extension>,
66 #[doc = "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
67 pub r#modifier_extension: Vec<super::super::types::Extension>,
68 #[doc = "The role of the organization e.g. manufacturer, distributor, etc."]
69 pub r#role: Box<super::super::types::CodeableConcept>,
70 #[doc = "An organization that has an association with the item, e.g. manufacturer, distributor, responsible, etc."]
71 pub r#organization: Box<super::super::types::Reference>,
72}
73#[allow(clippy::derivable_impls)]
74impl Default for InventoryItemResponsibleOrganization {
75 fn default() -> Self {
76 Self {
77 r#id: Default::default(),
78 r#extension: Default::default(),
79 r#modifier_extension: Default::default(),
80 r#role: Box::new(super::super::types::CodeableConcept {
81 id: Some("$invalid".to_string()),
82 ..Default::default()
83 }),
84 r#organization: Box::new(super::super::types::Reference {
85 id: Some("$invalid".to_string()),
86 ..Default::default()
87 }),
88 }
89 }
90}
91#[doc = "The descriptive characteristics of the inventory item."]
92#[derive(Debug, Clone, PartialEq)]
93pub struct InventoryItemDescription {
94 #[doc = "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces."]
95 pub r#id: Option<std::string::String>,
96 #[doc = "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
97 pub r#extension: Vec<super::super::types::Extension>,
98 #[doc = "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
99 pub r#modifier_extension: Vec<super::super::types::Extension>,
100 #[doc = "The language for the item description, when an item must be described in different languages and those languages may be authoritative and not translations of a 'main' language."]
101 pub r#language: Option<super::super::types::Code>,
102 #[doc = "Textual description of the item."]
103 pub r#description: Option<super::super::types::String>,
104}
105#[allow(clippy::derivable_impls)]
106impl Default for InventoryItemDescription {
107 fn default() -> Self {
108 Self {
109 r#id: Default::default(),
110 r#extension: Default::default(),
111 r#modifier_extension: Default::default(),
112 r#language: Default::default(),
113 r#description: Default::default(),
114 }
115 }
116}
117#[doc = "Association with other items or products."]
118#[derive(Debug, Clone, PartialEq)]
119pub struct InventoryItemAssociation {
120 #[doc = "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces."]
121 pub r#id: Option<std::string::String>,
122 #[doc = "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
123 pub r#extension: Vec<super::super::types::Extension>,
124 #[doc = "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
125 pub r#modifier_extension: Vec<super::super::types::Extension>,
126 #[doc = "This attribute defined the type of association when establishing associations or relations between items, e.g. 'packaged within' or 'used with' or 'to be mixed with."]
127 pub r#association_type: Box<super::super::types::CodeableConcept>,
128 #[doc = "The related item or product."]
129 pub r#related_item: Box<super::super::types::Reference>,
130 #[doc = "The quantity of the related product in this product - Numerator is the quantity of the related product. Denominator is the quantity of the present product. For example a value of 20 means that this product contains 20 units of the related product; a value of 1:20 means the inverse - that the contained product contains 20 units of the present product."]
131 pub r#quantity: Box<super::super::types::Ratio>,
132}
133#[allow(clippy::derivable_impls)]
134impl Default for InventoryItemAssociation {
135 fn default() -> Self {
136 Self {
137 r#id: Default::default(),
138 r#extension: Default::default(),
139 r#modifier_extension: Default::default(),
140 r#association_type: Box::new(super::super::types::CodeableConcept {
141 id: Some("$invalid".to_string()),
142 ..Default::default()
143 }),
144 r#related_item: Box::new(super::super::types::Reference {
145 id: Some("$invalid".to_string()),
146 ..Default::default()
147 }),
148 r#quantity: Box::new(super::super::types::Ratio {
149 id: Some("$invalid".to_string()),
150 ..Default::default()
151 }),
152 }
153 }
154}
155#[doc = "The descriptive or identifying characteristics of the item."]
156#[derive(Debug, Clone, PartialEq)]
157pub struct InventoryItemCharacteristic {
158 #[doc = "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces."]
159 pub r#id: Option<std::string::String>,
160 #[doc = "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
161 pub r#extension: Vec<super::super::types::Extension>,
162 #[doc = "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
163 pub r#modifier_extension: Vec<super::super::types::Extension>,
164 #[doc = "The type of characteristic that is being defined."]
165 pub r#characteristic_type: Box<super::super::types::CodeableConcept>,
166 #[doc = "The value of the attribute."]
167 pub r#value: InventoryItemCharacteristicValue,
168}
169#[allow(clippy::derivable_impls)]
170impl Default for InventoryItemCharacteristic {
171 fn default() -> Self {
172 Self {
173 r#id: Default::default(),
174 r#extension: Default::default(),
175 r#modifier_extension: Default::default(),
176 r#characteristic_type: Box::new(super::super::types::CodeableConcept {
177 id: Some("$invalid".to_string()),
178 ..Default::default()
179 }),
180 r#value: Default::default(),
181 }
182 }
183}
184#[doc = "Instances or occurrences of the product."]
185#[derive(Debug, Clone, PartialEq)]
186pub struct InventoryItemInstance {
187 #[doc = "Unique id for the element within a resource (for internal references). This may be any string value that does not contain spaces."]
188 pub r#id: Option<std::string::String>,
189 #[doc = "May be used to represent additional information that is not part of the basic definition of the element. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
190 pub r#extension: Vec<super::super::types::Extension>,
191 #[doc = "May be used to represent additional information that is not part of the basic definition of the element and that modifies the understanding of the element in which it is contained and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
192 pub r#modifier_extension: Vec<super::super::types::Extension>,
193 #[doc = "The identifier for the physical instance, typically a serial number."]
194 pub r#identifier: Vec<super::super::types::Identifier>,
195 #[doc = "The lot or batch number of the item."]
196 pub r#lot_number: Option<super::super::types::String>,
197 #[doc = "The expiry date or date and time for the product."]
198 pub r#expiry: Option<super::super::types::DateTime>,
199 #[doc = "The subject that the item is associated with."]
200 pub r#subject: Option<Box<super::super::types::Reference>>,
201 #[doc = "The location that the item is associated with."]
202 pub r#location: Option<Box<super::super::types::Reference>>,
203}
204#[allow(clippy::derivable_impls)]
205impl Default for InventoryItemInstance {
206 fn default() -> Self {
207 Self {
208 r#id: Default::default(),
209 r#extension: Default::default(),
210 r#modifier_extension: Default::default(),
211 r#identifier: Default::default(),
212 r#lot_number: Default::default(),
213 r#expiry: Default::default(),
214 r#subject: Default::default(),
215 r#location: Default::default(),
216 }
217 }
218}
219#[doc = "functional description of an inventory item used in inventory and supply-related workflows."]
220#[derive(Debug, Clone, PartialEq)]
221pub struct InventoryItem {
222 #[doc = "The logical id of the resource, as used in the URL for the resource. Once assigned, this value never changes."]
223 pub r#id: Option<super::super::types::Id>,
224 #[doc = "The metadata about the resource. This is content that is maintained by the infrastructure. Changes to the content might not always be associated with version changes to the resource."]
225 pub r#meta: Option<Box<super::super::types::Meta>>,
226 #[doc = "A reference to a set of rules that were followed when the resource was constructed, and which must be understood when processing the content. Often, this is a reference to an implementation guide that defines the special rules along with other profiles etc."]
227 pub r#implicit_rules: Option<super::super::types::Uri>,
228 #[doc = "The base language in which the resource is written."]
229 pub r#language: Option<super::super::types::Code>,
230 #[doc = "A human-readable narrative that contains a summary of the resource and can be used to represent the content of the resource to a human. The narrative need not encode all the structured data, but is required to contain sufficient detail to make it \"clinically safe\" for a human to just read the narrative. Resource definitions may define what content should be represented in the narrative to ensure clinical safety."]
231 pub r#text: Option<Box<super::super::types::Narrative>>,
232 #[doc = "These resources do not have an independent existence apart from the resource that contains them - they cannot be identified independently, nor can they have their own independent transaction scope. This is allowed to be a Parameters resource if and only if it is referenced by a resource that provides context/meaning."]
233 pub r#contained: Vec<super::super::Resource>,
234 #[doc = "May be used to represent additional information that is not part of the basic definition of the resource. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer can define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension."]
235 pub r#extension: Vec<super::super::types::Extension>,
236 #[doc = "May be used to represent additional information that is not part of the basic definition of the resource and that modifies the understanding of the element that contains it and/or the understanding of the containing element's descendants. Usually modifier elements provide negation or qualification. To make the use of extensions safe and managable, there is a strict set of governance applied to the definition and use of extensions. Though any implementer is allowed to define an extension, there is a set of requirements that SHALL be met as part of the definition of the extension. Applications processing a resource are required to check for modifier extensions.\n\nModifier extensions SHALL NOT change the meaning of any elements on Resource or DomainResource (including cannot change the meaning of modifierExtension itself)."]
237 pub r#modifier_extension: Vec<super::super::types::Extension>,
238 #[doc = "Business identifier for the inventory item."]
239 pub r#identifier: Vec<super::super::types::Identifier>,
240 #[doc = "Status of the item entry."]
241 pub r#status: super::super::types::Code,
242 #[doc = "Category or class of the item."]
243 pub r#category: Vec<super::super::types::CodeableConcept>,
244 #[doc = "Code designating the specific type of item."]
245 pub r#code: Vec<super::super::types::CodeableConcept>,
246 #[doc = "The item name(s) - the brand name, or common name, functional name, generic name."]
247 pub r#name: Vec<InventoryItemName>,
248 #[doc = "Organization(s) responsible for the product."]
249 pub r#responsible_organization: Vec<InventoryItemResponsibleOrganization>,
250 #[doc = "The descriptive characteristics of the inventory item."]
251 pub r#description: Option<InventoryItemDescription>,
252 #[doc = "The usage status e.g. recalled, in use, discarded... This can be used to indicate that the items have been taken out of inventory, or are in use, etc."]
253 pub r#inventory_status: Vec<super::super::types::CodeableConcept>,
254 #[doc = "The base unit of measure - the unit in which the product is used or counted."]
255 pub r#base_unit: Option<Box<super::super::types::CodeableConcept>>,
256 #[doc = "Net content or amount present in the item."]
257 pub r#net_content: Option<Box<super::super::types::Quantity>>,
258 #[doc = "Association with other items or products."]
259 pub r#association: Vec<InventoryItemAssociation>,
260 #[doc = "The descriptive or identifying characteristics of the item."]
261 pub r#characteristic: Vec<InventoryItemCharacteristic>,
262 #[doc = "Instances or occurrences of the product."]
263 pub r#instance: Option<InventoryItemInstance>,
264 #[doc = "Link to a product resource used in clinical workflows."]
265 pub r#product_reference: Option<Box<super::super::types::Reference>>,
266}
267#[allow(clippy::derivable_impls)]
268impl Default for InventoryItem {
269 fn default() -> Self {
270 Self {
271 r#id: Default::default(),
272 r#meta: Default::default(),
273 r#implicit_rules: Default::default(),
274 r#language: Default::default(),
275 r#text: Default::default(),
276 r#contained: Default::default(),
277 r#extension: Default::default(),
278 r#modifier_extension: Default::default(),
279 r#identifier: Default::default(),
280 r#status: super::super::types::Code {
281 id: Some("$invalid".to_string()),
282 ..Default::default()
283 },
284 r#category: Default::default(),
285 r#code: Default::default(),
286 r#name: Default::default(),
287 r#responsible_organization: Default::default(),
288 r#description: Default::default(),
289 r#inventory_status: Default::default(),
290 r#base_unit: Default::default(),
291 r#net_content: Default::default(),
292 r#association: Default::default(),
293 r#characteristic: Default::default(),
294 r#instance: Default::default(),
295 r#product_reference: Default::default(),
296 }
297 }
298}