public static Label GetMolecularLabel(LabelFormatEnum labelFormat, string masterAccessionNo, string patientFirstName, string patientLastName, string specimenDescription, YellowstonePathology.Business.PanelSet.Model.PanelSet panelSet, bool includeTestAbbreviation) { Label result = null; switch (labelFormat) { case LabelFormatEnum.DYMO: result = new MolecularLabelDymo(masterAccessionNo, patientFirstName, patientLastName, specimenDescription, panelSet, includeTestAbbreviation); break; case LabelFormatEnum.ZEBRA: result = new MolecularLabelZebra(masterAccessionNo, patientFirstName, patientLastName, specimenDescription, panelSet); break; } return result; }
public static Label GetMolecularLabel(LabelFormatEnum labelFormat, string masterAccessionNo, string patientFirstName, string patientLastName, string specimenDescription, YellowstonePathology.Business.PanelSet.Model.PanelSet panelSet, bool includeTestAbbreviation) { Label result = null; switch (labelFormat) { case LabelFormatEnum.DYMO: result = new MolecularLabelDymo(masterAccessionNo, patientFirstName, patientLastName, specimenDescription, panelSet, includeTestAbbreviation); break; case LabelFormatEnum.ZEBRA: result = new MolecularLabelZebra(masterAccessionNo, patientFirstName, patientLastName, specimenDescription, panelSet); break; } return(result); }
protected RestRequest createDownloadShipmentLabel(string id, LabelFormatEnum format, LabelTypeEnum type) { RestRequest request = new RestRequest($"/v1/shipments/{id}/label?format={format.ToString()}&type={type.ToString()}", Method.GET); return(request); }
public async Task <Result <LabelData> > DownloadShipmentLabelAsync(string shipmentId, LabelFormatEnum format = LabelFormatEnum.Pdf, LabelTypeEnum type = LabelTypeEnum.normal) { RestRequest request = createDownloadShipmentLabel(shipmentId, format, type); IRestResponse response = await RestClient.ExecuteTaskAsync(request); byte[] response2 = RestClient.DownloadData(request); File.WriteAllBytes(@"C:\\test.pdf", response2); return(new Result <LabelData>(response)); }
public byte[] DownloadShipmentLabel(string shipmentId, LabelFormatEnum format = LabelFormatEnum.Pdf, LabelTypeEnum type = LabelTypeEnum.normal) { RestRequest request = createDownloadShipmentLabel(shipmentId, format, type); return(RestClient.DownloadData(request)); }