FHIR CI-Build

This is the Continuous Integration Build of FHIR (will be incorrect/inconsistent at times).
See the Directory of published versions

Inventoryreport.shex

Orders and Observations Work GroupMaturity Level: N/AStandards Status: InformativeCompartments: No defined compartments

Raw ShEx

ShEx statement for inventoryreport

PREFIX fhir: <http://hl7.org/fhir/> 
PREFIX fhirvs: <http://hl7.org/fhir/ValueSet/>
PREFIX xsd: <http://www.w3.org/2001/XMLSchema#> 
PREFIX rdf: <http://www.w3.org/1999/02/22-rdf-syntax-ns#> 

IMPORT <code.shex>
IMPORT <Device.shex>
IMPORT <Period.shex>
IMPORT <Patient.shex>
IMPORT <dateTime.shex>
IMPORT <Location.shex>
IMPORT <Quantity.shex>
IMPORT <Reference.shex>
IMPORT <Identifier.shex>
IMPORT <Annotation.shex>
IMPORT <Practitioner.shex>
IMPORT <RelatedPerson.shex>
IMPORT <DomainResource.shex>
IMPORT <CodeableConcept.shex>
IMPORT <BackboneElement.shex>
IMPORT <CodeableReference.shex>


start=@<InventoryReport> AND {fhir:nodeRole [fhir:treeRoot]}

# A report of inventory or stock items
<InventoryReport> EXTENDS @<DomainResource> CLOSED {   

    a [fhir:InventoryReport]?;
    fhir:nodeRole [fhir:treeRoot]?;

    fhir:identifier @<OneOrMore_Identifier>?;  # Business identifier for the report
    fhir:status @<code> AND
    	{fhir:v @fhirvs:inventoryreport-status};  # draft | requested | active | 
                                            # entered-in-error 
    fhir:countType @<code> AND
    	{fhir:v @fhirvs:inventoryreport-counttype};  # snapshot | difference
    fhir:operationType @<CodeableConcept>?;  # addition | subtraction
    fhir:operationTypeReason @<CodeableConcept>?;  # The reason for this count - 
                                            # regular count, ad-hoc count, new 
                                            # arrivals, etc 
    fhir:reportedDateTime @<dateTime>;      # When the report has been submitted
    fhir:reporter @<Reference> AND {fhir:link 
    			@<Device> OR 
    			@<Patient> OR 
    			@<Practitioner> OR 
    			@<RelatedPerson> ? }?;  # Who submits the report
    fhir:reportingPeriod @<Period>?;        # The period the report refers to
    fhir:inventoryListing @<OneOrMore_InventoryReport.inventoryListing>?;  # An inventory listing section 
                                            # (grouped by any of the attributes) 
    fhir:note @<OneOrMore_Annotation>?;     # A note associated with the 
                                            # InventoryReport 
}  

# An inventory listing section (grouped by any of the attributes)
<InventoryReport.inventoryListing> EXTENDS @<BackboneElement> CLOSED {   
    fhir:location @<Reference> AND {fhir:link 
    			@<Location> ? }?;  # Location of the inventory items
    fhir:itemStatus @<CodeableConcept>?;    # The status of the items that are 
                                            # being reported 
    fhir:countingDateTime @<dateTime>?;     # The date and time when the items 
                                            # were counted 
    fhir:item @<OneOrMore_InventoryReport.inventoryListing.item>?;  # The item or items in this listing
}  

# The item or items in this listing
<InventoryReport.inventoryListing.item> EXTENDS @<BackboneElement> CLOSED {   
    fhir:category @<CodeableConcept>?;      # The inventory category or 
                                            # classification of the items being 
                                            # reported 
    fhir:quantity @<Quantity>;              # The quantity of the item or items 
                                            # being reported 
    fhir:item @<CodeableReference>;         # The code or reference to the item 
                                            # type 
}  

#---------------------- Cardinality Types (OneOrMore) -------------------

<OneOrMore_Identifier> CLOSED {
    rdf:first @<Identifier>  ;
    rdf:rest [rdf:nil] OR @<OneOrMore_Identifier> 
}

<OneOrMore_InventoryReport.inventoryListing> CLOSED {
    rdf:first @<InventoryReport.inventoryListing>  ;
    rdf:rest [rdf:nil] OR @<OneOrMore_InventoryReport.inventoryListing> 
}

<OneOrMore_Annotation> CLOSED {
    rdf:first @<Annotation>  ;
    rdf:rest [rdf:nil] OR @<OneOrMore_Annotation> 
}

<OneOrMore_InventoryReport.inventoryListing.item> CLOSED {
    rdf:first @<InventoryReport.inventoryListing.item>  ;
    rdf:rest [rdf:nil] OR @<OneOrMore_InventoryReport.inventoryListing.item> 
}

#---------------------- Value Sets ------------------------

# The type of count.
fhirvs:inventoryreport-counttype ["snapshot" "difference"]

# The status of the InventoryReport.
fhirvs:inventoryreport-status ["draft" "requested" "active" "entered-in-error"]


Usage note: every effort has been made to ensure that the ShEx files are correct and useful, but they are not a normative part of the specification.