Skip to content
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

add enhancements for pressure sore (push score) #999

Merged
merged 3 commits into from
Oct 15, 2022

Conversation

iamsdas
Copy link
Contributor

@iamsdas iamsdas commented Sep 5, 2022

Proposed Changes

  • add pressure_sore_enhanced field
  • create schema to validate the field
  • add save/update logic for push score calculation

fixes: #986
@coronasafe/code-reviewers

@iamsdas iamsdas marked this pull request as ready for review September 8, 2022 17:47
@iamsdas iamsdas requested a review from a team as a code owner September 8, 2022 17:47
@iamsdas
Copy link
Contributor Author

iamsdas commented Sep 8, 2022

Note: currently created a pressure_sore_enhance field as I'm not sure if it's alright to delete the pre-existing data in the pressure_sore field. (The previous schema only stored the region and scale of the entries.)

@iamsdas iamsdas requested a review from gigincg September 8, 2022 18:01
@gigincg
Copy link
Member

gigincg commented Sep 9, 2022

@iamsdas Staying inline with the EOD Discussion with @aparnacoronasafe let's migrate the existing data(0-5) itself, propotional to the PUSH score (0-17) using the following logic.

base = existing_simple_pressure_sore
push_score = (base/5)*17
pressure_sore = { push_score }

@sonarcloud
Copy link

sonarcloud bot commented Sep 9, 2022

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot E 1 Security Hotspot
Code Smell A 1 Code Smell

No Coverage information No Coverage information
0.0% 0.0% Duplication

@iamsdas
Copy link
Contributor Author

iamsdas commented Sep 9, 2022

Added migration to migrate the existing pressure_sore data from the old schema to the new one. Also, since we are able to migrate the older data we don't need to create a new pressure_sore_enhanced field anymore.

@vigneshhari
Copy link
Member

is #1016 a duplicate of this ?

@iamsdas
Copy link
Contributor Author

iamsdas commented Sep 10, 2022

is #1016 a duplicate of this ?

It seems like that PR is required for a different issue. The only part overlapping with that PR is the addition of the description field in the pressure_sore schema.

@Pragati1610
Copy link
Contributor

have resolved the overlap: removed the description field from pressure_sore schema

@sonarcloud
Copy link

sonarcloud bot commented Oct 15, 2022

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot E 1 Security Hotspot
Code Smell A 2 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@vigneshhari vigneshhari merged commit 7439e4b into coronasafe:master Oct 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Pressure Sore: Enhancement (PUSH score)
4 participants