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

BUG: Institution: 0 is removed from the Exceptional costs field and an information message is displayed after a new offering is created #3693

Closed
astridSABC opened this issue Sep 12, 2024 · 0 comments
Assignees
Labels
Bug Something isn't working Institution Institution Features

Comments

@astridSABC
Copy link
Collaborator

astridSABC commented Sep 12, 2024

Describe the Bug
When an offering is created with "0" Exceptional costs, when you go back into the offering (edit), the "0" is removed from the exceptional cost field and an information message is displayed below the study costs.

Institution user would not know that their is an information message

Repeat for "Tuition", "Mandatory Fees", and "Book and Supplies"

Expected Behaviour
"0" in Exceptional cost field was saved
No information message is displayed

"0" in Tuition" cost field was saved
"0" in "Mandatory Fees" cost field was saved
"0" in "Book and Supplies" cost field was saved

image.png

Actual Behaviour
0 is removed from the Exceptional costs field and an information message is displayed below the study costs.

Adding a "0" back in the Exceptional costs field immediately clears the warning message.

Repeat for "Tuition", "Mandatory Fees", and "Book and Supplies"

Note: Adding a "1" or other numbers greater (>) than "0" (up to 999,999) does not provide the information message.

image.png

image.png

** Steps To Reproduce**

Preconditions
BC Public institution is created
Program that allows PT is created

  1. Go to a test BC Public institution to the program that was created above
  2. Click on 'Add offering.'
  3. Add any name
  4. Add any year
  5. Offered: PT
  6. Course load: 40
  7. Delivered: onsite
  8. WIL: no
  9. Study dates: 16 weeks (e.g. Sept. 4, 2024 - Dec. 20, 2024)
  10. Study breaks: no
  11. Study costs (enter generic study costs that have been used throughout assessment testing)
    Tuition: 10,000
    Books and Supplies: 1,500
    Miscellaneous costs: 2,500
    Exceptional costs: 0 (double check that the 0 is there)
  12. Study availability: yes
  13. Declaration: Select checkbox
  14. Watch the exceptional cost field
  15. Click "Validate" button
  16. Click "Add offering now" button
  17. Offering created success message is displayed
  18. Offering is displayed in the study period offerings table with Approved status
  19. Click "Edit" link to edit the offering
  20. Scroll down the page
  21. Review below the study costs section
  22. Repeat with a FT offering
@astridSABC astridSABC added Bug Something isn't working Institution Institution Features Business Items under Business Consideration labels Sep 12, 2024
@CarlyCotton CarlyCotton self-assigned this Sep 17, 2024
@CarlyCotton CarlyCotton added Dev & Architecture Development and Architecture and removed Business Items under Business Consideration labels Sep 26, 2024
@andrewsignori-aot andrewsignori-aot removed the Dev & Architecture Development and Architecture label Oct 15, 2024
@sh16011993 sh16011993 self-assigned this Nov 26, 2024
github-merge-queue bot pushed a commit that referenced this issue Nov 27, 2024
### As a part of this PR, the following bug was fixed: 

**Bug:** 0 is removed from the Exceptional costs field and the warning
banner as shown below shows up. Likewise, for the other 3 cost fields.


![image](https://github.com/user-attachments/assets/24dfb56d-006a-4030-92be-6498f91bbaf0)

**Fix:** `numericTransformer` on receiving the value of 0 from the
database was returning it as `null` rather than the numeric value `0`.
Updated the code to fix it and return `0` instead of `null`.


https://github.com/user-attachments/assets/c8831e66-1dbe-45a6-8a46-61f2357a6b8f
@sh16011993 sh16011993 reopened this Nov 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working Institution Institution Features
Projects
None yet
Development

No branches or pull requests

5 participants