1387: Skip a product lineItem
Test Case #:1387 | Test Case Name: Skip a product lineItem |
System: OpenLMIS | Subsystem: blue |
Test case designed by: Paulina Borowa | Design Date:10.01.2017 |
Short description: Description Same behavior for both Regular and Emergency R&R Also, this impacts printing create a new story Mary Jo Kochendorfer to clean up so that a user can either print all products or hide the skipped ones. This ticket is an API ticket for implementing the ability to skip product line items in the Requisition API. The corresponding UI task is OLMIS-1084 In Progress . Acceptance criteria for API part
|
|
Pre – conditions: |
Step | Action | Expected system response | Comment |
1 | Requisition Temp0ate with skipped part: { |
| |
2 | try to skipping/unskipping line item on requisition with status INITIATED and SUBMITTED In URL 10.222.17.205//api/requisitions/6167e65c-6f56-4aeb-bff5-fdfe84e01a21/?access_token=f3f194f8-e307-4add-809a-18efb286ffb0 Body: { "id": "6167e65c-6f56-4aeb-bff5-fdfe84e01a21", "createdDate": [ 2016, 5, 10, 15, 43, 16 ], "creatorId": null, "requisitionLineItems": [ { "id": "8c8026b8-0ae8-4adb-b2ca-bfb0dfb030a5", "orderableProduct": { "id": "d602d0c6-4052-456c-8ccd-61b4ad77bece", "productCode": "C100", "name": "Levora", "packSize": 84, "packRoundingThreshold": 42, "roundToZero": false, "programs": [ { "programId": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "productId": "d602d0c6-4052-456c-8ccd-61b4ad77bece", "productCategoryId": "15b8ef1f-a5d6-42dd-95bf-bb68a4504e82", "productCategoryDisplayName": "Oral Contraceptive", "productCategoryDisplayOrder": 6, "active": true, "fullSupply": true, "displayOrder": 1, "maxMonthsOfStock": 1000, "dosesPerMonth": 1, "pricePerPack": null } ], "dispensable": { "dispensingUnit": "10 tab strip" } }, "beginningBalance": 50, "totalReceivedQuantity": 0, "totalLossesAndAdjustments": 0, "stockOnHand": null, "requestedQuantity": 0, "totalConsumedQuantity": 0, "requestedQuantityExplanation": null, "remarks": null, "approvedQuantity": null, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped": true, "adjustedConsumption": null, "stockAdjustments": [] }, { "id": "552eb0f7-fc57-4916-bb54-0c3c9540420a", "orderableProduct": { "id": "23819693-0670-4c4b-b400-28e009b86b51", "productCode": "C200", "name": "Ortho-Novum", "packSize": 63, "packRoundingThreshold": 31, "roundToZero": false, "programs": [ { "programId": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "productId": "23819693-0670-4c4b-b400-28e009b86b51", "productCategoryId": "15b8ef1f-a5d6-42dd-95bf-bb68a4504e82", "productCategoryDisplayName": "Oral Contraceptive", "productCategoryDisplayOrder": 6, "active": true, "fullSupply": true, "displayOrder": 2, "maxMonthsOfStock": 1000, "dosesPerMonth": 1, "pricePerPack": "15.94" } ], "dispensable": { "dispensingUnit": "each" } }, "beginningBalance": 0, "totalReceivedQuantity": 0, "totalLossesAndAdjustments": 0, "stockOnHand": null, "requestedQuantity": 0, "totalConsumedQuantity": 0, "requestedQuantityExplanation": null, "remarks": null, "approvedQuantity": null, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped": true, "adjustedConsumption": null, "stockAdjustments": [] }, { "id": "bcbd9a7c-6068-40d9-90ab-cb090fd6ed8c", "orderableProduct": { "id": "bfde33c3-83f1-4feb-a27c-842852f66b71", "productCode": "C400", "name": "Male Condom", "packSize": 1, "packRoundingThreshold": 0, "roundToZero": false, "programs": [ { "programId": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "productId": "bfde33c3-83f1-4feb-a27c-842852f66b71", "productCategoryId": "3bfe0282-732b-4ce8-b4f9-aa7ffb297758", "productCategoryDisplayName": "Barrier Method", "productCategoryDisplayOrder": 7, "active": true, "fullSupply": true, "displayOrder": 3, "maxMonthsOfStock": 20, "dosesPerMonth": 1, "pricePerPack": "25.46" } ], "dispensable": { "dispensingUnit": "each" } }, "beginningBalance": 90, "totalReceivedQuantity": 0, "totalLossesAndAdjustments": 0, "stockOnHand": null, "requestedQuantity": 0, "totalConsumedQuantity": 0, "requestedQuantityExplanation": null, "remarks": null, "approvedQuantity": null, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped": false, "adjustedConsumption": null, "stockAdjustments": [] }, { "id": "502eb011-27bc-4f7f-bb1f-6425ae66a5d5", "orderableProduct": { "id": "880cf2eb-7b68-4450-a037-a0dec1a17987", "productCode": "C500", "name": "Implanon", "packSize": 1, "packRoundingThreshold": 0, "roundToZero": false, "programs": [ { "programId": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "productId": "880cf2eb-7b68-4450-a037-a0dec1a17987", "productCategoryId": "06606981-67cc-42d1-87ed-21f22fb0ea58", "productCategoryDisplayName": "Implantable Contraceptive", "productCategoryDisplayOrder": 8, "active": true, "fullSupply": false, "displayOrder": 4, "maxMonthsOfStock": 20, "dosesPerMonth": 1, "pricePerPack": "30.98" } ], "dispensable": { "dispensingUnit": "10 tab strip" } }, "beginningBalance": 0, "totalReceivedQuantity": 0, "totalLossesAndAdjustments": 0, "stockOnHand": null, "requestedQuantity": 0, "totalConsumedQuantity": 0, "requestedQuantityExplanation": null, "remarks": null, "approvedQuantity": null, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped":false, "adjustedConsumption": null, "stockAdjustments": [] }, { "id": "5b449a32-aedf-4a8b-a9d7-c3b665ad76e2", "orderableProduct": { "id": "7b9b66e0-f008-4c38-93ec-7a5f4868cca9", "productCode": "C600", "name": "Levonorgestrel ", "packSize": 1, "packRoundingThreshold": 0, "roundToZero": false, "programs": [ { "programId": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "productId": "7b9b66e0-f008-4c38-93ec-7a5f4868cca9", "productCategoryId": "06606981-67cc-42d1-87ed-21f22fb0ea58", "productCategoryDisplayName": "Implantable Contraceptive", "productCategoryDisplayOrder": 8, "active": true, "fullSupply": true, "displayOrder": 5, "maxMonthsOfStock": 20, "dosesPerMonth": 1, "pricePerPack": "5.10" } ], "dispensable": { "dispensingUnit": "10 tab strip" } }, "beginningBalance": 50, "totalReceivedQuantity": 0, "totalLossesAndAdjustments": 0, "stockOnHand": null, "requestedQuantity": 0, "totalConsumedQuantity": 0, "requestedQuantityExplanation": null, "remarks": null, "approvedQuantity": null, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped": true, "adjustedConsumption": null, "stockAdjustments": [] }, { "id": "89e46600-aa5a-4cc9-8bfd-67be8e907778", "orderableProduct": { "id": "7f7b83db-580d-4269-88d2-7f9c80a591a9", "productCode": "C300", "name": "Depo-Estradiol", "packSize": 5, "packRoundingThreshold": 2, "roundToZero": false, "programs": [ { "programId": "66032ea8-b69b-4102-a1eb-844e57143187", "productId": "7f7b83db-580d-4269-88d2-7f9c80a591a9", "productCategoryId": "74f39ab7-b5ce-4087-a6ea-65799a35e79b", "productCategoryDisplayName": "Injectable Hormonal Contraceptive", "productCategoryDisplayOrder": 9, "active": true, "fullSupply": true, "displayOrder": 6, "maxMonthsOfStock": 20, "dosesPerMonth": 1, "pricePerPack": "4.34" }, { "programId": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "productId": "7f7b83db-580d-4269-88d2-7f9c80a591a9", "productCategoryId": "74f39ab7-b5ce-4087-a6ea-65799a35e79b", "productCategoryDisplayName": "Injectable Hormonal Contraceptive", "productCategoryDisplayOrder": 9, "active": true, "fullSupply": false, "displayOrder": 6, "maxMonthsOfStock": 20, "dosesPerMonth": 1, "pricePerPack": "20.77" } ], "dispensable": { "dispensingUnit": "each" } }, "beginningBalance": 0, "totalReceivedQuantity": 0, "totalLossesAndAdjustments": 0, "stockOnHand": null, "requestedQuantity": 0, "totalConsumedQuantity": 0, "requestedQuantityExplanation": null, "remarks": null, "approvedQuantity": null, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped": false, "adjustedConsumption": null, "stockAdjustments": [] } ], "comments": [], "facility": { "id": "e6799d64-d10d-4011-b8c2-0e4d4a3f65ce", "code": "HC01", "name": "Comfort Health Clinic", "description": null, "active": true, "goLiveDate": null, "goDownDate": null, "comment": null, "enabled": true, "openLmisAccessible": true, "supportedPrograms": [ { "id": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "code": "PRG001", "name": "Family Planning", "description": null, "programActive": true, "periodsSkippable": true, "showNonFullSupplyTab": true, "supportActive": true, "supportStartDate": null }, { "id": "10845cb9-d365-4aaa-badd-b4fa39c6a26a", "code": "PRG002", "name": "Essential Meds", "description": null, "programActive": true, "periodsSkippable": false, "showNonFullSupplyTab": false, "supportActive": true, "supportStartDate": null } ], "geographicZone": { "id": "bf2b810b-cdbf-48b2-b569-149b3cf42387", "code": "M-So-Bal-Bal", "name": "Balaka", "level": { "id": "90e35999-a64f-4312-ba8f-bc13a1311c75", "code": "City", "name": null, "levelNumber": 4 }, "parent": null }, "operator": { "id": "9456c3e9-c4a6-4a28-9e08-47ceb16a4121", "code": "moh", "name": "Ministry of Health" }, "type": { "id": "ac1d268b-ce10-455f-bf87-9c667da8f060", "code": "health_center", "name": "Health Center", "description": null, "displayOrder": 1, "active": true } }, "program": { "id": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "code": "PRG001", "name": "Family Planning", "description": null, "active": true, "periodsSkippable": true, "showNonFullSupplyTab": true }, "processingPeriod": { "id": "c9287c65-67fa-4958-adb6-52069f2b1379", "processingSchedule": { "id": "9c15bd6e-3f6b-4b91-b53a-36c199d35eac", "code": "SCH001", "description": null, "modifiedDate": [ 2015, 12, 31, 23, 59, 59 ], "name": "Monthly" }, "name": "Apr2017", "description": null, "startDate": [ 2017, 4, 1 ], "endDate": [ 2017, 4, 30 ] }, "status": "INITIATED", "emergency": false, "supplyingFacility": "e6799d64-d10d-4011-b8c2-0e4d4a3f65ce", "supervisoryNode": null, "template": "5a268780-fafd-4243-9551-5c7daa824913" } | for requisition with INITIATED status: Status 200 OK for requisition with SUBMITTED status: Status 200 OK |
|
3 | Try to change value of skipped to true/false in requisition with status: APPROVE Body: { "id": "21d138bc-f2c2-4188-adf3-a3aae381abde", "createdDate": [ 2016, 5, 30, 17, 0, 56 ], "creatorId": null, "requisitionLineItems": [ { "id": "a6d8a940-4172-4fb9-9c5b-2ac238851dab", "orderableProduct": { "id": "2400e410-b8dd-4954-b1c0-80d8a8e785fc", "productCode": "C1", "name": "Acetylsalicylic Acid", "packSize": 16, "packRoundingThreshold": 8, "roundToZero": false, "programs": [ { "programId": "10845cb9-d365-4aaa-badd-b4fa39c6a26a", "productId": "2400e410-b8dd-4954-b1c0-80d8a8e785fc", "productCategoryId": "6805dd74-ec00-4697-9a5d-5b78414fcaf6", "productCategoryDisplayName": "Antibiotics", "productCategoryDisplayOrder": 1, "active": true, "fullSupply": true, "displayOrder": 1, "maxMonthsOfStock": 1000, "dosesPerMonth": 10, "pricePerPack": "3.16" } ], "dispensable": { "dispensingUnit": "10 tab strip" } }, "beginningBalance": 1000, "totalReceivedQuantity": 30000, "totalLossesAndAdjustments": null, "stockOnHand": 30000, "requestedQuantity": 35000, "totalConsumedQuantity": 31000, "requestedQuantityExplanation": null, "remarks": null, "approvedQuantity": 0, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped": null, "adjustedConsumption": null, "stockAdjustments": [] }, { "id": "7bfa442a-88c8-4004-917b-fe0d6c979591", "orderableProduct": { "id": "103396e1-f5e4-4754-bb7b-1c799097dfea", "productCode": "C2", "name": "Glibenclamide", "packSize": 40, "packRoundingThreshold": 20, "roundToZero": false, "programs": [ { "programId": "10845cb9-d365-4aaa-badd-b4fa39c6a26a", "productId": "103396e1-f5e4-4754-bb7b-1c799097dfea", "productCategoryId": "6805dd74-ec00-4697-9a5d-5b78414fcaf6", "productCategoryDisplayName": "Antibiotics", "productCategoryDisplayOrder": 1, "active": false, "fullSupply": true, "displayOrder": 2, "maxMonthsOfStock": 10, "dosesPerMonth": 3, "pricePerPack": "2.13" } ], "dispensable": { "dispensingUnit": "each" } }, "beginningBalance": 1000, "totalReceivedQuantity": 30000, "totalLossesAndAdjustments": null, "stockOnHand": 30000, "requestedQuantity": 35000, "totalConsumedQuantity": 31000, "requestedQuantityExplanation": null, "remarks": null, "approvedQuantity": 0, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped": true, "adjustedConsumption": null, "stockAdjustments": [] } ], "comments": [], "facility": { "id": "44a29ccb-ed55-4c26-9eca-7e5759269b25", "code": "FAC003", "name": "Facility Inactive Enabled", "description": null, "active": false, "goLiveDate": null, "goDownDate": null, "comment": null, "enabled": true, "openLmisAccessible": false, "supportedPrograms": [], "geographicZone": { "id": "0bbd69c1-e20f-48f5-aae4-26dcd8aa7602", "code": "Mal-So", "name": "Southern Region", "level": { "id": "9b497d87-cdd9-400e-bb04-fae0bf6a9491", "code": "Region", "name": null, "levelNumber": 2 }, "parent": null }, "operator": { "id": "1074353d-7364-4618-a127-708d7303a231", "code": "dwb", "name": "Doctors without Borders" }, "type": { "id": "663b1d34-cc17-4d60-9619-e553e45aa441", "code": "dist_hosp", "name": "District Hospital", "description": null, "displayOrder": 2, "active": true } }, "program": { "id": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "code": "PRG001", "name": "Family Planning", "description": null, "active": true, "periodsSkippable": true, "showNonFullSupplyTab": true }, "processingPeriod": { "id": "7880be4f-6582-472a-9ea5-a6baed71e6e5", "processingSchedule": { "id": "057921bd-1841-4748-8523-dbe5ebb58368", "code": "SCH002", "description": null, "modifiedDate": null, "name": "Quarterly" }, "name": "Q4", "description": null, "startDate": [ 2017, 10, 1 ], "endDate": [ 2017, 12, 31 ] }, "status": "APPROVED", "emergency": false, "supplyingFacility": "e6799d64-d10d-4011-b8c2-0e4d4a3f65ce", "supervisoryNode": "fb38bd1c-beeb-4527-8345-900900329c10", "template": "5a268780-fafd-4243-9551-5c7daa824913" } | Status 500 Internal Server Error
|
the same behavior is with requisition with status SKIPPED and RELEASED |
4 | Try to change value of skipped from null to true/false in requisition with status: AUTHORIZED "id": "8c7f1a6d-d139-483a-ad60-4288016f3d23", "createdDate": [ 2016, 4, 30, 16, 21, 33 ], "creatorId": null, "requisitionLineItems": [ { "id": "ac49b686-c74c-4684-a635-d777ee298cd2", "orderableProduct": { "id": "103396e1-f5e4-4754-bb7b-1c799097dfea", "productCode": "C2", "name": "Glibenclamide", "packSize": 40, "packRoundingThreshold": 20, "roundToZero": false, "programs": [ { "programId": "10845cb9-d365-4aaa-badd-b4fa39c6a26a", "productId": "103396e1-f5e4-4754-bb7b-1c799097dfea", "productCategoryId": "6805dd74-ec00-4697-9a5d-5b78414fcaf6", "productCategoryDisplayName": "Antibiotics", "productCategoryDisplayOrder": 1, "active": false, "fullSupply": true, "displayOrder": 2, "maxMonthsOfStock": 10, "dosesPerMonth": 3, "pricePerPack": "2.13" } ], "dispensable": { "dispensingUnit": "each" } }, "beginningBalance": 50, "totalReceivedQuantity": 250, "totalLossesAndAdjustments": null, "stockOnHand": null, "requestedQuantity": 250, "totalConsumedQuantity": 300, "requestedQuantityExplanation": "Some test explanation", "remarks": null, "approvedQuantity": null, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped": true, "adjustedConsumption": null, "stockAdjustments": [] }, { "id": "1d0d970f-c619-40db-ae81-6d8990505502", "orderableProduct": { "id": "103396e1-f5e4-4754-bb7b-1c799097dfea", "productCode": "C2", "name": "Glibenclamide", "packSize": 40, "packRoundingThreshold": 20, "roundToZero": false, "programs": [ { "programId": "10845cb9-d365-4aaa-badd-b4fa39c6a26a", "productId": "103396e1-f5e4-4754-bb7b-1c799097dfea", "productCategoryId": "6805dd74-ec00-4697-9a5d-5b78414fcaf6", "productCategoryDisplayName": "Antibiotics", "productCategoryDisplayOrder": 1, "active": false, "fullSupply": true, "displayOrder": 2, "maxMonthsOfStock": 10, "dosesPerMonth": 3, "pricePerPack": "2.13" } ], "dispensable": { "dispensingUnit": "each" } }, "beginningBalance": 1000, "totalReceivedQuantity": 30000, "totalLossesAndAdjustments": null, "stockOnHand": null, "requestedQuantity": 35000, "totalConsumedQuantity": 31000, "requestedQuantityExplanation": "Some test explanation", "remarks": null, "approvedQuantity": null, "totalStockoutDays": 0, "total": null, "packsToShip": null, "pricePerPack": null, "numberOfNewPatientsAdded": null, "totalCost": null, "skipped": false, "adjustedConsumption": null, "stockAdjustments": [] } ], "comments": [], "facility": { "id": "13037147-1769-4735-90a7-b9b310d128b8", "code": "DH01", "name": "Balaka District Hospital", "description": null, "active": true, "goLiveDate": null, "goDownDate": null, "comment": null, "enabled": true, "openLmisAccessible": true, "supportedPrograms": [ { "id": "dce17f2e-af3e-40ad-8e00-3496adef44c3", "code": "PRG001", "name": "Family Planning", "description": null, "programActive": true, "periodsSkippable": true, "showNonFullSupplyTab": true, "supportActive": true, "supportStartDate": null }, { "id": "10845cb9-d365-4aaa-badd-b4fa39c6a26a", "code": "PRG002", "name": "Essential Meds", "description": null, "programActive": true, "periodsSkippable": false, "showNonFullSupplyTab": false, "supportActive": true, "supportStartDate": null } ], "geographicZone": { "id": "50293982-602a-4046-ac29-d7f83a8a13e9", "code": "M-So-Bal", "name": "Balaka District", "level": { "id": "93c05138-4550-4461-9e8a-79d5f050c223", "code": "District", "name": null, "levelNumber": 3 }, "parent": null }, "operator": { "id": "9456c3e9-c4a6-4a28-9e08-47ceb16a4121", "code": "moh", "name": "Ministry of Health" }, "type": { "id": "663b1d34-cc17-4d60-9619-e553e45aa441", "code": "dist_hosp", "name": "District Hospital", "description": null, "displayOrder": 2, "active": true } }, "program": { "id": "10845cb9-d365-4aaa-badd-b4fa39c6a26a", "code": "PRG002", "name": "Essential Meds", "description": null, "active": true, "periodsSkippable": false, "showNonFullSupplyTab": null }, "processingPeriod": { "id": "f419bcd8-ac7a-4b75-8c84-c065ef437938", "processingSchedule": { "id": "057921bd-1841-4748-8523-dbe5ebb58368", "code": "SCH002", "description": null, "modifiedDate": null, "name": "Quarterly" }, "name": "Q1", "description": null, "startDate": [ 2017, 1, 1 ], "endDate": [ 2017, 3, 31 ] }, "status": "AUTHORIZED", "emergency": false, "supplyingFacility": "ab95f1cf-ae8d-4888-ba9d-05141d3f50de", "supervisoryNode": "fb38bd1c-beeb-4527-8345-900900329c10", "template": "4b30f6c9-b84b-4f17-8173-852101a5ea29" } | Status: 200 Ok but skipped value didn't change it's still null
|
|
5 | Check if skipped value can besomething beyond boolean | "status": 400, "error": "Bad Request",
| |
6 | Check if:
|
|
|
7 |
| ||
8 |
|
OpenLMIS: the global initiative for powerful LMIS software