Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

catissuecoreopenspecimen/rest/ng/specimen/print-rules/name={ruleName}

or

catissuecoreopenspecimen/rest/ng/specimen/print-rules/{id}

Use this resource to update print rule in the caTissue openSpecimen application. Use HTTP PATCH method to call this API by passing the below details in JSON format.

 

Below are the attributes which need to be sent in the request body:

Parameter

Definition

specimenClass[Optional]

Class of the specimen. By default it will be 'Anyany'
Permissible Values: Molecularmolecular, fluid, Fluidcell, Celltissue, Tissueany

dataOnLabel

Information that needs to be included in the label based on the specimen class/type and label type

workstationIP [Optional]

IP address of the machine from where the print request will come and this decides to which printer the request has to be forwarded to. By default it will be 'Anyany'

It can be specified in wild card format like grouping

e.g

all IPs starting with 128 will have same rule

all IPs starting with 128.3. will have same rule

ruleNameName of the Print Ruleprint rule. Should be unique in system

printerName

Name of the printer where the request has to be forwarded to.

labelType

This could be Capcap+Slide slide or Sideslide. This parameter and the specimen type define the information that needs to go in the label. This will help user to configure based on label physical dimensions.

specimenType [Optional]

Type of the specimen . By default it will be 'Anyany'
Permissible Values: 'Anyany' or any specimen type of the class specified in same row

catissuecore

loginName

login name of user
domainNamedomain name of user
cpShortTitleCollection protocol short title

openspecimen/rest/ng/specimen/print-rules/name={ruleName}

or

catissuecoreopenspecimen/rest/ng/specimen/print-rules/{id}

Use this URL to patch print rule in caTissue openSpecimen application.


Result:

The response of this request will contains the details of the patched print rule.

Below is the example of the patch print rule:

URL

http://<host>:<port>/catissuecoreopenspecimen/rest/ng/specimen/print-rules/name={ruleName}

or

catissuecoreopenSpecimencore/rest/ng/specimen/print-rules/{ruleId}

MethodPATCH
Requestapplication/json
json

{

    "labelType" : "Capcap+Slideslide"

}

Response

{
id3
name"My PrintRule"
specimenClass"Fluidfluid"
specimenType"Anyany"
labelType"Capcap+Slideslide"
workstationIP"127.0.0.1"
dataOnLabel[2]
0:  "Specimen type"
1:  "Specimen Label"
-
printerName"TB2"
cpShortTitle"SCS_CP"
loginName
{
loginName"admin@admin.com"
domainName"catissue"
}
}

 

 

 

Error Cases :

code
Applies to
Status Message
200All resourcesPrint rule has been updated successfully
400All requestsInvalid parameters, e.g  duplicate Print print rule name, blank Print print rule name etc
401All requestsAuthorization failed, User user doesn’t have Authorityauthority
404All requestsPrint rule not found, Print print rule with given details not present in the system
500All requestsInternal server error, Encountered encountered server error while performing operations