예제 #1
0
        public void LabelAppend(LabelData labelData, Priority priority)
        {
            if ((this.Text == string.Empty))
            {
                return;
            }

            if (LabelPrintMode == LabelPrintMode.Collection)
            {
                labelData.LabelAppendCollection(this.Text,this.SpecimenType,this.SpecimenExtension);
            }
            else if (LabelPrintMode == LabelPrintMode.Demographic)
            {
                labelData.LabelAppendDemographic(this.Text, this.SpecimenType, this.SpecimenExtension);
            }
            else if (LabelPrintMode == LabelPrintMode.Comment)
            {
                labelData.LabelAppendComment(this.Text, this.SpecimenType, this.SpecimenExtension);
            }
            else if (LabelPrintMode == LabelPrintMode.Aliquot)
            {
                if (priority == Priority.Routine)
                {
                    labelData.LabelAppendAliquotRoutine(this.Text, this.SpecimenType, this.SpecimenExtension);
                }
                else if (priority == Priority.Stat)
                {
                    labelData.LabelAppendAliquotStat(this.Text, this.SpecimenType, this.SpecimenExtension);
                }

            }
            else
            {
                throw new Exception("Unknown LabelPrintMode");
            }
        }
예제 #2
0
        /// <summary>
        /// Print collection, comment, and (collection or aliquot) labels
        /// </summary>
        private static void _printLabels(ImmutableOrderData immutableOrderData, string printer,
            SetupTableData setupTableData, Func<LabelData,LabelData> configureLabels)
        {
            //PrintDowntimeLabels
            var labelData = new LabelData(immutableOrderData.orderNumber, immutableOrderData.priority,
                immutableOrderData.mrn, immutableOrderData.lastName, immutableOrderData.firstName, immutableOrderData.ward);

               configureLabels(labelData).doPrint(printer, setupTableData);
        }