-
Notifications
You must be signed in to change notification settings - Fork 69
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OH2-389 | Provide operation context #477
OH2-389 | Provide operation context #477
Conversation
Are these breaking changes all intentional?
|
Should I make opeFor optional ? |
no, I'm asking if you agree with the reported changes. Since they break many API, how we should proceed? |
Yes, we have to open an issue to align the FE. Actually DTOs in the API aren't specific. Maybe later we should refactor the code and create DTO to return concise data requested by the API consumers. For example, take a look at this DTO which is returned every time we're retrieving admissions: {
"id": 12,
"admitted": 0,
"type": "N",
"ward": {
"code": "str",
"description": "string",
"telephone": "string",
"fax": "string",
"email": "string",
"beds": 0,
"nurs": 0,
"docs": 0,
"visitDuration": 0,
"lock": 0,
"opd": true,
"female": true,
"male": true,
"pharmacy": true
},
"patient": {
"code": 0,
"firstName": "Mario",
"secondName": "Rossi",
"name": "string",
"birthDate": "1979-05-01",
"age": 40,
"agetype": "null",
"sex": "M",
"address": "Via Roma, 12",
"city": "Verona",
"nextKin": "string",
"telephone": "+393456789012",
"note": "Test insert new patient",
"motherName": "Roberta",
"mother": "A",
"fatherName": "Giuseppe",
"father": "D",
"bloodType": "A+",
"hasInsurance": "N",
"parentTogether": "N",
"taxCode": "RSSMRA79E01L781N",
"lock": 0,
"blobPhoto": [
"string"
],
"hashCode": 0,
"allergies": "string",
"anamnesis": "string",
"status": "I",
"consensusFlag": true,
"consensusServiceFlag": true
},
"admDate": "string",
"admType": {
"code": "A",
"description": "AMBULANCE"
},
"diseaseIn": {
"code": "99",
"description": "string",
"diseaseType": {
"code": "st",
"description": "string"
},
"opdInclude": true,
"ipdInInclude": true,
"ipdOutInclude": true,
"hashCode": 0,
"lock": 0
},
"diseaseOut1": {
"code": "99",
"description": "string",
"diseaseType": {
"code": "st",
"description": "string"
},
"opdInclude": true,
"ipdInInclude": true,
"ipdOutInclude": true,
"hashCode": 0,
"lock": 0
},
"diseaseOut2": {
"code": "99",
"description": "string",
"diseaseType": {
"code": "st",
"description": "string"
},
"opdInclude": true,
"ipdInInclude": true,
"ipdOutInclude": true,
"hashCode": 0,
"lock": 0
},
"diseaseOut3": {
"code": "99",
"description": "string",
"diseaseType": {
"code": "st",
"description": "string"
},
"opdInclude": true,
"ipdInInclude": true,
"ipdOutInclude": true,
"hashCode": 0,
"lock": 0
},
"operation": {
"code": "string",
"description": "string",
"type": {
"code": "st",
"description": "string"
},
"opeFor": "opd_admission",
"major": 0,
"lock": 0
},
"opDate": "string",
"opResult": "N",
"disDate": "string",
"disType": {
"code": "SN",
"description": "SORTIE NORMALE"
},
"note": "string",
"transUnit": 0,
"visitDate": "string",
"pregTreatmentType": {
"code": "string",
"description": "string",
"hashCode": 0
},
"deliveryDate": "string",
"deliveryType": {
"code": "N",
"description": "ACCOUCHEMENT NORMAL"
},
"deliveryResult": {
"code": "M",
"description": "MORTALITÉ MATERNELLE"
},
"weight": 0,
"ctrlDate1": "2024-10-08T13:49:26.253Z",
"ctrlDate2": "2024-10-08T13:49:26.253Z",
"abortDate": "2024-10-08T13:49:26.253Z",
"userID": "string",
"hashCode": 0,
"lock": 0,
"deleted": "N",
"fhu": "string",
"yprog": 0
} We (FE) don't really need all those information every time we retrieve an admission. |
For these breaking changes you can just open a PR on the UI with same code (OH2-389) and needed changes For new DTOs I think it could be done later with dedicated issues. |
It's a refactoring that is not particulary related to OH2-389. IMHO the discussion about that should be moved into a new issue or in slack. |
Tests on develop are failing because this PR is not merged. Let's merge this PR and open an issue to align the FE |
Please @SilverD3 can you open the issue? |
See OH2-389
Paired with #1427