could anyone maybe clarify why in the order entry design the accessionNumber was chosen to default to null?
Reading at https://wiki.openmrs.org/display/docs/Order+Entry+API
I can see that the orderNumber is unique per order and can be used when referencing the order from external systems.
I am working on the radiology module, and in radiology it is very common to use the accessionNumber when searching for DICOM studies made for a specific order. I am now wondering if I should implement a similar mechanism to the OrderNumberGenerator for the accessionNumber in the radiology API or if there is interest in having such a mechanism in openmrs-core?
Order number is the placer number – i.e., an identifier generated to identify the request that something be done. An accession number is an identifier a filler number – i.e., an identifier generated by the application fulfilling the request. It’s not within the purview of the EMR (or order entry service) to manage accession numbers. A radiology system may assign an accession number to uniquely identify the study (or studies) fulfilling the order. Likewise a lab system may generate an accession number for each specimen received.
In short, accession number generation/management is within the purview of the fulfiller, which might be a module or could be a separate system altogether (radiology, laboratory, pharmacy, ancillary services, etc.). To that end, I’m not sure it would make sense for the EMR to be generating these number. An exception might be a utility for general identifier generation to be used across a variety of modules.