965: Configure order file template
Test Case #:965 | Test Case Name:Configure order file template |
System: OpenLMIS | Subsystem: requisition |
Test case designed by: Paulina Borowa | Design Date:15.09.2016 |
Short description: As an implementor, I want to configure the order file template so that my order files are generated with my desired columns and formats to enable transfer of data via an FTP. |
|
Pre – conditions: |
Step
Action | Expected system response | Comment | |
1 | Create requisitionLine. In Url: Method: Post Example Body: { { "id": "27d954cb-c79e-49ce-936c-00d222553979", "product":{"id": "1752b457-0a4b-4de0-bf94-5a6a8002427e"}, "stockInHand": 10, "beginningBalance": 5, "totalReceivedQuantity": 5, "requestedQuantity": 15, "totalConsumedQuantity": 4, "approvedQuantity": 12, "requisition": { "id": "76b01375-97d7-472f-9bca-03e49e4db5ff" } } } | Status 201 Created | |
2 | Create Requisition. In Url: Method: Post Example Body: { "id": "10000000-0000-0000-0000-000000000001", "createdDate": "2016-03-30T15:43:16", "facility": { "id": "3a5d1b1c-e1eb-452d-85e6-c657e942aa67" }, "program": { "id": "7df82e47-577e-4a9f-81ad-8f0f285aef60" }, "processingPeriod": { "id": "c2252ba4-ebfc-4a6d-859f-db25cdfaa4bd" }, "status": "INITIATED", "emergency": "false", "requisitionLines": [ { "id": "27d954cb-c79e-49ce-936c-00d222553979", "product":{"id": "1752b457-0a4b-4de0-bf94-5a6a8002427e"}, "stockInHand": 10, "beginningBalance": 5, "totalReceivedQuantity": 5, "requestedQuantity": 15, "totalConsumedQuantity": 4, "approvedQuantity": 12 }] } | Status 201 Created
| Create requisition with requisitionLine |
2 | Create Order. In Url: Method: Post Example Body: { "id": "00000000-0000-0000-0000-000000001111", "requisition": { "id": "76b01375-97d7-472f-9bca-03e49e4db5ff" }, "createdDate": "2016-04-30T16:45:22", "createdBy": { "id": "c9f76777-ac6d-4207-bdd7-dbbd1ad92b14" }, "program": { "id": "44af344c-d73f-48a5-aaab-59a017b026aa" }, "requestingFacility": { "id": "b6b79a14-ae2a-4f39-b8ed-3a1be7be0d88" }, "receivingFacility": { "id": "3bb20e25-3cab-43c2-8203-f91285b8b7b9" }, "supplyingFacility": { "id": "30829158-3769-4cc5-b611-ccfcc5136b5a" }, "orderCode": "ORD1122", "status": "RECEIVED", "quotedCost": 100000 } | Status 201 created | With previously created requisition |
3 | Edit orderFileTemplates data. In Url: http://localhost:8080/api/orderFileTemplates/?access_token=1781f31a-3a75-4667-9b9f-08cd90e6bd09 Method Post Example Body: { | Status 200 OK | Check acceptance criteria: * all column headers can be defined (renamed) by the implementor * Facility code column populates the facility code from the requisition information * Product Code column populates the product name from requisition information/reference data * Product Name column populates the product name from requisition information/reference data * Approved quantity column populates based on the approved quanitity column in the requisition * Period information populates based on the requisition * Period format is defined by the implementor, choices include * Order date populates based on the date converted * Order date format is defined by the implementor, choices include, same as period format * Implementor can define the Order file prefix |
4 | To see if the changes save, check endpoint: Method Get | Status 200 OK For example:
|
OpenLMIS: the global initiative for powerful LMIS software