Got feedback or spotted a mistake?

Leave a comment at the end of this page or email contact@krishagni.com

Configure Specimen Status Field and Icons

Introduction

Users have the option to display a status icon for each specimen on the specimen list view page. To enable this feature, you must incorporate the following configuration within the specimen list view section. This configuration allows for color-coded representation of specimens according to their respective statuses.

It is quite simple to distinguish between the specimens that have been collected, are pending, or have been distributed.

The default workflow comes with the specimen status field configured across the system. 

Configuration

However, if your CP has JSON workflow configured, the color-coding must be configured within the CP workflow.

{ "name": "specimen-list-view", "data": { "icons": [ "<os-specimen-status-icon specimen=\"row\"></os-specimen-status-icon>" //Displays availability status of specimen on specimen list view page ], "columns": [ { "expr": "Specimen.label", "caption": "Label", "metainfo": { "showLink": "true" } }, { "expr": "Specimen.createdOn", "caption": "Created On" }, { "expr": "Specimen.type", "caption": "Type" }, { "expr": "Specimen.tissueSite", "caption": "Anatomic Site" }, { "expr": "Specimen.pathologicalStatus", "caption": "Pathology Status" }, { "expr": "Specimen.availableQty", "caption": "Quantity", "metainfo": { "showUnit": "true", "measure": "quantity" } }, { "expr": "concat(Specimen.specimenPosition.containerName, concat_ws(\"\", concat(\" (\", Specimen.specimenPosition.formattedPos, \")\")))", "caption": "Location" } ], "criteria": "Specimen.collectionStatus exists", // Make sure that you update the criteria "orderBy": [ { "expr": "Specimen.createdOn", "direction": "desc" } ], "filters": [ { "expr": "Specimen.label", "caption": "Label", "searchType": "contains" }, { "expr": "Specimen.lineage", "caption": "Lineage" }, { "expr": "Specimen.createdOn", "caption": "Created On" }, { "expr": "Specimen.type", "caption": "Type" }, { "expr": "Specimen.tissueSite", "caption": "Anatomic Site" }, { "expr": "Specimen.pathologicalStatus", "caption": "Pathology Status" }, { "expr": "Specimen.availableQty", "caption": "Quantity" }, { "expr": "Specimen.availabilityStatus", //Adds a 'Status' field in filters "caption": "Status", "values": [ "Available", "Closed", "Distributed", "Missed Collection", "Not Collected", "Pending", "Reserved" ] } ] } },

Screenshot:

image-20240919-090345.png

Configure Icons based on Specimen Class/Type

Not supported in v11 onwards.

You can configure icons based on specimen class or specimen types. For example, Buffy Coat should be displayed in turquoise and DNA in pink.

{ "name" : "specimen-list-view", "view" : null, "ctrl" : null, "data" : { "icons" : [ "<span style=\"display: inline-block; margin-left: 5px;\">", //Adds a space between the icon and checkbox "<os-specimen-status-icon ng-show = \"row.hidden.specimenType == 'DNA'\" style=\"color: pink;\"></os-specimen-status-icon>", // Displays DNA in pink "<os-specimen-status-icon ng-show = \"row.hidden.specimenType == 'Buffy Coat'\" style=\"color: turquoise;\"></os-specimen-status-icon>", // Displays Buffy Coat in turquoise "</span>" ], "columns" : [ { "expr" : "Specimen.label", "caption" : "Label", "metainfo" : { "showLink" : "true" } }, { "expr" : "Specimen.createdOn", "caption" : "Created On" }, { "expr" : "Specimen.type", "caption" : "Type" }, { "expr" : "Specimen.tissueSite", "caption" : "Anatomic Site" }, { "expr" : "Specimen.pathologicalStatus", "caption" : "Pathology Status" }, { "expr" : "Specimen.availableQty", "caption" : "Quantity", "metainfo" : { "showUnit" : "true", "measure" : "quantity" } }, { "expr" : "concat(Specimen.specimenPosition.containerName, concat_ws(\"\", concat(\" (\", Specimen.specimenPosition.formattedPos, \")\")))", "caption" : "Location" } ], "criteria" : "Specimen.collectionStatus exists", "orderBy" : [ { "expr" : "Specimen.createdOn", "direction" : "desc" } ], "filters" : [ { "expr" : "Specimen.label", "caption" : "Label", "searchType" : "contains" }, { "expr" : "Specimen.lineage", "caption" : "Lineage" }, { "expr" : "Specimen.createdOn", "caption" : "Created On" }, { "expr" : "Specimen.type", "caption" : "Type" }, { "expr" : "Specimen.tissueSite", "caption" : "Anatomic Site" }, { "expr" : "Specimen.pathologicalStatus", "caption" : "Pathology Status" }, { "expr" : "Specimen.availableQty", "caption" : "Quantity" }, { "expr" : "Specimen.availabilityStatus", "caption" : "Status", "values" : [ "Available", "Closed", "Distributed", "Missed Collection", "Not Collected", "Pending", "Reserved" ] } ] } }

 

Got feedback or spotted a mistake?

Leave a comment at the end of this page or email contact@krishagni.com