Implement CRUD endpoints for uniaxial test data
Implement POST/api/rafs-ddms/Uniaxial/{record_id}/data is implemented and available on Swagger
- record_id is the SamplesAnalysis WPC which was created previously
- User should be able to fill the SamplesAnalysis report with measurements taken in this analysis
- Successful response (200 status code) should update SamplesAnalysis record and include DDMSDatasets array with GET endpoint to the linked bulk data of Uniaxial
- Validation cases should be covered with appropriate status codes
- Request & response structure should correspond to populated JSON
Implement GET/api/rafs-ddms/Uniaxial/{record_id}/data endpoint is implemented and available on Swagger
- record_id is the SamplesAnalysis WPC
- User should be able to retrieve bulk data of Uniaxial using new endpoint
- Successful response (200 status code) should retrieve all existing Uniaxial Measurements (bulk data) linked to specified record id (SamplesAnalysis WPC)
- Validation cases should be covered with appropriate status codes
- Structure of request and response should correspond to populated JSON content schema
Build schema and register based on the following example:
Content Example
"SampleAnalysisID": "^[\\w\\-\\.]+:work-product-component\\-\\-SampleAnalysis:UniaxialTest123",
"data": [
{
"SampleID": "^[\\w\\-\\.]+:master-data\\-\\-SampleAnalysis:Uniaxial75FR",
"SampleOrientation": "Vertical",
"LabSampleIdentifier": "75FR",
"Remarks": "Successfully Checked",
"DepletionCondition": "True",
"Lithology": "Interbedded",
"Length": {
"Value": 1.93,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:in"
},
"Diameter": {
"Value": 1.00,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:in"
},
"Density": {
"Value": 2.03,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:g%2Fcm3"
},
"BulkCompressibility": {
"Value": 0.000000835,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:1%2Fpsi"
},
"PoreVolumeCompressibility": {
"Value": 0.00000280,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:1%2Fpsi"
}
},
{
"SampleID": "^[\\w\\-\\.]+:master-data\\-\\-Sample:Uniaxial76FR",
"SampleOrientation": "Vertical",
"LabSampleIdentifier": "76FR",
"Remarks": "Successfully Checked",
"DepletionCondition": "Effective",
"Lithology": "Interbedded",
"Length": {
"Value": 2.20,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:in"
},
"Diameter": {
"Value": 1.00,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:in"
},
"Density": {
"Value": 2.05,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:g%2Fcm3"
},
"BulkCompressibility": {
"Value": 0.000000893,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:1%2Fpsi"
},
"PoreVolumeCompressibility": {
"Value": 0.00000310,
"UnitOfMeasure": "opendes:reference-data--UnitOfMeasure:1%2Fpsi"
}
}
]
Edited by Mykhailo Buriak