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

Feat 143 fix escrow decimal #299

Open
wants to merge 13 commits into
base: main
Choose a base branch
from

Conversation

hamede-abdulgafur
Copy link
Collaborator

@hamede-abdulgafur hamede-abdulgafur commented Jun 2, 2024

Bug Description
The bug involved incorrect decimal formatting for credits in escrow within the wallet section of the application. Instead of displaying the correct value with two decimal places (e.g., 90.00), the application was showing the credits in escrow as whole numbers without decimals (e.g., 9000).

Root Cause
The issue was caused by the escrowBalance value being handled as a whole number (in cents) without converting it to a formatted decimal value (dollars).

code changes
this.updateState({
credits,
creditsLoaded: loaded,
balance: balance / 100, // Correctly format the balance
escrowCredits,
escrowBalance: escrowBalance / 100, // Correctly format the escrow balance
});

wengf2086 and others added 13 commits July 1, 2023 12:43
…ck-from-gitignore

Removed package-lock.json from .gitignore
This PR adds a file environments.org.ts file to the .gitignore file.
This file will be referenced with the new way to execute the application
locally when someone is a part of the organization. We do this by adding
another configuration to the angular.json file for an "org" environment.
In addition, two new scripts were added to the package.json file to work
with this.
Updated readme to include steps on how to configure Firebase, launch
PostgreSQL in a container, and start both client and server.
These updates allow for us to use the npm run deploy:test to deploy both
the api and the ui to the test envrionment. I also updated the emailing
and other services to treat test like prod and allow for notifications
to be sent.

---------
Updates as suggested via codelyzer and depcheck to fix issue with npm
restore failing.

---------

Co-authored-by: Quinn Heffern <[email protected]>
…T#132)

I added a pgpass and servers.json file to the .docker folder to be used
in the docker-compose.yml file. These allow us to setup the pgadmin
container to automatically add an "Involvemint Local" server with access
to the postgres container so that new engineers do not have to worry
about adding the server or authenticating with the local involvemin
database in order to view it from pgadmin.

Updated the init.sql scrip to successfully create the involvemin
database when first running the docker compose up command. The previous
script failed due to the "if not exists" part.

Updated the build process locally to use the local flag instead of the
org flag. This is more logical from an engineers perspective. It means
that the environment file will be environment.local.ts and the commands
to run the server and client are npm run start:server:local and npm run
start:client:local respectively.

I updated the readme to reflect the changes made in this branch.
Updated the docker compose to use 5433 as the locally accessible port in
order to not clash with any locally running postgres instances outside
of the docker container. We were running into issues where if someone
already has a local postgres server running, the application was
connecting to it instead of the docker container. This is fine as long
as the developer knows where to look, but for getting DFG running as
quick as possible this eliminates a bit of confusion.
Updates to use a default address when running locally instead of
depending on access to the geolocation api. The default address ensures
that the default latitude and longitude match the addresses.

Adds docker container that host the firebase emulator suite so that we
can run the application without using a gcp storage bucket.
@fogunsan fogunsan self-requested a review June 7, 2024 02:39
Copy link
Collaborator

@fogunsan fogunsan left a comment

Choose a reason for hiding this comment

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

Most of the commits made are not your own. You can create another branch checkout from dfg/sum24-involvement, and then add your changes to that branch. Adjust your PR to merge onto dfg/sum24-involvemint not main. Also upload a video of you testing the code.

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.

7 participants