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

#1702 - Allow institution to specify custom regulatory body #1763

Merged

Conversation

sh16011993
Copy link
Collaborator

@sh16011993 sh16011993 commented Feb 27, 2023

  • Updated the institutionprofilecreation.json form to add Other as a value to the Institution regulating body dropdown and the Other Regulating Body text field.

image

  • Updated the Create Institution API to persist the changes to the database.
  • Added the other_regulating_body column to the database and created the appropriate database migration scripts along with the required SQL script to add the other_regulating_body column and also the SQL script to remove the column if the migration needs to be reverted.

image

  • Updated the institutionprofile.json form to display Other regulating body field in the Institution profile on the AEST portal.

image

  • Updated the Modify Institution API to persist the changes if the user updates the institution via the Manage Institution section on the UI.

Updating the field:
image

After the update:
image

Worked on displaying other regulating institution in the Institution Profile
Finally worked on displaying other regulating institution in the aest portal institution profile and then updating it in the update institution section.
…y_custom_regulatory_body' into 1702_allow_institution_to_specify_custom_regulatory_body
Removed my changes related to prettier from .eslintrc.js which I mistakenly committed previously
@sh16011993 sh16011993 added Content Tasks related to UIUX content Web Portal SIMS-Api SIMS-Api DB DB migration involved labels Feb 27, 2023
Copy link
Contributor

@ann-aot ann-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please add description and UI screenshots

-- Add other_regulating_body column to institutions table
ALTER TABLE sims.institutions ADD COLUMN IF NOT EXISTS other_regulating_body VARCHAR(100);

COMMENT ON COLUMN sims.institutions.other_regulating_body IS 'Allows the user to enter the description if the option other is selected from the regulating body dropdown';
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add a period at the end of the sentence.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks. Will do.

Copy link
Collaborator

@andrewsignori-aot andrewsignori-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice and great first PR. @ann-aot and @dheepak-aot covered pretty much everything. I will be waiting for the changes to review again.

Copy link
Collaborator

@andrepestana-aot andrepestana-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job @sh16011993 . The other devs already addressed the issues. One thing I noticed: please let the person who commented to resolve the conversation.

@sh16011993
Copy link
Collaborator Author

sh16011993 commented Feb 28, 2023

Great job @sh16011993 . The other devs already addressed the issues. One thing I noticed: please let the person who commented to resolve the conversation.

Actually I was talking to @ann-aot at the time I resolved the specific conversation with her. We discussed on the call and then resolved it.

@sh16011993
Copy link
Collaborator Author

Nice and great first PR. @ann-aot and @dheepak-aot covered pretty much everything. I will be waiting for the changes to review again.

@andrewsignori-aot I have updated the code with the review comments.

@@ -102,6 +108,9 @@ export class InstitutionProfileAPIInDTO extends InstitutionContactAPIInDTO {
website: string;
@IsNotEmpty()
regulatingBody: string;
@ValidateIf((e) => e.regulatingBody === "other")
@IsNotEmpty()
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same max length validation needs to added here as well.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I apologize, I missed it.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No problem.

@Column({
name: "regulating_body",
})
regulatingBody: string;

/**
* Other regulating body
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Period missing in the comment. Also please try to use the same comment used for the column.

image

@dheepak-aot
Copy link
Collaborator

Thanks for doing the changes. Added 2 more comments.

Copy link
Collaborator

@dheepak-aot dheepak-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing the changes @sh16011993. Nice beginning.

Copy link
Collaborator

@andrepestana-aot andrepestana-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Collaborator

@andrewsignori-aot andrewsignori-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing the changes. Please take a look on the last minor comments.

@sonarqubecloud
Copy link

sonarqubecloud bot commented Mar 1, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.0% 0.0% Duplication

@github-actions
Copy link

github-actions bot commented Mar 1, 2023

Backend Unit Tests Coverage Report

Totals Coverage
Statements: 17.67% ( 1882 / 10651 )
Methods: 7.66% ( 106 / 1384 )
Lines: 20.45% ( 1657 / 8103 )
Branches: 10.22% ( 119 / 1164 )

@github-actions
Copy link

github-actions bot commented Mar 1, 2023

E2E Workflow Workers Coverage Report

Totals Coverage
Statements: 37.88% ( 225 / 594 )
Methods: 22.89% ( 19 / 83 )
Lines: 45.5% ( 202 / 444 )
Branches: 5.97% ( 4 / 67 )

@github-actions
Copy link

github-actions bot commented Mar 1, 2023

E2E Queue Consumers Coverage Report

Totals Coverage
Statements: 57.1% ( 354 / 620 )
Methods: 43.24% ( 32 / 74 )
Lines: 61.1% ( 322 / 527 )
Branches: 0% ( 0 / 19 )

@github-actions
Copy link

github-actions bot commented Mar 1, 2023

E2E SIMS API Coverage Report

Totals Coverage
Statements: 43.84% ( 3526 / 8043 )
Methods: 28.25% ( 280 / 991 )
Lines: 50.61% ( 3099 / 6123 )
Branches: 15.82% ( 147 / 929 )

Copy link
Collaborator

@andrewsignori-aot andrewsignori-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing the changes, it looks good 👍

Copy link
Contributor

@ann-aot ann-aot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good start and good work @sh16011993 👍 Thanks for doing the changes

@sh16011993 sh16011993 self-assigned this Mar 1, 2023
@sh16011993 sh16011993 merged commit 262bb4f into main Mar 1, 2023
@sh16011993 sh16011993 temporarily deployed to DEV March 1, 2023 18:44 — with GitHub Actions Inactive
@sh16011993 sh16011993 temporarily deployed to DEV March 1, 2023 18:44 — with GitHub Actions Inactive
@sh16011993 sh16011993 deleted the 1702_allow_institution_to_specify_custom_regulatory_body branch March 1, 2023 18:44
@sh16011993 sh16011993 temporarily deployed to DEV March 1, 2023 18:57 — with GitHub Actions Inactive
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Content Tasks related to UIUX content DB DB migration involved SIMS-Api SIMS-Api
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants